最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

OpenClaw CLI 命令速查手冊(中文注釋+示例版)

  發(fā)布時間:2026-03-26 10:26:38   作者:小空霸kongba007   我要評論
本文檔提供了OpenClaw CLI命令的速查手冊,包含初始化配置、診斷維護(hù)和網(wǎng)關(guān)管理三大類命令,文中介紹的非常詳細(xì),對大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價值,需要的朋友們下面隨著小編來一起學(xué)習(xí)學(xué)習(xí)吧

下面我把它整理成更適合查閱的 Markdown 表格版命令參考。
我按這幾個字段來列:

  • 命令
  • 子命令
  • 常用參數(shù)
  • 中文備注
  • 例子
  • 詳細(xì)用途

這份表是基于你貼出來的 OpenClaw zsh completion 命令樹整理的,所以它適合作為一份 CLI 使用速查表。

1. 初始化 / 配置 / 診斷

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw setup---workspace --wizard --non-interactive初始化本地 OpenClaw 目錄和默認(rèn)工作區(qū)openclaw setup --workspace ~/.openclaw/workspace創(chuàng)建 ~/.openclaw/openclaw.json 和默認(rèn) workspace,適合第一次手動初始化
openclaw onboard---workspace --flow --mode --gateway-port --install-daemon --skip-channels首次引導(dǎo)向?qū)?/td>openclaw onboard --flow quickstart --mode local一站式完成網(wǎng)關(guān)、模型、工作區(qū)、技能、渠道的初始配置
openclaw configure---section分區(qū)配置向?qū)?/td>openclaw configure --section gateway --section channels只修改某一部分配置,而不是全量重跑 onboarding
openclaw configget--json讀取配置項openclaw config get channels.feishu.enabled按點路徑讀取配置值
openclaw configset--json設(shè)置配置項openclaw config set channels.feishu.enabled true --json修改某個配置字段,通常直接寫入 openclaw.json
openclaw configunset-刪除配置項openclaw config unset channels.feishu.allowFrom刪除某個字段,讓配置回退默認(rèn)行為
openclaw doctor---repair --fix --force --deep健康檢查與修復(fù)openclaw doctor --repair檢查網(wǎng)關(guān)、配置、渠道、服務(wù)是否異常,并嘗試修復(fù)
openclaw dashboard---no-open打開控制臺openclaw dashboard打開控制 UI,用瀏覽器查看運行狀態(tài)
openclaw reset---scope --yes --dry-run重置本地狀態(tài)openclaw reset --scope config+creds+sessions --yes清空配置、憑據(jù)、會話,適合重新初始化
openclaw uninstall---service --state --workspace --all卸載 OpenClaw 本地環(huán)境openclaw uninstall --all --yes刪除服務(wù)、狀態(tài)、工作區(qū),但 CLI 本體可能仍保留

2. Gateway / Daemon / 日志

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw gatewayrun--port --bind --token --auth --verbose --dev前臺運行 Gatewayopenclaw gateway run --port 18789 --verbose啟動 WebSocket Gateway,負(fù)責(zé) sessions、routing、channels
openclaw gatewaystatus--json --deep --timeout查看網(wǎng)關(guān)狀態(tài)openclaw gateway status --json查看 Gateway 是否運行、是否可探測
openclaw gatewayinstall--port --runtime --token安裝后臺服務(wù)openclaw gateway install --port 18789把 Gateway 安裝成 launchd/systemd/schtasks 服務(wù)
openclaw gatewaystart--json啟動后臺服務(wù)openclaw gateway start啟動已安裝的 Gateway 服務(wù)
openclaw gatewaystop--json停止后臺服務(wù)openclaw gateway stop停止 Gateway 服務(wù)
openclaw gatewayrestart--json重啟后臺服務(wù)openclaw gateway restart修改配置后常用來重啟服務(wù)
openclaw gatewaycall--params --json調(diào)用 Gateway RPCopenclaw gateway call some.method --params '{"foo":"bar"}' --json直接調(diào)用內(nèi)部 RPC,適合調(diào)試
openclaw gatewayhealth--json獲取健康信息openclaw gateway health --json查看運行健康狀態(tài)
openclaw gatewayprobe--url --token --json探測本地/遠(yuǎn)程 Gatewayopenclaw gateway probe --json綜合檢查網(wǎng)關(guān)可達(dá)性、探測能力
openclaw gatewaydiscover--json發(fā)現(xiàn) Gatewayopenclaw gateway discover --json通過 Bonjour 等方式發(fā)現(xiàn)可連接網(wǎng)關(guān)
openclaw daemonstatus--json查看后臺服務(wù)狀態(tài)openclaw daemon status關(guān)注系統(tǒng)服務(wù)安裝/運行情況
openclaw daemoninstall--port --runtime安裝后臺服務(wù)openclaw daemon install --port 18789與 gateway install 類似,更偏服務(wù)管理
openclaw daemonstart--json啟動服務(wù)openclaw daemon start啟動后臺 Gateway
openclaw daemonstop--json停止服務(wù)openclaw daemon stop停止后臺 Gateway
openclaw daemonrestart--json重啟服務(wù)openclaw daemon restart配置更新后重啟
openclaw logs---follow --limit --json --plain查看日志openclaw logs --follow實時查看 Gateway 文件日志,是排障核心命令

