Create a Message changedapi/messages/create
Nearest release: v2.1.296, published 4 hours before 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+9added
Lines−17removed
From line
53
where the diff opens
First seen
14 Aug 2026
this site's first read of the page
Recorded edits19to this page, all time
The whole hunk
from line 53, old and new numbered
/
from line 53
5353
5454 Each input message must be an object with a `role` and `content`. You can specify a single `user`-role message, or you can include multiple `user` and `assistant` messages.
5555
56 If the final message uses the `assistant` role, the response content will continue immediately from the content in that message. This can be used to constrain part of the model's response.
56 If the final message uses the `assistant` role, the response content will continue immediately from the content in that message. This can be used to constrain part of the model's response. This is called prefill. On models that don't support prefill, creating a message that ends with a partial `assistant` response returns a 400 error. See [Prefill not supported](https://platform.claude.com/docs/en/api/errors#prefill-not-supported).
5757
5858 Example with a single `user` message:
5959
from line 71
7171 ]
7272 ```
7373
74 Example with a partially-filled response from Claude:
74 Example with a partially-filled response from Claude, for models that support prefill:
7575
7676 ```json
7777 [
from line 1133
11331133
11341134 - `"claude-haiku-4-5"`
11351135
1136 Fastest model with near-frontier intelligence
1137
11381136 - `"claude-haiku-4-5-20251001"`
11391137
1140 Fastest model with near-frontier intelligence
1141
11421138 - `"claude-opus-4-5"`
11431139
11441140 Powerful intelligence for long-running agents and coding
from line 1311
13151311
13161312- `thinking: optional ThinkingConfigParam`
13171313
1318 Configuration for enabling Claude's extended thinking.
1314 Configuration for Claude's thinking.
13191315
1320 When enabled, responses include `thinking` content blocks showing Claude's thinking process before the final answer. Requires a minimum budget of 1,024 tokens and counts towards your `max_tokens` limit.
1316 With `{"type": "adaptive"}`, Claude decides when and how much to think. With `{"type": "enabled"}` (manual extended thinking), you set a `budget_tokens` of at least 1,024. Thinking tokens count toward your `max_tokens` limit.
13211317
1322 See [extended thinking](https://platform.claude.com/docs/en/build-with-claude/extended-thinking) for details.
1318 Which `type` values are accepted, and what happens when you omit `thinking`, depend on the model. See [thinking](https://platform.claude.com/docs/en/build-with-claude/thinking#configuring-thinking) for each model's behavior.
13231319
13241320 - `ThinkingConfigEnabled object`
13251321
from line 1333
13371333
13381334 - `display: optional "summarized" or "omitted" or null`
13391335
1340 Controls how thinking content appears in the response. When set to `summarized`, thinking is returned normally. When set to `omitted`, thinking content is redacted but a signature is returned for multi-turn continuity. Defaults to `summarized`.
1336 Controls how thinking content appears in the response. When set to `summarized`, thinking is returned normally. When set to `omitted`, thinking content is redacted but a signature is returned for multi-turn continuity. The default depends on the model; see [Controlling thinking display](https://platform.claude.com/docs/en/build-with-claude/thinking#controlling-thinking-display).
13411337
13421338 - `"summarized"`
13431339
from line 1353
13571353
13581354 - `display: optional "summarized" or "omitted" or null`
13591355
1360 Controls how thinking content appears in the response. When set to `summarized`, thinking is returned normally. When set to `omitted`, thinking content is redacted but a signature is returned for multi-turn continuity. Defaults to `summarized`.
1356 Controls how thinking content appears in the response. When set to `summarized`, thinking is returned normally. When set to `omitted`, thinking content is redacted but a signature is returned for multi-turn continuity. The default depends on the model; see [Controlling thinking display](https://platform.claude.com/docs/en/build-with-claude/thinking#controlling-thinking-display).
13611357
13621358 - `"summarized"`
13631359
from line 3978
39823978
39833979 - `"claude-haiku-4-5"`
39843980
3985 Fastest model with near-frontier intelligence
3986
39873981 - `"claude-haiku-4-5-20251001"`
3988
3989 Fastest model with near-frontier intelligence
39903982
39913983 - `"claude-opus-4-5"`
39923984
No line in this hunk matches that.