What
- The documented behavior of
user_message_uuidchanged: it stamps the turn's first top-level assistant message (which may be only a thinking block, or a synthetic API-error message), not simply the first reply frame. - With
--include-partial-messages, the first non-ping stream event is now stamped independently of the completed message, so the same uuid can appear on two frames instead of the partial stream replacing the complete-message stamp. - The SDK docstring now also clarifies that a turn started by a typed prompt stamps both its first non-ping stream event and, independently, its first complete assistant message (
SDKAssistantMessage.user_message_uuid), so both can carry the same uuid.
Why
This makes the SDK's documentation match its real streaming behavior, so integrators relying on user_message_uuid to correlate partial and complete messages get accurate expectations instead of being misled by outdated docs.
Names in the bundleuser_message_uuid
Documented inclaude-code/agent-sdk/streaming-output
The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.
Confirmed since
Anthropic's documentation has since written up user_message_uuid, on Agent SDK reference - TypeScript.
Claude Code sets the list together with `user_message_uuid` on each reply frame that carries that field and on the result. For the full set of turn frames that echo the answered message's `uuid`, and the version each requires, see [`user_m…agent-sdk/typescript see the edit
One source agreesOne thing we can check says the same as this entry.
Anthropic's documentation agrees
Anthropic's documentation has since written up user_message_uuid, on Agent SDK reference - TypeScript.