3. 渠道 / 飛書 / 配對

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw channelslist--json列出已配置渠道openclaw channels list --json查看 Telegram、Feishu、Slack 等賬號是否已配置
openclaw channelsstatus--probe --json查看渠道狀態(tài)openclaw channels status --probe --json檢查憑據(jù)、連接狀態(tài)是否正常
openclaw channelscapabilities--channel --account --json查看渠道能力openclaw channels capabilities --channel feishu --json查看該渠道支持哪些消息能力
openclaw channelsresolve--channel --account --kind --json名稱解析為 IDopenclaw channels resolve --channel feishu --kind user "張三"把用戶/群名稱解析成內(nèi)部目標(biāo) ID
openclaw channelslogs--channel --lines --json查看渠道日志openclaw channels logs --channel feishu --lines 200專門看某個渠道的日志片段
openclaw channelsadd--channel --account --name --token --bot-token --app-token添加或更新渠道openclaw channels add --channel feishu --account main為某渠道寫入賬號配置,飛書、Telegram、Slack 都走這里
openclaw channelsremove--channel --account --delete移除渠道openclaw channels remove --channel feishu --account main --delete停用或刪除某個渠道賬號
openclaw channelslogin--channel --account渠道登錄openclaw channels login --channel whatsapp某些渠道需要登錄鏈接
openclaw channelslogout--channel --account渠道登出openclaw channels logout --channel whatsapp斷開登錄會話
openclaw pairinglist--channel --json查看待審批配對openclaw pairing list --channel feishu --json對 dmPolicy=pairing 的渠道,列出待審批用戶
openclaw pairingapprove--channel --notify批準(zhǔn)配對openclaw pairing approve ABC123 --channel feishu --notify批準(zhǔn)某個飛書用戶,讓其后續(xù)消息進(jìn)入正常 Agent 鏈路

4. 消息操作

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw messagesend--message/-m --target/-t --channel --account --media --reply-to發(fā)送消息openclaw message send -m "hello" -t user_xxx --channel feishu向某個渠道目標(biāo)發(fā)送消息
openclaw messagebroadcast--targets --message --channel批量廣播openclaw message broadcast --channel feishu --targets u1,u2 --message "通知"向多個目標(biāo)一次性發(fā)消息
openclaw messagepoll--poll-question --poll-option發(fā)起投票openclaw message poll --channel discord --target 123 --poll-question "吃什么" --poll-option 火鍋 --poll-option 燒烤某些渠道支持原生投票
openclaw messageread--target --channel --limit --before --after讀最近消息openclaw message read --channel feishu --target user_xxx --limit 20拉取目標(biāo)最近消息記錄
openclaw messageedit--message-id --message編輯消息openclaw message edit --channel discord --message-id 123 --message "修正版"修改已發(fā)送消息
openclaw messagedelete--message-id刪除消息openclaw message delete --channel discord --message-id 123刪除指定消息
openclaw messagereact--message-id --emoji --remove添加/移除反應(yīng)openclaw message react --channel slack --message-id 123 --emoji ??對消息加 emoji reaction
openclaw messagereactions--message-id --limit查看反應(yīng)openclaw message reactions --channel slack --message-id 123列出某條消息的反應(yīng)詳情
openclaw messagepin--message-id置頂消息openclaw message pin --channel discord --target chan_xxx --message-id 123把消息置頂
openclaw messageunpin--message-id取消置頂openclaw message unpin --channel discord --target chan_xxx --message-id 123取消置頂
openclaw messagepins--limit查看置頂列表openclaw message pins --channel discord --target chan_xxx列出當(dāng)前頻道置頂
openclaw messagesearch--query --channel-id --author-id搜索消息openclaw message search --channel discord --query "error"按關(guān)鍵字檢索消息
openclaw messagepermissions--target --channel查看權(quán)限openclaw message permissions --channel discord --target channel:123查看機(jī)器人在該目標(biāo)上的權(quán)限
openclaw messagethread create--thread-name --message新建線程openclaw message thread create --channel discord --target chan_xxx --thread-name "討論"創(chuàng)建討論線程
openclaw messagethread list--channel-id --limit列線程openclaw message thread list --channel discord --channel-id 123查看頻道線程
openclaw messagethread reply--message --reply-to在線程中回復(fù)openclaw message thread reply --channel discord --target thread_xxx --message "收到"往線程里發(fā)送消息
openclaw messageemoji list--guild-id列表情openclaw message emoji list --channel discord --guild-id 123查看服務(wù)器表情
openclaw messageemoji upload--emoji-name --media上傳表情openclaw message emoji upload --channel discord --guild-id 123 --emoji-name ok --media ./ok.png上傳自定義表情
openclaw messagesticker send--sticker-id發(fā)貼紙openclaw message sticker send --channel discord --target chan_xxx --sticker-id 123發(fā)送貼紙
openclaw messagesticker upload--sticker-name --media上傳貼紙openclaw message sticker upload --channel discord --guild-id 123 --sticker-name wow --media ./wow.png上傳貼紙資源
openclaw messagechannel info--target頻道信息openclaw message channel info --channel discord --target chan_xxx查看頻道詳情
openclaw messagechannel list--guild-id列頻道openclaw message channel list --channel discord --guild-id 123列出服務(wù)器頻道
openclaw messagemember info--user-id --guild-id成員信息openclaw message member info --channel discord --guild-id 123 --user-id 456查看成員信息
openclaw messagevoice status--guild-id --user-id語音狀態(tài)openclaw message voice status --channel discord --guild-id 123 --user-id 456查看某成員語音狀態(tài)
openclaw messageevent list--guild-id列活動openclaw message event list --channel discord --guild-id 123查看計劃活動
openclaw messageevent create--event-name --start-time建活動openclaw message event create --channel discord --guild-id 123 --event-name "周會" --start-time 2026-03-12T10:00:00創(chuàng)建活動事件
openclaw messagetimeout--guild-id --user-id --duration-min禁言成員openclaw message timeout --channel discord --guild-id 123 --user-id 456 --duration-min 10對成員進(jìn)行超時禁言
openclaw messagekick--guild-id --user-id移出成員openclaw message kick --channel discord --guild-id 123 --user-id 456踢出成員
openclaw messageban--guild-id --user-id封禁成員openclaw message ban --channel discord --guild-id 123 --user-id 456封禁成員

