Resources
Errors
Error envelopes and error codes.
Alpha Version
The Ostium Builder Service is in Alpha. API endpoints, specifications, and builder URLs may change without notice. Use with caution in production environments.
HTTP Error Envelope
| Field | Type | Required | Description |
|---|---|---|---|
error | string | Yes | Human-readable error message. |
code | number | Yes | HTTP status code. |
errorCode | string | Yes | Machine-readable error code. |
details | object | No | Extra context (e.g., validation errors). |
Example:
{
"error": "Validation failed: Price must be a positive number string",
"code": 400,
"errorCode": "VALIDATION_ERROR",
"details": {
"validationErrors": {
"open.p": ["Price must be a positive number string"]
}
}
}Validation Errors
Validation errors include a details.validationErrors object keyed by field
path.
WebSocket Error Envelope
WebSocket errors are returned inside the message envelope under error.
| Field | Type | Required | Description |
|---|---|---|---|
message | string | Yes | Human-readable error message. |
code | number | Yes | HTTP-style status code. |
errorCode | string | Yes | Machine-readable error code. |
Example:
{
"id": "client-1",
"ok": false,
"error": {
"message": "Invalid JSON payload",
"code": 400,
"errorCode": "INVALID_REQUEST"
}
}Error Codes
VALIDATION_ERRORINVALID_REQUESTINVALID_ACTIONINVALID_ADDRESSNOT_FOUNDUNAUTHORIZEDRATE_LIMIT_EXCEEDEDINTERNAL_ERRORSERVICE_UNAVAILABLE