>>

Error Response

All the possible error responses that are returned from Eludris HTTP microservices.

>>

Rate Limited

The error when a client is rate limited.

FieldTypeDescription
type“RATE_LIMITED”The type of this ErrorResponse variant.
statusu16The HTTP status of the error.
messageStringA brief explanation of the error.
try_afterNumberThe amount of milliseconds you’re still rate limited for.
>>

Example

{
  "type": "RATE_LIMITED",
  "status": 429,
  "message": "You have been rate limited",
  "try_after": 1234
}
>>

Validation

The error when a request a client sends is incorrect and fails validation.

FieldTypeDescription
type“VALIDATION”The type of this ErrorResponse variant.
statusu16The HTTP status of the error.
messageStringA brief explanation of the error.
value_nameStringThe name of the value that failed validation.
infoStringExtra information about what went wrong.
>>

Example

{
  "type": "VALIDATION",
  "status": 422,
  "message": "Invalid request",
  "value_name": "author",
  "info": "author name is a bit too cringe"
}
>>

Not Found

The error when a client requests a resource that does not exist.

FieldTypeDescription
type“NOT_FOUND”The type of this ErrorResponse variant.
statusu16The HTTP status of the error.
messageStringA brief explanation of the error.
>>

Example

{
  "type": "NOT_FOUND",
  "status": 404,
  "message": "The requested resource could not be found"
}
>>

Server

The error when the server fails to process a request.

Getting this error means that it’s the server’s fault and not the client that the request failed.

FieldTypeDescription
type“SERVER”The type of this ErrorResponse variant.
statusu16The HTTP status of the error.
messageStringA brief explanation of the error.
infoStringExtra information about what went wrong.
>>

Example

{
  "type": "SERVER",
  "status": 500,
  "message": "Server encountered an unexpected error",
  "info": "Server got stabbed 28 times"
}