Skip to content
Source
Sign inSign up
TanStack/ai
Open History to see the last commit

MessagesSnapshotEvent.md

20 lines608 Bytes

1---
2id: MessagesSnapshotEvent
3title: MessagesSnapshotEvent
4---
5​
6Defined in: [packages/ai/src/types.ts:1766](https://github.com/TanStack/ai/blob/main/packages/ai/src/types.ts#L1766)
7​
8Emitted to provide a snapshot of all messages in a conversation.
9​
10Unlike StateSnapshot (which carries arbitrary application state),
11MessagesSnapshot specifically delivers the conversation transcript.
12​
13@ag-ui/core provides: `messages` (as @ag-ui/core Message[])
14​
15Note: The `messages` field uses the @ag-ui/core Message type.
16Use converters to transform to/from TanStack UIMessage format.
17​
18## Extends
19​
20- `MessagesSnapshotEvent`