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

# Run modes and permissions

> Switch among default, plan, agent, and auto modes, and handle permission dialogs.

The mode picker at the bottom of the input box controls what the model can do on its own and which actions must ask you first.

Claude Code provides all four modes. Codex and the other engines do not offer plan mode.

## Four modes

| UI name      | Internal value      | Behavior                                                     | Best for                            |
| ------------ | ------------------- | ------------------------------------------------------------ | ----------------------------------- |
| Default mode | `default`           | Confirm reads, writes, and commands first                    | Unfamiliar repos, production config |
| Plan mode    | `plan`              | Read-only tools only. Produce a plan, then wait for approval | Large changes, comparing approaches |
| Agent mode   | `acceptEdits`       | Auto-accept file creates and edits                           | Everyday code changes               |
| Auto mode    | `bypassPermissions` | Skip permission checks                                       | Local tasks you fully trust         |

<img src="https://mintcdn.com/mossx-docs/kz4nt5KFSKzkAZwe/images/jetbrains/permission-dialog.png?fit=max&auto=format&n=kz4nt5KFSKzkAZwe&q=85&s=a13dca444104c8761694ea1150136cb4" alt="Permission confirmation dialog" width="100%" data-path="images/jetbrains/permission-dialog.png" />

<Warning>
  Auto mode skips file and command confirmation. Use it only when you accept the model changing any project file and running commands.
</Warning>

## How to answer a permission dialog

Default mode, and some agent-mode actions, open a permission dialog:

| Option       | Result                                                       |
| ------------ | ------------------------------------------------------------ |
| Allow        | Approve this time                                            |
| Always allow | Do not ask again for the same kind of action in this session |
| Deny         | Skip this time. The model tries another approach or stops    |

Requests from an external process are labeled separately. The dialog has a countdown. After timeout it closes and the model continues with the current policy. Set the timeout seconds in **Settings → General → Behavior**.

When the model asks you a multiple-choice question, it uses an **Ask user** dialog. Turn on system notifications in Settings so you do not miss it after switching windows.

## Plan mode

Plan mode only grants read-only tools. The model analyzes the code, proposes a plan, then waits for your approval.

Typical flow:

1. Switch to **Plan mode**
2. Describe the change
3. Review the plan and ask for a revision if needed
4. Approve or reject it in the approval box
5. After approval, let it execute

<img src="https://mintcdn.com/mossx-docs/kz4nt5KFSKzkAZwe/images/jetbrains/plan-approval.png?fit=max&auto=format&n=kz4nt5KFSKzkAZwe&q=85&s=9b4353c5670edf5a501ef4f3b1671674" alt="Plan approval" width="100%" data-path="images/jetbrains/plan-approval.png" />

Codex, Grok, Kimi, OpenCode, and Pi do not list plan mode. Use default / agent / auto on those runtimes.

## Codex sandbox

Codex has a separate sandbox policy in **Settings → Permissions**. It is a second layer on top of chat mode:

* Mode: whether to ask you
* Sandbox: which directories and network the command can actually touch

You can combine them. For example, agent mode auto-accepts edits while a stricter sandbox limits commands.