5. Agent / Agents / Sessions

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw agent---message/-m --to/-t --agent --channel --deliver --local --thinking --json手動跑一輪 agentopenclaw agent -m "hello" --agent main --channel feishu --deliver不依賴外部入站消息,直接觸發(fā)一個 agent turn
openclaw agentslist--json --bindings列出 agentopenclaw agents list --bindings --json查看有哪些 agent,以及它們的路由綁定
openclaw agentsadd--workspace --model --agent-dir --bind新增 agentopenclaw agents add helper --workspace ~/helper-ws --model openai/gpt-4.1新增隔離 agent,可指定獨立 workspace
openclaw agentsset-identity--agent --name --theme --emoji --avatar設(shè)置 agent 身份openclaw agents set-identity --agent main --name "Lobster" --emoji "??"更新 agent 的名稱、形象、主題
openclaw agentsdelete--force --json刪除 agentopenclaw agents delete helper --force刪除某個 agent 及其狀態(tài)
openclaw sessions---json --store --active查看會話openclaw sessions --json --active 60查看最近活躍 session,研究路由和會話落盤很有用

6. Memory / Models / System

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw memorystatus--agent --json --deep查看記憶索引狀態(tài)openclaw memory status --agent main --json看 memory 是否已建立索引
openclaw memoryindex--agent --force重建記憶索引openclaw memory index --agent main --force強(qiáng)制重建記憶庫索引
openclaw memorysearch--agent --max-results --min-score --json搜索記憶openclaw memory search "飛書配置" --agent main --json在記憶文件中檢索相關(guān)內(nèi)容
openclaw modelslist--all --local --provider --json列模型openclaw models list --provider openai --json查看當(dāng)前模型目錄
openclaw modelsstatus--json --probe --agent查看模型狀態(tài)openclaw models status --probe --json檢查 provider 認(rèn)證、默認(rèn)模型、可用性
openclaw modelsset-設(shè)置默認(rèn)模型openclaw models set openai/gpt-4.1把默認(rèn)對話模型切換成指定模型
openclaw modelsset-image-設(shè)置圖片模型openclaw models set-image openai/gpt-image-1配置默認(rèn)圖像模型
openclaw modelsaliases list--json查看別名openclaw models aliases list --json查看模型別名表
openclaw modelsfallbacks list--json查看回退模型openclaw models fallbacks list --json查看主模型失敗時的回退鏈
openclaw modelsscan--provider --set-default --json掃描候選模型openclaw models scan --provider openrouter --set-default --json自動發(fā)現(xiàn)可用模型并設(shè)置默認(rèn)值
openclaw modelsauth add-增加認(rèn)證openclaw models auth add交互式添加 provider 認(rèn)證
openclaw modelsauth login--provider --method登錄 provideropenclaw models auth login --provider google-gemini-cli跑 provider 自帶登錄流程
openclaw modelsauth setup-token--provider初始化 tokenopenclaw models auth setup-token --provider anthropic用 CLI 協(xié)助建立 token
openclaw modelsauth paste-token--provider --profile-id粘貼 tokenopenclaw models auth paste-token --provider openai手動把 token 寫入認(rèn)證配置
openclaw systemevent--text --mode --json注入系統(tǒng)事件openclaw system event --text "重新加載人格" --mode now向主 session 注入一條系統(tǒng)事件
openclaw systemheartbeat last--json查看最后心跳openclaw system heartbeat last --json查看最近一次心跳事件
openclaw systemheartbeat enable--json開啟心跳openclaw system heartbeat enable打開系統(tǒng)心跳機(jī)制
openclaw systemheartbeat disable--json關(guān)閉心跳openclaw system heartbeat disable關(guān)閉系統(tǒng)心跳
openclaw systempresence--json查看 presenceopenclaw system presence --json查看系統(tǒng) presence 條目

7. Cron / Hooks / Plugins / Skills

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw cronstatus--json查看調(diào)度器狀態(tài)openclaw cron status --json查看 cron 子系統(tǒng)是否運行
openclaw cronlist--all --json列任務(wù)openclaw cron list --all --json查看當(dāng)前定時任務(wù)
openclaw cronadd--name --message --every --cron --agent --announce添加任務(wù)openclaw cron add --name morning --every 1d --message "早報" --agent main周期性觸發(fā) agent 或系統(tǒng)事件
openclaw cronrm--json刪除任務(wù)openclaw cron rm <job-id>刪除定時任務(wù)
openclaw cronenable-啟用任務(wù)openclaw cron enable <job-id>啟用某個已禁用任務(wù)
openclaw crondisable-禁用任務(wù)openclaw cron disable <job-id>暫停某個任務(wù)
openclaw cronruns--id --limit查看運行歷史openclaw cron runs --id <job-id> --limit 20查看任務(wù)執(zhí)行記錄
openclaw cronrun--due立即執(zhí)行openclaw cron run --id <job-id>手動調(diào)試執(zhí)行某任務(wù)
openclaw cronedit--name --message --every --enable編輯任務(wù)openclaw cron edit <job-id> --every 2h --enable修改任務(wù)計劃、消息、目標(biāo)
openclaw hookslist--eligible --json --verbose列 hooksopenclaw hooks list --verbose查看可用和已安裝 hooks
openclaw hooksinfo--jsonhook 詳情openclaw hooks info my-hook --json查看某個 hook 詳細(xì)信息
openclaw hookscheck--json檢查 hookopenclaw hooks check --json看是否滿足依賴和啟用條件
openclaw hooksenable-啟用 hookopenclaw hooks enable my-hook讓 hook 進(jìn)入運行狀態(tài)
openclaw hooksdisable-禁用 hookopenclaw hooks disable my-hook停止 hook 生效
openclaw hooksinstall--link安裝 hookopenclaw hooks install ./my-hook-pack --link安裝本地 hook 包
openclaw hooksupdate--all --dry-run更新 hooksopenclaw hooks update --all更新已安裝 hooks
openclaw pluginslist--json --enabled --verbose列插件openclaw plugins list --enabled查看插件目錄及啟用情況
openclaw pluginsinfo--json插件詳情openclaw plugins info feishu --json查看某插件元信息
openclaw pluginsenable-啟用插件openclaw plugins enable feishu在配置中啟用插件
openclaw pluginsdisable-禁用插件openclaw plugins disable feishu在配置中禁用插件
openclaw pluginsinstall--link安裝插件openclaw plugins install ./plugin-dir --link安裝本地或 npm 插件
openclaw pluginsuninstall--force --dry-run卸載插件openclaw plugins uninstall feishu --force卸載某插件
openclaw pluginsupdate--all --dry-run更新插件openclaw plugins update --all更新已安裝插件
openclaw pluginsdoctor-檢查插件問題openclaw plugins doctor診斷插件加載異常
openclaw skillslist--json --eligible --verbose列技能openclaw skills list --eligible查看可用 skills
openclaw skillsinfo--json技能詳情openclaw skills info browser --json查看某個 skill 的元信息
openclaw skillscheck--json檢查技能openclaw skills check --json看哪些 skills 缺依賴、哪些可直接用

