Guest Machines
API referenceRuns

Retrieve a run sandbox operation

GET/api/v1/runs/{run_id}/sandbox/control/{control_id}/operations/{operation_id}

Poll a submitted command or file operation. A terminal response contains the kind-specific size-limited result or a stable failure code.

unknown is a terminal recovery result: Guest Machines could not prove whether the provider applied the effect. Never blindly retry a command or write after an unknown outcome. Guest Machines retires the bound guest machine before allowing the agent to resume.

A terminal result becomes unavailable as soon as it is 24 hours old; operation metadata remains.

Required access

Credentials: automation account, delegated token, user API key

User API keys use the owner’s current permissions, subject to any key restrictions. Capability scopes below apply to automation account keys and delegated tokens.

Scope: runs:read

The exact credential that owns the control may read its operation and result. Every other caller receives 404.

Authorization

AuthorizationBearer <token>

A user-owned key prefixed gsmc_uk_, bound to one organization. It follows its owner's current membership, role and resource permissions, optionally restricted to read-only access. No X-Org-Id header is needed; a conflicting organization is rejected. Credential creation, personal connection setup and human attestations require a signed-in session. Runs are private to the calling user; sharing an agent grants access to your own personal memory of it, never to the agent's own memory.

In: header

Path Parameters

run_id*Run Id
control_id*Control Id
Formatuuid
operation_id*Operation Id
Formatuuid

Header Parameters

X-Org-Id?|

Selects the active organization for a direct user session that has more than one membership. Automation account keys and delegated tokens are each bound to one organization and ignore it.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/api/v1/runs/0/sandbox/control/497f6eca-6276-4993-bfeb-53cbbbba6f08/operations/497f6eca-6276-4993-bfeb-53cbbbba6f08" \  -H "Authorization: Bearer $GUEST_MACHINES_API_KEY"
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "run_id": 0,  "control_id": "81e20d46-f0a2-4692-a3cd-ac0ccfe84ea6",  "sequence": 0,  "request_id": "266ea41d-adf5-480b-af50-15b940c2b846",  "kind": "command",  "status": "cancelled",  "failure_code": "string",  "created_at": "2019-08-24T14:15:22Z",  "started_at": "2019-08-24T14:15:22Z",  "completed_at": "2019-08-24T14:15:22Z",  "result": {    "property1": null,    "property2": null  }}