Space message events stream (experimental / beta)
2 min read
Space message events stream (experimental / beta)
Streams the platform chat events produced by a single assistant run over Server-Sent Events (SSE), so an API client can follow a message from dispatch to completion without polling.
Do not use for integrations or workflows. Experimental / beta Unique API endpoints are for evaluation and early feedback only. The route, event names, and frame payloads may change without a major API version bump. Do not build production integrations, customer workflows, or long-lived automation on this endpoint.
Endpoint
POST /{VERSION}/beta/space/message/eventVERSIONis2026-03-01, supplied the same way as for every other Unique API route.The request body is identical to
POST /space/message:assistantIdis required,chatIdis optional and a new chat is created when it is omitted.The response is
text/event-stream. SendAccept: text/event-streamand disable response buffering in any intermediate proxy.
Experimental endpoints only live on the Unique API (not on the legacy Public API).
Feature flag
The endpoint returns 404 Not Found unless FEATURE_FLAG_ENABLE_EXPERIMENTAL_ENDPOINTS_UN_21060 is enabled for the calling company. The flag must be enabled for both unique-api and node-chat.
SSE contract
Event | When | Payload |
|---|---|---|
| Immediately after the user message is persisted |
|
| For every run-scoped platform chat event (assistant message creation, stream chunks, updates, finish) | The platform event envelope ( |
| The assistant run reached a terminal answer or elicitation |
|
| The run failed, or the stream hit its one-hour ceiling |
|
Only events belonging to the run started by this request are forwarded; events from other chats or other runs in the same chat are filtered out. The stream ends after run.completed or run.error, or as soon as the client disconnects.
Limitations
External assistants are not supported. Companies running on external assistants receive
400 Bad Request, because the run-scoped events the stream depends on are not emitted for them.A run that has not finished after one hour is terminated with a
run.errorframe.Client disconnects stop the stream but do not cancel the assistant run.
Related
Ticket: UN-21060