Delete a test scenario
Permanently delete one scenario (scenarioId) or many (scenarioIds) from the agent's test library. The scenarios' run history is deleted with them (FK cascade), this cannot be undone, so confirm with the operator before bulk deletes. Resolve ids with list_scenarios first. Returns the deleted count; an id that isn't on this agent reports not-found rather than silently succeeding.
Authorization
bearerAuth A personal access token from Settings > API tokens.
In: header
Path Parameters
Workspace slug (GET /me lists yours).
Agent slug within the workspace.
Query Parameters
Many scenarios to delete in one call (bulk library curation).
1 <= items <= 100Must be true to perform this action. It deletes something, publishes, or changes what live callers get straight away, so confirm with the user first.
Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X DELETE "https://example.com/workspaces/string/agents/string/tests/string"{
"deleted": 0,
"property1": null,
"property2": null
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}Create a test scenario POST
A simulated caller the eval engine plays against the agent and grades. Define passing here: assertions for anything with a right answer, rubrics for what only a reader can judge, workflowChecks for its functions. It never changes the agent.
Get a test scenario GET
Read one scenario's full payload, name, type, folder, tags, the per-type caller script (conditions / instructions / callerUtterances), the expected-outcome judge prompt, attached metricIds, persona, the linked test profile with its variables, caller tool toggles, language, connectionMode, toolMode, agentSpeaksFirst, callerModel, its assertions, workflowChecks, callSetup and line-condition environment, and its latest run status. Use this before update_scenario so you patch from the current state rather than guessing, list_scenarios only returns summaries.