8. Browser / Nodes / Devices / Node / Sandbox / TUI

這一組命令非常多,我給你列最常用、最有代表性的。

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw browserstatus--json瀏覽器狀態(tài)openclaw browser status --json查看 OpenClaw 專用瀏覽器是否運行
openclaw browserstart-啟動瀏覽器openclaw browser start啟動專用瀏覽器環(huán)境
openclaw browserstop-停止瀏覽器openclaw browser stop停掉瀏覽器進(jìn)程
openclaw browsertabs-列出標(biāo)簽頁openclaw browser tabs查看當(dāng)前所有打開頁面
openclaw browseropen-打開網(wǎng)址openclaw browser open https://example.com新開一個標(biāo)簽頁
openclaw browsernavigate--target-id跳轉(zhuǎn)頁面openclaw browser navigate https://openai.com當(dāng)前標(biāo)簽頁跳轉(zhuǎn)
openclaw browserscreenshot--full-page --type截圖openclaw browser screenshot --full-page獲取當(dāng)前頁面截圖
openclaw browsersnapshot--format --limit頁面結(jié)構(gòu)快照openclaw browser snapshot --format ai讀取頁面結(jié)構(gòu),適合自動化
openclaw browserclick--target-id點擊元素openclaw browser click REF_12根據(jù)快照 ref 點擊頁面元素
openclaw browsertype--submit --slowly輸入文字openclaw browser type REF_8 "hello" --submit給輸入框填內(nèi)容
openclaw browserpdf--target-id導(dǎo)出 PDFopenclaw browser pdf保存頁面為 PDF
openclaw browserconsole--level控制臺日志openclaw browser console --level error查看頁面 JS 錯路徑讀取配置值
openclaw configset--json設(shè)置配置項openclaw config set channels.feishu.enabled true --json修改某個配置字段,通常直接寫入 openclaw.json
openclaw configunset-刪除配置項openclaw config unset channels.feishu.allowFrom刪除某個字段,讓配置回退默認(rèn)行為
openclaw doctor---repair --fix --force --deep健康檢查與修復(fù)openclaw doctor --repair檢查網(wǎng)關(guān)、配置、渠道、服務(wù)是否異常,并嘗試修復(fù)
openclaw dashboard---no-open打開控制臺openclaw dashboard打開控制 UI,用瀏覽器查看運行狀態(tài)
openclaw reset---scope --yes --dry-run重置本地狀態(tài)openclaw reset --scope config+creds+sessions --yes清空配置、憑據(jù)、會話,適合重新初始化
openclaw uninstall---service --state --workspace --all卸載 OpenClaw 本地環(huán)境openclaw uninstall --all --yes刪除服務(wù)、狀態(tài)、工作區(qū),但 CLI 本體可能仍保留

2. Gateway / Daemon / 日志

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw gatewayrun--port --bind --token --auth --verbose --dev前臺運行 Gatewayopenclaw gateway run --port 18789 --verbose啟動 WebSocket Gateway,負(fù)責(zé) sessions、routing、channels
openclaw gatewaystatus--json --deep --timeout查看網(wǎng)關(guān)狀態(tài)openclaw gateway status --json查看 Gateway 是否運行、是否可探測
openclaw gatewayinstall--port --runtime --token安裝后臺服務(wù)openclaw gateway install --port 18789把 Gateway 安裝成 launchd/systemd/schtasks 服務(wù)
openclaw gatewaystart--json啟動后臺服務(wù)openclaw gateway start啟動已安裝的 Gateway 服務(wù)
openclaw gatewaystop--json停止后臺服務(wù)openclaw gateway stop停止 Gateway 服務(wù)
openclaw gatewayrestart--json重啟后臺服務(wù)openclaw gateway restart修改配置后常用來重啟服務(wù)
openclaw gatewaycall--params --json調(diào)用 Gateway RPCopenclaw gateway call some.method --params '{"foo":"bar"}' --json直接調(diào)用內(nèi)部 RPC,適合調(diào)試
openclaw gatewayhealth--json獲取健康信息openclaw gateway health --json查看運行健康狀態(tài)
openclaw gatewayprobe--url --token --json探測本地/遠(yuǎn)程 Gatewayopenclaw gateway probe --json綜合檢查網(wǎng)關(guān)可達(dá)性、探測能力
openclaw gatewaydiscover--json發(fā)現(xiàn) Gatewayopenclaw gateway discover --json通過 Bonjour 等方式發(fā)現(xiàn)可連接網(wǎng)關(guān)
openclaw daemonstatus--json查看后臺服務(wù)狀態(tài)openclaw daemon status關(guān)注系統(tǒng)服務(wù)安裝/運行情況
openclaw daemoninstall--port --runtime安裝后臺服務(wù)openclaw daemon install --port 18789與 gateway install 類似,更偏服務(wù)管理
openclaw daemonstart--json啟動服務(wù)openclaw daemon start啟動后臺 Gateway
openclaw daemonstop--json停止服務(wù)openclaw daemon stop停止后臺 Gateway
openclaw daemonrestart--json重啟服務(wù)openclaw daemon restart配置更新后重啟
openclaw logs---follow --limit --json --plain查看日志openclaw logs --follow實時查看 Gateway 文件日志,是排障核心命令

