6 custom skills (assign-task, dispatch-webhook, daily-briefing, task-capture, qmd-brain, tts-voice) with technical documentation. Compatible with Claude Code, OpenClaw, Codex CLI, and OpenCode.
57 lines
19 KiB
JSON
Executable File
57 lines
19 KiB
JSON
Executable File
{
|
|
"title": "Slash commands",
|
|
"content": "Commands are handled by the Gateway. Most commands must be sent as a **standalone** message that starts with `/`.\nThe host-only bash chat command uses `! <cmd>` (with `/bash <cmd>` as an alias).\n\nThere are two related systems:\n\n* **Commands**: standalone `/...` messages.\n* **Directives**: `/think`, `/verbose`, `/reasoning`, `/elevated`, `/exec`, `/model`, `/queue`.\n * Directives are stripped from the message before the model sees it.\n * In normal chat messages (not directive-only), they are treated as “inline hints” and do **not** persist session settings.\n * In directive-only messages (the message contains only directives), they persist to the session and reply with an acknowledgement.\n * Directives are only applied for **authorized senders** (channel allowlists/pairing plus `commands.useAccessGroups`).\n Unauthorized senders see directives treated as plain text.\n\nThere are also a few **inline shortcuts** (allowlisted/authorized senders only): `/help`, `/commands`, `/status`, `/whoami` (`/id`).\nThey run immediately, are stripped before the model sees the message, and the remaining text continues through the normal flow.\n\n* `commands.text` (default `true`) enables parsing `/...` in chat messages.\n * On surfaces without native commands (WhatsApp/WebChat/Signal/iMessage/Google Chat/MS Teams), text commands still work even if you set this to `false`.\n* `commands.native` (default `\"auto\"`) registers native commands.\n * Auto: on for Discord/Telegram; off for Slack (until you add slash commands); ignored for providers without native support.\n * Set `channels.discord.commands.native`, `channels.telegram.commands.native`, or `channels.slack.commands.native` to override per provider (bool or `\"auto\"`).\n * `false` clears previously registered commands on Discord/Telegram at startup. Slack commands are managed in the Slack app and are not removed automatically.\n* `commands.nativeSkills` (default `\"auto\"`) registers **skill** commands natively when supported.\n * Auto: on for Discord/Telegram; off for Slack (Slack requires creating a slash command per skill).\n * Set `channels.discord.commands.nativeSkills`, `channels.telegram.commands.nativeSkills`, or `channels.slack.commands.nativeSkills` to override per provider (bool or `\"auto\"`).\n* `commands.bash` (default `false`) enables `! <cmd>` to run host shell commands (`/bash <cmd>` is an alias; requires `tools.elevated` allowlists).\n* `commands.bashForegroundMs` (default `2000`) controls how long bash waits before switching to background mode (`0` backgrounds immediately).\n* `commands.config` (default `false`) enables `/config` (reads/writes `openclaw.json`).\n* `commands.debug` (default `false`) enables `/debug` (runtime-only overrides).\n* `commands.useAccessGroups` (default `true`) enforces allowlists/policies for commands.\n\nText + native (when enabled):\n\n* `/help`\n* `/commands`\n* `/skill <name> [input]` (run a skill by name)\n* `/status` (show current status; includes provider usage/quota for the current model provider when available)\n* `/allowlist` (list/add/remove allowlist entries)\n* `/approve <id> allow-once|allow-always|deny` (resolve exec approval prompts)\n* `/context [list|detail|json]` (explain “context”; `detail` shows per-file + per-tool + per-skill + system prompt size)\n* `/whoami` (show your sender id; alias: `/id`)\n* `/subagents list|stop|log|info|send` (inspect, stop, log, or message sub-agent runs for the current session)\n* `/config show|get|set|unset` (persist config to disk, owner-only; requires `commands.config: true`)\n* `/debug show|set|unset|reset` (runtime overrides, owner-only; requires `commands.debug: true`)\n* `/usage off|tokens|full|cost` (per-response usage footer or local cost summary)\n* `/tts off|always|inbound|tagged|status|provider|limit|summary|audio` (control TTS; see [/tts](/tts))\n * Discord: native command is `/voice` (Discord reserves `/tts`); text `/tts` still works.\n* `/stop`\n* `/restart`\n* `/dock-telegram` (alias: `/dock_telegram`) (switch replies to Telegram)\n* `/dock-discord` (alias: `/dock_discord`) (switch replies to Discord)\n* `/dock-slack` (alias: `/dock_slack`) (switch replies to Slack)\n* `/activation mention|always` (groups only)\n* `/send on|off|inherit` (owner-only)\n* `/reset` or `/new [model]` (optional model hint; remainder is passed through)\n* `/think <off|minimal|low|medium|high|xhigh>` (dynamic choices by model/provider; aliases: `/thinking`, `/t`)\n* `/verbose on|full|off` (alias: `/v`)\n* `/reasoning on|off|stream` (alias: `/reason`; when on, sends a separate message prefixed `Reasoning:`; `stream` = Telegram draft only)\n* `/elevated on|off|ask|full` (alias: `/elev`; `full` skips exec approvals)\n* `/exec host=<sandbox|gateway|node> security=<deny|allowlist|full> ask=<off|on-miss|always> node=<id>` (send `/exec` to show current)\n* `/model <name>` (alias: `/models`; or `/<alias>` from `agents.defaults.models.*.alias`)\n* `/queue <mode>` (plus options like `debounce:2s cap:25 drop:summarize`; send `/queue` to see current settings)\n* `/bash <command>` (host-only; alias for `! <command>`; requires `commands.bash: true` + `tools.elevated` allowlists)\n\n* `/compact [instructions]` (see [/concepts/compaction](/concepts/compaction))\n* `! <command>` (host-only; one at a time; use `!poll` + `!stop` for long-running jobs)\n* `!poll` (check output / status; accepts optional `sessionId`; `/bash poll` also works)\n* `!stop` (stop the running bash job; accepts optional `sessionId`; `/bash stop` also works)\n\n* Commands accept an optional `:` between the command and args (e.g. `/think: high`, `/send: on`, `/help:`).\n* `/new <model>` accepts a model alias, `provider/model`, or a provider name (fuzzy match); if no match, the text is treated as the message body.\n* For full provider usage breakdown, use `openclaw status --usage`.\n* `/allowlist add|remove` requires `commands.config=true` and honors channel `configWrites`.\n* `/usage` controls the per-response usage footer; `/usage cost` prints a local cost summary from OpenClaw session logs.\n* `/restart` is disabled by default; set `commands.restart: true` to enable it.\n* `/verbose` is meant for debugging and extra visibility; keep it **off** in normal use.\n* `/reasoning` (and `/verbose`) are risky in group settings: they may reveal internal reasoning or tool output you did not intend to expose. Prefer leaving them off, especially in group chats.\n* **Fast path:** command-only messages from allowlisted senders are handled immediately (bypass queue + model).\n* **Group mention gating:** command-only messages from allowlisted senders bypass mention requirements.\n* **Inline shortcuts (allowlisted senders only):** certain commands also work when embedded in a normal message and are stripped before the model sees the remaining text.\n * Example: `hey /status` triggers a status reply, and the remaining text continues through the normal flow.\n* Currently: `/help`, `/commands`, `/status`, `/whoami` (`/id`).\n* Unauthorized command-only messages are silently ignored, and inline `/...` tokens are treated as plain text.\n* **Skill commands:** `user-invocable` skills are exposed as slash commands. Names are sanitized to `a-z0-9_` (max 32 chars); collisions get numeric suffixes (e.g. `_2`).\n * `/skill <name> [input]` runs a skill by name (useful when native command limits prevent per-skill commands).\n * By default, skill commands are forwarded to the model as a normal request.\n * Skills may optionally declare `command-dispatch: tool` to route the command directly to a tool (deterministic, no model).\n * Example: `/prose` (OpenProse plugin) — see [OpenProse](/prose).\n* **Native command arguments:** Discord uses autocomplete for dynamic options (and button menus when you omit required args). Telegram and Slack show a button menu when a command supports choices and you omit the arg.\n\n## Usage surfaces (what shows where)\n\n* **Provider usage/quota** (example: “Claude 80% left”) shows up in `/status` for the current model provider when usage tracking is enabled.\n* **Per-response tokens/cost** is controlled by `/usage off|tokens|full` (appended to normal replies).\n* `/model status` is about **models/auth/endpoints**, not usage.\n\n## Model selection (`/model`)\n\n`/model` is implemented as a directive.\n\n* `/model` and `/model list` show a compact, numbered picker (model family + available providers).\n* `/model <#>` selects from that picker (and prefers the current provider when possible).\n* `/model status` shows the detailed view, including configured provider endpoint (`baseUrl`) and API mode (`api`) when available.\n\n`/debug` lets you set **runtime-only** config overrides (memory, not disk). Owner-only. Disabled by default; enable with `commands.debug: true`.\n\n* Overrides apply immediately to new config reads, but do **not** write to `openclaw.json`.\n* Use `/debug reset` to clear all overrides and return to the on-disk config.\n\n`/config` writes to your on-disk config (`openclaw.json`). Owner-only. Disabled by default; enable with `commands.config: true`.\n\n* Config is validated before write; invalid changes are rejected.\n* `/config` updates persist across restarts.\n\n* **Text commands** run in the normal chat session (DMs share `main`, groups have their own session).\n* **Native commands** use isolated sessions:\n * Discord: `agent:<agentId>:discord:slash:<userId>`\n * Slack: `agent:<agentId>:slack:slash:<userId>` (prefix configurable via `channels.slack.slashCommand.sessionPrefix`)\n * Telegram: `telegram:slash:<userId>` (targets the chat session via `CommandTargetSessionKey`)\n* **`/stop`** targets the active chat session so it can abort the current run.\n* **Slack:** `channels.slack.slashCommand` is still supported for a single `/openclaw`-style command. If you enable `commands.native`, you must create one Slack slash command per built-in command (same names as `/help`). Command argument menus for Slack are delivered as ephemeral Block Kit buttons.",
|
|
"code_samples": [
|
|
{
|
|
"code": "* `commands.text` (default `true`) enables parsing `/...` in chat messages.\n * On surfaces without native commands (WhatsApp/WebChat/Signal/iMessage/Google Chat/MS Teams), text commands still work even if you set this to `false`.\n* `commands.native` (default `\"auto\"`) registers native commands.\n * Auto: on for Discord/Telegram; off for Slack (until you add slash commands); ignored for providers without native support.\n * Set `channels.discord.commands.native`, `channels.telegram.commands.native`, or `channels.slack.commands.native` to override per provider (bool or `\"auto\"`).\n * `false` clears previously registered commands on Discord/Telegram at startup. Slack commands are managed in the Slack app and are not removed automatically.\n* `commands.nativeSkills` (default `\"auto\"`) registers **skill** commands natively when supported.\n * Auto: on for Discord/Telegram; off for Slack (Slack requires creating a slash command per skill).\n * Set `channels.discord.commands.nativeSkills`, `channels.telegram.commands.nativeSkills`, or `channels.slack.commands.nativeSkills` to override per provider (bool or `\"auto\"`).\n* `commands.bash` (default `false`) enables `! <cmd>` to run host shell commands (`/bash <cmd>` is an alias; requires `tools.elevated` allowlists).\n* `commands.bashForegroundMs` (default `2000`) controls how long bash waits before switching to background mode (`0` backgrounds immediately).\n* `commands.config` (default `false`) enables `/config` (reads/writes `openclaw.json`).\n* `commands.debug` (default `false`) enables `/debug` (runtime-only overrides).\n* `commands.useAccessGroups` (default `true`) enforces allowlists/policies for commands.\n\n## Command list\n\nText + native (when enabled):\n\n* `/help`\n* `/commands`\n* `/skill <name> [input]` (run a skill by name)\n* `/status` (show current status; includes provider usage/quota for the current model provider when available)\n* `/allowlist` (list/add/remove allowlist entries)\n* `/approve <id> allow-once|allow-always|deny` (resolve exec approval prompts)\n* `/context [list|detail|json]` (explain “context”; `detail` shows per-file + per-tool + per-skill + system prompt size)\n* `/whoami` (show your sender id; alias: `/id`)\n* `/subagents list|stop|log|info|send` (inspect, stop, log, or message sub-agent runs for the current session)\n* `/config show|get|set|unset` (persist config to disk, owner-only; requires `commands.config: true`)\n* `/debug show|set|unset|reset` (runtime overrides, owner-only; requires `commands.debug: true`)\n* `/usage off|tokens|full|cost` (per-response usage footer or local cost summary)\n* `/tts off|always|inbound|tagged|status|provider|limit|summary|audio` (control TTS; see [/tts](/tts))\n * Discord: native command is `/voice` (Discord reserves `/tts`); text `/tts` still works.\n* `/stop`\n* `/restart`\n* `/dock-telegram` (alias: `/dock_telegram`) (switch replies to Telegram)\n* `/dock-discord` (alias: `/dock_discord`) (switch replies to Discord)\n* `/dock-slack` (alias: `/dock_slack`) (switch replies to Slack)\n* `/activation mention|always` (groups only)\n* `/send on|off|inherit` (owner-only)\n* `/reset` or `/new [model]` (optional model hint; remainder is passed through)\n* `/think <off|minimal|low|medium|high|xhigh>` (dynamic choices by model/provider; aliases: `/thinking`, `/t`)\n* `/verbose on|full|off` (alias: `/v`)\n* `/reasoning on|off|stream` (alias: `/reason`; when on, sends a separate message prefixed `Reasoning:`; `stream` = Telegram draft only)\n* `/elevated on|off|ask|full` (alias: `/elev`; `full` skips exec approvals)\n* `/exec host=<sandbox|gateway|node> security=<deny|allowlist|full> ask=<off|on-miss|always> node=<id>` (send `/exec` to show current)\n* `/model <name>` (alias: `/models`; or `/<alias>` from `agents.defaults.models.*.alias`)\n* `/queue <mode>` (plus options like `debounce:2s cap:25 drop:summarize`; send `/queue` to see current settings)\n* `/bash <command>` (host-only; alias for `! <command>`; requires `commands.bash: true` + `tools.elevated` allowlists)\n\nText-only:\n\n* `/compact [instructions]` (see [/concepts/compaction](/concepts/compaction))\n* `! <command>` (host-only; one at a time; use `!poll` + `!stop` for long-running jobs)\n* `!poll` (check output / status; accepts optional `sessionId`; `/bash poll` also works)\n* `!stop` (stop the running bash job; accepts optional `sessionId`; `/bash stop` also works)\n\nNotes:\n\n* Commands accept an optional `:` between the command and args (e.g. `/think: high`, `/send: on`, `/help:`).\n* `/new <model>` accepts a model alias, `provider/model`, or a provider name (fuzzy match); if no match, the text is treated as the message body.\n* For full provider usage breakdown, use `openclaw status --usage`.\n* `/allowlist add|remove` requires `commands.config=true` and honors channel `configWrites`.\n* `/usage` controls the per-response usage footer; `/usage cost` prints a local cost summary from OpenClaw session logs.\n* `/restart` is disabled by default; set `commands.restart: true` to enable it.\n* `/verbose` is meant for debugging and extra visibility; keep it **off** in normal use.\n* `/reasoning` (and `/verbose`) are risky in group settings: they may reveal internal reasoning or tool output you did not intend to expose. Prefer leaving them off, especially in group chats.\n* **Fast path:** command-only messages from allowlisted senders are handled immediately (bypass queue + model).\n* **Group mention gating:** command-only messages from allowlisted senders bypass mention requirements.\n* **Inline shortcuts (allowlisted senders only):** certain commands also work when embedded in a normal message and are stripped before the model sees the remaining text.\n * Example: `hey /status` triggers a status reply, and the remaining text continues through the normal flow.\n* Currently: `/help`, `/commands`, `/status`, `/whoami` (`/id`).\n* Unauthorized command-only messages are silently ignored, and inline `/...` tokens are treated as plain text.\n* **Skill commands:** `user-invocable` skills are exposed as slash commands. Names are sanitized to `a-z0-9_` (max 32 chars); collisions get numeric suffixes (e.g. `_2`).\n * `/skill <name> [input]` runs a skill by name (useful when native command limits prevent per-skill commands).\n * By default, skill commands are forwarded to the model as a normal request.\n * Skills may optionally declare `command-dispatch: tool` to route the command directly to a tool (deterministic, no model).\n * Example: `/prose` (OpenProse plugin) — see [OpenProse](/prose).\n* **Native command arguments:** Discord uses autocomplete for dynamic options (and button menus when you omit required args). Telegram and Slack show a button menu when a command supports choices and you omit the arg.\n\n## Usage surfaces (what shows where)\n\n* **Provider usage/quota** (example: “Claude 80% left”) shows up in `/status` for the current model provider when usage tracking is enabled.\n* **Per-response tokens/cost** is controlled by `/usage off|tokens|full` (appended to normal replies).\n* `/model status` is about **models/auth/endpoints**, not usage.\n\n## Model selection (`/model`)\n\n`/model` is implemented as a directive.\n\nExamples:",
|
|
"language": "unknown"
|
|
},
|
|
{
|
|
"code": "Notes:\n\n* `/model` and `/model list` show a compact, numbered picker (model family + available providers).\n* `/model <#>` selects from that picker (and prefers the current provider when possible).\n* `/model status` shows the detailed view, including configured provider endpoint (`baseUrl`) and API mode (`api`) when available.\n\n## Debug overrides\n\n`/debug` lets you set **runtime-only** config overrides (memory, not disk). Owner-only. Disabled by default; enable with `commands.debug: true`.\n\nExamples:",
|
|
"language": "unknown"
|
|
},
|
|
{
|
|
"code": "Notes:\n\n* Overrides apply immediately to new config reads, but do **not** write to `openclaw.json`.\n* Use `/debug reset` to clear all overrides and return to the on-disk config.\n\n## Config updates\n\n`/config` writes to your on-disk config (`openclaw.json`). Owner-only. Disabled by default; enable with `commands.config: true`.\n\nExamples:",
|
|
"language": "unknown"
|
|
}
|
|
],
|
|
"headings": [
|
|
{
|
|
"level": "h2",
|
|
"text": "Config",
|
|
"id": "config"
|
|
},
|
|
{
|
|
"level": "h2",
|
|
"text": "Command list",
|
|
"id": "command-list"
|
|
},
|
|
{
|
|
"level": "h2",
|
|
"text": "Usage surfaces (what shows where)",
|
|
"id": "usage-surfaces-(what-shows-where)"
|
|
},
|
|
{
|
|
"level": "h2",
|
|
"text": "Model selection (`/model`)",
|
|
"id": "model-selection-(`/model`)"
|
|
},
|
|
{
|
|
"level": "h2",
|
|
"text": "Debug overrides",
|
|
"id": "debug-overrides"
|
|
},
|
|
{
|
|
"level": "h2",
|
|
"text": "Config updates",
|
|
"id": "config-updates"
|
|
},
|
|
{
|
|
"level": "h2",
|
|
"text": "Surface notes",
|
|
"id": "surface-notes"
|
|
}
|
|
],
|
|
"url": "llms-txt#slash-commands",
|
|
"links": []
|
|
} |