Get headless agent run state
Agents
Get headless agent run state
Returns the current run state. Terminal runs (completed, error,
pending_approval) include the assistant content, toolsInvoked,
pendingApprovalIds, and error. Run state is persisted durably
(survives restarts and is readable across instances); the granular SSE
event buffer used for Last-Event-ID replay is kept in-process for a
limited window. Requires the agents:run scope.
GET
Get headless agent run state
Authorizations
API key or personal access token (NEX-1042). Send as
Authorization: Bearer <token>. Token format:
nex_live_…— live API key (server-to-server)nex_test_…— sandbox API keynex_pat_…— personal access token (acts as the issuing user)
Authorization is decided by the key's scopes array, not the
owning user's RBAC role. See POST /api/api-keys to mint a key.
Response
Run state
Available options:
running, completed, pending_approval, error, rejected 
