Overview
The BlackBox API follows standard HTTP status codes to indicate the success or failure of API requests. Understanding these error responses helps diagnose issues and implement appropriate error-handling strategies.
Errors may occur due to:
- Invalid request parameters (e.g., missing required fields or incorrect data types).
- Authentication failures (e.g., invalid credentials or insufficient access rights).
- Rate limits (e.g., exceeding API call limits).
- Server-side issues (e.g., service unavailability or internal errors).
When an error occurs, the API returns a status code, an error message, and sometimes additional details about the failure. The response is formatted in JSON.
Response Status Codes
| Error Code | Description |
200 | OK: The request succeeded. |
400 | Bad Request: The request has invalid syntax for the given content type. |
401 | Unauthorized: Required authentication by the authentication header has failed or is missing. |
402 | The Optimize Limit has been exceeded. |
403 | Forbidden: Incorrect permissions for the operation. |
404 | Not Found: The action or resource was not found. |
405 | Not Allowed: Not supported by the resource. |
409 | Conflict: A resource with the same criteria already exists. |
410 | Gone: The requested content has been permanently deleted from the server. |
422 | Unprocessable Entity: The input was parsed correctly, but was invalid for another reason. |
429 | Too Many Requests: The API rate limit has been exceeded. |
500 | Internal Server Error: An unexpected condition was encountered. |
503 | Service Unavailable: A part of the service, or a third party that is required to complete the operation, is unavailable. |