> ## Documentation Index
> Fetch the complete documentation index at: https://docs.oasm.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Plans and approvals

> Review the agent's plan before it starts, approve or reject each command, and see the safety checks that run in every approval mode

Agent mode runs real tools on your workers, so AI Studio keeps you in control at two points:

* **The plan.** In Agent mode the agent writes a plan, and nothing runs until you approve it.
* **Each call.** While the plan runs, the **approval mode** decides whether a command waits for your yes.

Underneath both, fixed safety checks refuse some calls whatever you approve, in Auto mode too.

## Approval modes

| Mode | Description in the menu | What it means |
| - | - | - |
| **Manual** | Approve each new command | The agent asks before each command or tool call that can change something. A command you already approved in this chat is not asked again |
| **Auto** | Run every command without asking | Calls run without a prompt, unless a safety check asks for your approval |

In **Manual**, these ask first:

* shell commands and tool connector runs on the worker,
* changes to projects, targets and installed tools, and starting project workflows,
* proposing a finding for review,
* fetching a public web page,
* tools of external MCP servers, unless the server marks the tool as read-only.

Workspace lookups (assets, vulnerabilities, ports, projects and the like) never ask, and neither do the agent's own bookkeeping tools, such as updating the plan or dispatching a subagent.

### Where the mode is set

