Error Codes

All errors return JSON with error (string) and code (integer).

HTTP Status Codes

CodeMeaningWhen
200OKSuccessful request
400Bad RequestInvalid parameters (wrong enum value, invalid combination)
401UnauthorizedMissing/invalid Authorization: Bearer <key> header
500Internal Server ErrorDatabase query failure or unexpected server error
503Service UnavailableOne or more backends down (only from /ready)

Error Response Format

{"error": "Human-readable description", "code": 400}

Specific 400 Errors

EndpointTriggerError Message
/v1/wallets/:addr/performanceInvalid window"Invalid window. Use 1d, 7d, or 30d"
/v1/wallets/:addr/positionsInvalid status"Invalid status. Use open, closed, or all"
/v1/leaderboardInvalid window"Invalid window. Use 1d, 7d, or 30d"
/v1/leaderboardInvalid sort"Invalid sort. Use pnl_usd, roi, or win_rate"
/v1/tokens/:mint/ohlcvInvalid timeframe/view"Invalid timeframe/view combination. Use timeframe=1s|1m|5m|15m|1h and view=full|filtered"

WebSocket Errors

Sent as {"op": "error", "message": "..."}. Do not close the connection.

TriggerMessage
Malformed JSON"Invalid message format"
Too many subscriptions"Subscription limit reached (max 50)"
Invalid channel name"Invalid channel '...'. Expected: token:<mint>:trades|ticks|ohlcv:<view>:<tf> or wallet:<address>:pnl|positions"
Invalid OHLCV view"Invalid OHLCV view '...'. Use 'full' or 'filtered'"
Invalid OHLCV timeframe"Invalid OHLCV timeframe '...'. Use 1s, 1m, 5m, 15m, or 1h"
Empty key"Empty key in channel"
Invalid key chars"Invalid characters in key '...'"
Key too long"Key too long (max 64 chars)"