Error Handling
https://api.cerulea.app/v1
All errors are returned with a consistent structure. The
error.code
field is stable across API versions and safe to branch on.
Error Response Format
JSON
{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Request body failed validation",
"details": [
{ "field": "consensus", "issue": "must be one of: poa, pos, dpos, pbft, raft" }
],
"requestId": "req_01HXYZ456"
}
}Common Error Codes
| HTTP Code | Error Code | Description |
|---|---|---|
| BAD_REQUEST | Invalid request parameters | |
| UNAUTHORIZED | Invalid or missing authentication | |
| FORBIDDEN | Insufficient permissions for the requested operation | |
| NOT_FOUND | Resource not found | |
| VALIDATION_ERROR | Request body failed validation | |
| RATE_LIMITED | Rate limit exceeded, retry after the indicated delay | |
| INTERNAL_ERROR | Internal server error |