The Gero Nexus API uses standard HTTP status codes and returns detailed error information to help you diagnose and handle issues gracefully.Documentation Index
Fetch the complete documentation index at: https://nexus.gerowallet.io/docs/llms.txt
Use this file to discover all available pages before exploring further.
Error Response Format
All errors return a consistent JSON structure:| Field | Type | Description |
|---|---|---|
error | string | HTTP error type (e.g., “Bad Request”, “Not Found”) |
message | string | Human-readable description of what went wrong |
code | string | Machine-readable error code for programmatic handling |
details | object | Additional context about the error (optional) |
HTTP Status Codes
Success Codes
| Code | Status | Description |
|---|---|---|
200 | OK | Request successful |
201 | Created | Resource created successfully |
202 | Accepted | Request accepted for processing |
204 | No Content | Request successful, no content to return |
Client Error Codes (4xx)
400 Bad Request
400 Bad Request
The request was malformed or contains invalid parameters.Common causes:
- Missing required parameters
- Invalid parameter format
- Invalid JSON in request body
- Value out of allowed range
401 Unauthorized
401 Unauthorized
403 Forbidden
403 Forbidden
The authenticated user lacks permission for this action.Common causes:
- Account lacks required role
- Endpoint restricted to specific plans
- Attempting to access another user’s resources
404 Not Found
404 Not Found
The requested resource does not exist.Common causes:
- Invalid resource ID or hash
- Resource has been deleted
- Typo in the endpoint URL
- Transaction not yet confirmed on-chain
422 Unprocessable Entity
422 Unprocessable Entity
The request was valid but cannot be processed.Common causes:
- Transaction validation failed
- Insufficient funds for transaction
- UTXO already spent
- Invalid transaction structure
429 Too Many Requests
429 Too Many Requests
Server Error Codes (5xx)
500 Internal Server Error
500 Internal Server Error
An unexpected error occurred on the server.Solution: Retry the request. If the problem persists, contact support with the
request_id.502 Bad Gateway
502 Bad Gateway
Error communicating with upstream service.Solution: Check provider health and retry after a brief delay.
503 Service Unavailable
503 Service Unavailable
504 Gateway Timeout
504 Gateway Timeout
Request timed out waiting for upstream service.Solution: Retry the request. Consider using pagination for large queries.
Common Error Codes
| Code | Description |
|---|---|
INVALID_TOKEN | JWT token is invalid or expired |
INVALID_ADDRESS | Cardano address format is invalid |
INVALID_HASH | Transaction or block hash is invalid |
RESOURCE_NOT_FOUND | Requested resource does not exist |
RATE_LIMIT_EXCEEDED | Too many requests |
TX_SUBMIT_FAILED | Transaction submission failed |
PROVIDER_ERROR | Upstream data provider error |
VALIDATION_ERROR | Request validation failed |
Error Handling Examples
JavaScript/TypeScript
Python
Best Practices
Always Check Status
Never assume a request succeeded. Always check the HTTP status code and handle errors appropriately.
Use Error Codes
Use the
code field for programmatic error handling rather than parsing error messages.Implement Retry Logic
For transient errors (5xx, 429), implement retry with exponential backoff.
Log Request IDs
Log the
request_id from error responses to help support diagnose issues.Retry Strategy
Implement exponential backoff for retryable errors:Next Steps
Rate Limits
Understand rate limiting and quotas
Pagination
Working with paginated responses
Authentication
Learn about API authentication
API Reference
Explore all available endpoints