Hub Tools Reference

The MCP tools an orchestration hub uses to run agents on your joined machines. nfltr orch and nfltr mcp --toolset hub (in your own Claude Code session) serve the same set on the hosted nfltr.xyz relay.

The hub decides everything: what to spawn, where, with which model, when to continue or stop. nfltr only dispatches, routes messages, persists and reports. spawn_agent makes no model call; the first model call is the agent's own.


Tools

ToolInputResult
spawn_agentprompt (the whole brief), optional constraintsagent_id, status: pending, fleet, returned immediately
send_messageagent_id, textmode: steer (running: delivered into the live session between tool calls) or mode: continue (finished or stopped: a new turn in the same session and workspace, on the same machine)
stop_agentagent_id, optional reasonthe agent; its cancellation arrives through wait_for_agents
list_agentsnoneper agent: status, worker, machine, prompt summary, turns, progress, last activity; fleet
wait_for_agentsoptional agent_ids, timeout_ms (default 30000, max 600000)completions[], pending[], timed_out, fleet
list_nodesnonejoined machines: machine, labels (resources, description, allowed repositories), max_agents, running_agents, free_agents; fleet
list_worker_peersnoneconnected agents with their labels and free slots

A node starts no agent process until a spawn needs one, so a joined machine shows in list_nodes, not in list_worker_peers.

Completions

Each entry of completions[] carries the agent's final text, its structured result when it gave one, artifacts, branch and sha when it pushed work, state, worker, machine, turn, and usage (tokens and USD as reported). Failures arrive the same way, as a completion with a reason:

ReasonMeaning
node_lostthe node running the agent died mid-turn
tools_not_allowedthe agent needed a command the node does not allow (joined without --allow-all-tools)
budget_exceededthe agent's or the hub's budget was reached
no connected worker satisfies constraints …nothing eligible connected within the spawn's bound; lists what was connected
cancelledstopped by stop_agent or timeout_ms; artifacts holds a recovery patch of the uncommitted edits

Spawn constraints

All optional; unknown keys are rejected.

KeyMeaning
machinehard filter: the machine id (from list_nodes)
labelshard filter: every label must match exactly (e.g. flavor to pick a harness on a node that has several)
model, effortpassed to the agent unchanged; omitted stays omitted
isolationshared or per_task workspace
mutates_workspacetrue gives the agent a git task workspace whose edits come back as branch, sha or patch. A permission, not an obligation: a turn that edits nothing completes with its answer. It does not limit what the agent's tools do on the machine; the node's tool setting does.
timeout_mshard bound per turn, including waiting for a free slot or for a named machine to join (default 30 s for that wait)
workspace{repo, ref}: the agent works in a worktree of that repository at ref. Routed only to nodes whose checkout is that repository or whose --allow-repo matches it; every spelling of one remote matches.
output_validation{require_object, allowed_statuses, required_fields, non_empty_fields}: the agent must answer with a structured result that satisfies it (say so in the brief); a nonconforming result fails the turn. Omitted: plain text.
budget{max_tokens, max_usd}: cap on this agent's reported usage across its turns; the running turn is stopped (budget_exceeded) and further messages refused. max_usd needs max_tokens.

Fleet capacity

fleet (in spawn_agent, list_agents, wait_for_agents and list_nodes results) is the capacity at that moment: free_agent_slots = worker_free_slots (free slots on connected agents) + node_free_agents (agent processes the nodes may still start), with connected_workers, node_max_agents, node_running_agents, nodes_unreachable and read errors. It states capacity only; using it is the hub's call.

Placement is mechanism only: among eligible agents, one with a free slot is chosen, idle first; if none is free, a node that matches starts one; if every slot is busy the agent stays pending and dispatches when a slot frees, within its bound. A continuation always runs where its session is.

Budgets

Hub-wide caps: --hub-max-tokens N and --hub-max-usd X on nfltr orch or nfltr mcp --toolset hub cover every agent of the hub; once passed, running turns are stopped and spawns and messages refused. Usage is what agents report; every completion carries it. A stopped or lost turn's tokens are counted up to the stop, but its cost is never estimated (cost_unreported: true), so a USD cap needs a token cap. Nothing is capped by default.

$ nfltr orch --hub-max-tokens 2000000 --hub-max-usd 5 "<goal>"

Delivery guarantees

Related: Use nfltr from Claude Code · Many agents across machines · Join machines as nodes.