| Where | Effect |
| - | - |
| **Settings → Models → Default Approval Mode** | The mode every new chat starts in. **Not Set (Use Last Choice)** uses the mode you last picked. See [Models](https://docs.oasm.io/ai-studio/settings/models.md) |
| Approval selector in the composer | The mode for this chat. In a new chat it starts at your default, else your last choice in this browser, else **Manual** |
| The plan prompt | Approving a plan switches the chat to **Auto** or **Manual**, whichever you picked |

Opening an existing chat shows that chat's saved mode. A change you make in an open chat applies from your next message, and it clears any **allow** choices you made earlier in the chat.

## When the agent writes a plan

Plans exist in Agent mode only. Ask mode never plans.

In Agent mode, every tool call waits for an approved plan with a step in progress. That includes read-only lookups: a call made earlier is refused and shows **Needs plan** in the chat, and the agent writes a plan instead. A reply that needs no tool, such as a clarifying question, needs no plan.

How a plan comes together:

1. When you send a task, OASM pins a **goal** for it: the one outcome you want, with what counts as success. It shows as **Goal** above the plan.
2. The agent writes the plan: an ordered list of outcomes, such as "Attack surface mapped" or "Candidates validated", rather than the tools it will use. A plan has at most 20 steps.
3. The **Run this plan?** prompt replaces the composer until you decide.

While an approved plan runs, the agent can add steps it discovers it needs without asking you again. Once every step is completed or failed, new tool work needs a new plan.

## Approve a plan

![The Run this plan? prompt with the description Review the plan before the agent starts running it, four numbered plan steps, the options Yes, run it automatically; Yes, but approve each command; No; a field Tell the agent how to change the plan; and the hint Press a number, or arrows and Enter, Esc to cancel](https://mintcdn.com/oasmplatform/JcAER2Ib37AN8_8A/images/screens/ai-approval.webp?fit=max\&auto=format\&n=JcAER2Ib37AN8_8A\&q=85\&s=b2be0f0b810b89af9f8a452ef3a7c105)

Reviewing a four-step plan before the agent starts

The prompt lists the steps, numbered. The plan also shows in the chat with the status **Planning** while it waits, and **Plan ready** once approved.

| Option | Key | What happens |
| - | - | - |
| **Yes, run it automatically** | <kbd>1</kbd> | Approves the plan and switches the chat to **Auto**: commands run without asking |
| **Yes, but approve each command** | <kbd>2</kbd> | Approves the plan and switches the chat to **Manual**: the agent asks before each new command |
| **No** | <kbd>3</kbd> | Discards the plan and its goal. The agent runs nothing and asks how you want to proceed |
| **Tell the agent how to change the plan** | Type, then <kbd>Enter</kbd> | Discards the plan with your feedback. The agent writes a revised plan, which you review again |

The prompt applies in both approval modes: even in **Auto**, a new plan waits for you.

### Change a plan with feedback

**1. Open the feedback box**

Click **Tell the agent how to change the plan**, or press <kbd>↓</kbd> until it is selected.

**2. Say what to change**

For example: "Skip the port scan and only check the TLS configuration of app.example.com".

**3. Send it**

Press <kbd>Enter</kbd>. The plan is discarded and the agent sends a new one in a new **Run this plan?** prompt.

Pressing <kbd>Enter</kbd> with the box empty rejects the plan like **No**.

## Approve a command or tool call

In **Manual** mode, each new call that can change something waits for you:

* A shell command shows **Run this command?** with the exact command line.
* Any other tool shows **Allow** followed by the tool's name, for example **Allow Run Tool Connector?**, with a short description and the arguments the agent passes. Long values are cut; click **Show all** to read them in full.
* A tool from an external MCP server also shows **MCP server:** with the server name, and the hints the server declares: **Read-only**, **May be destructive**, **Idempotent** or **Uses external services**.

When several requests wait at once, the prompt shows how many more are queued, such as "+2 more waiting", and answers them one at a time. Identical commands sent in parallel share one prompt.

| Option | What happens |
| - | - |
| **Yes** | Runs this call |
| **Yes, allow** *tool* **in this conversation** | Runs this call, and later calls of the same tool in this chat run without asking, whatever their input. Not offered for shell commands |
| **Yes, allow all requests in this conversation** | Runs this call and every other request of this chat, including the ones already waiting, without asking |
| **No** | Rejects the call |
| **Tell the agent what to do instead** | Rejects the call with your feedback |

A rejected call is not retried. The agent follows your feedback, or asks you how to proceed.

The **allow** choices last for the chat. They are cleared when the approval mode changes, including when you approve a new plan. They never cover a call that a safety check escalated (see below): that one always asks.

### Keyboard

| Keys | Action |
| - | - |
| <kbd>1</kbd>–<kbd>9</kbd> | Pick the option with that number |
| <kbd>↑</kbd> <kbd>↓</kbd> | Move between the options and the feedback box |
| <kbd>Enter</kbd> | Confirm the selected option, or send the feedback |
| <kbd>Esc</kbd> | Reject |
| <kbd>Tab</kbd> | Move focus within the prompt |

The prompt ignores clicks and keys for the first half second after it appears, so a keystroke meant for the composer does not answer it by accident.

### Unanswered prompts

A plan or call prompt waits five minutes. After that it counts as a rejection and the agent carries on accordingly.

The prompt is tied to the run, not to your browser tab. If you leave the chat and come back within the five minutes, the prompt is shown again. **Stop** rejects any prompt that is still waiting. Answering prompts needs the `agent.write` permission.

## What runs without a prompt in subagents

Subagents work in the background, where nobody sees a prompt:

* A **built-in** agent running as a subagent runs its commands and tools without asking, in both approval modes. You approve its work through the plan.
* A **custom** agent running as a subagent gets read-only tools in a **Manual** chat. In an **Auto** chat it gets the tools it declares.
* A call that a safety check escalates to a prompt is refused in a subagent instead of waiting.

See [How subagents work](https://docs.oasm.io/ai-studio/side-panel.md#how-subagents-work).

## Safety checks that always run

These checks run before any approval, in **Auto** mode too, and for subagents. A call they refuse never runs, whatever you approve.

| Check | What it does |
| - | - |
| **Your permissions** | Each tool needs the same workspace permission as the matching console action. A call you could not make yourself is refused before any prompt |
| **Built-in deny list** | Refuses shell commands, and tools of external MCP servers, that would recursively delete the root, home or a system directory; format or wipe a filesystem; write raw data to a block device; run a fork bomb; shut down or reboot the worker host; run destructive SQL (`DROP`, `TRUNCATE`, or `DELETE` without `WHERE`); flush a Redis database; or send an HTTP `DELETE` request. Rewording or encoding the command does not get past it |
| **Workspace tool rules** | Rules set by the workspace owner can deny a tool, always ask for it (even in **Auto**), or allow it without asking. The matching rule with the highest priority decides; on a tie, deny beats ask and ask beats allow |
| **Scope** | A tool connector run, or a subagent dispatched against targets, must stay inside the scope, or it is refused. A host named in a shell command that may be outside the scope escalates to an approval prompt, even in **Auto**. A host excluded from the scope is always refused |

The **scope** is the project's include and exclude rules in a [project chat](https://docs.oasm.io/ai-studio/project-chats.md) whose project has include rules; otherwise it is the workspace's domain, IP and CIDR [targets](https://docs.oasm.io/target.md). A domain target covers its subdomains. Assets inside that scope count too.

An escalated call shows **Needs approval:** followed by the reason at the top of the prompt, for example that a host may be outside the workspace targets.

> [!NOTE]
>
> Workspace tool rules have no console page yet: workspace owners manage them through the `/api/agents/tool-rules` endpoints. Rules use wildcard patterns (`*` for any run of characters, `?` for one character) matched, ignoring case, against the whole command or tool input. A rule without a pattern matches every call of its tool.

## Best practices

* Read every plan before approving it. Use **Tell the agent how to change the plan** rather than approving a plan you would only partly run.
* Keep **Manual** for work you have not reviewed. Pick **Yes, run it automatically** only for a plan whose every step you are happy to run unattended.
* Use **Yes, allow** *tool* **in this conversation** for a tool you trust in this chat, rather than **allow all requests**.
* Run engagements from a [project chat](https://docs.oasm.io/ai-studio/project-chats.md), so the scope check uses the project's scope rules.

## Related

> [card] [Chat](https://docs.oasm.io/ai-studio/chat.md)
>
> The composer, Ask and Agent mode, and stopping a run

> [card] [Side panel](https://docs.oasm.io/ai-studio/side-panel.md)
>
> Follow the plan, subagents and tool calls while they run

> [card] [Models](https://docs.oasm.io/ai-studio/settings/models.md)
>
> Set the default approval mode

> [card] [AI agent architecture](https://docs.oasm.io/architecture/ai-agent.md#plans-and-approvals)
>
> How the plan and approval gates work inside the runtime


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.