Errors

All errors return JSON with the same envelope.

Envelope

json
{
  "error": {
    "status": 404,
    "message": "contract not found"
  }
}

Status codes

StatusMeaningCommon causes
400Bad requestMissing required query param, invalid JSON body, invalid window value
401UnauthenticatedMissing API key, revoked key, malformed prefix
403ForbiddenPlan doesn't allow this endpoint; key lacks the required scope
404Not foundUnknown contract id, ticker, or signal
429Rate limitedExceeded per-key sliding window; back off until X-RateLimit-Reset
500Server errorBug on our side; retry once and report if it persists

Recommended client behaviour

  • 4xx: surface the message verbatim — they're written to be human-readable.
  • 429: retry-after using X-RateLimit-Reset; consider exponential backoff if multiple in a row.
  • 5xx: retry up to 3 times with exponential backoff (1s, 2s, 4s).