# IDEMPOTENCY_KEY_REQUIRED: the Idempotency-Key header is missing

> Every issuance in production requires the Idempotency-Key header. It prevents a retry after a network drop from duplicating the sale with the SII.

Source: https://api.sharkpos.cl/en/errors/idempotency-key-required/

Checked on 2026-11-25 against the SharkPOS API code · [Markdown](/en/errors/idempotency-key-required.md)
`IDEMPOTENCY_KEY_REQUIRED` · HTTP 400
Message you may see:
- `Falta el encabezado Idempotency-Key (hasta 128 caracteres). (The Idempotency-Key header is missing, up to 128 characters.)`
- `Idempotency-Key header is required.`

## What it means
Every issuance in production requires the `Idempotency-Key` header. It is what prevents a retry after a network drop from duplicating the sale with the SII (Chile's tax authority).

## Why it happens
- The HTTP client does not send the header.
- A proxy or framework drops it.

## How to fix it
- Add `Idempotency-Key: <stable sale id>` (8 to 128 characters) to every issuance.
- Use the sale id, not a new UUID per attempt.

**Should you retry?** Yes, after adding the header.
All API errors are JSON: `{"status": "error", "code": "...", "message": "...", "solution": "..."}`. The `code` is stable; `message` and `solution` are in Spanish. Full table in the [guide for agents](/en/docs/agents.md).

## Related
- [IDEMPOTENCY_CONFLICT: Idempotency-Key already used with another body](/en/errors/idempotency-conflict/)

Integrating receipts or invoices? Try it in the [sandbox](/sandbox/), without touching the real SII.
