Skip to main content
Queues a run and answers at once, without waiting for it. Each test is talked through 3 times with the agent in test mode, against a simulated customer, and each conversation is reviewed against its pass_if. Follow it with GET .../tests/runs/{runId}.

Endpoint

Required scope

agents:write

Path parameters

Body

Example request

curl

Response

202 Accepted

conversations is tests × attempts: how many simulated conversations this run holds.

400 Bad Request

A test_ids entry that is not an ObjectId, or an unknown property.

404 Not Found

AGENT_NOT_FOUND when the agent belongs to another project of the company, UPSTREAM_ERROR (message AGENT_NOT_FOUND) when no agent has that id in the company. test_not_found when a test in test_ids does not exist or is archived.

409 Conflict

run_in_progress: the agent already has a run queued or running. Its id is in the message and in running_run_id of the summary.

422 Unprocessable Entity

no_tests: the agent has no active tests to run.

401 Unauthorized

Missing, invalid, revoked, or expired token.

403 Forbidden

The token does not have the agents:write scope.

502 Bad Gateway

The agent service is unreachable.

Operational notes

  • Nothing real is touched. The agent runs in test mode: the functions that write (booking, charging, opening a ticket) are simulated, and the customer is invented.
  • A run costs conversations. Each one runs the agent for up to max_turns turns, plus the simulated customer and one review.
  • One run per agent at a time.