Skip to main content
Every edit you make changes a draft. The tester lets you talk to that draft — by text or by voice — before you publish it to phone and chat. Nothing you do here touches the live, published version, and draft runs are not billed.
The tester always runs the draft. Phone and chat serve the last published version. If a change works in the tester but not on a real call, you probably haven’t published yet — see Versioning & Publishing.

Simulate over text (and voice)

POST /agents/{agentId}/simulate opens a server-sent events (SSE) stream. Set mode to text for the chat tester or voice for the in-browser voice tester. Leave draftMode as its default (true) to run against the freshly-compiled draft. Each SSE frame is a single audit event: the event: line is the event type, and the data: line is the event JSON. You’ll see user_utterance, agent_message, tool_call, kb_retrieval, guardrail, and more stream by in real time — the same shapes you’ll later read back as a receipt. The stream ends with event: done (or event: error).
curl -N https://builder.flowyte.com/api/v1/agents/AGENT_ID/simulate \
  -H "Authorization: Bearer flowyte_sk_…" \
  -H "Content-Type: application/json" \
  -d '{"mode":"text","draftMode":true,"transcript":["What are your hours?"]}'

In-browser voice with a talk-token

To test voice live in the browser, mint a short-lived talk-token. It returns the credentials your browser needs to join a real-time voice session — a URL, a token, and a room.
POST /agents/{agentId}/talk-token is a dashboard-only call. It is authenticated by your dashboard session, not by an API key, so it cannot be called with flowyte_sk_…. Use it from the in-browser tester.
With draftMode: true the session runs the ephemeral draft and is not billed. With draftMode: false it runs the latest published version — and returns 409 no_published_version if the agent has never been published.

In the API

ActionEndpointScope
Simulate (text / voice) over SSEPOST /agents/{agentId}/simulateagents:write
Mint an in-browser voice talk-tokenPOST /agents/{agentId}/talk-tokendashboard session only
Kick a probe run (scripted scenario)POST /agents/{agentId}/probe/runagents:write
Poll a probe runGET /agents/{agentId}/probe/runs/{runId}agents:read
Stream probe progress (SSE)GET /agents/{agentId}/probe/runs/{runId}/streamagents:read
Probe runs a saved scenario end-to-end and reports whether quality gates passed — goal completion, per-turn latency, and language fidelity. Use it in CI to catch regressions before they reach callers.