Restore a version of an Agent's disk
Puts disk version version (or latest) back. A virtual Agent's workspace is rewritten at once (done); a pod gets a new volume seeded from the version before any turn (pending, with disk.operation in the view until it ends). The Agent keeps its id, vault and sessions. Refused during a turn or another copy (agent_busy).
AuthorizationBearer <token>An application key of the Tenant (PUT /v1/tenant/keys/{keyId}), or Studio's key, derived from the admin key. With Nylorun-Subject and Nylorun-Scopes, it acts for that person, narrowed to those scopes. Never accepted from a browser (Origin).
agentId*stringThe Agent id, percent-encoded: users%2Falice%2Ftriage for users/alice/triage
Nylorun-Protocol*stringThe protocol version, 18
Nylorun-Subject?stringThe person an application key acts for
Nylorun-Scopes?stringThe subject's space-separated scopes; required with a subject
application/json- body
requestId?string1 <= lengthversion*|Restored, or being restored
application/json- response
agentId*stringrestored*integer0 < valuestatus*string"done""pending"volumeGeneration?integer0 <= valueimport { createClient } from "@nylorun/agents";const client = await createClient();await client.agents.restore("users/alice/assistant", "latest");{ "agentId": "string", "restored": 1, "status": "done", "volumeGeneration": 0}Snapshot an Agent's disk POST
Between turns, a new version of the Agent's disk (`/workspace`, and a pod's `/harness` but the engine's own files): files with their modes and modification times, links and empty directories, as a version of the folder artifact the Agent owns. Unchanged files are stored once; an unchanged disk makes no version (`unchanged`). A stopped pod is started first. Refused during a turn or another copy (`agent_busy`).
List an Agent's disk versions GET
Newest first. Read a version's tree, files, diff and zip through `/v1/artifacts/{artifactId}/versions/{version}/…`.