When it fires
The server did not finish handling the request within its 30-second processing budget. This response is produced by the API’s framework layer, so its body differs slightly from catalogue errors:type is about:blank and title is "Request Timeout". Branch on code (REQUEST_TIMEOUT) or the 504 status, never on title.
Why it happens
- An unusually slow dependency (database contention or a blockchain RPC latency spike).
- A request that asks for too much in one call.
- Network degradation between you and the API (rare).
How to fix
- Retry once with backoff. Most timeouts are transient. Retry writes with the same
Idempotency-Key, because the original may still have completed. See Idempotency. - If one endpoint times out consistently, narrow the request: use smaller
limitvalues and fetch one resource at a time. - For long-running operations, use webhooks rather than waiting on a response.
- The TypeScript SDK raises this as
KashServerErrorand retries it automatically.