Answer · Errors · Debugging
Common odds API error codes
Answer: 401 invalid_key, 403 plan_lacks_ws (Free/Hobby on /v1/stream), 403 sport_not_in_plan, 429 rate/connection limits. WS close 4001 revoked, 4002 no subscribe in 30 s, 4008 slow consumer, 1001 server restart. Catalogue: errors.
Quick fixes#
| Code | Where | Fix |
|---|---|---|
400 invalid_filter | REST, WS error frame | Check sport and market names |
401 missing_key / invalid_key | REST, WS upgrade | Send a valid ps_live_ key |
403 plan_lacks_ws | WS upgrade | Upgrade to Builder |
403 sport_not_in_plan | REST (WS: error frame) | Pick sports in the dashboard or upgrade |
403 plan_lacks_history | /v1/closing | Builder or Pro |
plan_lacks_raw | WS error frame | format: "raw" needs Pro |
429 rate_limited | REST | Wait Retry-After seconds |
429 daily_quota | REST (Free) | Wait for 00:00 UTC or upgrade |
429 connection_limit | WS upgrade | Close a connection (Builder 3, Pro 10) |
close 4002 | WS | Send subscribe within 30 s |
close 4008 | WS | Read faster or subscribe to less |
close 4001 | WS | Key revoked: load a new key |
close 1001 | WS | Server restart: reconnect with backoff |
Trial CTA#
Builder (€99/mo) for WebSocket and closing history. 3-day trial; card required, charged after day 3 unless cancelled. Free REST: signup. Related: answers hub, docs.
Related: curl OpenAPI recipes, Why /v1/stream returns 403.
Questions people ask#
Does 403 close the socket?#
Upgrade rejection can be HTTP before upgrade; in-band error frames may not close the socket — read errors.
Where is the full list?#
Is this educational content for adults?#
Yes (18+).