Skip to main content
All errors follow a consistent envelope format.

Error response shape

{
  "error": {
    "code": "not_found",
    "message": "Signal 'sig_xyz' not found",
    "status": 404
  }
}
FieldTypeDescription
codestringMachine-readable error code
messagestringHuman-readable description
statusintegerHTTP status code

Error codes

StatusCodeDescription
400bad_requestInvalid request parameters
401unauthorizedInvalid or missing API key
403forbiddenInsufficient permissions
404not_foundResource not found
409conflictResource already exists (e.g. duplicate API key)
422Request validation error (FastAPI)
429rate_limit_exceededRate limit exceeded (check Retry-After header)

Handling errors

from gildea_sdk import Gildea, RateLimitError, APIError

client = Gildea()
try:
    client.signals.list(q="AI")
except RateLimitError as e:
    time.sleep(e.retry_after or 60)
except APIError as e:
    print(f"Error ({e.status}): {e}")