Technical reference for the OpenClaw framework. Real-time synchronization with the official documentation engine.
Use this file to discover all available pages before exploring further.
Slash commands
Commands are handled by the Gateway. Most commands must be sent as a standalone message that starts with
text
/
. The host-only bash chat command uses
text
! <cmd>
(with
text
/bash <cmd>
as an alias).
When a conversation or thread is bound to an ACP session, normal follow-up text routes to that ACP harness. Gateway management commands still stay local:
text
/acp ...
always reaches the OpenClaw ACP command handler, and
text
/status
plus
text
/unfocus
stay local whenever command handling is enabled for the surface.
Enables parsing `/...` in chat messages. On surfaces without native commands (WhatsApp/WebChat/Signal/iMessage/Google Chat/Microsoft Teams), text commands still work even if you set this to `false`.
Registers native commands. Auto: on for Discord/Telegram; off for Slack (until you add slash commands); ignored for providers without native support. Set `channels.discord.commands.native`, `channels.telegram.commands.native`, or `channels.slack.commands.native` to override per provider (bool or `"auto"`). `false` clears previously registered commands on Discord/Telegram at startup. Slack commands are managed in the Slack app and are not removed automatically.
Registers **skill** commands natively when supported. Auto: on for Discord/Telegram; off for Slack (Slack requires creating a slash command per skill). Set `channels.discord.commands.nativeSkills`, `channels.telegram.commands.nativeSkills`, or `channels.slack.commands.nativeSkills` to override per provider (bool or `"auto"`).
Enables `! ` to run host shell commands (`/bash ` is an alias; requires `tools.elevated` allowlists).
Controls how long bash waits before switching to background mode (`0` backgrounds immediately).
Enables `/config` (reads/writes `openclaw.json`).
Enables `/mcp` (reads/writes OpenClaw-managed MCP config under `mcp.servers`).
Enables `/plugins` (plugin discovery/status plus install + enable/disable controls).
Enables `/debug` (runtime-only overrides).
Enables `/restart` plus gateway restart tool actions.
Sets the explicit owner allowlist for owner-only command/tool surfaces. This is the human operator account that can approve dangerous actions and run commands such as `/diagnostics`, `/export-trajectory`, and `/config`. It is separate from `commands.allowFrom` and from DM pairing access.
Per-channel: makes owner-only commands require **owner identity** to run on that surface. When `true`, the sender must either match a resolved owner candidate (for example an entry in `commands.ownerAllowFrom` or provider-native owner metadata) or hold internal `operator.admin` scope on an internal message channel. A wildcard entry in channel `allowFrom`, or an empty/unresolved owner-candidate list, is **not** sufficient — owner-only commands fail closed on that channel. Leave this off if you want owner-only commands gated only by `ownerAllowFrom` and the standard command allowlists.
Controls how owner ids appear in the system prompt.
Optionally sets the HMAC secret used when `commands.ownerDisplay="hash"`.
Per-provider allowlist for command authorization. When configured, it is the only authorization source for commands and directives (channel allowlists/pairing and `commands.useAccessGroups` are ignored). Use `"*"` for a global default; provider-specific keys override it.
Enforces allowlists/policies for commands when `commands.allowFrom` is not set.
Command list
Current source-of-truth:
core built-ins come from
text
src/auto-reply/commands-registry.shared.ts
generated dock commands come from
text
src/auto-reply/commands-registry.data.ts
plugin commands come from plugin
text
registerCommand()
calls
actual availability on your gateway still depends on config flags, channel surface, and installed/enabled plugins
Core built-in commands
Generated dock commands
Dock commands switch the current session's reply route to another linked
channel. See Channel docking for setup,
examples, and troubleshooting.
Dock commands are generated from channel plugins with native-command support. Current bundled set:
text
/dock-discord
(alias:
text
/dock_discord
)
text
/dock-mattermost
(alias:
text
/dock_mattermost
)
text
/dock-slack
(alias:
text
/dock_slack
)
text
/dock-telegram
(alias:
text
/dock_telegram
)
Use dock commands from a direct chat to switch the current session's reply route to another linked channel. The agent keeps the same session context, but future replies for that session are delivered to the selected channel peer.
Dock commands require
text
session.identityLinks
. The source sender and target peer must be in the same identity group, for example
text
["telegram:123", "discord:456"]
. If a Telegram user with id
text
123
sends
text
/dock_discord
, OpenClaw stores
text
lastChannel: "discord"
and
text
lastTo: "456"
on the active session. If the sender is not linked to a Discord peer, the command replies with a setup hint instead of falling through to normal chat.
Docking changes the active session route only. It does not create channel accounts, grant access, bypass channel allowlists, or move transcript history to another session. Use
text
/dock-telegram
,
text
/dock-slack
,
text
/dock-mattermost
, or another generated dock command to switch the route again.
Bundled plugin commands
Bundled plugins can add more slash commands. Current bundled commands in this repo:
inspects and controls the bundled Codex app-server harness. See Codex harness.
QQBot-only commands:
text
/bot-ping
text
/bot-version
text
/bot-help
text
/bot-upgrade
text
/bot-logs
Dynamic skill commands
User-invocable skills are also exposed as slash commands:
text
/skill <name> [input]
always works as the generic entrypoint.
skills may also appear as direct commands like
text
/prose
when the skill/plugin registers them.
native skill-command registration is controlled by
text
commands.nativeSkills
and
text
channels.<provider>.commands.nativeSkills
.
text
/tools
text
/tools
answers a runtime question, not a config question: what this agent can use right now in this conversation.
Default
text
/tools
is compact and optimized for quick scanning.
text
/tools verbose
adds short descriptions.
Native-command surfaces that support arguments expose the same mode switch as
text
compact|verbose
.
Results are session-scoped, so changing agent, channel, thread, sender authorization, or model can change the output.
text
/tools
includes tools that are actually reachable at runtime, including core tools, connected plugin tools, and channel-owned tools.
For profile and override editing, use the Control UI Tools panel or config/catalog surfaces instead of treating
text
/tools
as a static catalog.
Usage surfaces (what shows where)
Provider usage/quota (example: "Claude 80% left") shows up in
text
/status
for the current model provider when usage tracking is enabled. OpenClaw normalizes provider windows to
text
% left
; for MiniMax, remaining-only percent fields are inverted before display, and
text
model_remains
responses prefer the chat-model entry plus a model-tagged plan label.
Token/cache lines in
text
/status
can fall back to the latest transcript usage entry when the live session snapshot is sparse. Existing nonzero live values still win, and transcript fallback can also recover the active runtime model label plus a larger prompt-oriented total when stored totals are missing or smaller.
Execution vs runtime:
text
/status
reports
text
Execution
for the effective sandbox path and
text
Runtime
for who is actually running the session:
text
OpenClaw Pi Default
,
text
OpenAI Codex
, a CLI backend, or an ACP backend.
Per-response tokens/cost is controlled by
text
/usage off|tokens|full
(appended to normal replies).
text
/model status
is about models/auth/endpoints, not usage.
Model selection (
text
/model
)
text
/model
is implemented as a directive.
Examples:
text
/model
/model list
/model 3
/model openai/gpt-5.4
/model opus@anthropic:default
/model status
Notes:
text
/model
and
text
/model list
show a compact, numbered picker (model family + available providers).
On Discord,
text
/model
and
text
/models
open an interactive picker with provider and model dropdowns plus a Submit step.
text
/model <#>
selects from that picker (and prefers the current provider when possible).
text
/model status
shows the detailed view, including configured provider endpoint (
text
baseUrl
) and API mode (
text
api
) when available.
Debug overrides
text
/debug
lets you set runtime-only config overrides (memory, not disk). Owner-only. Disabled by default; enable with
text
commands.debug: true
.
Examples:
text
/debug show
/debug set messages.responsePrefix="[openclaw]"
/debug set channels.whatsapp.allowFrom=["+1555","+4477"]
/debug unset messages.responsePrefix
/debug reset
note
Overrides apply immediately to new config reads, but do **not** write to `openclaw.json`. Use `/debug reset` to clear all overrides and return to the on-disk config.
Plugin trace output
text
/trace
lets you toggle session-scoped plugin trace/debug lines without turning on full verbose mode.
Examples:
text
/trace
/trace on
/trace off
Notes:
text
/trace
with no argument shows the current session trace state.
text
/trace on
enables plugin trace lines for the current session.
text
/trace off
disables them again.
Plugin trace lines can appear in
text
/status
and as a follow-up diagnostic message after the normal assistant reply.
text
/trace
does not replace
text
/debug
;
text
/debug
still manages runtime-only config overrides.
text
/trace
does not replace
text
/verbose
; normal verbose tool/status output still belongs to
text
/verbose
.
Config updates
text
/config
writes to your on-disk config (
text
openclaw.json
). Owner-only. Disabled by default; enable with
text
commands.config: true
.
Examples:
text
/config show
/config show messages.responsePrefix
/config get messages.responsePrefix
/config set messages.responsePrefix="[openclaw]"
/config unset messages.responsePrefix
note
Config is validated before write; invalid changes are rejected. `/config` updates persist across restarts.
MCP updates
text
/mcp
writes OpenClaw-managed MCP server definitions under
text
mcp.servers
. Owner-only. Disabled by default; enable with
text
commands.mcp: true
.
Examples:
text
/mcp show
/mcp show context7
/mcp set context7={"command":"uvx","args":["context7-mcp"]}
/mcp unset context7
note
`/mcp` stores config in OpenClaw config, not Pi-owned project settings. Runtime adapters decide which transports are actually executable.
Plugin updates
text
/plugins
lets operators inspect discovered plugins and toggle enablement in config. Read-only flows can use
text
/plugin
as an alias. Disabled by default; enable with
text
commands.plugins: true
.
Examples:
text
/plugins
/plugins list
/plugin show context7
/plugins enable context7
/plugins disable context7
note
* `/plugins list` and `/plugins show` use real plugin discovery against the current workspace plus on-disk config.
* `/plugins enable|disable` updates plugin config only; it does not install or uninstall plugins.
* After enable/disable changes, restart the gateway to apply them.
Surface notes
BTW side questions
text
/btw
is a quick side question about the current session.
Unlike normal chat:
it uses the current session as background context,
it runs as a separate tool-less one-shot call,
it does not change future session context,
it is not written to transcript history,
it is delivered as a live side result instead of a normal assistant message.
That makes
text
/btw
useful when you want a temporary clarification while the main task keeps going.