3. 渠道 / 飛書 / 配對

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw channelslist--json列出已配置渠道openclaw channels list --json查看 Telegram、Feishu、Slack 等賬號是否已配置
openclaw channelsstatus--probe --json查看渠道狀態(tài)openclaw channels status --probe --json檢查憑據(jù)、連接狀態(tài)是否正常
openclaw channelscapabilities--channel --account --json查看渠道能力openclaw channels capabilities --channel feishu --json查看該渠道支持哪些消息能力
openclaw channelsresolve--channel --account --kind --json名稱解析為 IDopenclaw channels resolve --channel feishu --kind user "張三"把用戶/群名稱解析成內(nèi)部目標(biāo) ID
openclaw channelslogs--channel --lines --json查看渠道日志openclaw channels logs --channel feishu --lines 200專門看某個渠道的日志片段
openclaw channelsadd--channel --account --name --token --bot-token --app-token添加或更新渠道openclaw channels add --channel feishu --account main為某渠道寫入賬號配置,飛書、Telegram、Slack 都走這里
openclaw channelsremove--channel --account --delete移除渠道openclaw channels remove --channel feishu --account main --delete停用或刪除某個渠道賬號
openclaw channelslogin--channel --account渠道登錄openclaw channels login --channel whatsapp某些渠道需要登錄鏈接
openclaw channelslogout--channel --account渠道登出openclaw channels logout --channel whatsapp斷開登錄會話
openclaw pairinglist--channel --json查看待審批配對openclaw pairing list --channel feishu --json對 dmPolicy=pairing 的渠道,列出待審批用戶
openclaw pairingapprove--channel --notify批準(zhǔn)配對openclaw pairing approve ABC123 --channel feishu --notify批準(zhǔn)某個飛書用戶,讓其后續(xù)消息進(jìn)入正常 Agent 鏈路

4. 消息操作

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw messagesend--message/-m --target/-t --channel --account --media --reply-to發(fā)送消息openclaw message send -m "hello" -t user_xxx --channel feishu向某個渠道目標(biāo)發(fā)送消息
openclaw messagebroadcast--targets --message --channel批量廣播openclaw message broadcast --channel feishu --targets u1,u2 --message "通知"向多個目標(biāo)一次性發(fā)消息
openclaw messagepoll--poll-question --poll-option發(fā)起投票openclaw message poll --channel discord --target 123 --poll-question "吃什么" --poll-option 火鍋 --poll-option 燒烤某些渠道支持原生投票
openclaw messageread--target --channel --limit --before --after讀最近消息openclaw message read --channel feishu --target user_xxx --limit 20拉取目標(biāo)最近消息記錄
openclaw messageedit--message-id --message編輯消息openclaw message edit --channel discord --message-id 123 --message "修正版"修改已發(fā)送消息
openclaw messagedelete--message-id刪除消息openclaw message delete --channel discord --message-id 123刪除指定消息
openclaw messagereact--message-id --emoji --remove添加/移除反應(yīng)openclaw message react --channel slack --message-id 123 --emoji ??對消息加 emoji reaction
openclaw messagereactions--message-id --limit查看反應(yīng)openclaw message reactions --channel slack --message-id 123列出某條消息的反應(yīng)詳情
openclaw messagepin--message-id置頂消息openclaw message pin --channel discord --target chan_xxx --message-id 123把消息置頂
openclaw messageunpin--message-id取消置頂openclaw message unpin --channel discord --target chan_xxx --message-id 123取消置頂
openclaw messagepins--limit查看置頂列表openclaw message pins --channel discord --target chan_xxx列出當(dāng)前頻道置頂
openclaw messagesearch--query --channel-id --author-id搜索消息openclaw message search --channel discord --query "error"按關(guān)鍵字檢索消息
openclaw messagepermissions--target --channel查看權(quán)限openclaw message permissions --channel discord --target channel:123查看機(jī)器人在該目標(biāo)上的權(quán)限
openclaw messagethread create--thread-name --message新建線程openclaw message thread create --channel discord --target chan_xxx --thread-name "討論"創(chuàng)建討論線程
openclaw messagethread list--channel-id --limit列線程openclaw message thread list --channel discord --channel-id 123查看頻道線程
openclaw messagethread reply--message --reply-to在線程中回復(fù)openclaw message thread reply --channel discord --target thread_xxx --message "收到"往線程里發(fā)送消息
openclaw messageemoji list--guild-id列表情openclaw message emoji list --channel discord --guild-id 123查看服務(wù)器表情
openclaw messageemoji upload--emoji-name --media上傳表情openclaw message emoji upload --channel discord --guild-id 123 --emoji-name ok --media ./ok.png上傳自定義表情
openclaw messagesticker send--sticker-id發(fā)貼紙openclaw message sticker send --channel discord --target chan_xxx --sticker-id 123發(fā)送貼紙
openclaw messagesticker upload--sticker-name --media上傳貼紙openclaw message sticker upload --channel discord --guild-id 123 --sticker-name wow --media ./wow.png上傳貼紙資源
openclaw messagechannel info--target頻道信息openclaw message channel info --channel discord --target chan_xxx查看頻道詳情
openclaw messagechannel list--guild-id列頻道openclaw message channel list --channel discord --guild-id 123列出服務(wù)器頻道
openclaw messagemember info--user-id --guild-id成員信息openclaw message member info --channel discord --guild-id 123 --user-id 456查看成員信息
openclaw messagevoice status--guild-id --user-id語音狀態(tài)openclaw message voice status --channel discord --guild-id 123 --user-id 456查看某成員語音狀態(tài)
openclaw messageevent list--guild-id列活動openclaw message event list --channel discord --guild-id 123查看計劃活動
openclaw messageevent create--event-name --start-time建活動openclaw message event create --channel discord --guild-id 123 --event-name "周會" --start-time 2026-03-12T10:00:00創(chuàng)建活動事件
openclaw messagetimeout--guild-id --user-id --duration-min禁言成員openclaw message timeout --channel discord --guild-id 123 --user-id 456 --duration-min 10對成員進(jìn)行超時禁言
openclaw messagekick--guild-id --user-id移出成員openclaw message kick --channel discord --guild-id 123 --user-id 456踢出成員
openclaw messageban--guild-id --user-id封禁成員openclaw message ban --channel discord --guild-id 123 --user-id 456封禁成員

