Skip to main content
POST
/
v2
/
{entity}
/
{project}
/
eval_results
/
query
Eval Results Query
curl --request POST \
  --url https://api.example.com/v2/{entity}/{project}/eval_results/query \
  --header 'Content-Type: application/json' \
  --data '
{
  "evaluation_call_ids": [
    "<string>"
  ],
  "evaluation_run_ids": [
    "<string>"
  ],
  "require_intersection": false,
  "include_raw_data_rows": false,
  "resolve_row_refs": false,
  "include_rows": true,
  "include_summary": false,
  "summary_require_intersection": true,
  "include_predict_and_score_children": true,
  "include_costs": false,
  "sort_by": [
    {
      "field": "<string>",
      "evaluation_call_id": "<string>",
      "mode": "value"
    }
  ],
  "filters": [
    {
      "query": {
        "$expr": {
          "$and": [
            {
              "$literal": "<string>"
            }
          ]
        }
      },
      "evaluation_call_id": "<string>"
    }
  ],
  "filter_logic_operator": "or",
  "limit": 123,
  "offset": 0
}
'
import requests

url = "https://api.example.com/v2/{entity}/{project}/eval_results/query"

payload = {
"evaluation_call_ids": ["<string>"],
"evaluation_run_ids": ["<string>"],
"require_intersection": False,
"include_raw_data_rows": False,
"resolve_row_refs": False,
"include_rows": True,
"include_summary": False,
"summary_require_intersection": True,
"include_predict_and_score_children": True,
"include_costs": False,
"sort_by": [
{
"field": "<string>",
"evaluation_call_id": "<string>",
"mode": "value"
}
],
"filters": [
{
"query": { "$expr": { "$and": [{ "$literal": "<string>" }] } },
"evaluation_call_id": "<string>"
}
],
"filter_logic_operator": "or",
"limit": 123,
"offset": 0
}
headers = {"Content-Type": "application/json"}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
evaluation_call_ids: ['<string>'],
evaluation_run_ids: ['<string>'],
require_intersection: false,
include_raw_data_rows: false,
resolve_row_refs: false,
include_rows: true,
include_summary: false,
summary_require_intersection: true,
include_predict_and_score_children: true,
include_costs: false,
sort_by: [{field: '<string>', evaluation_call_id: '<string>', mode: 'value'}],
filters: [
{
query: {$expr: {$and: [{$literal: '<string>'}]}},
evaluation_call_id: '<string>'
}
],
filter_logic_operator: 'or',
limit: 123,
offset: 0
})
};

fetch('https://api.example.com/v2/{entity}/{project}/eval_results/query', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/v2/{entity}/{project}/eval_results/query",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'evaluation_call_ids' => [
'<string>'
],
'evaluation_run_ids' => [
'<string>'
],
'require_intersection' => false,
'include_raw_data_rows' => false,
'resolve_row_refs' => false,
'include_rows' => true,
'include_summary' => false,
'summary_require_intersection' => true,
'include_predict_and_score_children' => true,
'include_costs' => false,
'sort_by' => [
[
'field' => '<string>',
'evaluation_call_id' => '<string>',
'mode' => 'value'
]
],
'filters' => [
[
'query' => [
'$expr' => [
'$and' => [
[
'$literal' => '<string>'
]
]
]
],
'evaluation_call_id' => '<string>'
]
],
'filter_logic_operator' => 'or',
'limit' => 123,
'offset' => 0
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.example.com/v2/{entity}/{project}/eval_results/query"

payload := strings.NewReader("{\n \"evaluation_call_ids\": [\n \"<string>\"\n ],\n \"evaluation_run_ids\": [\n \"<string>\"\n ],\n \"require_intersection\": false,\n \"include_raw_data_rows\": false,\n \"resolve_row_refs\": false,\n \"include_rows\": true,\n \"include_summary\": false,\n \"summary_require_intersection\": true,\n \"include_predict_and_score_children\": true,\n \"include_costs\": false,\n \"sort_by\": [\n {\n \"field\": \"<string>\",\n \"evaluation_call_id\": \"<string>\",\n \"mode\": \"value\"\n }\n ],\n \"filters\": [\n {\n \"query\": {\n \"$expr\": {\n \"$and\": [\n {\n \"$literal\": \"<string>\"\n }\n ]\n }\n },\n \"evaluation_call_id\": \"<string>\"\n }\n ],\n \"filter_logic_operator\": \"or\",\n \"limit\": 123,\n \"offset\": 0\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.example.com/v2/{entity}/{project}/eval_results/query")
.header("Content-Type", "application/json")
.body("{\n \"evaluation_call_ids\": [\n \"<string>\"\n ],\n \"evaluation_run_ids\": [\n \"<string>\"\n ],\n \"require_intersection\": false,\n \"include_raw_data_rows\": false,\n \"resolve_row_refs\": false,\n \"include_rows\": true,\n \"include_summary\": false,\n \"summary_require_intersection\": true,\n \"include_predict_and_score_children\": true,\n \"include_costs\": false,\n \"sort_by\": [\n {\n \"field\": \"<string>\",\n \"evaluation_call_id\": \"<string>\",\n \"mode\": \"value\"\n }\n ],\n \"filters\": [\n {\n \"query\": {\n \"$expr\": {\n \"$and\": [\n {\n \"$literal\": \"<string>\"\n }\n ]\n }\n },\n \"evaluation_call_id\": \"<string>\"\n }\n ],\n \"filter_logic_operator\": \"or\",\n \"limit\": 123,\n \"offset\": 0\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/v2/{entity}/{project}/eval_results/query")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"evaluation_call_ids\": [\n \"<string>\"\n ],\n \"evaluation_run_ids\": [\n \"<string>\"\n ],\n \"require_intersection\": false,\n \"include_raw_data_rows\": false,\n \"resolve_row_refs\": false,\n \"include_rows\": true,\n \"include_summary\": false,\n \"summary_require_intersection\": true,\n \"include_predict_and_score_children\": true,\n \"include_costs\": false,\n \"sort_by\": [\n {\n \"field\": \"<string>\",\n \"evaluation_call_id\": \"<string>\",\n \"mode\": \"value\"\n }\n ],\n \"filters\": [\n {\n \"query\": {\n \"$expr\": {\n \"$and\": [\n {\n \"$literal\": \"<string>\"\n }\n ]\n }\n },\n \"evaluation_call_id\": \"<string>\"\n }\n ],\n \"filter_logic_operator\": \"or\",\n \"limit\": 123,\n \"offset\": 0\n}"

