Skip to content

Commit 9d84806

Browse files
[AIG]headers glossary initial documentation (#18250)
* headers glossary initial documentation * minor changes * Update glossary.mdx * added links * added links * added header hierachy docs * spelling * added links * Moved hierarchy info --------- Co-authored-by: Kathy <[email protected]>
1 parent 6152af3 commit 9d84806

File tree

2 files changed

+74
-0
lines changed

2 files changed

+74
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
title: Glossary
3+
pcx_content_type: glossary
4+
---
5+
6+
import { Glossary } from "~/components";
7+
8+
AI Gateway supports a variety of headers to help you configure, customize, and manage your API requests. This page provides a complete list of all supported headers, along with a short description
9+
10+
<Glossary product="ai-gateway" />
11+
12+
## Configuration hierarchy
13+
14+
Settings in AI Gateway can be configured at three levels: **Provider**, **Request**, and **Gateway**. Since the same settings can be configured in multiple locations, the following hierarchy determines which value is applied:
15+
16+
1. **Provider-level headers**:
17+
Relevant only when using the [Universal Endpoint](/ai-gateway/providers/universal/), these headers take precedence over all other configurations.
18+
2. **Request-level headers**:
19+
Apply if no provider-level headers are set.
20+
3. **Gateway-level settings**:
21+
Act as the default if no headers are set at the provider or request levels.
22+
23+
This hierarchy ensures consistent behavior, prioritizing the most specific configurations. Use provider-level and request-level headers for more fine-tuned control, and gateway settings for general defaults.
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
productName: AI Gateway
3+
entries:
4+
- term: cf-aig-event-id
5+
general_definition: |-
6+
[cf-aig-event-id](/ai-gateway/evaluations/add-human-feedback-api/#3-retrieve-the-cf-aig-log-id) is a unique identifier for an event, used to trace specific events through the system.
7+
8+
- term: cf-aig-step
9+
general_definition: |-
10+
[cf-aig-step](/ai-gateway/configuration/fallbacks/#response-headercf-aig-step) identifies the processing step in the AI Gateway flow for better tracking and debugging.
11+
12+
- term: cf-aig-log-id
13+
general_definition: |-
14+
The [cf-aig-log-id](/ai-gateway/evaluations/add-human-feedback-api/#3-retrieve-the-cf-aig-log-id) is a unique identifier for the specific log entry to which you want to add feedback.
15+
16+
- term: cf-aig-collect-log
17+
general_definition: |-
18+
The [cf-aig-collect-log](/ai-gateway/observability/logging/#collect-logs-cf-aig-collect-log) header allows you to bypass the default log setting for the gateway.
19+
20+
- term: cf-aig-custom-cost
21+
general_definition: |-
22+
Allows the [customization of request cost](/ai-gateway/configuration/custom-costs/#custom-cost) to reflect user-defined parameters.
23+
24+
- term: cf-aig-cache-key
25+
general_definition: |-
26+
The [cf-aig-cache-key-aig-cache-key](/ai-gateway/configuration/caching/#custom-cache-key-cf-aig-cache-key) let you override the default cache key in order to precisely set the cacheability setting for any resource.
27+
28+
- term: cf-aig-cache-status
29+
general_definition: |-
30+
[Status indicator for caching](/ai-gateway/configuration/caching/#default-configuration), showing if a request was served from cache.
31+
32+
- term: cf-aig-metadata
33+
general_definition: |-
34+
[Custom metadata](/ai-gateway/configuration/custom-metadata/)allows you to tag requests with user IDs or other identifiers, enabling better tracking and analysis of your requests.
35+
36+
- term: cf-aig-cache-ttl
37+
general_definition: |-
38+
Specifies the [cache time-to-live for responses](/ai-gateway/configuration/caching/#cache-ttl-cf-aig-cache-ttl).
39+
40+
- term: cf-aig-skip-cache
41+
general_definition: |-
42+
Header to [bypass caching for a specific request](/ai-gateway/configuration/caching/#skip-cache-cf-aig-skip-cache).
43+
44+
# Deprecated headers
45+
- term: cf-cache-ttl
46+
general_definition: |-
47+
Deprecated: This header is replaced by `cf-aig-cache-ttl`. It specifies cache time-to-live.
48+
49+
- term: cf-skip-cache
50+
general_definition: |-
51+
Deprecated: This header is replaced by `cf-aig-skip-cache`. It bypasses caching for a specific request.

0 commit comments

Comments
 (0)