5. Agent / Agents / Sessions

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw agent---message/-m --to/-t --agent --channel --deliver --local --thinking --json手動跑一輪 agentopenclaw agent -m "hello" --agent main --channel feishu --deliver不依賴外部入站消息,直接觸發(fā)一個 agent turn
openclaw agentslist--json --bindings列出 agentopenclaw agents list --bindings --json查看有哪些 agent,以及它們的路由綁定
openclaw agentsadd--workspace --model --agent-dir --bind新增 agentopenclaw agents add helper --workspace ~/helper-ws --model openai/gpt-4.1新增隔離 agent,可指定獨立 workspace
openclaw agentsset-identity--agent --name --theme --emoji --avatar設(shè)置 agent 身份openclaw agents set-identity --agent main --name "Lobster" --emoji "??"更新 agent 的名稱、形象、主題
openclaw agentsdelete--force --json刪除 agentopenclaw agents delete helper --force刪除某個 agent 及其狀態(tài)
openclaw sessions---json --store --active查看會話openclaw sessions --json --active 60查看最近活躍 session,研究路由和會話落盤很有用

6. Memory / Models / System

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw memorystatus--agent --json --deep查看記憶索引狀態(tài)openclaw memory status --agent main --json看 memory 是否已建立索引
openclaw memoryindex--agent --force重建記憶索引openclaw memory index --agent main --force強(qiáng)制重建記憶庫索引
openclaw memorysearch--agent --max-results --min-score --json搜索記憶openclaw memory search "飛書配置" --agent main --json在記憶文件中檢索相關(guān)內(nèi)容
openclaw modelslist--all --local --provider --json列模型openclaw models list --provider openai --json查看當(dāng)前模型目錄
openclaw modelsstatus--json --probe --agent查看模型狀態(tài)openclaw models status --probe --json檢查 provider 認(rèn)證、默認(rèn)模型、可用性
openclaw modelsset-設(shè)置默認(rèn)模型openclaw models set openai/gpt-4.1把默認(rèn)對話模型切換成指定模型
openclaw modelsset-image-設(shè)置圖片模型openclaw models set-image openai/gpt-image-1配置默認(rèn)圖像模型
openclaw modelsaliases list--json查看別名openclaw models aliases list --json查看模型別名表
openclaw modelsfallbacks list--json查看回退模型openclaw models fallbacks list --json查看主模型失敗時的回退鏈
openclaw modelsscan--provider --set-default --json掃描候選模型openclaw models scan --provider openrouter --set-default --json自動發(fā)現(xiàn)可用模型并設(shè)置默認(rèn)值
openclaw modelsauth add-增加認(rèn)證openclaw models auth add交互式添加 provider 認(rèn)證
openclaw modelsauth login--provider --method登錄 provideropenclaw models auth login --provider google-gemini-cli跑 provider 自帶登錄流程
openclaw modelsauth setup-token--provider初始化 tokenopenclaw models auth setup-token --provider anthropic用 CLI 協(xié)助建立 token
openclaw modelsauth paste-token--provider --profile-id粘貼 tokenopenclaw models auth paste-token --provider openai手動把 token 寫入認(rèn)證配置
openclaw systemevent--text --mode --json注入系統(tǒng)事件openclaw system event --text "重新加載人格" --mode now向主 session 注入一條系統(tǒng)事件
openclaw systemheartbeat last--json查看最后心跳openclaw system heartbeat last --json查看最近一次心跳事件
openclaw systemheartbeat enable--json開啟心跳openclaw system heartbeat enable打開系統(tǒng)心跳機(jī)制
openclaw systemheartbeat disable--json關(guān)閉心跳openclaw system heartbeat disable關(guān)閉系統(tǒng)心跳
openclaw systempresence--json查看 presenceopenclaw system presence --json查看系統(tǒng) presence 條目