response = http.request(request)
puts response.read_body
{
  "rows": [
    {
      "row_digest": "<string>",
      "raw_data_row": null,
      "evaluations": [
        {
          "evaluation_call_id": "<string>",
          "trials": [
            {
              "predict_and_score_call_id": "<string>",
              "predict_call_id": "<string>",
              "model_output": null,
              "scores": {},
              "model_latency_seconds": 123,
              "total_tokens": 123,
              "total_cost": 123,
              "scorer_call_ids": {},
              "genai_span_ref": [
                {
                  "trace_id": "<string>",
                  "span_id": "<string>"
                }
              ]
            }
          ]
        }
      ]
    }
  ],
  "total_rows": 123,
  "summary": {
    "row_count": 0,
    "evaluations": [
      {
        "evaluation_call_id": "<string>",
        "trial_count": 0,
        "scorer_stats": [
          {
            "scorer_key": "<string>",
            "path": "<string>",
            "trial_count": 0,
            "numeric_count": 0,
            "numeric_mean": 123,
            "pass_true_count": 0,
            "pass_known_count": 0,
            "pass_rate": 123,
            "pass_signal_coverage": 123
          }
        ],
        "predict_total_tokens": 123,
        "predict_total_cost": 123,
        "evaluation_ref": "<string>",
        "model_ref": "<string>",
        "display_name": "<string>",
        "trace_id": "<string>",
        "started_at": "<string>"
      }
    ]
  },
  "warnings": [
    "<string>"
  ]
}
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}

Path Parameters

entity
string
required
project
string
required

Body

application/json
evaluation_call_ids
string[] | null

Evaluation root call IDs to include.

evaluation_run_ids
string[] | null

Alias for evaluation call IDs from the Evaluation Runs API.

require_intersection
boolean
default:false

When true, only include rows present in all requested evaluations.

include_raw_data_rows
boolean
default:false

When true, populate raw_data_row on each result row. Inline rows are returned as their dict value; dataset-referenced rows are returned as the ref string unless resolve_row_refs is also true.

resolve_row_refs
boolean
default:false

When true (requires include_raw_data_rows=True), resolve dataset-row reference strings to actual row data via a table lookup. When false, dataset-row refs are returned as-is.

include_rows
boolean
default:true

When true, include grouped row/trial data in rows and compute total_rows for the requested row-level view.

include_summary
boolean
default:false

When true, include aggregated scorer/evaluation summary data in summary.

summary_require_intersection
boolean | null

Optional intersection behavior for the summary section. When null, the value of require_intersection is used.

include_predict_and_score_children
boolean
default:true

When true (default), fetch child calls (predict/score) of each predict_and_score call to populate predict_call_id, scorer_call_ids, and more precise latency/token data. When false, these fields are derived from the predict_and_score call itself (predict_call_id and scorer_call_ids will be null/empty).

include_costs
boolean
default:false

When true, enrich the predict-and-score child calls with cost so the summary can report predict-only predict_total_cost. Opt-in: other callers skip the cost computation.

sort_by
EvalResultsSortBy · object[] | null

Sort specification for result rows. Supported field prefixes: scores., inputs., outputs.. When null, rows are sorted by row_digest ASC.

filters
EvalResultsFilter · object[] | null

Filters applied to grouped rows. Multiple filters are AND'd together.

filter_logic_operator
enum<string>
default:or

How to combine filters across evaluations: 'and' (Match All - row must match in ALL evals) or 'or' (Match Any - row must match in ANY eval). Defaults to 'or' (Match Any).

Available options:
and,
or
limit
integer | null

Optional row-level page size applied after grouping and intersection.

offset
integer
default:0

Optional row-level page offset applied after grouping and intersection.

Response

Successful Response

rows
EvalResultsRow · object[]
required
total_rows
integer
required
summary
EvalResultsSummaryRes · object | null
warnings
string[]

Non-fatal warnings (e.g. failed to resolve dataset row refs).