Get Message Events
Messages
Message Events
Stream assistant responses and tool activity for a chat over Server-Sent Events.
GET
Get Message Events
Open a Server-Sent Events (SSE) stream to receive the assistant’s response and tool activity for a chat in real time. Connect to this stream before or right after you call Add Message so you capture every event.
Authentication
This request requires your API key in thex-api-key header.
The response uses the
text/event-stream content type. Keep the connection open and read events as they arrive rather than waiting for the request to complete.Request
ID of the chat whose events you want to stream.
Event payload
Each SSE event carries aMessageEventDto JSON object.
ID of the chat the event belongs to.
Unique ID of the event.
Event status. One of
inProgress, completed, or failed.Name of the tool used, when the event represents tool activity.
Message content or a description of the event.
Arguments passed to the tool.
Response returned by the tool.
Examples
Stream output
An event with
status set to failed indicates the assistant could not complete the response. Use the content field for the failure description.Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Response
200 - application/json
Einzelnes MessageEventDto (wird als SSE-Event gesendet)
ID des Chats
ID des Events
Name des Tools, das verwendet wurde
Inhalt der Nachricht oder Eventbeschreibung
Optionales Objekt mit Parametern, die an das Tool übergeben wurden
Optionales Objekt mit der Antwort vom Tool
Status des Events
Available options:
inProgress, completed, failed