GET /v1/agent-runs/history
Returns the org-scoped run history for one deep agent (by `agentType`) — the audit trail of what was run: prompt, status, turns, token usage, cost, and a link to the served report when one was produced. Newest-first.

Authentication

API Key (header: Authorization)

Query Parameters

agentType string required query
Agent type (registry key or custom agent id)
limit integer optional query
Max items to return (default 20, max 100)
offset integer optional query
Items to skip (default 0)

Responses

200 OK
application/json
code integer
data object
hasMore boolean
items object[]
Array of:
agentType string
completionTokens integer
costUsd number
createdAt string
detail string
finishedAt string
prompt string
promptTokens integer
runId string
servedUrl string
ServedURL is the absolute, browser-openable address of the served report, empty when the run served no artifact (or the worker base is unconfigured).
status string
turns integer
usageModel string
userId string
limit integer
offset integer
message string
requestId string
curl -X GET 'https://api.example.com/v1/agent-runs/history?agentType=string' \  -H 'Authorization: Bearer YOUR_API_TOKEN'
const response = await fetch('https://api.example.com/v1/agent-runs/history?agentType=string', {  method: 'GET',  headers: {      "Authorization": "Bearer YOUR_API_TOKEN"  }});const data = await response.json();console.log(data);
import requestsheaders = {    'Authorization': 'Bearer YOUR_API_TOKEN'}response = requests.get('https://api.example.com/v1/agent-runs/history?agentType=string', headers=headers)print(response.json())
package mainimport (	"fmt"	"io"	"net/http")func main() {	req, _ := http.NewRequest("GET", "https://api.example.com/v1/agent-runs/history?agentType=string", nil)	req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN")	resp, _ := http.DefaultClient.Do(req)	defer resp.Body.Close()	result, _ := io.ReadAll(resp.Body)	fmt.Println(string(result))}
200 Response
{  "code": 200,  "data": {    "hasMore": true,    "items": [      {        "agentType": "<string>",        "completionTokens": 123,        "costUsd": 123,        "createdAt": "<string>",        "detail": "<string>",        "finishedAt": "<string>",        "prompt": "<string>",        "promptTokens": 123,        "runId": "<string>",        "servedUrl": "<string>",        "status": "<string>",        "turns": 123,        "usageModel": "<string>",        "userId": "<string>"      }    ],    "limit": 123,    "offset": 123  },  "message": "success",  "requestId": "abc-123"}