Skip to Main Content

Error Code Reference

Common HTTP error codes returned by the Shoonya API — what each means and how to resolve it.

Overview

The table below lists the common HTTP status codes you may receive while calling the Shoonya API, along with the recommended resolution for each.

Purpose

Use this as the single lookup table for HTTP-level error handling (retries, re-auth, escalation) across every integration — link to a specific row instead of duplicating error explanations on each endpoint page.

Reference table

CodeError DescriptionResolution
400Missing or bad request parameters or values.Validate the payload against the endpoint's parameter table — check for missing required fields or incorrect types/values.
403Session expired or invalidated. Must relogin.Re-authenticate via the login/OAuth flow and obtain a fresh session token; do not retry the same request with the old token.
404Requested resource was not found.Confirm the endpoint path and any identifiers used (order ID, symbol, token, etc.) are correct.
405Request method (GET, POST, etc.) is not allowed on the requested endpoint.Check the endpoint's documented HTTP method and correct the client call.
410The requested resource is gone permanently.Stop calling this endpoint/resource; check the changelog for its replacement.
429Too many requests to the API (rate limiting).Back off per the Rate Limits page and retry with exponential backoff and jitter.
500Something unexpected went wrong.Retry with backoff; if persistent, capture the request/response and escalate to support.
502The backend OMS is down and the API is unable to communicate with it.Please check the host or WebSocket URL you're connecting to, and confirm you're going through the OAuth login flow correctly before retrying — a 502 here often traces back to a misconfigured host/socket endpoint or an invalid/incomplete auth handshake rather than a transient outage.
503Service unavailable; the API is down.Retry with backoff; check the status page before escalating.
504Gateway timeout; the API is unreachable.Retry with backoff. For order placement/modification calls, reconcile via a status GET before retrying, to avoid duplicate orders.