Agent, teleport and storage tools
Run agents in a Space, teleport apps, and use Keyvault and Cua Volume: the tools with their parameters, results and errors.
Agents#
Run coding agents inside a Space.
| Tool | Description |
|---|---|
agent_start | Start a coding agent in the Space. |
agent_message | Send a follow-up to an agent run. |
agent_events | Read an agent run's events after a cursor. |
agent_status | Read an agent run's status and result. |
agent_interrupt | Interrupt an agent run's current turn. |
agent_stop | Stop an agent run. |
agent_list | List agent runs in the Space. |
agent_capabilities | Report what the agent harnesses support. |
agent_sign_in | Sign a coding agent in on the Space's computer, the agent's own way. |
agent_threads | List the recent Claude Code, Codex and Hermes chats on this computer. For a person only. |
agent_thread_read | Read one of the recent Claude Code, Codex or Hermes chats on this computer. For a person only. |
agent_start#
Start a coding agent in the Space.
Installs the harness if needed (pinned, checksum-verified), gives it the Space's own MCP tools plus any mcp_servers, and runs it over the Agent Client Protocol as a detached spacesd process with auto-approved permissions (the Space is the sandbox). The run survives this server restarting or the connection dropping. Returns a run_id immediately: follow it with agent_events (cursor) or agent_status, continue it with agent_message, cancel a turn with agent_interrupt. Keys: provider keys saved in Cua Spaces (Settings → Connections) reach the runs whose harness reads them; env_from_host names provider key variables from this server's environment; host credential files are never copied.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_start; destructive |
| Swift SDK | space.agents.start(...) |
| Rust | Agents::start |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | "claude-code" | "gemini-cli" | "google-antigravity" | "goose" | "hermes" | "openai-codex" | "openclaw" | "opencode" | "pi" | required | Harness id. agent_capabilities lists what each needs. |
base_url | string | none | A custom model endpoint base URL (a proxy or compatible server). |
branch | string | none | Branch or tag for repo. |
cwd | string | none | Working directory in the Space. Default: the run's own. |
effort | string | none | Reasoning level: low, medium, high, xhigh or max. Taken by Claude Code and Codex; other agents ignore it. |
env | map of string | {} | More environment for the agent, for example {"HERMES_HOME": "/home/cua/bot"}. Stored 0600 in the run and redacted from its output; name provider keys in env_from_host instead, so their values never pass through the conversation. |
env_from_host | string[] | [] | Provider key variables to forward from this server's environment (or from the keys saved in Cua Spaces, Settings → Connections), for example ["ANTHROPIC_API_KEY"]. Names only; values never pass through the conversation. Saved keys the harness reads are added without being named. |
exit_when_idle | boolean | false | Stop (resumably) once the prompt is answered. Default false. |
files | string[] | [] | Host files attached to the first prompt (absolute paths on this server's computer, at most 8 MiB each). |
home | string | none | Run as this persistent agent: its home in the Cua Volume (agents/<home>/) is restored into the Space first and saved after every turn, the harness keeps its memory there, and the agent gets the cua bridge (notify_user, the drive). Creates the persistent agent (this harness, this Space) when it does not exist yet. Default: a one-off run whose state lives only in the Space. |
label | string | none | A label for listings. |
mcp_servers | object[] | [] | Extra MCP servers. The Space's own tools are included unless sandbox_mcp is false. |
mcp_servers[].args | string[] | [] | Its arguments. |
mcp_servers[].command | string | null | Command run inside the Space. |
mcp_servers[].name | string | required | Name the agent sees. |
mcp_servers[].url | string | null | http(s):// URL. |
model | string | none | Model id. |
prompt | string | required | The task. |
repo | string | none | Git URL cloned into the working directory first. |
resume_context | string | none | With resume_session: the earlier conversation as text, given to the agent before the prompt only when the harness cannot reload the session (up to 32 KiB). |
resume_session | string | none | Continue this session of the harness's own (an id from agent_threads) instead of starting a new one: the harness reloads it from its own store on this computer. Give cwd as the chat's folder. Not with home. |
sandbox_mcp | boolean | true | Give the agent the Space's own MCP tools. Default true. |
show | boolean | false | Open a terminal on the Space's desktop following the run. Default false. |
skills | boolean | true | Copy the cua skills into the harness. Default true. |
space | string | required | Space id or name. |
wire | string | none | The wire format of base_url: anthropic, openai-responses, openai-chat or gemini. Default: the harness's own. |
Result#
JSON: run_id, agent, space, process_tag, cwd, notes and hint.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
Notes#
- Runs auto-approved: the Space is the sandbox, which is why approvalsAreEnforced is false.
agent_message#
Send a follow-up to an agent run.
Continues the same session. While a turn runs the message is queued (or, with force=true, the turn is interrupted first); a run whose runner exited is restarted and resumes its session.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_message; destructive |
| Swift SDK | AgentRun.send(_:) |
| Rust | Agents::send |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
client_id | string | none | A key of the caller's for this message: sending it again (after a lost connection) returns the first answer and delivers nothing twice. |
force | boolean | false | Interrupt a running turn first instead of queueing. Default false. |
name | string | none | Or an agent member of the Space by name (its current run). Give exactly one of run_id and name. |
run_id | string | "" | run_id from agent_start. |
space | string | required | Space id or name. |
text | string | required | The message. |
Result#
JSON: delivered, run_id, status, phase and reason.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_events#
Read an agent run's events after a cursor.
Normalized events (install, session, turn_started, message, thought, tool_call, tool_update, plan, usage, permission, turn_ended, error, exited, ...) after cursor. Pass the returned cursor back to continue; caught_up=true means nothing more is written yet. The same kinds for every harness.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_events, in spaces:readonly; read-only, idempotent |
| Swift SDK | AgentRun.events(cursor:) |
| Rust | Agents::events |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
cursor | integer | 0 | cursor from the previous call. Default 0 (the start). At least 0. |
max | integer | 100 | Most events to return. Default 100. At least 0. |
name | string | none | Or an agent member of the Space by name (its current run). Give exactly one of run_id and name. |
raw | boolean | false | Include each event's raw ACP payload. Default false. |
run_id | string | "" | run_id from agent_start. |
space | string | required | Space id or name. |
Result#
JSON: run_id, status, phase, events (each seq, ts_ms, turn, kind, and text, tool_id, tool_title, tool_kind, tool_status, stop_reason when present; category: message, user, activity or hidden, and a one-line summary for activity; raw on request), cursor and caught_up.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_status#
Read an agent run's status and result.
status is running, idle, failed, crashed or unknown ('unknown' is never a guess). Includes the last turn's result (final text, stop reason, usage) and a rendered output tail. Read from files in the Space; never disturbs the run.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_status, in spaces:readonly; read-only, idempotent |
| Swift SDK | AgentRun.status() |
| Rust | Agents::status |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | none | Or an agent member of the Space by name (its current run). Give exactly one of run_id and name. |
run_id | string | "" | run_id from agent_start. |
space | string | required | Space id or name. |
tail | integer | 40 | Rendered output lines to return. Default 40. At least 0. |
Result#
JSON: run_id, agent, status, phase, reason, turn, alive, accepts_message, summary, created_at, result (text, stop_reason, usage, error, tool_calls), output_tail and space.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_interrupt#
Interrupt an agent run's current turn.
Cancels the turn in flight (ACP session/cancel); the session stays open for agent_message.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_interrupt; destructive |
| Swift SDK | AgentRun.interrupt() |
| Rust | Agents::interrupt |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | none | Or an agent member of the Space by name (its current run). Give exactly one of run_id and name. |
run_id | string | "" | run_id from agent_start. |
space | string | required | Space id or name. |
Result#
JSON: run_id, interrupted and status.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_stop#
Stop an agent run.
Ends the run, then verifies its process is gone; reports stopped=false rather than claiming success.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_stop; destructive |
| Swift SDK | AgentRun.stop() |
| Rust | Agents::stop |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | none | Or an agent member of the Space by name (its current run). Give exactly one of run_id and name. |
run_id | string | "" | run_id from agent_start. |
space | string | required | Space id or name. |
Result#
JSON: run_id, stopped, alive and reason.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_list#
List agent runs in the Space.
Every run in the Space, newest first, including runs another client started.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_list, in spaces:readonly; read-only, idempotent |
| Swift SDK | space.agents.list() |
| Rust | Agents::list |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
space | string | required | Space id or name. |
Result#
JSON: {"space", "runs"}, each run with run_id, agent, status, phase, reason, turn, alive, accepts_message, summary, created_at and label.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_capabilities#
Report what the agent harnesses support.
Every harness: readiness (including whether a credential is available, with a hint when not), what it installs, which key variables it reads, which endpoint wire formats it takes, and its known limits; plus the event kinds and statuses.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_capabilities, in spaces:readonly; read-only, idempotent |
| Swift SDK | space.agents.harnessCapabilities() |
| Rust | agents::capabilities |
Parameters#
No parameters.
Result#
JSON: protocol, statuses, event_kinds, harnesses (each id, name, ready (supported and not auth: missing), supported, auth (ok: a key saved in Cua Spaces (Settings → Connections) or one this server can forward with env_from_host; missing: none, so a run needs a sign-in inside its Space; unknown: the harness may be set up through its own config), auth_hint, installs, keys, endpoint_wires, sandbox_mcp, interactive_cli, notes), forwardable_env and runner.
Errors#
agent_sign_in#
Sign a coding agent in on the Space's computer, the agent's own way.
Only for a person, never for an agent: no MCP server lists or runs it. Signs Claude Code or Codex in on the Space's own computer with the agent's official sign-in (claude auth login, codex login --device-auth), so the sign-in stays in that computer's agent config and Cua never holds it. start shows a link (and Codex's code) for the person to open in their own browser; the person finishes it in their own browser.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | none: for a person only, never served over MCP; read-only, idempotent |
| Swift SDK | spaces.callTool("agent_sign_in") |
| Rust | Agents::sign_in |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
action | string | none | status (default), start, code (hand over the pasted code) or cancel. |
after_refusal | boolean | false | The agent's last run there was refused its sign-in: a sign-in that is there has run out (expired). |
agent | string | required | Harness id: claude-code or openai-codex. |
code | string | none | For code: the code the sign-in page showed (Claude Code). |
space | string | required | Space id or name. |
Result#
JSON: {"space", "agent", "state"}; state is not_signed_in, signing_in (with url, code (Codex: type it on that page) and paste_code (Claude Code: the person pastes the page's code back with action code)), signed_in, failed (with reason) or expired.
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
agent_threads#
List the recent Claude Code, Codex and Hermes chats on this computer. For a person only.
Only for a person, never for an agent: no MCP server lists or runs it, and the daemon answers only this computer's own user (never a relay caller or a Space's agent). Reads the coding agents' own stores on this computer read-only (Claude Code's projects folder, Codex's sessions, Hermes's state.db) and returns only each chat's title, folder and time; nothing is kept or sent anywhere. A store that is missing or unreadable adds nothing.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | none: for a person only, never served over MCP; read-only, idempotent |
| Swift SDK | spaces.callTool("agent_threads") |
| Rust | cua_agent_threads::recent |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agents | string[] | [] | Harness ids to look at: claude-code, openai-codex, hermes. Default: all three. |
limit | integer | 4 | How many chats, newest first (1-50). Default 4. At least 0. |
Result#
JSON: threads, newest first, each agent (harness id), id, title (the chat's name, or its first prompt cut to 80 characters), cwd (its folder, or null), last_active_ms and resume (the agent's own command that continues it in a terminal, as argv).
Errors#
invalid_argument, permission_denied
agent_thread_read#
Read one of the recent Claude Code, Codex or Hermes chats on this computer. For a person only.
Only for a person, never for an agent: no MCP server lists or runs it, and the daemon answers only this computer's own user. Reads one chat from the agent's own store, read-only: what the person typed and the agent's replies, without tool calls, tool output, thinking or the agent's own injected instructions. Call it once the person picked the chat; continue it with agent_start's resume_session.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | none: for a person only, never served over MCP; read-only, idempotent |
| Swift SDK | spaces.callTool("agent_thread_read") |
| Rust | cua_agent_threads::history |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | required | Its harness id (claude-code, openai-codex, hermes). |
id | string | required | Its id, from agent_threads. |
limit | integer | 200 | The newest messages to return (1-5000). Default 200. At least 0. |
Result#
JSON: thread (as in agent_threads), messages (oldest first, each key, role (person or agent), text (cut to 8 KiB), ts_ms, and cut when cut) and earlier_omitted (older messages left out).
Errors#
invalid_argument, permission_denied, not_found
Persistent agents#
Named agents whose memory outlives their Space: homes in Cua Volume, routines, notifications, pause and resume, access to the user's computers.
| Tool | Description |
|---|---|
agent_add | Create a named agent whose memory outlives its Space. |
persistent_agent_list | List persistent agents. |
agent_remove | Forget a persistent agent. |
agent_send | Give a persistent agent a turn. |
persistent_agent_save | Save a persistent agent's home now. |
agent_pause | Pause a persistent agent: its run, its routines and its Space. |
agent_resume | Resume a paused persistent agent. |
agent_schedule_add | Schedule a recurring turn for a persistent agent. |
agent_schedule_list | List routines. |
agent_schedule_remove | Delete a routine. |
agent_schedule_set_enabled | Turn a routine on or off. |
notify_user | Tell the user something in the Cua app. |
notifications_list | Read the notifications feed. |
notifications_ack | Mark notifications read. |
computer_access_grant | Let a persistent agent use one of the user's computers. |
computer_access_revoke | Take back a persistent agent's access to a computer. |
computer_access_list | List per-agent computer access. |
agent_add#
Create a named agent whose memory outlives its Space.
A persistent agent is an agent member of the Space it works in, with its memory in its home in the Cua Volume (agents/<name>/), restored before each run and saved after each turn. People @mention it in the Space's thread (thread_post) and it answers there; it sleeps until a message or a schedule wakes it. Its harness keeps its memory in the home (Claude Code auto memory, Codex memories, Hermes MEMORY.md, the OpenClaw workspace). With every_minutes, daily_at or weekly_on and a prompt it also gets a schedule. With sessions (1-8) it works on up to that many tasks at once, each in its own run; session 1 alone writes its home, the others start from the home as last saved. durable, on other than local and once are not available yet and are refused. Inside the Space the agent gets the cua bridge: the thread, notify_user, the drive, and the user's computers it was granted.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_add; destructive |
| Swift SDK | spaces.persistentAgents.create(...) |
| Rust | Persistent::create |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | "claude-code" | "gemini-cli" | "google-antigravity" | "goose" | "hermes" | "openai-codex" | "openclaw" | "opencode" | "pi" | required | Harness id. agent_capabilities lists what each needs. |
base_url | string | none | A custom model endpoint base URL. |
brief | string | none | Standing instructions: the first message each run takes carries them in front of its text (the thread shows only the message). |
daily_at | string | none | A schedule: every day at HH:MM local time (with prompt). |
durable | boolean | false | Re-drive the agent's runs after a crash. Default false. |
effort | string | none | Reasoning level (see agent_start's effort). |
env | map of string | {} | More environment for every run (not secrets; see env_from_host). |
env_from_host | string[] | [] | Provider key variables forwarded from this server's environment (or the keys saved in Cua Spaces) at every start, for example ["ANTHROPIC_API_KEY"]. Names only. |
every_minutes | integer | none | A schedule: every N minutes (with prompt). |
model | string | none | Model id. |
name | string | required | The agent's name: 1-63 of a-z, 0-9, ., _, -. Its home is agents/<name>/ in the Cua Volume. |
on | string | none | Where it runs: local (default), auto or a machine. |
once | boolean | false | Remove the member when its first task ends. Default false. |
prompt | string | none | What the schedule asks each time. |
rights | object | task | Who can give it tasks, control it and answer its approvals. Default: task members, control admins, approve admins (the owner always can). |
rights.approve | string | string[] | | admins | Who can answer its approval requests. Default admins. |
rights.control | string | string[] | | admins | Who can interrupt, stop, pause, resume or take control of it. Default admins; whoever asked for its current task can also stop that task. |
rights.task | string | string[] | | members | Who can @mention it to give it a task (also agent_send and agent_message). Default members. |
sessions | integer | 1 | Parallel sessions. Default 1. At least 0. |
space | string | required | The Space it works in (id or name). |
standby | boolean | false | Keep a run open with its session ready, so a message starts its turn at once (the agent is started in the background, and again if it ends). Default false. |
title | string | none | The schedule's title. Default: the first words of prompt. |
weekly_on | string | none | A schedule: every week at <weekday> HH:MM local time (with prompt). |
Result#
JSON: the agent record: name, harness, space, model, base_url, env_from_host, paused, space_state and created_ms; as a member of its Space also sessions, policy {durable, on, once, guard}, added_by, member_since_ms, status and, with a schedule, schedule (the routine).
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent
persistent_agent_list#
List persistent agents.
Every persistent agent of this computer's cua home, with its Space, its current run and when its home was last saved.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:persistent_agent_list, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.persistentAgents.list() |
| Rust | Persistent::list |
Parameters#
No parameters.
Result#
JSON: {"agents"}, each with name, harness, space, paused, space_state, run_id, saved_ms and last_error.
Errors#
agent_remove#
Forget a persistent agent.
Stops its run, removes its routines, closes its open thread tasks and takes it out of its Space. Its home (agents/<name>/) stays in the Cua Volume unless keep_home is false. The thread keeps what it wrote.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_remove; destructive |
| Swift SDK | spaces.persistentAgents.remove(_:) |
| Rust | Persistent::remove |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
keep_home | boolean | true | Keep its home (agents/<name>/) in the Cua Volume. Default true. |
name | string | required | The agent member's name. |
Result#
JSON: removed (the record) and home_deleted. By default the home stays in the Cua Volume.
Errors#
agent_send#
Give a persistent agent a turn.
A follow-up to the agent's idle run, or a new run with its home restored when it has none. Refused while a turn runs (never interrupts) and while paused. Follow the run with agent_events on the agent's Space.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_send; destructive |
| Swift SDK | spaces.persistentAgents.send(_:_:) |
| Rust | Persistent::send |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | required | The persistent agent's name. |
space | string | none | The agent's Space (id or name); when given, the agent must be a member of it. Needed for an agent in a Space another machine provides (a teammate's): the message goes to that machine. Default: the agent is found by its name here. |
text | string | required | The message (the prompt of a new run, or a follow-up). |
Result#
JSON: run_id, started (a new run, with the home restored) and restored (files, bytes, millis).
Errors#
invalid_argument, not_found, ambiguous_sandbox, agent, lease_held
persistent_agent_save#
Save a persistent agent's home now.
Saves the agent's home from its Space into the Cua Volume now (the daemon also saves after every turn): only files whose SHA-256 changed move.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:persistent_agent_save; mutating, idempotent |
| Swift SDK | spaces.persistentAgents.save(_:) |
| Rust | Persistent::save |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | required | The persistent agent's name. |
Result#
JSON: files, bytes, unchanged, removed, blocked (files the secret scanner kept out) and millis.
Errors#
invalid_argument, agent, secret_detected
agent_pause#
Pause a persistent agent: its run, its routines and its Space.
One call: stops the run, saves the home, releases the home's lease, keeps the agent's routines from firing, and suspends its Space when it is local. A cloud Space cannot be suspended, so pausing releases it after the home is saved; agent_resume creates it again from the same image and restores the home. Apps open in a released cloud Space do not come back. The user's own computers are never suspended.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_pause; mutating, idempotent |
| Swift SDK | spaces.persistentAgents.pause(_:) |
| Rust | Persistent::pause |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | required | The persistent agent's name. |
Result#
JSON: stopped_run, saved (the home save), space_state (suspended, released or running) and millis.
Errors#
invalid_argument, agent, sandbox
agent_resume#
Resume a paused persistent agent.
Resumes a suspended local Space, or creates a released cloud Space again from the same image, restores the home and lets routines fire again. With prompt, starts a run on it.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | cloud |
| Approval | permission spaces:agent_resume; destructive |
| Swift SDK | spaces.persistentAgents.resume(_:prompt:) |
| Rust | Persistent::resume |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
name | string | required | The persistent agent's name. |
prompt | string | none | Start a run on this prompt once the agent is back. Default: none (the next message or routine starts one). |
Result#
JSON: space (it can change when a cloud Space is created again), recreated, restored, run_id and ready_ms (from the call to the home being back in a ready Space).
Errors#
invalid_argument, agent, sandbox
agent_schedule_add#
Schedule a recurring turn for a persistent agent.
Fired by cua daemon whether or not an app is open, as a turn of the agent ([routine] <title>: <prompt>). A routine never interrupts a turn: a busy or paused agent skips that slot. A daemon that was asleep fires a missed routine once on waking.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_schedule_add; destructive |
| Swift SDK | spaces.persistentAgents.addRoutine(...) |
| Rust | Persistent::routine_add |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | required | The persistent agent that runs it. |
daily_at | string | none | Every day at HH:MM (local time). |
enabled | boolean | true | Default true. |
every_minutes | integer | none | Every N minutes. |
prompt | string | required | What the agent is asked each time. |
title | string | required | A short title (shown in the app and prefixed to the turn). |
weekly_on | string | none | Every week at <weekday> HH:MM (local time), for example mon 09:00. |
Result#
JSON: the routine: id, botID (the agent), title, prompt, schedule, isEnabled and createdAt.
Errors#
agent_schedule_list#
List routines.
Routines with their next firing and what the last one did.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_schedule_list, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.persistentAgents.routines(agent:) |
| Rust | Persistent::routines |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | none | Only this persistent agent's routines. Default: all. |
Result#
JSON: {"routines"}, each with id, botID, title, prompt, schedule, label, isEnabled, lastFiredAt, lastRunID, lastOutcome and next_fire.
Errors#
agent_schedule_remove#
Delete a routine.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_schedule_remove; mutating, idempotent |
| Swift SDK | spaces.persistentAgents.removeRoutine(_:) |
| Rust | Persistent::routine_remove |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
id | string | required | The routine's id. |
Result#
JSON: removed (the id).
Errors#
agent_schedule_set_enabled#
Turn a routine on or off.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:agent_schedule_set_enabled; mutating, idempotent |
| Swift SDK | spaces.persistentAgents.setRoutineEnabled(_:_:) |
| Rust | Persistent::routine_set_enabled |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
enabled | boolean | required | On or off. |
id | string | required | The routine's id. |
Result#
JSON: the routine.
Errors#
notify_user#
Tell the user something in the Cua app.
Posts a notification the Cua app shows ("Your research is ready"). Agents inside a Space get the same tool on their cua bridge.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:notify_user; destructive |
| Swift SDK | spaces.notifications.post(...) |
| Rust | notify::Feed::post |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | none | The persistent agent it is about, if any. |
body | string | none | The details. Default empty. |
title | string | required | One short line. |
Result#
JSON: notified and id.
Errors#
notifications_list#
Read the notifications feed.
The feed the Cua app turns into system notifications: turn ends of persistent agents, notify_user calls, access requests and failures. It persists while no app is open.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:notifications_list, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.notifications.list(...) |
| Rust | notify::Feed::list |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
since_ms | integer | none | Only ones newer than this (Unix ms). At least 0. |
unread_only | boolean | false | Only unread ones. Default false. |
Result#
JSON: {"notifications"}, newest first, each with id, at_ms, agent, kind (turn_ended, message, approval, error), title, body, run_id, space and read.
Errors#
notifications_ack#
Mark notifications read.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:notifications_ack; mutating, idempotent |
| Swift SDK | spaces.notifications.markRead(_:) |
| Rust | notify::Feed::ack |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
ids | string[] | [] | Ids to mark read. Default: every notification. |
Result#
JSON: marked (how many changed).
Errors#
computer_access_grant#
Let a persistent agent use one of the user's computers.
Lets one persistent agent use one of the user's computers (its computer-use tools, through the agent's bridge). Asks the user for presence (Touch ID or passphrase) first. Other agents of the account get nothing.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:computer_access_grant; destructive |
| Swift SDK | spaces.persistentAgents.allowComputer(_:machine:) |
| Rust | access::Access::grant |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | required | The persistent agent. |
expires_in_secs | integer | none | End the grant after this many seconds. Default: until revoked. At least 0. |
machine | string | required | The computer (a Space id, usually relay:<computer-id> from cua host setup). |
Result#
JSON: the grant: id, agent, machine, created_ms, expires_ms.
Errors#
invalid_argument, not_confirmed
computer_access_revoke#
Take back a persistent agent's access to a computer.
Takes the access back at once: the agent's next call is refused. No presence needed.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:computer_access_revoke; mutating, idempotent |
| Swift SDK | spaces.persistentAgents.revokeComputer(_:machine:) |
| Rust | access::Access::revoke |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | required | The persistent agent. |
machine | string | none | The computer. Default: every computer. |
Result#
JSON: revoked (how many grants).
Errors#
computer_access_list#
List per-agent computer access.
Which agents may use which of the user's computers, and the audited record of grants, uses and refusals.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:computer_access_list, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.persistentAgents.computerAccess(agent:) |
| Rust | access::Access::grants |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | none | Only this persistent agent's grants. Default: all. |
audit | integer | 0 | Include the audit log's newest entries (this many). Default 0. At least 0. |
Result#
JSON: {"grants"} (each id, agent, machine, created_ms, expires_ms, revoked) and, with audit, audit (newest first: ts_ms, principal, action, path (the computer), detail) plus audit_verified.
Errors#
Session teleport#
Move a signed-in app session from this computer into a Space.
| Tool | Description |
|---|---|
teleport_manifest | Describe what a session teleport would move. |
teleport_app | Move an app session into the Space. |
teleport_manifest#
Describe what a session teleport would move.
Read on this computer from the app's own provider: items, sizes, which are sensitive and which are checked by default. With space, also reports whether the Space can import the app.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:teleport_manifest, in spaces:readonly; read-only, idempotent |
| Requires (this computer) | app_sessions |
| Swift SDK | space.sessions.manifest(for:scope:) |
| Rust | Teleport::manifest |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
app | string | required | App id, e.g. firefox, chrome, claude-code. |
scope | string | full | full (the profile) or tabs. Default full. |
space | string | none | Space to check the receiving side of (GetManifest). Optional. |
Result#
JSON: app, display_name, scope, items (each relative_path, label, estimated_bytes, is_sensitive, is_checked_by_default), total_estimated_bytes, notes; with space, a receiver (supported, limitation, app_installed, supported_apps).
Errors#
invalid_argument, not_found, ambiguous_sandbox, host_capability_missing
Notes#
- The manifest is the thing an Approval is minted from: the SDK will not send a teleport the caller has not seen a manifest for.
teleport_app#
Move an app session into the Space.
Moves the app's signed-in session into the Space, but only through the Cua Keyvault and only with the user's consent. This tool never delivers on its own: the first call files a Keyvault access request and returns a request_id; the user approves it in Cua (Touch ID or the login password) or an unattended rule matches; a later call with the same request_id has the Keyvault broker perform the delivery over the daemon's authenticated channel. Without include the manifest's default-checked items move, never everything.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:teleport_app; destructive |
| Requires (spacesd) | teleport.* |
| Requires (this computer) | app_sessions |
| Swift SDK | space.sessions.send(_ approval:) |
| Rust | Teleport::send |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
acknowledge_sensitive | boolean | none | Must be true when the selection holds a sensitive item (credentials, cookies). The consent is explicit rather than defaulted. |
app | string | required | App id, e.g. firefox, chrome, claude-code. |
include | string[] | none | Manifest rel_paths to send. Default: the manifest's default-checked items, never everything. An empty list is refused as ambiguous. |
request_id | string | none | The Keyvault request id returned by a previous call. Present on a retry after the user approved the teleport in Cua; the broker then performs the delivery. Absent on the first call. |
scope | string | full | full or tabs. Default full. |
space | string | required | Space id or name. |
Result#
JSON. First call: consent_required: true, a request_id, would_send and approve. Retry with request_id once the user approved: moved: true with transferred_paths (what the Space imported), import_ids and expires_ms; or still consent_required while pending; or an error with the Keyvault code (requires_cua_app, denied, disabled) when it cannot proceed.
Errors#
invalid_argument, not_found, ambiguous_sandbox, spacesd_not_available, capability_missing, host_capability_missing, teleport_refused, transfer_failed
Notes#
- Works on every provider. A comment in the SDK claiming teleport was cloud-only was stale and was a real bug: callers were being told to provision a metered Space for work a free Local Space does.
- Consent is owned by the Keyvault broker, not this tool: the automation caller is treated as an unverified third party, so a delivery needs a live consent or an audited unattended rule and can never be self-approved (red-team E2).
Keyvault#
Use the user's saved credentials in a Space, only with their approval.
| Tool | Description |
|---|---|
request_site_login | Sign in to a site in the Space with the user's saved password. |
request_site_login#
Sign in to a site in the Space with the user's saved password.
Signs in to a website in the Space's browser with a password the user saved in the Cua Keyvault (imported from their browser). The first call files a Keyvault request and returns a request_id; the user approves it in Cua (Touch ID or the login password), once per sign-in by default. Call again with the same space, url and request_id: the Keyvault checks the page is on the saved login's exact origin, types the username and password through the Space's cua-driver, submits the form and returns what it did, never the password. Pass the browser tab you opened (session, target_id, tab_id from get_browser_state on the same Space) to sign in there; without one the Keyvault opens its own browser in the Space on url and returns its target_id and tab_id. agent names the persistent agent asking, shown to the user.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:request_site_login; destructive |
| Requires (spacesd) | driver |
| Swift SDK | space.requestSiteLogin(url:) |
| Rust | site_login::request_site_login |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
agent | string | none | The persistent agent asking (shown to the user in the approval). |
relay_plaintext_ack | boolean | false | Sends the password over a relay connection that predates end-to-end sealing even though the relay could read it in transit. Default false: such a Space refuses the fill instead (S1). |
request_id | string | none | The request id a previous call returned. Present on the retry after the user approved; absent on the first call. |
session | string | none | cua-driver lifecycle session label of the browser tab to sign in. |
space | string | required | Space id or name. |
tab_id | string | none | cua-driver tab id (from get_browser_state). |
target_id | string | none | cua-driver browser target id (from get_browser_state). |
url | string | required | The site's sign-in page (http or https), for example https://github.com/login. |
username | string | none | Which saved username, when the site has several. |
wait_secs | integer | 20 | Seconds to wait for the user's decision on a retry. Default 20, at most 120. At least 0. |
Result#
JSON. First call: status: "pending", a request_id, site and space. Retry with request_id: status: "filled" with site, origin, username_hint (masked), submitted, page_url and the browser target_id/tab_id it signed in; status: "pending" while the user decides; status: "denied" when they declined. Never the password.
Errors#
invalid_argument, not_found, ambiguous_sandbox, spacesd_not_available, capability_missing, login_refused
Notes#
- The password never reaches the caller: the Keyvault fills the form through the Space's cua-driver and returns only a masked username.
- Approval is required by default for every sign-in (one use per approval); only an unattended rule the user wrote skips it.
Cua Volume#
Read and write the volume every Space and agent shares, decide who may reach what, and see where it is stored and how it syncs.
| Tool | Description |
|---|---|
volume_ls | List a folder of the Cua Volume. |
volume_read | Read a file from the Cua Volume. |
volume_write | Write a file to the Cua Volume. |
volume_delete | Delete a file from the Cua Volume. |
volume_history | List a Cua Volume file's versions. |
volume_restore | Restore an old version of a Cua Volume file. |
volume_grant | Grant an agent or Space more Cua Volume access. |
volume_revoke | Revoke a Cua Volume grant. |
volume_grants | List Cua Volume grants. |
volume_request_access | Ask the user for more Cua Volume access. |
volume_requests | List Cua Volume access requests waiting for the user. |
volume_approve | Approve a Cua Volume access request. |
volume_deny | Decline a Cua Volume access request. |
volume_audit | Read the Cua Volume audit log. |
volume_storage | Show where the Cua Volume keeps its bytes. |
volume_storage_set | Test or change where the Cua Volume keeps its bytes. |
volume_mount_status | Show whether the Cua Volume is mounted as a volume. |
volume_mount | Mount the Cua Volume as a volume. |
volume_unmount | Unmount the Cua Volume volume. |
volume_sync_status | Show the Cua Volume's sync state across devices. |
volume_sync_events | Wait for Cua Volume sync events. |
volume_sync_resolve | Mark a Cua Volume sync conflict as seen. |
volume_cache_stats | Show the Cua Volume block cache. |
volume_cache_set | Set the Cua Volume block cache's size cap. |
volume_cache_clear | Clear the Cua Volume block cache. |
volume_ls#
List a folder of the Cua Volume.
Cua Volume is one versioned drive per account, shared by every Space and agent: public/ (shared reference, read by everyone), agents/<agent>/ (a persistent agent's home: memory, outputs, inbox) and spaces/<space>/ (per-Space scratch). As the user (the default) you see everything. With as_agent (and in_space) you see exactly what that agent sees: it reads public/, writes its own home and its Space's folder, and anything wider needs a grant the user approves.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_ls, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeLs(path:asAgent:inSpace:) |
| Rust | cua_volume::Session::ls |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | See the drive as this persistent agent does (ada). Only narrows: the agent's defaults and grants apply. Default: the user (the whole drive). |
in_space | string | none | With as_agent: the Space id the agent is in, whose spaces/<space>/ folder it may write. |
path | string | none | Folder, for example agents/ada/ or public/. Default: the root. |
Result#
JSON: path, principal and entries (each path, name, folder, size, modified_ms, etag, mode, and sync when a file has something to say: state pending_upload, conflict (with conflict_path) or conflict_copy, and written_by when another device wrote it last).
Errors#
invalid_argument, forbidden, volume_backend
volume_read#
Read a file from the Cua Volume.
Reads at most 8 MiB. Text comes back as utf8, anything else as base64.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_read, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeRead(path:version:asAgent:inSpace:) |
| Rust | cua_volume::Session::read |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | See volume_ls. |
in_space | string | none | See volume_ls. |
path | string | required | File path, for example agents/ada/memory/MEMORY.md. |
version | string | none | A version id from volume_history. Default: the current version. |
Result#
JSON: path, size, etag, version, modified_ms, encoding (utf8 or base64), content, and sync while the drive's services run (state synced, pending_upload, conflict or conflict_copy; written_by, conflict_path).
Errors#
invalid_argument, forbidden, volume_backend
volume_write#
Write a file to the Cua Volume.
Every write is a new version (history is kept). if_etag makes it a compare-and-swap, create_only makes it create-only. Writes under agents/ are scanned for secrets and refused by kind and line; keep credentials in the Keyvault.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_write; destructive |
| Swift SDK | spaces.volumeWrite(path:content:encoding:ifEtag:createOnly:asAgent:inSpace:) |
| Rust | cua_volume::Session::write |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | See volume_ls. |
content | string | required | The content, as text or base64 (see encoding). At most 8 MiB. |
create_only | boolean | false | Write only if nothing is at path yet. Default false. |
encoding | string | utf8 | utf8 or base64. Default utf8. |
if_etag | string | none | Write only if the current version has this etag (from volume_read or volume_ls): a compare-and-swap. |
in_space | string | none | See volume_ls. |
path | string | required | File path. |
Result#
JSON: the new version's key, size, etag, version and modified_ms.
Errors#
invalid_argument, forbidden, precondition_failed, secret_detected, volume_backend
volume_delete#
Delete a file from the Cua Volume.
Adds a delete marker; volume_history and volume_restore still reach the old versions.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_delete; destructive |
| Swift SDK | spaces.volumeDelete(path:ifEtag:asAgent:inSpace:) |
| Rust | cua_volume::Session::delete |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | See volume_ls. |
if_etag | string | none | Delete only if the current version has this etag. |
in_space | string | none | See volume_ls. |
path | string | required | File path. |
Result#
JSON: {"deleted": <path>}.
Errors#
invalid_argument, forbidden, precondition_failed, volume_backend
volume_history#
List a Cua Volume file's versions.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_history, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeHistory(path:asAgent:inSpace:) |
| Rust | cua_volume::Session::history |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | See volume_ls. |
in_space | string | none | See volume_ls. |
path | string | required | File path. |
Result#
JSON: path and versions (each version, size, modified_ms, deleted, latest), newest first.
Errors#
invalid_argument, forbidden, volume_backend
volume_restore#
Restore an old version of a Cua Volume file.
Writes the old version's content as a new version, so the restore itself can be undone.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_restore; destructive |
| Swift SDK | spaces.volumeRestore(path:version:asAgent:inSpace:) |
| Rust | cua_volume::Session::restore |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | See volume_ls. |
in_space | string | none | See volume_ls. |
path | string | required | File path. |
version | string | required | The version id to restore (from volume_history). |
Result#
JSON: the new current version's key, size, etag, version and modified_ms.
Errors#
invalid_argument, forbidden, secret_detected, volume_backend
volume_grant#
Grant an agent or Space more Cua Volume access.
Only for the user: widens an agent's or a Space's access past the defaults (an agent reads public/ and writes its own home and its Space's folder). The user confirms with presence (Touch ID, the login password or the vault passphrase) before anything widens; a grant that widens nothing is refused.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_grant; destructive |
| Swift SDK | spaces.volumeGrant(principal:prefix:mode:expiresInSecs:note:) |
| Rust | cua_volume::Drive::grant |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
expires_in_secs | integer | none | Lifetime in seconds. Default: until revoked. At least 0. |
mode | string | required | r (read) or rw (read and write). |
note | string | none | A note shown next to the grant. |
prefix | string | required | A folder (agents/writer/outputs/) or one file. |
principal | string | required | agent:<name> or space:<id>. |
Result#
JSON: the grant (id, principal, prefix, mode, created_ms, expires_ms, revoked, note).
Errors#
invalid_argument, not_confirmed, forbidden
volume_revoke#
Revoke a Cua Volume grant.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_revoke; mutating, idempotent |
| Swift SDK | spaces.volumeRevoke(grantId:) |
| Rust | cua_volume::Drive::revoke |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
grant_id | string | required | The grant id (from volume_grants). |
Result#
JSON: the revoked grant.
Errors#
volume_grants#
List Cua Volume grants.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_grants, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeGrants(all:) |
| Rust | cua_volume::Drive::grants |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
all | boolean | false | Include expired and revoked grants. Default false. |
Result#
JSON: {"grants": [...]}, live grants only unless all.
Errors#
volume_request_access#
Ask the user for more Cua Volume access.
Files a request the user sees in Cua; it grants nothing by itself. Poll volume_ls or volume_read to see when access arrives.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_request_access; destructive |
| Swift SDK | spaces.volumeRequestAccess(prefix:mode:reason:asAgent:inSpace:) |
| Rust | cua_volume::Drive::request_access |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
as_agent | string | none | The agent asking. |
in_space | string | none | See volume_ls. |
mode | string | required | r or rw. |
prefix | string | required | The folder or file wanted. |
reason | string | none | Why (shown to the user as the agent's words). |
Result#
JSON: the request (id, principal, prefix, mode, reason, created_ms).
Errors#
volume_requests#
List Cua Volume access requests waiting for the user.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_requests, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeRequests() |
| Rust | cua_volume::Drive::requests |
Parameters#
No parameters.
Result#
JSON: {"requests": [...]}.
Errors#
volume_approve#
Approve a Cua Volume access request.
Only for the user, with presence.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_approve; destructive |
| Swift SDK | spaces.volumeApprove(requestId:expiresInSecs:) |
| Rust | cua_volume::Drive::approve |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
expires_in_secs | integer | none | Lifetime in seconds. Default: until revoked. At least 0. |
request_id | string | required | The request id (from volume_requests). |
Result#
JSON: the grant the request became.
Errors#
invalid_argument, not_confirmed, forbidden
volume_deny#
Decline a Cua Volume access request.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_deny; destructive |
| Swift SDK | spaces.volumeDeny(requestId:) |
| Rust | cua_volume::Drive::deny |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
request_id | string | required | The request id. |
Result#
JSON: {"denied": <request id>}.
Errors#
volume_audit#
Read the Cua Volume audit log.
Every grant, revocation, request, refusal, blocked secret, sync, lease and agent access, from a hash-chained log; an edited or truncated log reports verified=false.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_audit, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeAudit(limit:) |
| Rust | cua_volume::audit::AuditLog::tail |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
limit | integer | 50 | How many. Default 50, at most 1000. At least 0. |
Result#
JSON: events (each seq, ts_ms, principal, action, path, detail), newest first, and verified (with error when the hash chain does not verify).
Errors#
volume_storage#
Show where the Cua Volume keeps its bytes.
Only for the user. Keys are never returned; has_keys says whether the credential store holds them.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_storage, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeStorage() |
| Rust | cua_volume::service::DriveService::storage |
Parameters#
No parameters.
Result#
JSON: backend (fs or s3), fs_path, s3 (endpoint, region, bucket, root, path_style), has_keys, cloud_available.
Errors#
volume_storage_set#
Test or change where the Cua Volume keeps its bytes.
Only for the user. Tests the storage first (bucket versioning, list, then write, read back and delete a probe object; retries path-style addressing to tell when a self-hosted store needs it); with dry_run nothing else happens. Otherwise, when the test passes, saves the setting and the keys (credential store) and switches the running drive to it without a restart. The bucket must have versioning on. cloud is refused.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_storage_set; mutating, idempotent |
| Swift SDK | spaces.volumeStorageSet(update:) |
| Rust | cua_volume::service::DriveService::set_storage |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
access_key_id | string | none | The access key id (with the secret; both or neither). Saved in the credential store, never in a file. |
backend | string | required | fs (this computer) or s3 (an S3-compatible bucket: AWS S3, R2, MinIO). cloud is refused. |
dry_run | boolean | false | Only test the connection; change nothing. Default false. |
s3 | object | none | The bucket, for s3. |
s3.bucket | string | required | |
s3.endpoint | string | null | http://127.0.0.1:9000, https://<account>.r2.cloudflarestorage.com; absent for AWS. |
s3.path_style | boolean | null | Path-style addressing (MinIO and most self-hosted stores). |
s3.region | string | null | us-east-1; auto for R2. Default us-east-1. |
s3.root | string | null | A key prefix inside the bucket. Default none. |
secret_access_key | string | none | The secret access key. |
Result#
JSON: ok, reachable, authorized, versioning, detail (a sentence when not ok saying how to fix it), problem (unreachable, bad_keys, forbidden, bucket_missing, versioning_off, path_style_needed) and applied (saved and switched live).
Errors#
volume_mount_status#
Show whether the Cua Volume is mounted as a volume.
Only for the user. The drive can appear as a volume (Finder on macOS, a FUSE mount on Linux); it is off until the user turns it on with volume_mount.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_mount_status, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeMountStatus() |
| Rust | cua_volume::service::DriveService::mount_status |
Parameters#
No parameters.
Result#
JSON: enabled, state (off, mounting, mounted, needs_approval, unsupported, error), method (nfs, fuse, fskit, none), path, volume_name, detail, settings_url; plus the Spaces' own: volumes (mounted in a Space: space, mount_path, backend, principal) and volume_errors (each space and error: why a Space has no Cua Volume, for example no /dev/fuse in a container on runc).
Errors#
volume_mount#
Mount the Cua Volume as a volume.
Only for the user. Turns the mount on (kept across restarts) and mounts. Idempotent.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_mount; mutating, idempotent |
| Swift SDK | spaces.volumeMount() |
| Rust | cua_volume::service::DriveService::mount |
Parameters#
No parameters.
Result#
JSON: the mount status after the attempt (see volume_mount_status).
Errors#
volume_unmount#
Unmount the Cua Volume volume.
Only for the user. Turns the mount off; files still uploading land first.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_unmount; mutating, idempotent |
| Swift SDK | spaces.volumeUnmount() |
| Rust | cua_volume::service::DriveService::unmount |
Parameters#
No parameters.
Result#
JSON: the mount status after unmounting.
Errors#
invalid_argument, forbidden, volume_backend
volume_sync_status#
Show the Cua Volume's sync state across devices.
Devices sharing one bucket learn each other's changes through a change log in the bucket itself. A write that lost to a later one is never dropped: it stays in the file's history and as the visible conflict copy. A persistent agent may call it too (through its bridge): it sees the pending uploads and conflicts of files it can read and its own Space's volume. In a Space it reports this computer's view.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_sync_status, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeSyncStatus() |
| Rust | cua_volume::service::DriveService::sync_status |
Parameters#
No parameters.
Result#
JSON: device_id, device_name, feed (live, off for a store on this computer, offline when the bucket stops answering, with last_error), poll_interval_ms, last_poll_ms, last_remote_change_ms, pending_uploads, pending_bytes, conflicts (each path, conflict_path, winner_device, loser_device, winner_version, loser_version, ts_ms), devices (each id, name, this_device, last_seen_ms, last_change_ms, changes), last_error, pending (each path, bytes: files still uploading), backend (fs or s3), mount (this computer's mount: off, mounting, mounted, needs_approval, unsupported, error), cache (a bucket's block cache, when there is one) and volumes (the volume mounted in Spaces: each space, mount_path, backend, principal).
Errors#
volume_sync_events#
Wait for Cua Volume sync events.
Only for the user. A long poll: answers at once when events newer than since_seq exist, else waits up to wait_ms for one. Kinds: remote_change, remote_delete, upload_started, upload_done, upload_failed, conflict, error.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_sync_events, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeSyncEvents(sinceSeq:waitMs:) |
| Rust | cua_volume::service::DriveService::sync_events |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
since_seq | integer | none | Return events after this seq (default 0: all kept). At least 0. |
wait_ms | integer | none | Wait up to this long for one when none is newer (default 0, at most 30000). At least 0. |
Result#
JSON: events (each seq, ts_ms, kind, path, device, size, version, detail) and next_seq.
Errors#
volume_sync_resolve#
Mark a Cua Volume sync conflict as seen.
Only for the user. Clears the conflict from the list; both files stay.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_sync_resolve; mutating, idempotent |
| Swift SDK | spaces.volumeSyncResolve(path:) |
| Rust | cua_volume::service::DriveService::sync_resolve |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
path | string | required | The file (or its conflict copy). |
Result#
JSON: {"resolved": <path>}.
Errors#
invalid_argument, forbidden, not_found
volume_cache_stats#
Show the Cua Volume block cache.
Only for the user. Reads of a remote store go through a local block cache; counters are since the runtime started.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_cache_stats, in spaces:readonly; read-only, idempotent |
| Swift SDK | spaces.volumeCacheStats() |
| Rust | cua_volume::service::DriveService::cache_stats |
Parameters#
No parameters.
Result#
JSON: dir, size_bytes, capacity_bytes, block_bytes, blocks, hits, misses, hit_rate, prefetched_bytes, evictions.
Errors#
volume_cache_set#
Set the Cua Volume block cache's size cap.
Only for the user. Evicts down to the new cap at once; kept across restarts.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_cache_set; mutating, idempotent |
| Swift SDK | spaces.volumeCacheSet(capacityBytes:) |
| Rust | cua_volume::service::DriveService::cache_set |
Parameters#
| Parameter | Type | Default | Description |
|---|---|---|---|
capacity_bytes | integer | required | Bytes (at least 268435456, 256 MiB). At least 0. |
Result#
JSON: the cache stats after the change.
Errors#
volume_cache_clear#
Clear the Cua Volume block cache.
Only for the user. Drops every cached block; files stay in the drive.
| Providers | all (cloud, local, direct, relay) |
| Platforms | all (macos, windows, linux) |
| Metering | free |
| Approval | permission spaces:volume_cache_clear; mutating, idempotent |
| Swift SDK | spaces.volumeCacheClear() |
| Rust | cua_volume::service::DriveService::cache_clear |
Parameters#
No parameters.
Result#
JSON: the cache stats after clearing.