7. Cron / Hooks / Plugins / Skills

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw cronstatus--json查看調(diào)度器狀態(tài)openclaw cron status --json查看 cron 子系統(tǒng)是否運行
openclaw cronlist--all --json列任務(wù)openclaw cron list --all --json查看當(dāng)前定時任務(wù)
openclaw cronadd--name --message --every --cron --agent --announce添加任務(wù)openclaw cron add --name morning --every 1d --message "早報" --agent main周期性觸發(fā) agent 或系統(tǒng)事件
openclaw cronrm--json刪除任務(wù)openclaw cron rm <job-id>刪除定時任務(wù)
openclaw cronenable-啟用任務(wù)openclaw cron enable <job-id>啟用某個已禁用任務(wù)
openclaw crondisable-禁用任務(wù)openclaw cron disable <job-id>暫停某個任務(wù)
openclaw cronruns--id --limit查看運行歷史openclaw cron runs --id <job-id> --limit 20查看任務(wù)執(zhí)行記錄
openclaw cronrun--due立即執(zhí)行openclaw cron run --id <job-id>手動調(diào)試執(zhí)行某任務(wù)
openclaw cronedit--name --message --every --enable編輯任務(wù)openclaw cron edit <job-id> --every 2h --enable修改任務(wù)計劃、消息、目標(biāo)
openclaw hookslist--eligible --json --verbose列 hooksopenclaw hooks list --verbose查看可用和已安裝 hooks
openclaw hooksinfo--jsonhook 詳情openclaw hooks info my-hook --json查看某個 hook 詳細(xì)信息
openclaw hookscheck--json檢查 hookopenclaw hooks check --json看是否滿足依賴和啟用條件
openclaw hooksenable-啟用 hookopenclaw hooks enable my-hook讓 hook 進(jìn)入運行狀態(tài)
openclaw hooksdisable-禁用 hookopenclaw hooks disable my-hook停止 hook 生效
openclaw hooksinstall--link安裝 hookopenclaw hooks install ./my-hook-pack --link安裝本地 hook 包
openclaw hooksupdate--all --dry-run更新 hooksopenclaw hooks update --all更新已安裝 hooks
openclaw pluginslist--json --enabled --verbose列插件openclaw plugins list --enabled查看插件目錄及啟用情況
openclaw pluginsinfo--json插件詳情openclaw plugins info feishu --json查看某插件元信息
openclaw pluginsenable-啟用插件openclaw plugins enable feishu在配置中啟用插件
openclaw pluginsdisable-禁用插件openclaw plugins disable feishu在配置中禁用插件
openclaw pluginsinstall--link安裝插件openclaw plugins install ./plugin-dir --link安裝本地或 npm 插件
openclaw pluginsuninstall--force --dry-run卸載插件openclaw plugins uninstall feishu --force卸載某插件
openclaw pluginsupdate--all --dry-run更新插件openclaw plugins update --all更新已安裝插件
openclaw pluginsdoctor-檢查插件問題openclaw plugins doctor診斷插件加載異常
openclaw skillslist--json --eligible --verbose列技能openclaw skills list --eligible查看可用 skills
openclaw skillsinfo--json技能詳情openclaw skills info browser --json查看某個 skill 的元信息
openclaw skillscheck--json檢查技能openclaw skills check --json看哪些 skills 缺依賴、哪些可直接用

8. Browser / Nodes / Devices / Node / Sandbox / TUI

這一組命令非常多,我給你列最常用、最有代表性的。

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw browserstatus--json瀏覽器狀態(tài)openclaw browser status --json查看 OpenClaw 專用瀏覽器是否運行
openclaw browserstart-啟動瀏覽器openclaw browser start啟動專用瀏覽器環(huán)境
openclaw browserstop-停止瀏覽器openclaw browser stop停掉瀏覽器進(jìn)程
openclaw browsertabs-列出標(biāo)簽頁openclaw browser tabs查看當(dāng)前所有打開頁面
openclaw browseropen-打開網(wǎng)址openclaw browser open https://example.com新開一個標(biāo)簽頁
openclaw browsernavigate--target-id跳轉(zhuǎn)頁面openclaw browser navigate https://openai.com當(dāng)前標(biāo)簽頁跳轉(zhuǎn)
openclaw browserscreenshot--full-page --type截圖openclaw browser screenshot --full-page獲取當(dāng)前頁面截圖
openclaw browsersnapshot--format --limit頁面結(jié)構(gòu)快照openclaw browser snapshot --format ai讀取頁面結(jié)構(gòu),適合自動化
openclaw browserclick--target-id點擊元素openclaw browser click REF_12根據(jù)快照 ref 點擊頁面元素
openclaw browsertype--submit --slowly輸入文字openclaw browser type REF_8 "hello" --submit給輸入框填內(nèi)容
openclaw browserpdf--target-id導(dǎo)出 PDFopenclaw browser pdf保存頁面為 PDF
openclaw browserconsole--level控制臺日志openclaw browser console --level error查看頁面 JS 錯誤
openclaw nodesstatus--json節(jié)點狀態(tài)openclaw nodes status --json查看已知節(jié)點連接情況
openclaw nodespending--json待審批節(jié)點openclaw nodes pending --json查看待配對節(jié)點
openclaw nodesapprove--json批準(zhǔn)節(jié)點openclaw nodes approve <node-id>批準(zhǔn)一個新節(jié)點接入
openclaw nodesrun--node --raw --agent在節(jié)點上執(zhí)行命令openclaw nodes run --node mac-mini --raw "ls -la"在遠(yuǎn)端節(jié)點執(zhí)行 shell 命令
openclaw nodesnotify--node --title --body本地通知openclaw nodes notify --node mac-mini --title "提醒" --body "任務(wù)完成"給節(jié)點機(jī)器發(fā)本地通知
openclaw nodescanvas snapshot--node畫布快照openclaw nodes canvas snapshot --node mac-mini獲取節(jié)點上的 canvas 快照
openclaw nodescamera snap--node拍照openclaw nodes camera snap --node iphone調(diào)用節(jié)點攝像頭拍照
openclaw nodesscreen record--node --duration錄屏openclaw nodes screen record --node mac-mini --duration 10s遠(yuǎn)程錄屏
openclaw deviceslist--json查看設(shè)備openclaw devices list --json查看待配對和已配對設(shè)備
openclaw devicesapprove--json批準(zhǔn)設(shè)備openclaw devices approve <device-id>允許設(shè)備接入
openclaw devicesreject--json拒絕設(shè)備openclaw devices reject <device-id>拒絕設(shè)備接入
openclaw devicesrotate--device --role輪換 tokenopenclaw devices rotate --device ipad --role viewer更新設(shè)備 token
openclaw devicesrevoke--device --role撤銷 tokenopenclaw devices revoke --device ipad --role viewer撤銷設(shè)備訪問權(quán)
openclaw noderun--host --port運行 headless nodeopenclaw node run --host 127.0.0.1 --port 18789啟動 headless node host
openclaw nodestatus--json查看 node 狀態(tài)openclaw node status --json查看本機(jī) node host 狀態(tài)
openclaw sandboxlist--json --browser列沙箱openclaw sandbox list --json查看 agent/browser 的容器沙箱
openclaw sandboxrecreate--all --agent --session重建沙箱openclaw sandbox recreate --all --force刪除舊容器并重建
openclaw sandboxexplain--session --agent --json解釋策略openclaw sandbox explain --agent main --json看當(dāng)前 session/agent 生效的沙箱與工具策略
openclaw tui---url --token --session --deliver --message打開終端 UIopenclaw tui --session main --message "hello"在終端里連接 Gateway 進(jìn)行對話

