Question
Idempotency‑Key header size limits in Ory Kratos self‑service flows
Kavi Lane
0 reputation · 29 Apr 2022, 07:10 UTC
41.1K views0
Idempotency‑Key header size limits in Ory Kratos self‑service flows
Determine the maximum permissible length and character set for the Idempotency‑Key header that Ory Kratos accepts to guarantee that retries do not create duplicate flow records.
The key is stored in a database column with a unique constraint; the column type defined in the Kratos schema (e.g., VARCHAR(255) or TEXT) influences acceptance. Kratos may reject oversized headers with an HTTP error or may truncate silently, which could affect idempotency guarantees.
- What is the exact maximum length (in bytes) of the Idempotency‑Key header that Kratos will accept without truncation or error?
- Does Kratos return a specific HTTP status code (e.g., 400 Bad Request) when the header exceeds that limit, or does it silently truncate the value?
- If the header is truncated, does the truncation preserve uniqueness sufficiently to prevent duplicate writes, or could it cause collisions leading to duplicate flow rows?