As of right now, the Wynncraft API only provides a service to you, via the use of a GET request. Responses are available in JSON.
The base url for the API is https://api.wynncraft.com/
. All data is received via JSON.
{% method %}
We expose different versions of the API, though, some versions may be unavailable at the time you are reading this.
Version | Status |
---|---|
2 | Available |
1 (legacy) | Available |
{% sample lang="v2" %}
To access version 2 of the api, the base url will be:
GET https://api.wynncraft.com/v2/
Unless otherwise specified, unknown requests will return a status 404 error:
{
"status": 404
}
See Response codes for more information on response and error codes.
{% sample lang="v1" %}
To access version 1 of the api (legacy), the base url will be:
GET https://api-legacy.wynncraft.com/public_api.php?
Unless otherwise specified, unknown requests will return a status 404 error:
{
"status": 404
}
See Errors for more information on response and error codes.
{% endmethod %} {% method %}
Each response will have a generic field or set of fields pertaining to the request.
See Errors for more information on error codes and messages.
{% sample lang="v2" %}
{
"kind": String,
"code": Number,
"message": String,
"timestamp": Number,
"version": String,
"data": [Object]
// ...
}
Name | Type | Description |
---|---|---|
kind | String | wynncraft/resource/type |
code | Number | See Errors |
message | String | See Errors |
timestamp | Number | Time request was made |
version | String | Current Version (Semver) |
data | Object Array | Response data |
{% sample lang="v1" %}
{
// ...
"request": {
"timestamp": Number,
"version": Number
}
}
Name | Type | Description |
---|---|---|
timestamp | Number | Time request was made |
version | Number | Current Version (Optional) |
{% endmethod %} |