For the complete documentation index, see llms.txt. Any page on this site can be fetched as Markdown by appending .md to its URL.

Voice agentsAgent tests

Create a test

POST
/v1/agent-media/agents/{agentId}/tests

Add a test to the agent. An agent holds at most 50 tests.

A test is checked against a version only when a run starts. One that names a tool or disposition the version does not have is saved here and recorded as invalid in the run.

Authorization

bearerAuth
AuthorizationBearer <token>

A Tandem bearer token. Requests are scoped to the organization the token belongs to; no organization header is required.

In: header

Path Parameters

agentId*string

The agent's unique ID.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/agent-media/agents/string/tests" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "mode": "scripted"  }'
{  "test": {    "name": "string",    "description": "string",    "mode": "scripted",    "scripted": {      "turns": [        "string"      ]    },    "simulated": {      "persona": "string",      "goal": "string",      "maxTurns": 20    },    "stubs": {},    "checks": [],    "criteria": [],    "repeat": 1,    "caller": {      "ani": "string",      "contact": {        "attributes": {          "property1": "string",          "property2": "string"        }      }    },    "workflowVariables": {      "property1": "string",      "property2": "string"    },    "memory": {      "callCount": 1,      "synopsis": "string",      "rollingSummary": "string",      "openThreads": "string"    },    "testId": "string",    "agentId": "string",    "source": "user",    "createdBy": "string",    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z"  }}
{  "error": "string",  "errors": [    {      "field": "string",      "message": "string"    }  ]}
{  "error": "string",  "message": "string",  "limit": 0,  "length": 0,  "reason": "string"}
{  "error": "string",  "message": "string",  "limit": 0,  "length": 0,  "reason": "string"}
{  "error": "string",  "message": "string",  "limit": 0,  "length": 0,  "reason": "string"}