Skip to main content
POST
/
eval-runs
Execute Evaluation
curl --request POST \
  --url https://api.example.com/eval-runs \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "input": "<string>",
  "agent_id": "<string>",
  "team_id": "<string>",
  "model_id": "<string>",
  "model_provider": "<string>",
  "additional_guidelines": "<string>",
  "additional_context": "<string>",
  "num_iterations": 1,
  "name": "<string>",
  "expected_output": "<string>",
  "criteria": "<string>",
  "scoring_strategy": "binary",
  "threshold": 7,
  "warmup_runs": 0,
  "expected_tool_calls": [
    "<string>"
  ]
}
'
import requests

url = "https://api.example.com/eval-runs"

payload = {
"input": "<string>",
"agent_id": "<string>",
"team_id": "<string>",
"model_id": "<string>",
"model_provider": "<string>",
"additional_guidelines": "<string>",
"additional_context": "<string>",
"num_iterations": 1,
"name": "<string>",
"expected_output": "<string>",
"criteria": "<string>",
"scoring_strategy": "binary",
"threshold": 7,
"warmup_runs": 0,
"expected_tool_calls": ["<string>"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

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

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
input: '<string>',
agent_id: '<string>',
team_id: '<string>',
model_id: '<string>',
model_provider: '<string>',
additional_guidelines: '<string>',
additional_context: '<string>',
num_iterations: 1,
name: '<string>',
expected_output: '<string>',
criteria: '<string>',
scoring_strategy: 'binary',
threshold: 7,
warmup_runs: 0,
expected_tool_calls: ['<string>']
})
};

fetch('https://api.example.com/eval-runs', 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/eval-runs",
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([
'input' => '<string>',
'agent_id' => '<string>',
'team_id' => '<string>',
'model_id' => '<string>',
'model_provider' => '<string>',
'additional_guidelines' => '<string>',
'additional_context' => '<string>',
'num_iterations' => 1,
'name' => '<string>',
'expected_output' => '<string>',
'criteria' => '<string>',
'scoring_strategy' => 'binary',
'threshold' => 7,
'warmup_runs' => 0,
'expected_tool_calls' => [
'<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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/eval-runs"

payload := strings.NewReader("{\n \"input\": \"<string>\",\n \"agent_id\": \"<string>\",\n \"team_id\": \"<string>\",\n \"model_id\": \"<string>\",\n \"model_provider\": \"<string>\",\n \"additional_guidelines\": \"<string>\",\n \"additional_context\": \"<string>\",\n \"num_iterations\": 1,\n \"name\": \"<string>\",\n \"expected_output\": \"<string>\",\n \"criteria\": \"<string>\",\n \"scoring_strategy\": \"binary\",\n \"threshold\": 7,\n \"warmup_runs\": 0,\n \"expected_tool_calls\": [\n \"<string>\"\n ]\n}")

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

req.Header.Add("Authorization", "Bearer <token>")
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/eval-runs")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"input\": \"<string>\",\n \"agent_id\": \"<string>\",\n \"team_id\": \"<string>\",\n \"model_id\": \"<string>\",\n \"model_provider\": \"<string>\",\n \"additional_guidelines\": \"<string>\",\n \"additional_context\": \"<string>\",\n \"num_iterations\": 1,\n \"name\": \"<string>\",\n \"expected_output\": \"<string>\",\n \"criteria\": \"<string>\",\n \"scoring_strategy\": \"binary\",\n \"threshold\": 7,\n \"warmup_runs\": 0,\n \"expected_tool_calls\": [\n \"<string>\"\n ]\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/eval-runs")

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

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"input\": \"<string>\",\n \"agent_id\": \"<string>\",\n \"team_id\": \"<string>\",\n \"model_id\": \"<string>\",\n \"model_provider\": \"<string>\",\n \"additional_guidelines\": \"<string>\",\n \"additional_context\": \"<string>\",\n \"num_iterations\": 1,\n \"name\": \"<string>\",\n \"expected_output\": \"<string>\",\n \"criteria\": \"<string>\",\n \"scoring_strategy\": \"binary\",\n \"threshold\": 7,\n \"warmup_runs\": 0,\n \"expected_tool_calls\": [\n \"<string>\"\n ]\n}"

response = http.request(request)
puts response.read_body
{
  "id": "f2b2d72f-e9e2-4f0e-8810-0a7e1ff58614",
  "agent_id": "basic-agent",
  "model_id": "gpt-4o",
  "model_provider": "OpenAI",
  "eval_type": "reliability",
  "eval_data": {
    "eval_status": "PASSED",
    "failed_tool_calls": [],
    "passed_tool_calls": [
      "multiply"
    ]
  },
  "created_at": "2025-08-27T15:41:59Z",
  "updated_at": "2025-08-27T15:41:59Z"
}
{
"detail": "Bad request",
"error_code": "BAD_REQUEST"
}
{
"detail": "Unauthenticated access",
"error_code": "UNAUTHENTICATED"
}
{
"detail": "Not found",
"error_code": "NOT_FOUND"
}
{
"detail": "Validation error",
"error_code": "VALIDATION_ERROR"
}
{
"detail": "Internal server error",
"error_code": "INTERNAL_SERVER_ERROR"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

db_id
string | null

Database ID to use for evaluation

table
string | null

Table to use for evaluation

Body

application/json
eval_type
enum<string>
required

Type of evaluation to run (accuracy, performance, or reliability)

Available options:
accuracy,
agent_as_judge,
performance,
reliability
input
string
required

Input text/query for the evaluation

Minimum string length: 1
agent_id
string | null

Agent ID to evaluate

team_id
string | null

Team ID to evaluate

model_id
string | null

Model ID to use for evaluation

model_provider
string | null

Model provider name

additional_guidelines
string | null

Additional guidelines for the evaluation

additional_context
string | null

Additional context for the evaluation

num_iterations
integer
default:1

Number of times to run the evaluation

Required range: 1 <= x <= 100
name
string | null

Name for this evaluation run

expected_output
string | null

Expected output for accuracy evaluation

criteria
string | null

Evaluation criteria for agent-as-judge evaluation

scoring_strategy
enum<string> | null
default:binary

Scoring strategy: 'numeric' (1-10 with threshold) or 'binary' (PASS/FAIL)

Available options:
numeric,
binary
threshold
integer | null
default:7

Score threshold for pass/fail (1-10), only used with numeric scoring

Required range: 1 <= x <= 10
warmup_runs
integer
default:0

Number of warmup runs before measuring performance

Required range: 0 <= x <= 10
expected_tool_calls
string[] | null

Expected tool calls for reliability evaluation

Response

Evaluation executed successfully

id
string
required

Unique identifier for the evaluation run

eval_type
enum<string>
required

Type of evaluation (accuracy, performance, or reliability)

Available options:
accuracy,
agent_as_judge,
performance,
reliability
eval_data
Eval Data · object
required

Evaluation results and metrics

agent_id
string | null

Agent ID that was evaluated

model_id
string | null

Model ID used in evaluation

model_provider
string | null

Model provider name

team_id
string | null

Team ID that was evaluated

workflow_id
string | null

Workflow ID that was evaluated

name
string | null

Name of the evaluation run

evaluated_component_name
string | null

Name of the evaluated component

eval_input
Eval Input · object | null

Input parameters used for the evaluation

created_at
string<date-time> | null

Timestamp when evaluation was created

updated_at
string<date-time> | null

Timestamp when evaluation was last updated