Getting Started

Errors

Errors use standard HTTP status codes and always share the same JSON shape.

Error format

Every error response has an error object with the HTTPstatus and a human readable message.

Status codes

StatusMeaning
200Success.
201API key created.
400Invalid request: unknown parameter, or a value out of range.
401The X-API-Key header is missing, or the key is invalid or revoked.
404The item or route does not exist, or no item matches the filters of /random.
500Unexpected server error.

Examples

Missing API key · 401

GET /api/v1/characters
{
  "error": {
    "status": 401,
    "message": "Missing API key. Send it in the X-API-Key header"
  }
}

Unknown parameter · 400

GET /api/v1/characters?elemnt=pyro
{
  "error": {
    "status": 400,
    "message": "Invalid query parameter(s): elemnt. Allowed: name, rarity, element, weaponType, region, gender, bodyType, releaseVersion, localSpecialty, ascensionStat, material, limit, offset, sort"
  }
}

Invalid value · 400

GET /api/v1/characters?limit=500
{
  "error": {
    "status": 400,
    "message": "\"limit\" must be an integer between 1 and 100"
  }
}

Item not found · 404

GET /api/v1/characters/paimon
{
  "error": {
    "status": 404,
    "message": "characters/paimon not found"
  }
}