← πŸ€– return to AI Agents
πŸ’» root@openclaw-gateway:~$ openclaw --help

πŸ¦€ OpenClaw Agent CLI Cheatsheet ⚑

A practical OpenClaw command reference for managing gateways 🌐, agents πŸ€–, channels πŸ“‘, skills 🧩, hooks πŸͺ, models 🧠, browser automation 🌍, nodes πŸ–₯️, and secure AI workflows πŸ”.

$ mission 🎯

Use OpenClaw as an agent gateway for controlled local automation, messaging channels, browser control, model routing, and security-minded operations. Keep tokens in environment variables, review actions, and test safely. πŸ”

πŸš€ Setup + Onboarding

Quick onboarding with daemon installopenclaw onboard --install-daemon
Setup workspace and configopenclaw setup --workspace ~/.openclaw/workspace
Interactive configurationopenclaw configure
Health checkopenclaw doctor

🌐 Gateway Management

Run gateway interactive modeopenclaw gateway
Run gateway on specific portopenclaw gateway --port 18789
Run gateway with Tailscaleopenclaw gateway --tailscale serve
Install gateway serviceopenclaw gateway install
Start gateway serviceopenclaw gateway start
Stop gateway serviceopenclaw gateway stop
Restart gateway serviceopenclaw gateway restart
Gateway statusopenclaw gateway status
OpenClaw statusopenclaw status
Deep status probeopenclaw status --deep
Health commandopenclaw health

πŸ€– Agent Management

List agentsopenclaw agents list
List agents with bindingsopenclaw agents list --bindings
Add agent interactivelyopenclaw agents add <name>
Add dev agent non-interactivelyopenclaw agents add dev --workspace ~/.openclaw/workspace-dev --model claude-sonnet-4.5 --non-interactive
Delete agentopenclaw agents delete <id>
Set identity from IDENTITY.mdopenclaw agents set-identity --agent main --from-identity
Set identity explicitlyopenclaw agents set-identity --agent main --name "MyAgent" --emoji "πŸ€–" --avatar avatars/bot.png

🧩 Skills + Hooks

List skillsopenclaw skills list
List eligible skillsopenclaw skills list --eligible
List skills as JSONopenclaw skills list --json
Skill infoopenclaw skills info <skill-name>
Check skill eligibilityopenclaw skills check
List hooksopenclaw hooks list
List eligible hooksopenclaw hooks list --eligible
Verbose hook infoopenclaw hooks list --verbose
Enable hookopenclaw hooks enable session-memory
Disable hookopenclaw hooks disable command-logger
Install hooks from npmopenclaw hooks install @openclaw/my-hooks
Install local hooksopenclaw hooks install ./my-hooks
Update all hooksopenclaw hooks update --all

πŸ“‘ Channels + Messaging

List channelsopenclaw channels list
Channel statusopenclaw channels status
Probe channel statusopenclaw channels status --probe
Add channel interactivelyopenclaw channels add
Add Telegram channelopenclaw channels add --channel telegram --account alerts --name "Alerts Bot" --token $TELEGRAM_BOT_TOKEN
Add Discord channelopenclaw channels add --channel discord --account work --token $DISCORD_BOT_TOKEN
Remove Telegram channelopenclaw channels remove --channel telegram --account alerts
Login to WhatsAppopenclaw channels login --channel whatsapp
Channel logsopenclaw channels logs
Send messageopenclaw message send --target +15555550123 --message "Hello from OpenClaw"
Read messagesopenclaw message read --target +15555550123
Delete messageopenclaw message delete --target <id>

🧠 Models + Authentication

Model statusopenclaw models status
Live model probeopenclaw models status --probe
Probe specific provideropenclaw models status --probe-provider anthropic
List modelsopenclaw models list
List all modelsopenclaw models list --all
List provider modelsopenclaw models list --provider anthropic
Set default modelopenclaw models set claude-sonnet-4.5
Set image modelopenclaw models set-image claude-sonnet-4.5
Anthropic token setupclaude setup-token
OpenClaw token setupopenclaw models auth setup-token --provider anthropic
Paste provider tokenopenclaw models auth paste-token --provider anthropic
List fallbacksopenclaw models fallbacks list
Add fallback modelopenclaw models fallbacks add claude-opus-4.6
Scan for modelsopenclaw models scan
Scan and set defaultopenclaw models scan --set-default

🌍 Browser Control

Browser statusopenclaw browser status
Start browseropenclaw browser start
Stop browseropenclaw browser stop
List tabsopenclaw browser tabs
Open URLopenclaw browser open https://example.com
Navigate target tabopenclaw browser navigate https://example.com --target-id <id>
Click selectoropenclaw browser click "#submit-button"
Type into selectoropenclaw browser type "#email" "user@example.com"
Press keyopenclaw browser press Enter
Screenshotopenclaw browser screenshot
Full page screenshotopenclaw browser screenshot --full-page
AI snapshotopenclaw browser snapshot --format ai

πŸ–₯️ Nodes + Devices

List nodesopenclaw nodes list
Connected node statusopenclaw nodes status --connected
Describe nodeopenclaw nodes describe --node <id>
Run command on nodeopenclaw nodes run --node <id> --cwd /path -- ls -la
Notify macOS nodeopenclaw nodes notify --node <id> --title "Build Complete" --body "Success" --sound default
List node camerasopenclaw nodes camera list --node <id>
Camera snapshotopenclaw nodes camera snap --node <id> --facing front
Camera clipopenclaw nodes camera clip --node <id> --duration 10s
Canvas snapshotopenclaw nodes canvas snapshot --node <id>
Present canvasopenclaw nodes canvas present --node <id> --target index.html
Record screenopenclaw nodes screen record --node <id> --duration 30s

πŸ” Safety + Verification

Check status before changesopenclaw status --deep
Review repo diffgit diff
Check git statusgit status
Avoid hardcoded tokensenv | grep -i token
Use env vars for bot tokensexport TELEGRAM_BOT_TOKEN=<token>
Validate site buildnpm run build
🧠 Ryan’s Recommended Workflow

Run OpenClaw inside TMUX 🐧, keep gateway logs visible πŸ“‘, isolate workspaces per agent πŸ“‚, use environment variables for channel tokens πŸ”, and validate every generated change with git diff + npm run build before deploying ⚑.