For the complete documentation index, see llms.txt. This page is also available as Markdown.

POST /v2/evals/datasets/{dataset_id}/rows

Add Eval Dataset Rows

post

Append rows as given; Location is the first created row.

How to use

Append 1–100 rows with input keys matching the dataset contract. Include expected_output for reference-based evaluation. This appends as supplied; use imports when inputs/expected output should be extracted from real traces.

Authentication and permissions

Required permissions: evals.update. Resource and owner access checks also apply.

Prepare request.json

Save the example body below as request.json for the curl sample. Replace example IDs, node keys, and dynamic configuration with values for your organization; these are illustrative, not pre-existing resources.

{
  "rows": [
    {
      "inputs": {
        "in-0": "What is 2+2?"
      },
      "expected_output": {
        "out-0": "4"
      }
    }
  ]
}
Authorizations
AuthorizationstringRequired

Personal API key (sk_...) or supported user access JWT. See Authentication and authorization for endpoint restrictions and scopes. Use exactly one Authorization header.

Path parameters
dataset_idstring · uuidRequired
Body
Responses
201

Successful Response

application/json
post/v2/evals/datasets/{dataset_id}/rows
curl
curl --fail-with-body -sS \
  "$STACKAI_BASE_URL/v2/evals/datasets/${DATASET_ID}/rows" \
  -H "Authorization: Bearer $STACKAI_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-binary @request.json
{
  "response_code": "text",
  "meta": {
    "ANY_ADDITIONAL_PROPERTY": "anything"
  },
  "data": [
    {
      "dataset_row_id": "123e4567-e89b-12d3-a456-426614174000",
      "dataset_id": "123e4567-e89b-12d3-a456-426614174000",
      "url": "text",
      "position": 1,
      "inputs": {
        "ANY_ADDITIONAL_PROPERTY": "anything"
      },
      "expected_output": {
        "ANY_ADDITIONAL_PROPERTY": "anything"
      },
      "source_run_id": "123e4567-e89b-12d3-a456-426614174000",
      "created_by": "123e4567-e89b-12d3-a456-426614174000",
      "updated_by": "123e4567-e89b-12d3-a456-426614174000",
      "created_at": "2026-01-01T00:00:00.000Z",
      "updated_at": "2026-01-01T00:00:00.000Z"
    }
  ]
}

Last updated

Was this helpful?