What are server-sent events (SSE)?
Server-sent events (SSE) is a simple web standard: you open one HTTP connection, and the server keeps sending small messages down it as things happen.
Each message has a type and data:
event: step
data: {"index":0,"type":"message","text":"I'll write hello.py and run it."}
The Agent API uses SSE for GET /v1/runs/{id}/events, so you see each step as Cosmos works. Browsers have EventSource, and every language can read the stream line by line. (With the Agent API, read it from your server, since requests need your key in headers.)
Learn more#
Related articles
Still need help?
Tried the steps above and still stuck? Email us. We usually reply within the first hour, and always within 24 hours. A full support team is with you.
Infrastructure questions, or permanent deletion of your data
infrastructure@clatterlabs.xyzFor deleting your whole account or the data of one service.