keep_generating: true, then continue receiving new events while it is still generating. Pass last_event_id to receive only events after the last one you received.start.| event | step | What it means |
|---|---|---|
status | varies, e.g. reasoning, assistant_start, tool steps | A progress update. May carry output (e.g. a title and description, or a todo list). |
token | subagent_stream | Progress narration from a sub-agent while it works. Not part of the answer: show it separately (e.g. as a live status line), don't append it to the answer. |
token | any other step (e.g. model_stream) | A piece of the answer. Append delta to the answer text. |
ping | ping | Keepalive after a quiet gap. Carries no data; ignore it. |
error | error | Something failed. output.error.code is the machine-readable code and output.error.details the message to show. Always followed by end. |
end | end | Always the last event. output.status says how the response ended: completed, stopped, errored, or disconnected (only seen when resuming). On completed, output holds the full answer. |
id: line holding its event id (e.g. id: 1789768688301-4), which marks its place in the response. start, ping, and every event of a response that can't be resumed have no event id.curl --location --globoff 'https:///response-service/api/v2/agents//responses//resume-events?last_event_id=&agent_version=' \
--header 'Ocp-Apim-Subscription-Key: ' \
--header 'Authorization: Bearer 'event: token
id: 1789768688301-3
data: {"delta": "Checking the travel policy for per-diem limits.", "step": "subagent_stream"}
event: ping
data: {"step": "ping"}
event: token
id: 1789768688301-4
data: {"delta": "Here is a summary", "step": "model_stream"}
event: end
id: 1789768688301-5
data: {"message": "Finished", "step": "end", "output": {"answer": "Here is a summary of the travel policy...", "thread_id": 1, "agent_response_id": 1, "corpus_id": null, "fork": null, "references": [], "artifacts": [], "chat_thread_name": "Travel policy summary", "blocked": false, "cache_hit": false, "data_points": [], "citations": [], "trace_id": "2c1f6e0a9b8d7c6e5f4a3b2c1d0e9f8a", "attached_file_metadata": [], "status": "completed"}, "success": true}