IDEMPOTENCY_KEY_REQUIRED: the Idempotency-Key header is missing
Checked on 2026-11-25 against the SharkPOS API code · Markdown
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.
Related
Integrating receipts or invoices? Try it in the sandbox, without touching the real SII.
Try it today in the sandbox
Get a sandbox API key: a test company with certificate and folios already loaded and a simulated SII. When you are ready, each RUT costs CLP 5,990 a month (VAT included) with 20,000 documents a month.