Skip to main content
POST
/
test-runs
/
{test_run_id}
/
requests
/
{offset}
/
{limit}
List test run requests with filters
curl --request POST \
  --url https://api.trymaitai.ai/api/v1/test-runs/{test_run_id}/requests/{offset}/{limit} \
  --header 'Content-Type: application/json' \
  --header 'X-Maitai-Api-Key: <api-key>' \
  --data '
{
  "scores": [
    0
  ],
  "criteria_name": "Accuracy"
}
'
{
  "items": [
    {
      "id": 9001,
      "test_run_id": 30,
      "test_set_id": 15,
      "chat_completion_request_test_id": 7700,
      "request_id": "req_abc123",
      "original_request_id": "req_xyz789",
      "status": "COMPLETED",
      "qualitative_evaluation_results": [
        {
          "criteria": "Accuracy",
          "score": "FAIL",
          "score_value": 0,
          "description": "Response omitted the required HS subheading."
        }
      ]
    }
  ],
  "total": 12,
  "offset": 0,
  "limit": 500
}

Documentation Index

Fetch the complete documentation index at: https://docs.trymaitai.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-Maitai-Api-Key
string
header
required

Your Maitai API key from the Portal.

Path Parameters

test_run_id
integer
required
offset
integer
required
limit
integer
required

Body

application/json
scores
integer[]

Filter to test-run requests whose lowest evaluation score is in this list. Boolean criteria use 0 (FAIL) and 1 (PASS); numeric criteria use 1-5 (POOR, FAIR, GOOD, GREAT, PERFECT). Pass [0] to keep boolean failures only.

criteria_name
string

Optional. Restrict the score filter to a single criterion name.

Response

200 - application/json

List test run requests with filters.

data
any