Launch Week 02 wrapped — explore all five launches

Create Test Run

POSThttps://api.confident-ai.com/v1/test-runs

Creates a new in-progress test run and returns its id. Use this id as the testRunId when ingesting traces (POST /v1/traces) so that each trace becomes one test case in this run.

POST/v1/test-runs
curl -X POST "https://api.confident-ai.com/v1/test-runs" \
  -H "CONFIDENT_API_KEY: <PROJECT-API-KEY>" \
  -H "Content-Type: application/json" \
  -d '{
  "identifier": "my-test-run",
  "metricCollection": "Agent Quality"
}'
200
{
  "success": true,
  "data": {
    "id": "<TEST-RUN-ID>"
  },
  "link": "https://app.confident-ai.com/project/<PROJECT-ID>/test-runs/<TEST-RUN-ID>",
  "deprecated": false
}

Headers

  • CONFIDENT_API_KEYstringRequired

    The API key of your Confident AI project.

Request body

  • metricCollectionstring

    This is the metric collection used to evaluate the test cases formed from traces ingested into this test run.

  • identifierstring

    This is an optional human-readable identifier for the test run, shown on the Confident AI platform.

Response

The created test run id.

  • successboolean

    A boolean indicating the success or failure of the API call

  • dataobject

    This maps to the test run id.

    Show 1 propertyHide 1 property
    • idstring

      This is the unique identifier of the created test run. Pass it as testRunId when ingesting traces.

  • linkstring

    This is the URL to the test run on the Confident AI platform.

  • deprecatedboolean

    This is true if this endpoint is deprecated.

Built byConfident AI