Agent Device Cloud
Sign in

Reference

HTTP API and errors

The console, CLI, MCP server and SDK all use this versioned API. Prefer the typed SDK client over hand-written requests.

Authentication

Owner session
Browser or CLI management session. Manages devices, Agent access, approvals and settings. Changes must come from the deployment origin.
Agent credential
Revocable Bearer token bound to one Agent access. It can only call the tools, folders and devices in that grant.
Device identity
Ed25519 or Android Keystore P-256 signatures with a timestamp and one-time nonce. Not accepted on owner or Agent routes.

Main endpoints

MethodPathCallerPurpose
GET/api/v1/meOwner or AgentCurrent identity and scope.
GET/api/v1/nodesOwnerPaired devices and capabilities.
POST/api/v1/pairing-codesOwnerCreate a one-time pairing code.
GET · POST/api/v1/grantsOwnerList or create Agent access.
PATCH · DELETE/api/v1/grants/:grantIdOwnerUpdate (with revision) or delete Agent access.
POST/api/v1/invocationsAgentSubmit a tool call.
GET/api/v1/invocations/:invocationIdOwner or AgentFollow a call through approval and dispatch.
GET/api/v1/tasks/:jobIdAgentTask state or final result.
POST/api/v1/tasks/:jobId/cancelAgentCancel a running task.
GET/api/v1/approvalsOwnerPending or resolved approvals (cursor paging).
GET/api/v1/auditOwnerActivity records (cursor paging).

Approvals and audit page newest-first: pass limit (1–100) and the returned nextCursor as cursor.

Invocation

Official clients fill identity fields from the Agent credential. Paths must stay inside the grant; changing tools also need an idempotency key.

JSON
{
  "schemaVersion": "0.1",
  "invocationId": "inv_example001",
  "attemptId": "att_example001",
  "accountId": "acct_example001",
  "actor": { "type": "agent", "id": "actor_example001" },
  "target": { "nodeId": "node_example001" },
  "authorization": { "grantId": "grant_example001", "rootIds": ["root_workspace001"] },
  "tool": "file.read",
  "args": { "path": "/Users/me/work/README.md" },
  "issuedAt": "2026-09-29T10:00:00.000Z",
  "expiresAt": "2026-09-29T10:05:00.000Z",
  "metadata": { "source": "sdk" }
}

A 200 response can still carry denied, approval_required or offline in status. queued and running results include a jobId to follow.

Error codes

CodeRetryWhat to do
invalid_requestNoFix the arguments.
expiredNoSubmit a new call with a new deadline.
deniedNoReview Agent access, device policy and local scope.
approval_requiredAfter approvalApprove before it expires.
offlineYesWait for the device to reconnect.
conflictConditionallyRefresh; never overwrite a newer revision.
lease_expiredConditionallyRead the task state before creating new work.
unknown_outcomeNever automaticallyCheck the device and receipt first.
internalWhen retryableBack off and keep the same request identity.

Never turn unknown_outcome into an automatic retry. The same idempotency key can recover a stored receipt; a new key can repeat the change.