Smart Agent Teams
EndpointsInsights

Get Dashboard

Get the company overview: agents, tasks, spend, approvals and a daily series. `days` sets the series length and must be 7, 14 or 30 (422 `VALIDATION_ERROR` otherwise); each day counts succeeded and failed runs, tasks created and completed, and run cost. Spend is month-to-date in integer cents; a `monthly_budget_cents` of `0` means no limit. `active_runs` lists up to 20 queued or running runs; `for_you` covers open tasks the caller created.

GET
/api/companies/{company_id}/dashboard

Get the company overview: agents, tasks, spend, approvals and a daily series.

days sets the series length and must be 7, 14 or 30 (422 VALIDATION_ERROR otherwise); each day counts succeeded and failed runs, tasks created and completed, and run cost. Spend is month-to-date in integer cents; a monthly_budget_cents of 0 means no limit. active_runs lists up to 20 queued or running runs; for_you covers open tasks the caller created.

Authorization

HTTPBearer
headerAuthorizationBearer <token>

Path Parameters

company_id*Company Id
Formatuuid

Query Parameters

days?Days

Length of the daily series: 7, 14 or 30

Default14

Response Body

Successful Response

application/json
  1. response
active_runs*array<>
agents_paused*Agents Paused
agents_running*Agents Running
agents_total*Agents Total
for_you?|null
monthly_budget_cents*Monthly Budget Cents
pending_approvals*Pending Approvals
range_days?Range Days
Default14
series*array<>
spend_mtd_cents*Spend Mtd Cents
tasks_blocked*Tasks Blocked
tasks_by_priority*
tasks_by_status*
tasks_in_progress*Tasks In Progress
curl -X GET "https://example.com/api/companies/497f6eca-6276-4993-bfeb-53cbbbba6f08/dashboard"
{  "active_runs": [    {      "agent_id": "2b1e3b65-2c04-4fa2-a2d7-467901e98978",      "cost_cents": 0,      "created_at": "2019-08-24T14:15:22Z",      "ended_at": "2019-08-24T14:15:22Z",      "error": "string",      "heartbeat_at": "2019-08-24T14:15:22Z",      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "routine_id": "f53c5ff7-cfb7-4f43-8b79-3421a01d8e2a",      "runner_id": "string",      "started_at": "2019-08-24T14:15:22Z",      "status": "string",      "summary": "string",      "task_id": "736fde4d-9029-4915-8189-01353d6982cb",      "tokens_in": 0,      "tokens_out": 0,      "trigger": "string"    }  ],  "agents_paused": 0,  "agents_running": 0,  "agents_total": 0,  "for_you": {    "blocked_tasks": 0,    "open_tasks": 0,    "recent": [      {        "assignee_agent_id": "8ff43445-51ff-4235-b9d4-d8007d4d5dc3",        "completed_at": "2019-08-24T14:15:22Z",        "created_at": "2019-08-24T14:15:22Z",        "created_by_agent_id": "acd3b99b-57bd-46a1-809a-5d915f3c2609",        "created_by_user_id": "209f54c4-4c33-43bc-9c6a-ef4c65ad7473",        "description": "string",        "due_date": "2019-08-24T14:15:22Z",        "goal_id": "3854d9ad-4bca-4a70-a63e-7c6bc2f12aee",        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",        "key": "string",        "number": 0,        "parent_id": "1c6ca187-e61f-4301-8dcb-0e9749e89eef",        "priority": "string",        "project_id": "405d8375-3514-403b-8c43-83ae74cfe0e9",        "sort_order": 0,        "started_at": "2019-08-24T14:15:22Z",        "status": "string",        "title": "string",        "updated_at": "2019-08-24T14:15:22Z"      }    ]  },  "monthly_budget_cents": 0,  "pending_approvals": 0,  "range_days": 14,  "series": [    {      "cost_cents": 0,      "date": "string",      "runs_failed": 0,      "runs_succeeded": 0,      "tasks_completed": 0,      "tasks_created": 0    }  ],  "spend_mtd_cents": 0,  "tasks_blocked": 0,  "tasks_by_priority": {    "property1": 0,    "property2": 0  },  "tasks_by_status": {    "property1": 0,    "property2": 0  },  "tasks_in_progress": 0}