The cache headers can only narrow what your organization set: a request cannot keep an answer longer, or accept a looser match, than the cache settings allow. In the same way,
x-alt-disable-content-logging can only turn content logging off.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Headers you can send with a request to the AI Gateway to use a saved prompt, steer the cache, keep content out of logs or set your own request reference.
| Header | Value | What it does |
|---|---|---|
x-request-id | Any text | Your own reference for the request. Altrum uses it instead of making one, returns it, and shows it in the request log. |
x-alt-prompt-id | A prompt id | Puts a saved prompt before your messages. |
x-alt-prompt-version | A whole number, such as 2 | The prompt version to use. Without it, the latest version. |
x-alt-cache-key | Any text | Keeps this request’s cached answers apart from others, for example per customer. |
x-alt-cache-ttl | 30s, 5m, 1h, or seconds | Keeps the answer for less time than your cache setting. |
x-alt-cache-threshold | 0 to 1 | Asks for a closer match than your cache setting. |
x-alt-cache-type | direct or semantic | direct matches word for word only, semantic by meaning only. |
x-alt-cache-no-store | true | Serves from the cache when it can, but does not store this answer. |
x-alt-disable-content-logging | true | Keeps this request’s prompt and reply out of the request log, even when your organization keeps content. |
x-alt-direct-key | true | Sends your own provider key. See Authentication. |
x-alt-disable-content-logging can only turn content logging off.
curl https://api.altrum.ai/v1/chat/completions \
-H "Authorization: Bearer $ALTRUM_VIRTUAL_KEY" \
-H "Content-Type: application/json" \
-H "x-request-id: order-4512-summary" \
-H "x-alt-prompt-id: support-reply" \
-H "x-alt-cache-key: customer-881" \
-d '{"model": "openai/gpt-4o-mini", "messages": [{"role": "user", "content": "Where is my order?"}]}'