Skip to main content
Stream a review answer and its progress without polling. Your API key needs the reviews:read scope. The endpoint uses the same bearer authentication, organization isolation, and rate limiting as the rest of the Open API.

Endpoint

Accept
string
required
Use text/event-stream for Postman or another SSE client. Use application/x-ndjson for one JSON event per line.
after
integer
default:"-1"
Last public event sequence you received. The server returns events with a greater sequence. Omit it or use -1 to start at the beginning.

Stream in Postman

  1. Send Submit a Review Question.
  2. Copy execution.streamUrl from the 202 Accepted response.
  3. Set a Postman streamUrl variable to that returned path, then create a GET {{baseUrl}}{{streamUrl}}?after=-1 request. The provided Plangrep collection instead builds the same URL from projectId, reviewId, and executionId.
  4. Select Bearer Token authorization and use your Open API key.
  5. Add Accept: text/event-stream, then click Send.
Postman opens its EventStream response view. Every SSE message uses the public sequence as id, the event type as event, and the full public JSON event as data.

Stream NDJSON

Each NDJSON line is the same JSON object carried in an SSE event’s data field.

Event contract

Every event contains version, executionId, sequence, createdAt, type, and a type-specific payload. Sequence values strictly increase, but they are not guaranteed to be contiguous. Stop reading after response.completed or response.error. Treat the terminal response.completed.payload.text as the canonical answer.

Event payloads

response.started.payload.responseTargetMs is the non-terminal response-time target in milliseconds. The stream remains open when this target is exceeded. tool.started and tool.completed payloads contain:

Reconnect safely

Save the latest sequence you received. If the connection closes before a terminal event, reconnect to the same URL with ?after={lastSequence}. Replay does not start a second execution. Disconnecting does not cancel the durable execution. Text deltas can combine internal chunks, and some sequence values can be omitted. This lets Plangrep sanitize URL-like tokens before advancing a public replay cursor.

Public-data boundary

Plangrep validates and rebuilds each event before returning it. The stream does not expose capability tokens, runtime or orchestrator URLs, internal container job IDs, model/session details, internal tool metadata, or unknown internal error details. Runtime artifact references are rewritten to bearer-authenticated Open API artifact URLs when a valid public mapping exists. Reading those artifact URLs requires artifacts:read.

Errors