PATCH
/api/v1/evals/{runId}Update eval run status
Updates the status of an eval run (used by workers or the SDK EvaluationLogger.finish path). Completed runs (passed/failed/error) are immutable (409). Optional summary carries the final score (clamped 0-1) and totalLatency.
Authentication
Send Authorization: Bearer YOUR_API_KEY on every request. Generate API keys at /dashboard/api-keys.
Parameters
runId in pathrequiredstringRequest body required
Example
{
"status": "pending",
"summary": {
"score": 0,
"totalLatency": 0
}
}Schema
{
"application/json": {
"schema": {
"type": "object",
"required": [
"status"
],
"properties": {
"status": {
"type": "string",
"enum": [
"pending",
"running",
"passed",
"failed",
"error"
]
},
"summary": {
"type": "object",
"properties": {
"score": {
"type": "number",
"description": "Overall score; clamped to 0-1."
},
"totalLatency": {
"type": "number",
"description": "Total run latency (stored as duration)."
}
}
}
}
}
}
}Response
All status codes
200Updated eval run.
400(no description)
401(no description)
403NOT_ORG_MEMBER — caller not a member of the run's org.
404(no description)
409IMMUTABLE_RUN — run already completed.
429(no description)
Code samples
cURL
curl -X PATCH \
https://evalguard.ai/api/v1/evals/{runId} \
-H "Authorization: Bearer $EVALGUARD_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "status": "pending", "summary": { "score": 0, "totalLatency": 0 } }'TypeScript
import { EvalGuard } from "@evalguard/sdk";
const client = new EvalGuard({ apiKey: process.env.EVALGUARD_API_KEY });
const response = await client.request({
method: "PATCH",
path: "/api/v1/evals/{runId}",
body: {
"status": "pending",
"summary": {
"score": 0,
"totalLatency": 0
}
},
});
console.log(response);Python
from evalguard import EvalGuard
import os
client = EvalGuard(api_key=os.environ["EVALGUARD_API_KEY"])
response = client.request(
method="PATCH",
path="/api/v1/evals/{runId}",
body={
"status": "pending",
"summary": {
"score": 0,
"totalLatency": 0
}
},
)
print(response)Go
package main
import (
"context"
"fmt"
"net/http"
"os"
"strings"
)
func main() {
body := strings.NewReader(`{"status":"pending","summary":{"score":0,"totalLatency":0}}`)
req, _ := http.NewRequestWithContext(context.Background(), "PATCH", "https://evalguard.ai/api/v1/evals/{runId}", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("EVALGUARD_API_KEY"))
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil { panic(err) }
defer resp.Body.Close()
fmt.Println(resp.Status)
}Errors
400401403404409429