Batch Testing

    Create batch test configurations, run batches of tests against multiple numbers or scenarios, retrieve batch run results, and re-run only the tests that failed.

    10 endpoints

    Create a batch

    POST/testing/batches

    Create a new batch test configuration for running tests across multiple phone numbers.

    Body Parameters

    NameTypeRequiredDescription
    namestringrequiredDisplay name for the batch
    configIdstringrequiredTest configuration ID to use as the base flow
    datasetIdstringrequiredDataset ID containing the phone numbers to test

    Request

    bash
    curl -X POST -H "x-api-key: YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{"name":"UK Regional Batch","configId":"cfg_abc123","datasetId":"ds_abc123"}' \
      https://api.nopaque.co.uk/testing/batches

    Response

    json
    {
      "id": "batch_abc123",
      "name": "UK Regional Batch",
      "configId": "cfg_abc123",
      "datasetId": "ds_abc123",
      "status": "created",
      "createdAt": "2026-04-10T12: 00: 00Z"
    }

    List batches

    GET/testing/batches

    List all batch test configurations in the workspace.

    Query Parameters

    NameTypeRequiredDescription
    limitnumberoptionalMaximum items to return (default 50)
    nextTokenstringoptionalPagination token from previous response

    Request

    bash
    curl -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batches

    Response

    json
    {
      "batches": [
        {
          "id": "batch_abc123",
          "name": "UK Regional Batch",
          "status": "created",
          "createdAt": "2026-04-10T12: 00: 00Z"
        }
      ]
    }

    Get a batch

    GET/testing/batches/{id}

    Get a specific batch test configuration by ID.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredBatch ID

    Request

    bash
    curl -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batches/batch_abc123

    Response

    json
    {
      "id": "batch_abc123",
      "name": "UK Regional Batch",
      "configId": "cfg_abc123",
      "datasetId": "ds_abc123",
      "status": "created",
      "createdAt": "2026-04-10T12: 00: 00Z"
    }

    Update a batch

    PUT/testing/batches/{id}

    Update a batch test configuration.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredBatch ID

    Body Parameters

    NameTypeRequiredDescription
    namestringoptionalUpdated display name
    datasetIdstringoptionalUpdated dataset ID

    Request

    bash
    curl -X PUT -H "x-api-key: YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{"name":"EU Regional Batch"}' \
      https://api.nopaque.co.uk/testing/batches/batch_abc123

    Response

    json
    {
      "id": "batch_abc123",
      "name": "EU Regional Batch",
      "updatedAt": "2026-04-10T12: 10: 00Z"
    }

    Delete a batch

    DELETE/testing/batches/{id}

    Delete a batch test configuration.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredBatch ID

    Request

    bash
    curl -X DELETE -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batches/batch_abc123

    Response

    json
    {
      "message": "Batch deleted successfully"
    }

    Run a batch

    POST/testing/batches/{id}/run

    Start a batch test run. Executes the test flow against all phone numbers in the dataset.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredBatch ID

    Request

    bash
    curl -X POST -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batches/batch_abc123/run

    Response

    json
    {
      "id": "brun_def456",
      "batchId": "batch_abc123",
      "status": "running",
      "startedAt": "2026-04-10T12: 15: 00Z"
    }

    List runs of a batch

    GET/testing/batches/{id}/runs

    List all runs for a specific batch test.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredBatch ID

    Request

    bash
    curl -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batches/batch_abc123/runs

    Response

    json
    {
      "runs": [
        {
          "id": "brun_def456",
          "status": "completed",
          "passRate": 0.92,
          "startedAt": "2026-04-10T12: 15: 00Z"
        }
      ]
    }

    List all batch runs

    GET/testing/batch-runs

    List all batch runs across all batches in the workspace.

    Query Parameters

    NameTypeRequiredDescription
    limitnumberoptionalMaximum items to return (default 50)
    nextTokenstringoptionalPagination token from previous response

    Request

    bash
    curl -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batch-runs

    Response

    json
    {
      "runs": [
        {
          "id": "brun_def456",
          "batchId": "batch_abc123",
          "status": "completed",
          "passRate": 0.92
        }
      ]
    }

    Get a batch run

    GET/testing/batch-runs/{id}

    Get a specific batch run by ID with full results.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredBatch run ID

    Request

    bash
    curl -H "x-api-key: YOUR_API_KEY" \
      https://api.nopaque.co.uk/testing/batch-runs/brun_def456

    Response

    json
    {
      "id": "brun_def456",
      "batchId": "batch_abc123",
      "status": "completed",
      "totalNumbers": 25,
      "passed": 23,
      "failed": 2,
      "passRate": 0.92,
      "completedAt": "2026-04-10T12: 30: 00Z"
    }

    Re-run the failed tests of a batch run

    POST/testing/batch-runs/{id}/rerun

    Dispatch a new batch run containing only the failed tests from a finished batch run, and return it. This places real calls and uses minutes, exactly like the original batch; the workspace's minutes are checked first (402 when they are exhausted). Which tests failed is worked out by the server: the latest run of each test in the parent that completed with a failing outcome. Passing tests are never re-run, and any ids you send are intersected with that set. The new run is linked to its parent (`parentBatchRunId`, `triggeredBy: rerun`). 400 when nothing in the parent failed, or the ids you sent matched none of the failures. The published SDKs (0.13.0) have no method for this, so the sample is curl only.

    Path Parameters

    NameTypeRequiredDescription
    idstringrequiredThe batch run to re-run failures from

    Body Parameters

    NameTypeRequiredDescription
    filterstringoptionalall-failed, errors (the test could not be evaluated, outcome ERROR) or mismatches (evaluated, but did not match expectations)
    membersobject[]optionalOnly these failed tests, each { type: param | mission, configId }. Takes precedence over testConfigIds
    └ typestringrequiredparam or mission
    └ configIdstringrequiredThe test config or mission test config id
    testConfigIdsstring[]optionalLegacy: only these failed standard test configs

    Request

    bash
    curl -X POST -H "x-api-key: YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{"filter":"all-failed"}' \
      https://api.nopaque.co.uk/testing/batch-runs/brun_def456/rerun

    Response

    json
    {
      "id": "brun_ghi789",
      "batchId": "batch_abc123",
      "workspaceId": "ws_abc123",
      "status": "pending",
      "testRunIds": [
        "run_101",
        "run_102"
      ],
      "summary": {
        "total": 2,
        "pending": 2,
        "running": 0,
        "passed": 0,
        "failed": 0,
        "error": 0
      },
      "startedAt": "2026-04-10T13: 00: 00Z",
      "triggeredBy": "rerun",
      "parentBatchRunId": "brun_def456",
      "rootBatchRunId": "brun_def456",
      "createdBy": "usr_abc123"
    }