Create Agent Test

Create a new test for the agent.

Authentication

AuthorizationBearer

Enter your API key with the Bearer prefix, e.g. ‘Bearer sk_…’.

Path parameters

idstringRequired

Request

This endpoint expects an object.
namestringRequired<=200 characters

Short human-readable label for the test.

typeenumRequired

Discriminates the shape of AgentTest.config.

  • reply - send one message to the agent and judge the response with an LLM.
  • tool - assert that the agent calls a specific tool given a context.
  • simulation - run a multi-turn conversation between the agent and an AI caller.
configobjectRequired

Type-specific configuration. Must match the shape for the given type.

descriptionstringOptional<=2000 characters
Optional longer description of what this test verifies.
tool_mock_configobjectOptional

Optional tool-mocking config applied during every run of this test.

variablesmap from strings to anyOptional

Per-test variable values substituted into string fields of the config at run-start. Keys use the same rules as agent-level DynamicVariable keys.

folder_idstring or nullOptional

Prefixed wire identifier (folder_<26 char Crockford base32>) of the folder to place the test in. Omit / null for root.

attached_agent_idslist of stringsOptional

Optional list of additional agents this test should also run against. The owner agent (path param) is always attached implicitly.

Response

The created test.
idstring

Prefixed wire identifier (test_<26 char Crockford base32>). URL paths accept only this prefixed form; legacy UUID path parameters are rejected with 404.

agent_idstring

Prefixed wire identifier (agent_<26 char Crockford base32>) of the owning agent.

namestring<=200 characters
descriptionstring<=2000 characters
typeenum

Discriminates the shape of AgentTest.config.

  • reply - send one message to the agent and judge the response with an LLM.
  • tool - assert that the agent calls a specific tool given a context.
  • simulation - run a multi-turn conversation between the agent and an AI caller.
configobject

Type-specific configuration document.

created_atdatetime
updated_atdatetime
tool_mock_configobject

Optional tool-mocking config applied during runs of this test.

variablesmap from strings to any

Per-test dynamic-variable overrides. Keys substitute {{key}} placeholders inside the test config at run-start. Unknown keys render as empty string, matching session dispatch behaviour.

folder_idstring or null

When set, prefixed wire identifier (folder_<26 char Crockford base32>) of the containing folder. Null means root (unfiled).

Errors

400
Bad Request Error
401
Unauthorized Error
404
Not Found Error