API
Agent API
Read a Space's reports over HTTP with your Obelism session or an MCP token. The four read-only operations and their OpenAPI spec.
1 min read
The agent API reads what the dashboard shows. It changes nothing. The MCP server runs on it, and /openapi.json describes it.
Every request carries a bearer token: an Obelism session token, or an access token from the MCP server's OAuth flow.
Authorization: Bearer <token>| Operation | Request |
|---|---|
listOrganizations | GET /api/agent/organizations |
listSpaces | GET /api/agent/organizations/{organizationId}/spaces |
getReport | GET /api/agent/organizations/{organizationId}/spaces/{spaceId}/{environment}/report?range= |
listEvents | GET /api/agent/organizations/{organizationId}/spaces/{spaceId}/{environment}/events?range= |
rangeis24h,7d(the default),30dor90d.getReportanswers with what the dashboard's overview shows: the totals withprevious(the range before), the series per UTC hour or day, and the top 10 pages, sources, campaigns, countries, devices, browsers, operating systems and clicked elements.listEventslists every event name and scope with its count, visitors and when it was last seen.
300 calls a minute per person. Errors are problem JSON with a code and a hint (errors).