Skip to main content

Module agent_rename

Module agent_rename 

Source
Expand description

Agents rename (POST /api/v1/agent/rename): an agent gives an agent on this machine a new displayed name, by the same path the window’s rename takes (agent_handlers::rename), so the pane, My Agents, the Swarm, message addressing, seats and the Kanban all follow. The agent’s id, slug, signing keys and workspace folder do not change: they are fixed when it launches. The old name keeps reaching it as a former name, and no other agent may take it.

The caller is the agent its token names; a request without one is refused, so a change is never attributed to the operator. A name another agent has now is refused. Each rename, and each refusal, is recorded in the audit log under the calling agent.

Structs§

Actor 🔒
The agent making the request.
RenameRequest 🔒

Constants§

AUDIT_ACTION 🔒
The audit entry’s action for a rename.
MAX_NAME_CHARS 🔒
The longest name: what a pane tab and a Swarm row can show.

Functions§

actor_of 🔒
audit 🔒
handle_agent_rename 🔒
run 🔒
run_as 🔒
run_remote 🔒
rename for an agent on another machine (remote_ops::agent_ops): the same checks and change a local call has, recorded under who (slug@machine).