9. DNS / Docs / Webhooks / Directory / Security / Update

命令子命令常用參數(shù)中文備注例子詳細(xì)用途
openclaw dnssetup--domain --apply配置 DNS 發(fā)現(xiàn)openclaw dns setup --domain openclaw.internal --apply配置 CoreDNS / 寬域服務(wù)發(fā)現(xiàn)
openclaw docs--搜索官方文檔openclaw docs直接查 OpenClaw 在線文檔
openclaw webhooksgmail setup--account --project --topic --hook-url配置 Gmail webhookopenclaw webhooks gmail setup --account me@gmail.com --project my-gcp-proj配置 Gmail Pub/Sub 與 OpenClaw hook
openclaw webhooksgmail run--account --topic --hook-url運行 Gmail watchopenclaw webhooks gmail run --account me@gmail.com --topic projects/x/topics/y啟動 Gmail 監(jiān)聽與推送循環(huán)
openclaw directoryself--channel --account --json查看當(dāng)前賬號openclaw directory self --channel feishu --json查詢機(jī)器人/當(dāng)前賬號自身信息
openclaw directorypeers list--query --limit列聯(lián)系人openclaw directory peers list --channel feishu --query 張 --limit 10搜索聯(lián)系人/同事
openclaw directorygroups list--query --limit列群組openclaw directory groups list --channel feishu --query 產(chǎn)品搜索群組
openclaw directorygroups members--group-id --limit列群成員openclaw directory groups members --channel feishu --group-id grp_xxx查看群成員
openclaw securityaudit--deep --fix --json安全審計openclaw security audit --deep --json審計配置、權(quán)限和常見安全風(fēng)險
openclaw updatewizard--timeout交互式更新openclaw update wizard通過向?qū)Ц?OpenClaw
openclaw updatestatus--json --timeout查看更新狀態(tài)openclaw update status --json查看當(dāng)前版本與更新通道

10. 你現(xiàn)在最值得先記住的“飛書工作流命令組”

如果你現(xiàn)在的重點是 研究 OpenClaw + 飛書 的運行鏈路,建議優(yōu)先記下面這組:

命令子命令例子用途
openclaw gatewaystatusopenclaw gateway status先確認(rèn) Gateway 是否活著
openclaw logs-openclaw logs --follow實時看飛書消息有沒有打進(jìn)來
openclaw channelslistopenclaw channels list --json確認(rèn)飛書渠道已配置
openclaw channelsstatusopenclaw channels status --probe --json檢查飛書連接狀態(tài)
openclaw pairinglistopenclaw pairing list --channel feishu看第一次私聊是否進(jìn)了 pairing
openclaw pairingapproveopenclaw pairing approve ABC123 --channel feishu --notify批準(zhǔn)用戶后才會進(jìn)入正常會話
openclaw sessions-openclaw sessions --json看有沒有生成 session
openclaw agent-openclaw agent -m "hello" --agent main --channel feishu --deliver手工觸發(fā)一次 agent 運行
openclaw messagesendopenclaw message send -m "測試" -t user_xxx --channel feishu直接往飛書發(fā)消息,排除 agent 問題
openclaw channelslogsopenclaw channels logs --channel feishu --lines 200看飛書插件日志

11. 一份最實用的排障順序

你可以直接按這個順序排查:

openclaw gateway status
openclaw channels list --json
openclaw channels status --probe --json
openclaw pairing list --channel feishu
openclaw sessions --json
openclaw logs --follow

這 6 條命令基本能把:

  • 網(wǎng)關(guān)是否運行
  • 飛書是否接通
  • 用戶是否卡在 pairing
  • 是否落到了 session
  • 日志里是否報錯

全部串起來。

到此這篇關(guān)于OpenClaw CLI 命令速查手冊(中文注釋+示例版)的文章就介紹到這了,更多相關(guān)OpenClaw CLI 命令內(nèi)容請搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持腳本之家!

相關(guān)文章

最新評論

满城县| 岳阳县| 荣成市| 饶平县| 江陵县| 新巴尔虎左旗| 洪泽县| 武鸣县| 华容县| 广东省| 东城区| 嘉禾县| 仪陇县| 科技| 珠海市| 大田县| 都昌县| 平塘县| 淮滨县| 乌兰察布市| 壶关县| 金寨县| 富顺县| 东至县| 禹城市| 京山县| 繁昌县| 南皮县| 晋中市| 建瓯市| 南陵县| 同心县| 湟中县| 扎兰屯市| 大竹县| 三亚市| 成武县| 鹤庆县| 上蔡县| 修武县| 简阳市|