Expand description
Agents: one tool for the other agents (who is reachable, what they are
doing, opening them) and the caller’s own history, with an action
(docs/specs/SPEC_MUXAPI_TOOL_CONSOLIDATION_2026_10_15.md §4.2, slice S4).
It replaces DiscoverAgents, FleetList (the same call), ListConversations,
GetAgentTranscript, OpenAgent and SearchHistory; their handlers
(fleet.rs, history.rs, panes.rs) run each action unchanged.
spawn (the agent-initiated action that makes a worker, not the CLI’s
process start) is its own (SPEC_AGENT_WORKERS_2026_10_15.md §3.1): srv
launches the worker, then this process sends it the brief, signed as the
caller.
Constants§
- ACTS 🔒
- DEFINITION_
FIELDS 🔒 - The fields
updatemay change (/api/v1/agent/update); the name, provider, environment, accounts and seat have their own actions. - OPERATOR_
FIELDS 🔒 - What decides what an agent runs, where its traffic goes or which project files it reads: the operator’s to set in
My Agents, as
env_setrefuses the same. - SPAWN_
WAIT 🔒 - How long
spawnwaits for srv: the person’s 30 s countdown in the pane (srv’sagent_notice), then anagent.openthat may install the worker’s CLI (150 s), with room to spare. A wait that ran out while srv carried on would launch a worker that never gets its brief.
Functions§
- ask_
go_ 🔒ahead ask_go_ahead: asks the person to go ahead with a host agent that shares a folder with a container agent (/api/v1/agent/folder-overlap-ask); srv shows them the ask in this agent’s pane and answers where it stands.- ask_
pin_ 🔒change ask_pin_change: asks the person to move or forget one pin (/api/v1/agent/pin-ask); srv builds the card from its own record of the pin, shows it in this agent’s pane, and answers where the ask stands.- brief_
message 🔒 - The worker’s first message: who it is, who it reports to, then the leader’s brief. It names the tool exactly: a worker that went looking for “SendMessage” found Claude Code’s own cross-session tool, whose message reaches the leader unverified and isn’t counted as a report.
- call 🔒
- capitalised 🔒
- container_
ask 🔒 - Where the new agent runs, as
spawn, a worker ofworkersandcreateask for it. - container_
caches 🔒 container_caches: a container agent’s cache volumes, read (their sizes) or, withclear, removed, by srv as the agent this process’s token names (/api/v1/agent/container/caches).- create_
agent 🔒 create: a named agent from a seeded template (/api/v1/agent/create), not started. srv may wait on the user’s answer, so it has the same wait asspawn.- definition_
action 🔒 update,bundles,hideandunhide: srv acts on the definition of the agent inagent(a picker template intemplatefor hide and unhide) as the agent this process’s token names, and records it under that agent (/api/v1/agent/{update,bundles,hide,unhide}).- definition_
params 🔒 - The body of an
updaterequest: the agent and eachupdatefield given. - env 🔒
env_getandenv_set: a definition’s extra environment variables, read or changed by srv as the agent this process’s token names, which records the change under that agent (/api/v1/agent/env).- env_
request 🔒 - What
env_getandenv_setsend srv (/api/v1/agent/env): the definition (the caller’s own when none is named) and, for a set, the whole text or the variables to set and unset.linesgoes as written, not trimmed. A number or a boolean given as a value is sent as its text. - export_
agent 🔒 export: one agent saved as a portable archive file under the caller’s own working folder (POST /api/v1/agent/export). srv writes the file; nothing of it passes through here.- handover_
action 🔒 bring_backandmove_status: the hand-over state of an agent saved to move (POST /api/v1/agent/<action>).- import_
agent 🔒 import: an agent archive put in My Agents (POST /api/v1/agent/import). srv reads the file; it asks the user ascreatedoes unless this is adry_run.- lifecycle 🔒
start,stop,detach,deleteandrotate_token: srv acts on the agent inagentas the agent this process’s token names, and records it under that agent (/api/v1/agent/{start,stop,detach,delete,rotate-token}).- message_
stats 🔒 Agents message_stats: what messages cost per agent per day, from srv’s audit file (read-only).- migrate_
ids 🔒 migrate_ids: the agent id update, one step at a time (/api/v1/agent/migrate-ids).stepisplan(the default; changes nothing),stop,applyorrollback(the latest finished run); srv acts as the agent this process’s token names and records every step butplanunder it.- move_
action 🔒 move: one agent moved to another computer on the LAN (POST /api/v1/agent/move). srv does the whole move; the answer says where it ended, and a move that stopped says how to continue it.- mute_
quiet 🔒 mute_quiet: a leader tells the quiet watch that one of its agents will be quiet forminutes(/api/v1/agent/mute-quiet).- open_
many 🔒 openwithagents: srv opens them all or none (/api/v1/agent/open_many).- open_
view 🔒 Agents openwithhostandview: true: srv puts a watching pane overagentof the paired computerhoston this agent’s own window (/api/v1/agent/open_view). Nothing runs on the other computer as a result, and the pane can’t be made to drive: only its person’s click in the pane does that.- own_
context 🔒 contextandcompact: the caller’s own pane only, which srv resolves from this process’s agent token (X-Agent-Token, sent on every request), never from a name (SPEC_AGENT_SELF_COMPACTION_2026_10_23.md §3.3).- ready 🔒
ready: the caller answers the note that asked it to prepare for a change, as its own pane, which srv resolves from this process’s agent token likecontextandcompact(/api/v1/agent/self/ready).- refuse_
operator_ 🔒fields - Refuses what decides what an agent runs, where its traffic goes or which project files it reads: before a local
request is made, and before a remote one is sent (over
hostit would otherwise be dropped without notice). - remote_
agents 🔒 start,open,stop,set_seat,rename,env_getorenv_seton another machine (host): srv signs the request as this agent and the other machine’s srv carries it out (agents.<action>, spec §4.3). Any other action refuses ahost, so a call never quietly runs here when it was meant for there.- rename_
agent 🔒 rename: the agent inagentgets the displayed name inname, by srv as the agent this process’s token names, which records it under that agent (/api/v1/agent/rename).- route_
ask 🔒 - The harness and model route the new agent runs on, as
spawn, a worker ofworkersandcreateask for them. - routes 🔒
routes: the model routes a spawn or create may name (/api/v1/agent/routes), read-only.- set_
container_ 🔒limits set_container_limits: a container agent’s CPU and memory limits, read or changed by srv as the agent this process’s token names (/api/v1/agent/container/limits). Neithermemory_mbnorcpusreads them.- set_
seats 🔒 set_seat: seats set or cleared by srv as the agent this process’s token names, which records each change under that agent (/api/v1/agent/seats).seatsgoes as given; srv checks the shape and every seat.- spawn 🔒
spawn: srv builds a worker from this agent’s definition and opens it next to it (/api/v1/agent/spawn), then the brief goes to the worker as this agent’s own message, signed with its key, so it arrives host-verified and the worker can answer with Message send.- spawn_
many 🔒 spawnwithworkers: srv checks them all, tells the user once, and launches all or none (/api/v1/agent/spawn_many); only then does each brief go to its worker, so a refused or failed batch has sent nothing.- update_
container 🔒 update_container: srv removes the named container agent’s container, so its next message starts it from the current agent image. Withcontainer_imageit first changes which of the two shipped images the agent runs. Refused while that agent has a turn running.- wants_
view 🔒 openwithview: true: show another computer’s agent in a pane on this window, watching only.- watch 🔒
watch: the recent transcript of an agent, then what it wrote sinceafter(/api/v1/agent/watch). Withwait_secondssrv holds the call until a line arrives, so the client waits a little longer.- workers 🔒
workers: this agent’s own workers, from srv (/api/v1/agent/workers).