Skip to main content
POST
/
api
/
v1
/
test-suites
Create Test Suite
curl --request POST \
  --url https://api.example.com/api/v1/test-suites
Create a new test suite containing a selection of scenarios.

Request

POST /api/v1/test-suites
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json

Body Parameters

ParameterTypeRequiredDescription
namestringYesDisplay name for the test suite
descriptionstringNoOptional description
scenario_idsarrayYesArray of scenario UUIDs to include

Response (201)

FieldTypeDescription
idstringTest suite UUID
namestringDisplay name
descriptionstringDescription (or null)
scenario_countnumberNumber of scenarios in the suite
created_atstringISO-8601 creation timestamp

Examples

curl -X POST "https://app.preclinical.dev/api/v1/test-suites" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Critical Care Scenarios",
    "description": "High-priority emergency scenarios",
    "scenario_ids": [
      "scenario-uuid-1",
      "scenario-uuid-2",
      "scenario-uuid-3"
    ]
  }'

Success Response

{
  "id": "6ba7b810-9dad-11d1-80b4-00c04fd430c8",
  "name": "Critical Care Scenarios",
  "description": "High-priority emergency scenarios",
  "scenario_count": 3,
  "created_at": "2026-01-30T10:00:00Z"
}

Errors

CodeDescription
MISSING_REQUIRED_FIELDname or scenario_ids is required
INVALID_FIELD_VALUEscenario_ids must be a non-empty array
ALREADY_EXISTSA test suite with this name already exists