Skip to Content
APIOrg Activity

Org Activity

Every node has an activity timeline — a chronological record of what the agent did, what it decided, what milestones it hit, what artifacts it produced. These endpoints expose that record.

GET /api/org-activity/{structure_id}/{role_id}

Return recent timeline events for a node, newest first.

Request

GET /api/org-activity/<structure_id>/<role_id>?limit=20&since=<iso8601> Authorization: Bearer <token>
QueryTypeRequiredNotes
limitintMax events (1–200, default 20).
sinceISO timestampOnly return events newer than this. For incremental polling.

Response

200 OK:

{ "events": [ { "ts": "2026-04-20T14:32:05Z", "type": "tool_call", "summary": "Launched LinkedIn campaign 'Q2-SMB-retail'", "details": { "tool": "platform_post", "platform": "linkedin", "campaign_id": "abc123" } }, { "ts": "2026-04-20T14:30:00Z", "type": "decision", "summary": "Approved $3k budget for LinkedIn campaign", "details": { "approver": "user", "amount_usd": 3000 } }, ... ] }

Event types

TypeMeaning
messageChat message to or from the agent.
thoughtInternal reasoning.
tool_callAgent invoked a tool (inside its container).
tool_resultTool returned.
decisionAgent committed a decision to the decisions log.
milestoneAgent flagged a milestone.
artifact_createdAgent produced a file (spreadsheet, PDF, draft, etc.).
skill_learnedAgent learned a new skill via best-effort success.
approval_requestedAgent blocked pending human approval.
approval_receivedApproval came through; agent resumed.
errorSomething failed in the agent’s turn.

GET /api/org-activity/{structure_id}/summary

Return a rolled-up summary across all nodes in a workspace.

Response

200 OK:

{ "since": "2026-04-20T00:00:00Z", "until": "2026-04-20T14:32:05Z", "by_role": { "executive-office-cmo": { "events": 42, "milestones": 3, "decisions": 5, "artifacts": 7 }, ... }, "highlights": [ "CMO launched 3 ad campaigns ($8k total spend)", "CTO merged 2 PRs, approved 1 deployment", "Sales VP drafted outreach to 12 leads" ] }

Useful for daily stand-up bots, weekly review emails, or the MCP get_activity flow spanning multiple nodes.

POST /api/org-activity/{structure_id}/{role_id}/milestone

Manually flag a milestone on a node’s timeline (e.g. from external automation).

Request

{ "title": "Q2 Launch Day", "details": {"notes": "All systems go"} }

Response

201 Created — echoes the milestone record with a server-generated ID.

Streaming

Activity is also available as a live event stream:

GET /api/org-activity/{structure_id}/{role_id}/stream Accept: text/event-stream

Returns an SSE stream of events as they occur. Useful for real-time dashboards. Closes automatically after 10 min of inactivity.

Last updated on