Follow a run over SSE
Streams the run's event log as Server-Sent Events, one event per line of output, in `seq` order. Each event carries `id: <seq>`, so a browser that reconnects automatically replays from exactly where it left off by sending its last id back in the `Last-Event-ID` header; the server replays the missed events and then resumes live, with no gap and no duplicate. The same cursor is available as a `?afterSeq=` query parameter for a client that cannot set headers. The stream ends by closing when the run reaches a terminal state, after the final `run.finished` or `run.error` event has been sent. A client that must not hold a connection open should poll the paged endpoint instead — the two share the same cursor space, so a client may switch between them without skipping or repeating an event.
Streams the run's event log as Server-Sent Events, one event per line of output, in seq order. Each event carries id: <seq>, so a browser that reconnects automatically replays from exactly where it left off by sending its last id back in the Last-Event-ID header; the server replays the missed events and then resumes live, with no gap and no duplicate. The same cursor is available as a ?afterSeq= query parameter for a client that cannot set headers.
The stream ends by closing when the run reaches a terminal state, after the final run.finished or run.error event has been sent. A client that must not hold a connection open should poll the paged endpoint instead — the two share the same cursor space, so a client may switch between them without skipping or repeating an event.
Path Parameters
The project the run belongs to.
The run to follow.
Query Parameters
Resume after this seq. Overridden by the Last-Event-ID header when that is present, which is what a browser's automatic reconnect sends.
0 <= valueResponse Body
text/event-stream
application/json
application/json
application/json
curl -X GET "https://example.com/projects/string/runs/string/stream"{ "seq": 0, "type": "run.started", "payload": null, "createdAt": "string"}Read a run's events GET
Returns the run's event log in order, starting after `afterSeq`. This is the paged counterpart to the SSE stream and is the right choice for a client that cannot hold a long-lived connection. The `nextCursor` it returns is exactly the value to send as the next `afterSeq`, or as `Last-Event-ID` when switching to the stream, so the two never skip or repeat an event. `done` is true once the run has reached a terminal state, which is the signal to stop polling.
Scan a project for drainer and phishing patterns POST
Runs the static drainer / phishing scanner over every readable source file in the project's sandbox and returns every hit with the rule that fired, the file, and the line. This is the same scanner and the same six rules the export gate uses, so `blocked: true` here means the export gate would refuse this project too. The matched text is redacted before it leaves the process; a seed phrase or private key is never returned whole. Read-only: nothing in the project is written or deleted.