> The index of all pages is at https://docs.afffast.com/llms.txt.

# idempotency_key_invalid

The Idempotency-Key header is not valid. Use 1 to 256 printable characters.

HTTP status: **400**. Error type: `idempotency_error`.

The Idempotency-Key header is not valid. Use 1 to 256 printable characters.

## Example

```json
{
  "error": {
    "type": "idempotency_error",
    "code": "idempotency_key_invalid",
    "message": "The Idempotency-Key header is not valid. Use 1 to 256 printable characters.",
    "param": "Idempotency-Key",
    "doc_url": "https://docs.afffast.com/errors/idempotency-key-invalid",
    "request_id": "req_3kQ9x7WmZpL2vNd8TfYb4A"
  }
}
```

## Causes

- The `Idempotency-Key` header is empty, longer than 256 characters, or it has characters that cannot be printed.

## How to fix

- Send a key of 1 to 256 printable characters. A UUID is a good key. See [Idempotency](https://docs.afffast.com/docs/idempotency.md).
