docs

Limits

Size, count and request-shape limits for the decision API, and what happens when you go over.

Requests over a limit are refused, never silently cut short. The refusal is an error that names the limit.

Context

LimitValueIf exceeded
Tokens for the state plus the longest question (per question row)32,768400 max_tokens_exceeded
Tokens for the state plus all questions (per request)65,536400 max_tokens_exceeded
Number of questions (System One)No fixed maximum. Only the token limits apply.
Number of questions (/v1/decisions)1 to 400400

The limits are published as "32k" and "64k". These are the defaults; GET /v1/models with the Sieve-Extras: true header reports each model's limits under context. Image tokens count toward both limits.

Long context. Send TypeSafe-Danger-Zone-Long-Context: true only for a model whose Sieve-Extras: true catalogue entry exposes a context.long_context value. The backend uses that model-specific value for both limits; it does not promise one global long-context number. A model without long-context support continues to use its normal limits.

Options and levels

LimitValue
choice options1 to 255 (422 outside this range)
score levels1 to 10 (422 outside this range)
/v1/decisions choices2 to 255, each unique
/v1/decisions score levels2 to 10

Request body

RuleLimitIf broken
Body size32 MiB (33,554,432 bytes), counted both as received and after decompression413
Text encodingUTF-8 JSON with no byte-order mark400
NestingAt most 64 levels of objects and arrays inside each of state, each question's instructions, and each question's criteria400
NumbersFinite only. NaN, Infinity, -Infinity and values that overflow (such as 1e400) are refused400
Content-EncodingOne layer of gzip, x-gzip or zstd. A zstd window may be up to 8 MiB415 (400 if the data is malformed)
Content-Typeapplication/json, or multipart/form-data when you send images415
Unknown top-level fields on System OneIgnored, not echoed

Nesting is counted inside each field, not over the whole body. A state that is 64 arrays deep is valid.

Compression

Send Content-Encoding: zstd or gzip for large bodies. The TypeSafe SDKs compress any body of 1 KiB or more with zstd by default.

  • Python SDK: zstd is built in on Python 3.14. On 3.13 and older install the extra, pip install "typesafe-sdk[zstd]". Without it the SDK sends plain bodies.
  • JavaScript SDK: zstd needs Node.js 22.15 or newer. Older runtimes send plain bodies.
  • LiteLLM proxy cannot read zstd request bodies and answers 500. Behind LiteLLM, turn compression off: TypeSafeClient(compression=False) in Python, new TypeSafeClient({ compression: false }) in JavaScript.

Images (not at launch)

Images and box questions need a vision model and the header TypeSafe-Danger-Zone-Images: true. Until then, requests with images or box return 400. The limits are:

LimitValueIf exceeded
FormatPNG or JPEG, still images only400
File size16 MiB per image, after base64 decoding413
Width and height280 to 1568 px eachToo small 400, too large 413
Total pixels78,400 to 2,458,624Too small 400, too large 413
All images together32 MiB after processing413
Images per request on /v1/decisions128400

Rate limits

Limits are set per organisation and per model, in requests per second and input tokens per second. A key can have tighter limits than its organisation, never looser. There can also be a daily input-token limit (reset at 00:00 UTC) and a cap on requests in flight. New organisations start with a lower daily allowance that grows with steady use.

When you hit a limit the API returns 429: wait for retry-after and try again. A single request that can never fit returns 400 max_tokens_exceeded instead: for example, more compute (state tokens counted once per question, plus question tokens) than your configured per-request cap, more input tokens than a per-second burst or daily limit, or more questions than your configured maximum. Split such a request. Overload returns 529 (System One) or 503 (/v1/decisions). See Errors for each body. The console's Limits page shows the limits that apply to you.

Default numbers are not published yet

The console's Limits page shows the exact limits for your organisation and lets you request an increase. In code, read the x-ratelimit-* headers on each response and honour retry-after. See Errors.

Next steps

Last updated