# Refusals

A refusal is how Vaubaan Gateway answers a call it will not run: a JSON-RPC error with code `-32603` whose `data` carries the refusal's `code`, the fields of that code and a `hint` telling the agent what to do. Nothing was executed and nothing is held: the gateway never keeps a call waiting.

This page lists every code with what the agent does and what you, the person behind the mission, do next. It is generated from the gateway: the codes and fields from its builders, the agent's side from the [reference for agents](/docs/reference/for-agents) every instance serves.

| Code | What happened |
| --- | --- |
| [`risk-not-accepted`](#risk-not-accepted) | The mission does not hold a permission this call needs. |
| [`budget-exhausted`](#budget-exhausted) | The limit of a permission is reached for the period. |
| [`approval-required`](#approval-required) | The mission creator asked to be asked first for one or more permissions of the call. `risk_ids` lists them; one request covers the call. |
| [`resource-not-in-mission`](#resource-not-in-mission) | The arguments cite a resource outside the mission. |
| [`account-ambiguous`](#account-ambiguous) | The mission holds several accounts of the call's service, and the call names no resource or resources of two of them. |
| [`rate-limited`](#rate-limited) | Too many actions on a permission in a short window. |
| [`account-unavailable`](#account-unavailable) | The account behind the call needs reconnecting. |
| [`account-revoked`](#account-revoked) | The account behind the call no longer serves this mission: removed (`final: true`) or its creator lost access (`final: false`). |
| [`mission-inactive`](#mission-inactive) | The mission is expired, without an owner (`orphaned`) or stopped (`revoked`). |
| [`wrong-credential-kind`](#wrong-credential-kind) | The key was presented on the wrong door. |

A refusal as the agent receives it:

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "error": {
    "code": -32603,
    "message": "Vaubaan refused the call: approval-required",
    "data": {
      "code": "approval-required",
      "risk_id": "supabase[prod].migration-write",
      "risk_ids": [
        "supabase[prod].migration-write"
      ],
      "fingerprint": "sha256:3f9a…",
      "approval_url": "https://your-domain/requests/req_02",
      "expires_at": "2026-11-20T18:00:00Z",
      "approval_valid_seconds": 600,
      "hint": "'supabase[prod].migration-write' requires the mission creator's approval for each action. Nothing was executed and nothing is held. An approval request is open at https://your-domain/requests/req_02 until 2026-11-20T18:00:00Z. Once granted, replay this call with the same tool and exactly the same arguments within 600s of the grant: the approval is used once, and any change of the arguments asks again. Hand this URL to the human steering you; do not retry in a loop and do not try to work around the refusal."
    }
  }
}
```

**The agent never works around a refusal**: no other tool, no other key, no direct access to the service, no splitting an action to slip under a limit. A link in a refusal (`claim_url`, `approval_url`) is for you: only the mission's creator, signed in, can answer it, and the same request is under **Waiting for you**.

## `risk-not-accepted`

**What happened.** The mission does not hold a permission this call needs.

**What the agent does.** Do not look for another way to the same effect. Tell the human which permissions are missing (`missing_risks`).

**What you do.** Nothing waits for you unless the agent asks: when it asks for the missing permission, the request is under **Waiting for you**, where you add it or refuse. To give it yourself, **Edit mission** and tick it. Add it only if the task needs it.

**Fields**: `code`, `missing_risks`, `executed_slices`, `hint`.

## `budget-exhausted`

**What happened.** The limit of a permission is reached for the period.

**What the agent does.** Stop that kind of action. Hand `claim_url` to the human; continue with work that does not need it. Do not retry in a loop.

**What you do.** Open the link, or **Waiting for you**: give more for this period or reset the limit, or let the period end. A one-off mission has no next period, so only your answer reopens it.

**Fields**: `code`, `risk_id`, `quota`, `consumed`, `period_end`, `claim_url`, `hint`.

Example hint:

> Budget exhausted for 'gmail.draft-write': 20/20 actions used this period. The quota reloads at 2026-11-21T00:00:00Z. A claim for the mission creator is open at https://your-domain/requests/req_01. Hand this URL to the human steering you; do not retry in a loop and do not try to work around the refusal.

## `approval-required`

**What happened.** The mission creator asked to be asked first for one or more permissions of the call. `risk_ids` lists them; one request covers the call.

**What the agent does.** Nothing was executed. Hand `approval_url` to the human, wait for their yes, then replay the call with **exactly** the same arguments.

**What you do.** Open the link, or **Waiting for you**: the request shows the exact call. Approve it or refuse it; unanswered, it closes when it expires. An approval is used once, for that call with those arguments.

**Fields**: `code`, `risk_id`, `risk_ids`, `fingerprint`, `approval_url`, `expires_at`, `approval_valid_seconds`, `hint`.

Example hint:

> 'supabase[prod].migration-write' requires the mission creator's approval for each action. Nothing was executed and nothing is held. An approval request is open at https://your-domain/requests/req_02 until 2026-11-20T18:00:00Z. Once granted, replay this call with the same tool and exactly the same arguments within 600s of the grant: the approval is used once, and any change of the arguments asks again. Hand this URL to the human steering you; do not retry in a loop and do not try to work around the refusal.

## `resource-not-in-mission`

**What happened.** The arguments cite a resource outside the mission.

**What the agent does.** Use one of the refs in `allowed_resources`, or ask the human to have the resource added.

**What you do.** If the task needs that resource, **Edit mission** and select it: the agent keeps its key and its next call reaches it. A resource created outside the gateway reaches a mission that takes "the resources found later" once discovery finds it.

**Fields**: `code`, `cited_ref`, `account`, `allowed_resources`, `hint`.

Example hint:

> Resource 'acme/billing' is not part of this mission on account 'acme'. The mission may touch: acme/web. A resource this mission creates through the gateway is reached right after its creation. For one created elsewhere, use one of these refs, or ask the mission creator to add the resource: they edit the mission, your key stays the same and your next call reaches it.

## `account-ambiguous`

**What happened.** The mission holds several accounts of the call's service, and the call names no resource or resources of two of them.

**What the agent does.** `accounts` lists each one with its resources. Call again naming one resource of the account you mean, or add `vaubaan_account` (its name or id); one call per account.

**What you do.** Nothing: the agent calls again naming the resource it means. A mission may hold several accounts of one service (one GitHub repository per key, say); each call runs with the account of the resource it names.

**Fields**: `code`, `service`, `accounts`, `hint`.

Example hint:

> This call names no resource, and this mission holds several GitHub accounts. The accounts and what the mission reaches on each: 'acme web' (acme/web); 'acme api' (acme/api). Call again naming one resource of the account you mean, or name the account with the argument 'vaubaan_account' (its name or id), as a list, a search or a creation needs; one call per account when you need several. The gateway never picks one for you.

## `rate-limited`

**What happened.** Too many actions on a permission in a short window.

**What the agent does.** Wait `retry_after_seconds`, retry once. Nothing was counted against the limit.

**What you do.** Nothing, usually: the agent waits and retries. If the per-minute limit is too low for the task, raise it under **Edit mission**, **Advanced**.

**Fields**: `code`, `risk_id`, `limit`, `retry_after_seconds`, `hint`.

Example hint:

> Rate limit reached for 'notion.content-append': 10 actions per 60s. Wait 12s before retrying. The quota is not consumed by this refusal.

## `account-unavailable`

**What happened.** The account behind the call needs reconnecting.

**What the agent does.** Nothing you can do fixes it. Tell the human who owns the account (`owner`).

**What you do.** The account's owner opens it under **Accounts** and reconnects it. Its missions work again with the keys they have.

**Fields**: `code`, `account`, `status`, `owner`, `hint`.

Example hint:

> Account 'me@example.com' is expired; every call through it fails until its owner me@example.com reconnects it. Contact them; nothing you can do from here fixes it.

## `account-revoked`

**What happened.** The account behind the call no longer serves this mission: removed (`final: true`) or its creator lost access (`final: false`).

**What the agent does.** Keep using the mission's other accounts. Do not retry through that one; tell the human, who can have a mission issued for its replacement.

**What you do.** Removed for good (`final: true`): create a mission for the account that replaces it. Your access withdrawn (`final: false`): ask the account's owner to give it back, and the same key works on it again.

**Fields**: `code`, `account`, `cause`, `final`, `hint`.

Example hint:

> The creator of this mission no longer has access to account 'acme-supabase' (its owner withdrew it, or the creator left the team that held it). Calls through it are refused while it is so; this same token works on it again if the access is given back. The mission still serves its other accounts: keep using them. Ask the mission creator to get the access back, or to issue a new mission for another account. Do not retry calls through 'acme-supabase'.

## `mission-inactive`

**What happened.** The mission is expired, without an owner (`orphaned`) or stopped (`revoked`).

**What the agent does.** Stop calling with this key and report to the human.

**What you do.** Expired: only its creator can extend it. Stopped (`revoked`): it never runs again; duplicate it into a new mission. Without an owner (`orphaned`): give back the access it was built on, and it serves calls again with the same keys.

**Fields**: `code`, `status`, `reason`, `hint`.

Example hint:

> This mission is expired: its end date passed. Only the mission creator can extend it. Stop calling with this token and report to the human.

## `wrong-credential-kind`

**What happened.** The key was presented on the wrong door.

**What the agent does.** A mission key only opens the execution endpoint (`/mcp`).

**What you do.** Give the agent the mission's key from the setup kit, and point it at the instance's `/mcp`. Your browser session never opens that door.

**Fields**: `code`, `door`, `presented`, `expected`, `hint`.

Example hint:

> A human-session cannot open the execution door; it expects a mission-token. A human-session opens the web interface only, never an MCP door. Credentials never cross over: use the mission-token issued for this door.

## When the key itself stops working

An HTTP 401 with JSON-RPC code `-32001` is not a refusal: the key is unknown or malformed. When `error.data.reason` is set, the key authenticated before and no longer does; the mission may still be running for its other holders.

| Reason | What happened | What the agent does |
| --- | --- | --- |
| `token-rotated` | The holder replaced this key. | Ask the human who gave you this key for the new one. |
| `token-revoked` | The holder, or the mission creator, revoked it. | Stop, and tell the human. |
| `holder-removed` | The holder was removed from the mission. | Stop, and tell the human. |
| `holder-deactivated` | The holder is no longer active on this instance. | Stop, and tell the human. |
