MCP Tool Surface
Agents talk to the SupaCloud platform through an MCP registry defined in
server/src/services/mcp/. Every tool belongs to exactly one tier; the tier
determines which allowlist entry unlocks it and which rate-limit bucket it
consumes.
Tiers and allowlist entries
Section titled “Tiers and allowlist entries”| Tier | Allowlist wildcard | Also granted by |
|---|---|---|
| Baseline | unconditional (always on) | supacloud.*, supacloud.full |
| Read | supacloud.read.* |
supacloud.full, exact name |
| Ops | supacloud.ops.* |
supacloud.full, exact name |
script.run carve-out |
supacloud.script.run |
supacloud.full, exact name |
| Scaffold | supacloud.scaffold.* |
supacloud.full, exact name |
| Deploy | supacloud.deploy.* |
supacloud.full, exact name |
supacloud.ops.* does not include script.run. Scripts can bind to
workspace resources and secrets at runtime, so the carve-out requires a
deliberate additional grant.
A profile-less task (workflow or auto-developer task with no
agent_profile_id) resolves to the read-only default surface
(supacloud.read.*). Ops and deploy tiers remain fail-closed unless an
explicit agent profile grants them (ADR 0033).
Any individual tool may also be granted by its exact name or by
supacloud.<tool-name>.
Baseline tools (N+4, always on)
Section titled “Baseline tools (N+4, always on)”Granted unconditionally to every authenticated agent session.
| Tool | Description |
|---|---|
delegate_subtask |
Delegate bounded work to another agent profile |
get_subtask_result |
Read the result of a delegated child task |
cancel_subtask |
Cancel a delegated child task |
memory.search |
Full-text search over workspace and project memories |
memory.get |
Read one memory by UUID |
memory.list_recent |
List recent workspace and project memories |
memory.propose_review |
Enqueue a pending memory review proposal (no immediate mutation) |
outcome.recent_for_profile |
Read recent outcome telemetry for this task’s agent profile |
review.submit_verdict |
Submit a review-class node’s structured verdict (verdict, head_sha, clean_rounds, criteria[], findings[], commands[] as {command, exit_code, summary}; a check verified by CI is a criteria[] entry {id: "ci: <command>", status: not_applicable}, never a command); the gate reads it. Refused outside a review-class node (audit, and the independent review slots review_1..review_3) |
implement.report |
Report the implement node’s self-check (commands[] with exit codes); a reported failure enters the bounded rework loop. Refused outside the implement node |
Read tier — supacloud.read.*
Section titled “Read tier — supacloud.read.*”All tools are read-only and workspace-scoped from the task session.
Workspace and platform reads
Section titled “Workspace and platform reads”| Tool | Description |
|---|---|
workspace.info |
Active workspace metadata (slug, name, member count, budget remaining, plan tier) |
projects.list |
Projects visible in the workspace |
project.get |
Single project detail |
tasks.list_active |
Running and queued tasks in the workspace |
tasks.get |
Single task detail (cost, duration, last event) |
runners.status |
Runner availability and capacity |
schedules.list |
The workspace’s schedules, paused ones included (enabled: false); each names its pinned profile as profile_slug (null without a pin) and its harness as agent_type |
resources.list |
Configured resources — kind, name, status only; no connection strings or secrets |
apps.list |
Apps with deployment status and public URL |
app.get |
Single app detail |
workflows.list |
Defined workflows |
workflow.get |
Workflow detail including steps (flattened from workflow_nodes + workflow_edges) |
app.migration.list |
Pending and applied migrations for an app |
Run observation
Section titled “Run observation”Read-only run, board, and event tools. Runs are workspace-scoped first, so a run’s detail and events never leak across workspaces.
| Tool | Description |
|---|---|
run.list |
List recent top-level runs of every kind (agent/workflow/script/app), newest first, with optional status/kind/project/task/app narrowing |
run.get |
Read one run by id plus its flattened descendant run tree (workflow node runs and loop iterations) |
run.events |
Read a run’s event log, paginated by sequence number (after_sequence / limit / tail). Since #977 a workflow run’s log also carries a per-node step timeline (workflow_node_started / _waiting / _completed / _failed / _skipped) |
approvals.list |
List the workspace’s waiting decision gates — paused task gates (filter: "tool", prompt redacted) and workflow human gates (filter: "workflow") |
backlog.list |
List backlog items, optionally narrowed by project and state |
backlog.get |
Read one backlog item with its prior runs, routing decision and merge gates (the Merge Gate Ledger and the required checks) |
routing.explain |
Explain a backlog item’s tier: the source, the matched rule, the required reviews and the routing file’s findings |
Source reads (W7-3)
Section titled “Source reads (W7-3)”| Tool | Description |
|---|---|
app.files.list |
List app source files |
app.files.get |
Read one app source file (body capped at 64 KiB) |
script.get |
Read a script definition |
script.list |
List scripts in the workspace |
app.builds.list |
List build history for an app |
Issue reads (ADR 0033)
Section titled “Issue reads (ADR 0033)”Resolved from project.issue_tracker ?? project.git_provider — covers all
six sources (GitHub, GitLab, Bitbucket, Forgejo, Linear, Notion).
| Tool | Description |
|---|---|
issue.get |
Read a single issue by ID |
issue.list |
List open issues for the task’s project |
CI evidence reads (SC-13)
Section titled “CI evidence reads (SC-13)”Read. Review-class nodes only. CI contexts and artifacts of this task’s pull request
head. The project comes from the session task, never from an argument, and a task that
is not a review-class node (the audit and review slots) is refused. The auditor uses
them instead of re-running a ci_only gate command, and records such a command in its
verdict as {command, ci_context, ci_state} with no exit_code.
| Tool | Description |
|---|---|
ci.status |
The pull request (pr_number optional; default: the pull request of the task’s backlog item), its head commit and branch, every commit-status context of that head (context, state, description, target URL) and the forge’s CI artifacts for it (ci_artifact_id, name, size, run id). artifacts_status is ok, unsupported (a forge without an artifacts API, artifacts: []) or failed |
ci.artifact.get |
Import one CI artifact of that head (ci_artifact_id, at most 64 MiB) into the artifact store, deduplicated by sha256, and return {artifact_id, name, sha256, size_bytes, media_type, url} with a signed URL. An artifact of another commit is refused |
Conversation reads (#596)
Section titled “Conversation reads (#596)”Provider-agnostic support conversations (Chatwoot / Intercom). Addressed by an
explicit workspace resource name (the support channel) — there is no
project-level binding. Also granted by supacloud.conversation.*.
| Tool | Description |
|---|---|
conversation.get |
Read a single conversation by ID from a workspace resource |
conversation.list |
List open conversations for a workspace resource |
Documentation and contract reads (#844)
Section titled “Documentation and contract reads (#844)”The only tools that read neither the database nor a tenant resource. They serve
the instance-wide committed documentation corpus (docs/user, docs/admin,
docs/developer and the German mirror docs/de) and the drift-gated
machine contracts, so an agent can look up how a surface behaves instead of
guessing.
| Tool | Description |
|---|---|
docs.search |
Keyword search over the product docs. Every query term must appear in a page’s path, title or body; hits rank by term frequency and carry the path for docs.get. Optional lang (en/de) and limit (default 10, max 50) |
docs.get |
Read one page by its corpus-relative .md/.mdx path (for example user/how-to/approve-agent-actions.mdx). YAML frontmatter is stripped; the body is capped at 64 KiB. lang: "de" resolves the German mirror of the given path when it exists |
spec.get |
Read one committed contract by name: openapi_public, workflow_schema, mcp_catalog, command_catalog, gate_manifest_schema (the backlog arm’s gate manifest), delivery_spec_schema (the delivery spec format — seven JSON Schemas of format 0.2 with their version lock) or delivery_spec_schema_v0_2 (the same, pinned to 0.2). Narrow a large document with an RFC-6901 pointer (e.g. /paths or /schemas/spec); the rendered body is capped at 64 KiB and a truncated answer lists the selected node’s child keys so you can navigate down |
spec.validate |
Validate delivery specs (format 0.2) against those schemas and the rules the reference validator and its spec gate apply: IDs that belong to their domain, satisfies links resolved against the project profile and its catalogue, parameter ranges and units, state machines, coverage, scenarios and status. Pass the profile, every YAML file under specs/<domain>/ and the catalogue in files ({path, content}), further repository paths for decision_records globs in paths. Returns findings with file, field, rule and message, capped at 200. It reads nothing from the database or the repository |
models.list |
The model catalog this instance knows: provider, exact model id, context window, per-million-token prices, input modalities, tool-call and reasoning support. Filter with provider (exact id) or query (case-insensitive substring over id and display name — this is how you turn “gemini flash 3.7” into the id a run needs). limit defaults to 50, caps at 200, and total_matches reports how many matched before the cut |
models.list answers which models exist, not which ones your workspace holds
a credential for — it is instance-wide reference material and carries no
workspace fact. It also does not carry the per-model harness capabilities
(effort ladder, fast mode, subagent support) that the model pickers show; those
come from a separate per-instance capability table.
spec.validate needs no documentation corpus: the schemas are compiled into the server, so it never degrades.
spec.get deliberately does not expose docs/openapi/management.json. The
management spec is the M2M control-plane surface, not agent reference material;
exposing it would widen the agent surface and needs an explicit owner decision.
Because they carry no tenant data and need no task context, all three are also
reachable through the external MCP gateway (ADR 0054) with an mcp:read token.
Ops tier — supacloud.ops.*
Section titled “Ops tier — supacloud.ops.*”Write tools; 10 calls per task. supacloud.ops.* does not include script.run.
| Tool | Description |
|---|---|
workflow.trigger |
Start a workflow run |
schedule.create |
Create a new schedule: cadence (once, daily, weekly, monthly, interval; cron is a deprecated alias), time_of_day, weekday, anchor_day, next_run_at, timezone, interval_minutes (minimum 5), and exactly one target: a task (profile_slug + prompt; the profile is pinned on the schedule, so its runbook applies at every fire), a workflow (workflow_id) or an App (app_id) run on each fire |
schedule.update |
Update an existing schedule |
schedule.pause |
Pause a schedule |
schedule.resume |
Resume a paused schedule |
schedule.delete |
Delete a schedule in the session workspace |
repo_sync.trigger |
Trigger a repo sync push or pull |
issue.comment |
Post a comment on an issue (any of the six providers) |
issue.transition |
Transition an issue to a new state |
pr.create |
Create a pull request (git forge only) |
conversation.reply |
Post a customer-visible reply (or private note) into a conversation (#596; idempotency-keyed) |
conversation.assign |
Assign a conversation to an agent (#596) |
conversation.resolve |
Resolve (close) a conversation (#596; idempotency-keyed) |
conversation.handoff |
Hand a conversation off to another team (#596) |
task.create |
Create and launch a task in a project of this workspace (#977; the budget and admin-mandated-closeout clamps in the service floor apply) |
task.cancel |
Cancel a running task of this workspace (#977) |
task.intervene |
Send an intervention message into a running task (#977; delivered with a SYSTEM origin and a [coordinator] prefix) |
approval.decide |
Decide a waiting gate (#977). Question-class task gates only — tool, visual and tier_change gates, and every workflow human gate, are refused: those exist to put a PERSON in the loop, so a machine may not answer them (the #858 invariant) |
run.rerun_node |
Re-execute one failed or cancelled top-level workflow node, superseding the failed child run (#977; stop-policy nodes only, never a loop frame) |
permission.grant |
Grant a scoped tool permission (#581-A) |
permission.revoke |
Revoke a scoped tool permission (#581-A) |
backlog.enqueue_item |
Add a work item to the backlog of a project without a tracker intake (SC-23). Refused for a forge or tracker project: work enters there as issues that SupaCloud’s tracker writer, the only writer to that tracker, creates and labels from the repository’s work-item contracts. Never writes a label |
backlog.reprioritize |
Change one backlog item’s priority (0 = highest) through the board’s reorder path (SC-23) |
backlog.hold |
Park one backlog item (blocked, a linked run is cancelled) with an audited reason (SC-23) |
backlog.release |
Return a parked backlog item to queued with an audited reason (SC-23) |
backlog.transition |
{item_id, target, reason, answer?, expected_head_sha?}: move one backlog item as a person moves it on the board, through the board’s own services. target is one of queued, in_progress, needs_info, blocked or done (anything else is refused before any write); reason is required, 1 to 2048 bytes, and lands in the audit row. The board’s checks apply: in_progress means dispatch now, under the dispatcher’s limits, and done runs the merge gate exactly like a release on the board, so a refused merge names its reason and moves nothing. done requires expected_head_sha (refused with any other target): the full commit id of the pull request head the release is for, as backlog.get shows it in gates.head_sha. A head that moved since refuses the release with release_head_changed before anything changes. Audited and counted like every Ops tool |
script.run carve-out — supacloud.script.run
Section titled “script.run carve-out — supacloud.script.run”| Tool | Description |
|---|---|
script.run |
Execute a workspace script |
Counts against the ops rate-limit bucket (10/task). An optional
script_allowlist array on the agent profile further restricts which scripts
(by slug) may be called.
Scaffold tier — supacloud.scaffold.*
Section titled “Scaffold tier — supacloud.scaffold.*”Proposal and task-spawn tools. Proposals create a pending proposals row for
human review without mutating durable state; task-spawn tools launch a
follow-up agent task addressed at an App or Script scaffold.
| Tool | Description |
|---|---|
scaffold.script.propose |
Propose a new or updated script |
scaffold.app.propose |
Propose a new app |
scaffold.app.file_upsert.propose |
Propose an app file upsert |
scaffold.workflow.propose |
Propose a new workflow |
task.create_for_app_scaffold |
Spawn a follow-up agent task for an app scaffold |
task.create_for_script_scaffold |
Spawn a follow-up agent task for a script scaffold |
Deploy tier — supacloud.deploy.*
Section titled “Deploy tier — supacloud.deploy.*”Deployment lifecycle tools; 5 calls per task.
supacloud.ops.* does not include deploy tools.
In addition to the allowlist grant, the resolved task actor must hold workspace owner or admin permission — the same check the Deployment service applies for HTTP requests.
Every deploy-tier tool — app.deploy, app.undeploy, app.pause, app.resume
and app.migration.apply — requires the human-approved two-step confirmation
protocol (see below).
| Tool | Description |
|---|---|
app.deploy |
Deploy an app to its public route |
app.undeploy |
Remove an app from its public route |
app.pause |
Set an app to maintenance mode |
app.resume |
Resume a paused app |
app.migration.apply |
Apply pending app migrations |
Rate limits
Section titled “Rate limits”Per-task caps
Section titled “Per-task caps”| Tier | Default | Config env var |
|---|---|---|
| Baseline + Read | 50 / task | AGENT_MCP_TOOL_RATE_LIMIT |
Ops (including script.run) |
10 / task / tool, 40 / task over all Ops tools | — (project/workspace mcp_caps, profile override) |
| Scaffold | 10 / task | — |
| Deploy | 5 / task | — (project/workspace mcp_caps) |
The per-task Ops budgets (per tool and in total) are durable: they are counted from the task’s audited calls plus its in-flight reservations, so a hub restart does not reset them. The total never defaults below the per-tool budget.
Workspace and profile caps
Section titled “Workspace and profile caps”Per-task limits are checked first; only if a call is within its per-task budget
is the workspace-daily / profile-hourly cap reservation attempted (the per-task
slot is refunded if the workspace/profile reservation fails). Counters are
derived from audit_events so they survive restarts.
| Scope | Tier | Default | Config env var |
|---|---|---|---|
| Workspace / day | Ops | 100 calls | AGENT_MCP_WORKSPACE_OPS_DAILY_LIMIT |
| Voice / day (share) | Ops | 30 % of the workspace-day ceiling, voice calls only | AGENT_MCP_VOICE_OPS_DAILY_SHARE_PCT |
| Voice number / hour | Ops | 30 calls per dialed number, across calls | AGENT_MCP_EXTERNAL_OPS_HOURLY_LIMIT |
| Workspace / day | Deploy | 20 calls | AGENT_MCP_WORKSPACE_DEPLOY_DAILY_LIMIT |
| Workspace / day | Scaffold proposals | 10 calls | AGENT_MCP_WORKSPACE_PROPOSAL_DAILY_LIMIT |
| Workspace / day | Scaffold task-spawns | 3 calls | AGENT_MCP_WORKSPACE_TASK_SPAWN_DAILY_LIMIT |
| Profile / hour | Ops | 30 calls | AGENT_MCP_PROFILE_OPS_HOURLY_LIMIT |
| Profile / hour | Deploy | 10 calls | AGENT_MCP_PROFILE_DEPLOY_HOURLY_LIMIT |
| Profile / hour | Scaffold proposals | 10 calls | AGENT_MCP_PROFILE_PROPOSAL_HOURLY_LIMIT |
| Profile / hour | Scaffold task-spawns | 3 calls | AGENT_MCP_PROFILE_TASK_SPAWN_HOURLY_LIMIT |
| Project / day | Ops | the workspace-daily default × the autonomy factor (×1.0 up to level 50, ×1.5 at 75, ×2.0 at 100) | — (mcp_caps.ops_per_project_day) |
A voice call is capped per dialed number, not per call, and voice calls together may spend only their share of the workspace day, so the autonomous loop always keeps the rest.
Per-project and per-workspace budgets (SC-23)
Section titled “Per-project and per-workspace budgets (SC-23)”Every Ops budget is resolvable per project: profile override ?? project
mcp_caps ?? workspace mcp_caps ?? instance env ?? built-in. A project sets
ops_per_task_per_tool, ops_per_task_total, ops_per_profile_hour,
ops_per_project_day, deploy_per_task_per_tool and deploy_per_project_day
(PUT /api/projects/{id}/mcp-caps, owner/admin, audited); the workspace sets the same
keys as project defaults (PUT /api/workspaces/{id}/mcp-caps).
The workspace-daily ceiling stays the outer safety net and is always checked
last. Only the workspace owner can move it (ops_per_workspace_day in the
workspace document, audited); a raise above the instance default is bounded by the
plan entitlement mcp.ops_daily_max (unlimited on Enterprise, no raise on the other
plans), a lowering always applies. No agent and no profile can raise any budget: the
MCP profile.create / profile.update tools do not accept mcp_ops_per_task_cap /
mcp_ops_per_hour_cap.
The layers are checked narrowest first: task total, task + tool, project day,
profile hour, workspace day. limits.get reports every layer with
limit/used/remaining and a retry_after_seconds bound once a window is
exhausted.
Refusals
Section titled “Refusals”Rate-limit exhaustion is a classified refusal that names the refusing layer. On the
external §29 gateway it is a JSON-RPC error (HTTP 200) whose data.code is
rate_limited or cap_exceeded, data.retryable is true (#1174), data.layer
names the layer (tool, task_total, project_daily, profile_hourly,
workspace_daily, external_actor) and data.retry_after_seconds says when a retry
can pass (null for the per-task layers, which never replenish). On the in-container
bridge the server answers HTTP 429 with the error code mcp_cap_exceeded and a cap
object carrying the same layer and retry_after_seconds; the agent runner surfaces
it to the agent as a structured, retryable tool error, so the agent waits or parks
the item instead of failing. The message reads MCP <layer> cap reached (<used>/<limit>).
Delegation capacity
Section titled “Delegation capacity”delegate_subtask counts active children against the fan-out cap, a
per-workspace setting: the subtask_children_per_parent key of
workspace_settings.mcp_caps (default 10; there is no hub-wide environment variable
for it), so a coordinator that works items one
after another is never refused for children that already finished. A separate
lifetime cap (SUBTASK_MAX_LIFETIME_CHILDREN_PER_PARENT, default 50) stops a
runaway delegate loop. An optional project_id runs the child in another project of
the same workspace; a project of another workspace is refused as not found. The child still runs under the
session’s capability allowlist. Cross-project backlog dependencies are deliberately not
modelled: one project is one repository, and a paired change in another repository
is filed as a work item of that project.
Tier requests
Section titled “Tier requests”delegate_subtask and task.create accept an optional tier (flagship,
balanced, fast, independent_review; independent-review is accepted as an
alias). The child is bound to that calibrator tier: at launch it runs the first
reachable model of the workspace’s chain for the tier (ADR 0077).
A task.create whose config.model_tier names a tier is the same request. A
requested tier stronger than the caller’s own is refused with 403 unless the
caller’s agent profile sets allow_tier_escalation; the order is fast <
balanced < flagship = independent_review, and a caller whose own tier is
unknown counts as fast. A tier request for a child profile with a fixed model
is a 400, and a tier with no reachable entry is a 422 that names the tier and
the harness. profile.create / profile.update accept model_policy: "tier"
with model_tier, but never allow_tier_escalation: an agent cannot grant itself
a stronger tier.
Deploy confirmation protocol
Section titled “Deploy confirmation protocol”Every deploy-tier tool (app.deploy, app.undeploy, app.pause, app.resume,
app.migration.apply) runs in two steps, and a person confirms between them.
The agent that asks for a deploy can never confirm it.
Step 1 — request approval. Call the tool without confirmation_token.
Nothing is performed. The server records a human-only tool-approval gate (a
task_tool_approvals row of kind tool) and returns:
{ "confirmation_required": true, "approval_required": true, "pending_approval": "<gate id>", "confirmation_token": "<HMAC-SHA256 token>", "expires_in_seconds": 86400, "message": "Not performed. A person must approve this call first; ...", "changes_summary": { "...": "..." }}The token is signed with SUPACLOUD_MCP_CONFIRMATION_SECRET over the hash of the
call’s inputs together with the gate id, and stays valid for 24 hours
(expires_in_seconds). A task holds at most one pending gate: repeating the
identical call returns the same gate, and a different call while a gate is
pending is refused with 409 naming it. The gate shows up in the approvals inbox
— the web inbox, the tool-approvals / approve-tool terminal commands, and
/approvals in Telegram and Discord — and the decision reaches the agent’s
mailbox.
Step 2 — redeem after a person approved. Call the tool again with the same
arguments plus confirmation_token and approval_id (the pending_approval of
step 1; a token without it is 400). The server verifies the signature, the
expiry and that the token signs this call’s inputs for that gate, and it runs the
call only against an approved gate: the gate must be approved, and the decider
must be a person, never the task’s own session or a task: / mcp: / sweep
label, who is still a workspace owner or admin (the deploy-admin bar). A token
redeemed before a person approved, after a rejection, for another gate or by any
other task is refused as Forbidden.
The token binds the call to its inputs and its gate; it is not the approval. One
approval acts at most once: the confirmed call is deduplicated on the gate id,
so a retry of the same second call never deploys twice. No idempotency_key is
needed.
approval.decide cannot decide a deploy gate: its tool half is question-class
only, so a coordinator agent cannot approve the deploy gate another agent raised.
The HMAC key is a server-side secret set via SUPACLOUD_MCP_CONFIRMATION_SECRET
(minimum 32 bytes). When unset, every deploy-tier call fails closed. The key is
never derived from task, user, workspace, or profile credentials.
The at-most-once record of a confirmed call lives in mcp_idempotency_keys
under the key approval:<gate id> (scoped to task_id + tool_name) and is cleaned
up 24 hours after the parent task reaches a terminal state.
Security properties
Section titled “Security properties”- No secret exposure.
resources.listreturns kind, name, and status only — never connection strings, passwords, or tokens. - No credential access. Agents cannot read or modify workspace credentials through MCP.
- Workspace isolation. All queries are scoped to the task’s workspace.
- Capability ceiling. An agent can only start or author work at or below its own
reach.
delegate_subtask,task.create_for_app_scaffold,task.create_for_script_scaffoldandtask.createrefuse (403) a target profile that grants a tool the session cannot call, direct memory writes, a wider script allowlist, a lower interactive-approval bar or a higher autonomy level;profile.createandprofile.updaterefuse to store such a profile. Every child carries the caller’s tool set inconfig.mcp_ceilingand its blast radius indenied_tools/environment_scope, and its session is intersected with them, so a later profile edit cannot widen it.task.createaccepts onlygit_workflow,model,provider,effort,mode,subagents,max_subagents,closeout,resource_class,model_tier,denied_toolsandenvironment_scopeinconfig(400 for any other key). Work a human launches from the web or the Management API is not bounded. - Audit trail. Every tool call emits an
audit_eventsrow with task correlation ID, tool name, status, and error class.
Related
Section titled “Related”- ADR 0028 — Extended MCP agent surface
- ADR 0033 — Always-on baseline and read-only default surface
- Management API — M2M operator surface (distinct from agent MCP)