Public War Rock Stats API / Öffentliche War Rock Stats API

08/25/2013 02:39 wa-sta#1
Hallo,

hier eine Kleinigkeit die ihr für euren Clan benutzen könnt:

[Only registered and activated users can see links. Click Here To Register...]

Quote:
How to use?
[Only registered and activated users can see links. Click Here To Register...]
//YOUR_API_KEY = The API Key you got to access the API
//NICKNAME = Nickname to search for

How to get the API Key?
[Only registered and activated users can see links. Click Here To Register...]

What is returned?
On success
Example:
40061|68|162695|110233|Adorables|0|DE|0|sunshine|

String PROFILE URL to wa-sta.net (Format: [Only registered and activated users can see links. Click Here To Register...])
| (Seperator)
Integer Level (Format: 0)
| (Seperator)
Integer Kills (Format: 0)
| (Seperator)
Integer Deaths (Format: 0)
| (Seperator)
String Clanname (Format: Stringname)
| (Seperator)
Integer Premiumstatus (0: Free2play| 1: Bronce Premium| 2: Silver Premium| 3: Gold Premium)
| (Seperator)
String Region (Format: 2-Digit Country Code ISO 3166-1 alpha-2 / 3-Digit Country Code ISO 3166-1 alpha-3 / Countryname)
| (Seperator)
Integer Onlinestatus (Format: 0: Offline or Privacystatus: Hidden / 1: Online)
| (Seperator)
String Nickname (Format: Nickname)
| (Seperator)

On failure
Error Codes:
"" (Empty String: Nickname not found)
-1 : Access not allowed, API Key is wrong/missing
-2 : No Nickname was sent/specified
-3 : Malicious Request
Damit könnt ihr z.B. auf eurer Clanseite einbinden, ob eure Member online sind, die Statistiken von ihnen etc.

Die Daten sind soweit aufbereitet dass sie recht unkompliziert einzubinden sind. Um Missbrauch vorzubeugen braucht ihr einen API-Key, den ihr (natürlich kostenlos) bei mir erhalten könnt. Entweder direkt hier per PM, oder unter: [Only registered and activated users can see links. Click Here To Register...]

Vielleicht kann es der ein oder andere gebrauchen :)
Es ist für die Nutzung auch noch ein kurzes PHP Beispiel (mit Kommentaren) auf der API-Seite angegeben. Falls ihr Hilfe braucht, meldet euch bei mir, ich helfe euch gerne :)

---------- English -------

[Only registered and activated users can see links. Click Here To Register...]

See the Quote above, it is a publicly available API to get statistics for War Rock to use on your clan homepage or whatever you feel like it could fit :)

To access the API you need a API-Key. Just send me a PM and i will generate you one :)

If you need a example of how it could work, check the api-site and read the well documented php example.

If you need any help just contact me
08/25/2013 02:50 ~iToXiiC#2
How to use with PHP:


$ctx = stream_context_create(array(
'http' => array(
'timeout' => 4
)
)
);

$api_key = "key"; // API-Key for wa-sta.net API
$str = @file_get_contents("http://wa-sta.net/other/api/api.php?api_key=$api_key&nickname=$nickname", 0, $ctx);

$splitted = explode('|', $str);

$wasta = $splitted[0];
$level = $splitted[1];
$kills = $splitted[2];
$deahts = $splitted[3];
$clan = $splitted[4];
$premium = $splitted[5];
$country = $splitted[6];
$online = $splitted[7];
$nickname = $splitted[8];
08/25/2013 14:53 wa-sta#3
Ihr könnt jetzt auch die Formatierung der Daten bestimmen. Siehe dazu unten. Unterstützt sind json/xml/(default)

Addition:

You can now also specify the output format of the data:
&format=(NULL) => seperated by |
&format=json => returns in json format
&format=xml => returns in xml
08/25/2013 22:52 theitfan1337#4
Generell mal einen Daumen hoch für dich, Scub4r. Finde es cool wie viel Mühe du dir mit deiner Seite gibst, vor allem da Nexon offensichtlich kein Interesse zeigt, etwas in die Richtung ops zurückzubringen.
08/26/2013 23:55 wa-sta#5
Quote:
Originally Posted by Baeloth View Post
Generell mal einen Daumen hoch für dich, Scub4r. Finde es cool wie viel Mühe du dir mit deiner Seite gibst, vor allem da Nexon offensichtlich kein Interesse zeigt, etwas in die Richtung ops zurückzubringen.
Danke sehr :)
08/27/2013 12:15 xxfabbelxx#6
Quote:
Originally Posted by Baeloth View Post
Generell mal einen Daumen hoch für dich, Scub4r. Finde es cool wie viel Mühe du dir mit deiner Seite gibst, vor allem da Nexon offensichtlich kein Interesse zeigt, etwas in die Richtung ops zurückzubringen.
Kann ich nur zustimmen. Aber sag mal yvonnchen sie soll Net so mit der MP5 drucken ._.
08/27/2013 17:48 AndakowaUser#7
coole sache

mal 'ne andere frage:
machst du das alles alleine (ein mann armee) oder besteht wa-sta aus einem team?
08/27/2013 20:00 wa-sta#8
Quote:
Originally Posted by AndakowaUser View Post
coole sache

mal 'ne andere frage:
machst du das alles alleine (ein mann armee) oder besteht wa-sta aus einem team?
Programmiertechnisch im Hintergrund alleine - Grafisch hab ich zum Glück Unterstützung
09/04/2013 16:35 wa-sta#9
Here are some undocumented features:

Quote:
- You can specify "wastaid" instead of "nickname" to have nickchanges reflected as you use the wasta id to query data
- The following data is returned meanwhile:

URL TO Wa-Sta.net profile
|
Level
|
Kills
|
Deaths
|
Clanname
|
Premium (0: F2P / 1: Bronze / 2: Silver / 3: Gold)
|
Region 2-digit ISO Code
|
Onlinestatus (0: Offline /1: Online
|
Nickname
|
Server (-1: Offline / 1: World / 2: West / 3: East)
|
Channel (-999: Offline / -1: Channel Select / 0: Itemshop / 1: CQC / 2: BG / 3: AI)
|
Room (-999: Offline / else: Roomnumber
|
Sorry for not updating that long
10/15/2013 18:06 wa-sta#10
Von einem anderen User erstellt mit Hilfe der Wa-Sta API:

WASTA App für Android:
[Only registered and activated users can see links. Click Here To Register...]

Created by another user using the Wa-Sta API:

WASTA app for android
[Only registered and activated users can see links. Click Here To Register...]
10/16/2013 03:16 UndercoverUser#11
Mir wäre da eine Mobile WASTA Seite lieber :-)
10/16/2013 04:11 wa-sta#12
Quote:
Originally Posted by UndercoverUser View Post
Mir wäre da eine Mobile WASTA Seite lieber :-)
Versprechen kann ich nichts, höchstens erst ab Mitte November hätte ich dafür zeit...