Endpoints and Headers
An endpoint is a URL path on a server, and a header is a named value that a request carries.
Claude Code calls the model server and a few account servers, and it adds headers to each request.
If you run Claude Code behind a proxy, the proxy must pass anthropic-version and anthropic-beta on without a change.
Base URL variables pick the server, and ANTHROPIC_CUSTOM_HEADERS adds headers. The switches are CLAUDE_CODE_GATEWAY_HINT_HEADERS, CLAUDE_CODE_ATTRIBUTION_HEADER=0, and CLAUDE_CODE_ENABLE_GATEWAY_MODEL_DISCOVERY=1. The model list is cached in ~/.claude/cache/gateway-models.json.
Model Endpoints
Source: Gateway Compatibility Guide, and Probes for cache_touch.
| Path | Status | What It Does |
|---|---|---|
/ | Documented: An official docs page names this item. | Sends the model request. |
/ | Documented: An official docs page names this item. | Counts tokens. Without it, Claude Code estimates from the number of characters. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Claude Code calls it every 30 seconds (10 to 120) to keep the prompt cache warm. It needs a subscriber login and the cache- beta. |
/ | Documented: An official docs page names this item. | Lists the models for the / picker, only with CLAUDE_. |
HEAD / | Documented: An official docs page names this item. | Warms up the connection. Claude Code skips it when an HTTP proxy or a client certificate is set. |
/ and / | Documented: An official docs page names this item. | The Amazon Bedrock format, chosen with ANTHROPIC_. |
: and : | Documented: An official docs page names this item. | The Google Cloud Agent Platform format, chosen with ANTHROPIC_. |
Account and Service Endpoints
These paths are strings in the program. The docs do not describe them, except the OpenTelemetry row. The Use column comes from the code that calls each path.
| Path | Status | Use |
|---|---|---|
/, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | / is the OAuth token URL. / returns the sign-in profile and organization. / returns plan usage (the / data). / is read and patched for the grove_ choice and for artifact pins. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The program sends a PATCH with the body { "grove_ when you accept the opt-in in the Grove notice. It reads grove_ back from the reply when that value is a boolean. The program does not state what the query parameter does. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The limits of your organization, cached in policy-. |
/, /, / | Undocumented: Only the program shows this item. It can change without notice. | The metrics opt-out check (metrics_), the notification preferences, and the skill health data, which is fetched only when the server flag tengu_ is on. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Event logging by Anthropic. |
/, /, / | Documented: An official docs page names this item. | OpenTelemetry export. See Monitoring. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | Feedback and shared transcripts. |
/, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | Cloud sessions, routines (/), GitHub pull request and review comment helpers, and the relay that the agent proxy uses. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | The quota check and the preflight check for an ultrareview cloud run. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | Model picker data, and a one-time fetch of the date of first use that is kept as claude. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Voice dictation. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | Artifact frames (/, through the agent proxy) and Claude Design MCP servers (/). |
The program also holds an Anthropic SDK client with paths such as /v1/agents, /v1/skills, /v1/vaults, and /v1/organizations/*.
They belong to the SDK code, and the Claude Code loop does not call them.
The program names these hosts: code.claude.com, claude.ai, claude.com, api.anthropic.com, platform.claude.com, www.anthropic.com, support.claude.com, downloads.claude.ai, and mcp-proxy.anthropic.com.
Sign-In and Account Paths
These paths are strings in the program. No source states their rules, so the Use column comes from the code that calls each path. Where the code does not show the purpose, the row says so.
| Path | Status | Use |
|---|---|---|
/ | Undocumented: Only the program shows this item. It can change without notice. | A startup fetch with a 5 second timeout. Claude Code skips it on third-party providers. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The URL that the remote managed settings are read from. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The target of the first-party metrics exporter, with a 5 second timeout. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Reads a profile with an API key and the account UUID. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | The Grove notice. The first path returns the config with a grove_ flag. The second is named for the notice-viewed event. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The fast mode status of your organization. Claude Code emits org when it changes. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Enrolls the device with your OAuth token. The body holds a display name such as Claude Code on and the host. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Part of the Claude in Chrome check. The OAuth token needs a scope that this path accepts (user:, user:, or user:), or Claude Code turns the feature off. |
/, /, https://, https:// | Undocumented: Only the program shows this item. It can change without notice. | The API_ and ROLES_ of the OAuth config. |
/, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | Organization paths for the GitHub app. / checks whether the app is installed, / asks the server to resync that status, and / checks whether the GitHub token is synced by web setup. Other calls also use the first path as a prefix. |
/ | Undocumented: Only the program shows this item. It can change without notice. | Posts a rate limit reset claim for your OAuth organization. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | File upload with your OAuth token (scope user:), and file content. In 2. the content URL ends with ?model_ when the caller asks for the model copy of the file, and with nothing otherwise (chunk-). |
/, https:// | Undocumented: Only the program shows this item. It can change without notice. | The base of an issuer for cri+jwt tokens (ES256), with its keys at / below it. No source states what it is for. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The issuer for local pairing. Claude Code builds / and / below it. |
/ | Undocumented: Only the program shows this item. It can change without notice. | The startup preflight checks / on the API host and / on the OAuth host, with a 10 second timeout. |
OAuth URLs and Hosts
The URLs below are part of the production OAuth config in the program. CLAUDE_CODE_CUSTOM_OAUTH_URL changes them.
| URL | Status | Use |
|---|---|---|
https:// | Undocumented: Only the program shows this item. It can change without notice. | The Console sign-in page (CONSOLE_). |
https:// | Undocumented: Only the program shows this item. It can change without notice. | The claude.ai sign-in page (CLAUDE_). |
https:// | Undocumented: Only the program shows this item. It can change without notice. | The token URL (TOKEN_). |
https:// | Undocumented: Only the program shows this item. It can change without notice. | The redirect for the manual code flow (MANUAL_). |
https://, https:// | Undocumented: Only the program shows this item. It can change without notice. | The success pages (CLAUDEAI_ and CONSOLE_) where the local callback server sends the browser. |
https:// | Undocumented: Only the program shows this item. It can change without notice. | Held next to the OAuth config. No source states its use. |
https://, https://, https:// | Undocumented: Only the program shows this item. It can change without notice. | BASE_, CLAUDE_, and MCP_. |
MCP Paths
| Path | Status | Use |
|---|---|---|
/ | Undocumented: Only the program shows this item. It can change without notice. | Lists your claude.ai MCP connectors. It needs the user: scope, and Claude Code adds include_. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | The MCP_ on https://, and the one of the local OAuth config at http://. |
/ | Undocumented: Only the program shows this item. It can change without notice. | A claude.ai URL that starts the sign-in of a connector. product_ is the entrypoint, such as cli. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | servers is read without credentials, with a 5 second timeout, in pages of 500, and Claude Code keeps the URLs of the remote servers. plugins is a constant, and no source states its use. |
/, /, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | Paths of built-in MCP servers that the program holds as constants. It names the servers Claude_, Claude_, and claude-. No source states the use of each path. |
https:// | Undocumented: Only the program shows this item. It can change without notice. | The docs HTTP MCP server of the built-in plugin cc- (chunk-). It is for building with the Claude API. The plugin is available only when a server-side gate is on and the other checks of the program pass (chunk-). |
https:// | Undocumented: Only the program shows this item. It can change without notice. | The URL of the managed MCP preset "Microsoft 365" (name m365, HTTP transport). |
Flags, Environments, and Files
| Path | Status | Use |
|---|---|---|
/, /, /, https:// | Undocumented: Only the program shows this item. It can change without notice. | The GrowthBook client that delivers the tengu_ gates. It reads the feature list, evaluates remotely, and evaluates with your auth headers (it falls back to / on an error). ${…} is the client key, and https:// is the host. DISABLE_ turns the fetch off. |
/, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | The bridge client of Remote Control. POST / registers the environment. The other paths are named for the environment, going offline, and reconnecting. |
/, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | Work item calls of the same bridge client, named for polling, acknowledging, heartbeat, and stop. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | cloud/ posts a new cloud environment of kind anthropic_ with the description "Default - trusted network access". |
/, /, /, /, / | Undocumented: Only the program shows this item. It can change without notice. | Session paths without beta=true. Claude Code posts events to /, and to / for a cloud session. |
/, /, / | Undocumented: Only the program shows this item. It can change without notice. | Files API paths without beta=true. Both Claude Code and the SDK client hold them. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | File store calls. read posts a filesystem_ and a path with a JWT, and stops after 60 seconds without bytes. |
/, / | Undocumented: Only the program shows this item. It can change without notice. | Organization memory stores. The program caches the discovery answer in org-. |
Hosts and Downloads
| URL | Status | Use |
|---|---|---|
https:// | Undocumented: Only the program shows this item. It can change without notice. | The base URL for release downloads, next to the update errors (update_). |
https:// | Undocumented: Only the program shows this item. It can change without notice. | Where the program fetches the official plugin marketplace. It is cached under marketplaces/. |
https://, https:// | Undocumented: Only the program shows this item. It can change without notice. | The signed model catalog (the signature is a . file, key claude-), and the $schema of its entries. |
https:// | Undocumented: Only the program shows this item. It can change without notice. | The URL of the plugin manifest schema, by its name. |
https://, https://, https://, https:// | Undocumented: Only the program shows this item. It can change without notice. | Doc sources that the program holds next to the claude- agent. |
https:// | Undocumented: Only the program shows this item. It can change without notice. | Named next to the "Repeated 529 Overloaded errors" message. |
Request Headers
Source: Gateway Compatibility Guide. Header names are not case-sensitive.
| Header | Status | Meaning |
|---|---|---|
Authorization, x- | Documented: An official docs page names this item. | The credential. |
anthropic- | Documented: An official docs page names this item. | The API version, 2023-. |
anthropic- | Documented: An official docs page names this item. | The list of beta values. See Betas. |
x- | Documented: An official docs page names this item. | One value for each session. |
x-, x- | Documented: An official docs page names this item. | The subagent that sent the request, and its parent. |
x- | Documented: An official docs page names this item. | The kind of request: main, subagent, workflow, compaction, or auxiliary. |
x- | Documented: An official docs page names this item. | The kind of agent: Explore, Plan, general-, custom, teammate, or fork. |
x-, x- | Documented: An official docs page names this item. | Marks a compaction request, and the first request after one. |
x- | Documented: An official docs page names this item. | The run time of the last tool batch, such as Bash=742;Read=9, with at most 32 entries and 4 KB. |
x- | Documented: An official docs page names this item. | A random UUID for the user prompt, from 2.. |
anthropic- | Documented: An official docs page names this item. | Needed on Claude Platform on AWS. |
ANTHROPIC_ | Documented: An official docs page names this item. | An env var for extra headers, one Name: on each line. It is not a header itself. |
x-, anthropic-, X-, X-, x- | Undocumented: Only the program shows this item. It can change without notice. | Names in the program. No source states their rules. |
The hint headers (x-claude-code-request-class and the next four rows) go out on a direct connection to the Anthropic API.
On a custom base URL they need CLAUDE_CODE_GATEWAY_HINT_HEADERS=1. Setting it to 0 stops them everywhere.
Response Headers Claude Code Reads
| Header | Status | Use |
|---|---|---|
retry- | Documented: An official docs page names this item. | A number of seconds. A value above 60 stops the retries unless CLAUDE_ is set. |
x- | Documented: An official docs page names this item. | true or false. It is one input to the retry decision. |
anthropic- | Documented: An official docs page names this item. | Plan usage and limits for claude. sign-ins. |
content- | Documented: An official docs page names this item. | text/, or application/ on Bedrock. |
Attribution Block
The first block of system is a text line that starts with x-anthropic-billing-header:.
The docs say the block holds the client version and a fingerprint of the conversation (Gateway Compatibility Guide).
The field names below come from the program.
| Field | Status | Meaning |
|---|---|---|
cc_ | Undocumented: Only the program shows this item. It can change without notice. | The client version. |
cc_ | Undocumented: Only the program shows this item. It can change without notice. | Where Claude Code runs, such as cli, sdk-, or claude-. |
cc_, cc_ | Undocumented: Only the program shows this item. It can change without notice. | The workload tag (--), and a flag for subagents. |
cc_, cc_, cc_, cc_, cc_ | Undocumented: Only the program shows this item. It can change without notice. | Request and turn tracking, only on the Anthropic API. |
cc_, cc_, cc_ | Undocumented: Only the program shows this item. It can change without notice. | Tags for the gateway and the project. |
CLAUDE_CODE_ATTRIBUTION_HEADER=0 removes the block.
The api.anthropic.com server strips it when it is the first and only block of its entry.
Example
Keep the hint headers on a custom gateway and read them there.
export ANTHROPIC_BASE_URL=https://gateway.example.com
export CLAUDE_CODE_GATEWAY_HINT_HEADERS=1
claude -p "hi"
The gateway then sees x-claude-code-request-class: main and the other hint headers on each request.