Skip to main content

Client options

apiKey
string
Secret API key. Falls back to process.env.CESTO_API_KEY. Required.
timeout
number
default:"60000"
Per-request timeout in milliseconds.
maxRetries
number
default:"2"
Max automatic retries on transient failures (408, 409, 429, 5xx, network errors, timeouts).
fetch
typeof fetch
Custom fetch implementation (e.g. undici). Defaults to the global fetch.

Per-request options

Every method accepts an options object as its last argument to override transport behavior for a single call:
timeout
number
Override the client timeout for this request.
maxRetries
number
Override retries for this request (e.g. 0 to disable).
signal
AbortSignal
Cancel the request; composed with the internal timeout.