---
title: "Chat commands"
description: "Text commands and slash-command aliases supported by mikan across chat platforms."
url: "https://geminixiang.github.io/commands/"
---

# Chat commands

`/login` opens a 15-minute capability link for API keys, OAuth, and shared vault profiles. It is
    available only in a DM/private conversation.
    `session` opens the current session viewer; `/new` resets the current DM session while retaining
    old files for inspection.
    `/admin` opens the 30-minute admin portal; model, sandbox limits, office door policy, reply
    policy, skills, events, and conversation state can be inspected there.

## Command quick reference

| Command                                              | Purpose and scope                                                                                                          |
| ---------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------- |
| `/login` / `/pi-login`                               | Open a 15-minute login/vault link. DM only.                                                                                |
| `session` / `/session` / `/pi-session`               | Open the current session viewer. DM only.                                                                                  |
| `/new` / `/pi-new`                                   | Reset the current session. DM only.                                                                                        |
| `/model` / `/pi-model [provider/model[:thinking]]`   | Show or switch the current conversation model. Thinking levels: `off`, `minimal`, `low`, `medium`, `high`, `xhigh`, `max`. |
| `/auto-reply` / `/pi-auto-reply on\|off\|status`     | Control auto-reply in the current group/channel.                                                                           |
| `stop` / `/stop`                                     | Stop the matching active run. On Slack, prefer text form so thread-local routing stays accurate.                           |
| `/admin` / `/pi-admin`                               | Open the 30-minute admin portal.                                                                                           |
| `/extensions` / `/pi-extensions`                     | List global and conversation extensions, versions, and contributed skills.                                                 |
| `/sandbox` / `/pi-sandbox`                           | Show the current sandbox limits plus this office's door policy and workspace layout.                                       |
| `/pi-sandbox boost`                                  | Apply configured boost limits until the managed sandbox runtime stops.                                                     |
| `/pi-sandbox door`                                   | Report the office's effective door policy and layout, with the available values.                                           |
| `/pi-sandbox door <default\|isolated\|shared\|full>` | Set this office's door policy. See [Office door policy](#office-door-policy) below.                                        |

`/pi-sandbox` applies to managed sandbox runtimes only: in `host` or `container:<name>` mode it replies that the command needs `image:*` or `gondolin:*`.

### Office door policy

`/pi-sandbox door` writes the conversation's own door-policy override. The same setting is available per office, and as a global default, in the admin portal.

| Word       | Effect                                                                               |
| ---------- | ------------------------------------------------------------------------------------ |
| `default`  | Clear the override and follow the global `sandbox.workspace` setting.                |
| `isolated` | Mount only this office's own directory.                                              |
| `shared`   | Trusted door: the office plus the workspace-level `MEMORY.md`, `skills/`, `events/`. |
| `full`     | Trusted door: mount the entire workspace.                                            |

The change takes effect on the next message, when the sandbox runtime is rebuilt with the new mounts; existing container contents are preserved. A switch is refused while the conversation is busy. See [Configuration](/configuration/) for the underlying `sandbox.workspace` fields.

  Native slash commands must also be registered with the platform. The command inventory lives in
  `src/commands/manifest.ts`: Discord's application commands and Telegram's command menu are derived
  from it at startup, and Slack's routing recognizes the manifest's `/pi-*` names. Because Discord
  rejects an option description longer than 100 characters, the manifest's argument descriptions are
  length-checked by the command tests. Slack's App manifest (`/pi-login`, `/pi-session`, `/pi-new`,
  `/pi-model`, `/pi-auto-reply`, `/pi-sandbox`, `/pi-extensions`, `/pi-admin`) must still be updated
  in the Slack App configuration by hand.

## Shared vault commands

All vault commands are DM-only:

| Command                       | Effect                                                                                      |
| ----------------------------- | ------------------------------------------------------------------------------------------- |
| `/login shared list`          | List shared login profiles.                                                                 |
| `/login shared create <name>` | Open a login link that creates a shared profile.                                            |
| `/login shared update <name>` | Open a login link that updates a shared profile.                                            |
| `/login shared delete <name>` | Delete a shared profile.                                                                    |
| `/login copy <name>`          | Copy a shared profile into the current conversation vault. Matching values are overwritten. |

Shared profiles are operator-managed credentials. Automatic inheritance through `sandbox.defaultSharedVault` is restricted to eligible membership-trust image/Cloudflare conversations; open-trigger surfaces such as GitHub do not inherit it.

## Web portals

The admin, login/vault, and session portals use the same HTTP server. Configure a public base URL for production:

1. Set the externally reachable URL:

   ```bash
   export LINK_URL="https://mikan.example.com"
   ```

2. Optionally select the listen port; when `LINK_URL` exists, the default is `8181`:

   ```bash
   export LINK_PORT=8181
   ```

3. For local-only testing, set only `LINK_PORT`. mikan binds to `127.0.0.1` and returns links under
   `http://localhost:<port>`.

Capability URLs are bearer secrets. Do not paste them into shared channels, logs, or issue trackers. Login links expire after 15 minutes and are consumed when credentials are written; admin links last 30 minutes; session links last 24 hours. A process restart invalidates every outstanding link.

See [Portal auth and capability model](/portal-auth-model/) for route-level permissions.

## OAuth flows

- [GitHub](/oauth/github/) <Badge text="OAuth" variant="default" />
- [Google Workspace](/oauth/google-workspace/) <Badge text="OAuth" variant="default" />
- [Google Cloud SDK / gcloud](/oauth/google-cloud-sdk/) <Badge text="OAuth" variant="default" />
