The Ruddr API uses conventional HTTP response codes to indicate the success or failure of an API request.
In general, status codes in the 2xx
range indicate success, codes in the 4xx
range indicate an error that failed given the information provided, and codes in the 5xx
range indicate an error with Ruddr's servers.
Some common status codes include:
Status Code | Name | Description |
---|---|---|
200 | OK | Everything worked as expected. |
204 | No Content | Everything worked as expected, but there is no content to return. Often the case with delete requests. |
400 | Bad Request | The request was unacceptable due to an issue with the request format or data. |
401 | Unauthorized | The API key is missing or invalid. |
404 | Not Found | The resource or endpoint does not exist. |
405 | Method Not Allowed | The endpoint URL exists, but does not support the requested operation. |
409 | Conflict | A resource was already found with the provided identifying information. |
429 | Too Many Requests | Too many requests hit the API too quickly. See more information. |
500 | Internal Server Error | Something went wrong on Ruddr's end. |
The error should be accompanied by a JSON object body with more information about the error. For example:
{
"status": 400,
"message": "Parameter 'id' is not a valid UUID."
}