beta-headers changedapi/beta-headers
Nearest release: v2.1.238, published under an hour after this site recorded the change. Shown because the two are within 24 hours of each other. Nothing here says the release caused the edit.
Recorded here
Lines+10added
Lines−10removed
From line
24
where the diff opens
First seen
14 Aug 2026
this site's first read of the page
Recorded edits15to this page, all time
The whole hunk
from line 24, old and new numbered
/
from line 24
2424
2525Each feature's documentation states the exact beta name to send. The [API overview](https://platform.claude.com/docs/en/api/overview) lists the APIs currently in beta.
2626
27The following examples show the same request with cURL, the `ant` CLI, and the SDKs. The SDKs take beta names in the `betas` parameter and send the `anthropic-beta` header for you:
27The following examples show the same request with cURL, the `ant` CLI, and the SDKs, using the [context editing](https://platform.claude.com/docs/en/build-with-claude/context-editing) beta as the example. The SDKs take beta names in the `betas` parameter and send the `anthropic-beta` header for you:
2828
2929<CodeGroup>
3030 ```bash cURL
from line 31
3131 curl https://api.anthropic.com/v1/messages \
3232 -H "x-api-key: $ANTHROPIC_API_KEY" \
3333 -H "anthropic-version: 2023-06-01" \
34 -H "anthropic-beta: files-api-2025-04-14" \
34 -H "anthropic-beta: context-management-2025-06-27" \
3535 -H "content-type: application/json" \
3636 -d '{
3737 "model": "claude-opus-5",
from line 44
4444
4545 ```bash CLI
4646 ant beta:messages create \
47 --beta files-api-2025-04-14 \
47 --beta context-management-2025-06-27 \
4848 --model claude-opus-5 \
4949 --max-tokens 1024 \
5050 --message '{role: user, content: "Hello, Claude"}'
from line 57
5757 model="claude-opus-5",
5858 max_tokens=1024,
5959 messages=[{"role": "user", "content": "Hello, Claude"}],
60 betas=["files-api-2025-04-14"],
60 betas=["context-management-2025-06-27"],
6161 )
6262
6363 print(response.content)
from line 70
7070 model: "claude-opus-5",
7171 max_tokens: 1024,
7272 messages: [{ role: "user", content: "Hello, Claude" }],
73 betas: ["files-api-2025-04-14"]
73 betas: ["context-management-2025-06-27"]
7474 });
7575
7676 console.log(msg.content);
from line 85
8585 Model = "claude-opus-5",
8686 MaxTokens = 1024,
8787 Messages = [new() { Role = Role.User, Content = "Hello, Claude" }],
88 Betas = ["files-api-2025-04-14"],
88 Betas = ["context-management-2025-06-27"],
8989 }
9090 );
9191
from line 101
101101 Messages: []anthropic.BetaMessageParam{
102102 anthropic.NewBetaUserMessage(anthropic.NewBetaTextBlock("Hello, Claude")),
103103 },
104 Betas: []anthropic.AnthropicBeta{anthropic.AnthropicBetaFilesAPI2025_04_14},
104 Betas: []anthropic.AnthropicBeta{anthropic.AnthropicBetaContextManagement2025_06_27},
105105 })
106106 if err != nil {
107107 panic(err)
from line 117
117117 .model(Model.CLAUDE_OPUS_5)
118118 .maxTokens(1024)
119119 .addUserMessage("Hello, Claude")
120 .addBeta(AnthropicBeta.FILES_API_2025_04_14)
120 .addBeta(AnthropicBeta.CONTEXT_MANAGEMENT_2025_06_27)
121121 .build();
122122
123123 BetaMessage message = client.beta().messages().create(params);
from line 131
131131 maxTokens: 1024,
132132 messages: [['role' => 'user', 'content' => 'Hello, Claude']],
133133 model: 'claude-opus-5',
134 betas: ['files-api-2025-04-14'],
134 betas: ['context-management-2025-06-27'],
135135 );
136136
137137 echo $message;
from line 144
144144 model: "claude-opus-5",
145145 max_tokens: 1024,
146146 messages: [{role: "user", content: "Hello, Claude"}],
147 betas: ["files-api-2025-04-14"]
147 betas: ["context-management-2025-06-27"]
148148 )
149149
150150 puts(message.content)
No line in this hunk matches that.