@spacebar_ai/moldclaw-core 2026.3.41 → 2026.3.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/accounts-5qY-dKca.d.ts +103 -0
- package/dist/accounts-SqdHz2ZP.js +114 -0
- package/dist/acp-cli-E6bcNqiE.js +2093 -0
- package/dist/actions.runtime-BU_XMuLk.js +119 -0
- package/dist/actions.runtime-CY5h8lqH.js +133 -0
- package/dist/agent-scope-lZlwP1At.js +208 -0
- package/dist/agents-C4SkadR1.js +853 -0
- package/dist/agents-RfwqGCzE.js +222 -0
- package/dist/agents.config-CX9CPNfP.js +17 -0
- package/dist/agents.config-DF9Zwn9n.js +121 -0
- package/dist/allow-list-3WSjz1zl.js +81 -0
- package/dist/allowlist-DNbDjFjw.js +142 -0
- package/dist/api-BEOpJ7dR.js +117 -0
- package/dist/audit-CpJz_eu6.js +787 -0
- package/dist/audit-CpfSjvyo.js +54 -0
- package/dist/audit-channel.collect.runtime-BeGotloZ.js +605 -0
- package/dist/audit-channel.runtime-BJDZ7ETt.js +121 -0
- package/dist/audit-extra.async-C2G0mqmk.js +813 -0
- package/dist/audit-membership-runtime-B1FqJsPV.js +162 -0
- package/dist/audit.deep.runtime-DyL9O_sU.js +25 -0
- package/dist/audit.nondeep.runtime-C6jFgJfH.js +832 -0
- package/dist/audit.runtime-Dnlsn23e.js +118 -0
- package/dist/auth-Ch3Rchm4.js +101 -0
- package/dist/auth-choice-CEFSlnLT.js +122 -0
- package/dist/auth-choice-CVCef-eU.js +268 -0
- package/dist/auth-choice-Cez-pXrg.js +507 -0
- package/dist/auth-choice-options-DO78mvPe.js +123 -0
- package/dist/auth-choice-prompt-CUkC7Mmb.js +36 -0
- package/dist/auth-choice-prompt-DCuQRiVl.js +115 -0
- package/dist/auth-choice.apply-helpers-BhbNIV8X.js +66 -0
- package/dist/auth-choice.plugin-providers.runtime-4BhqvEw_.js +119 -0
- package/dist/auth-profiles-smABVXzp.js +128040 -0
- package/dist/auth-profiles.runtime-Cr-ojtTc.js +116 -0
- package/dist/banner-CojBHPWr.js +342 -0
- package/dist/bluebubbles-BnLsj2Fy.d.ts +6 -0
- package/dist/bluebubbles-CVk7M3Bl.js +64 -0
- package/dist/bot-DdyrB2z9.d.ts +478 -0
- package/dist/brave-w4Fo8WZ3.js +24 -0
- package/dist/browser-cli-DWFs3P_i.js +1494 -0
- package/dist/build-info.json +3 -3
- package/dist/bundled/boot-md/handler.d.ts +1 -1
- package/dist/bundled/boot-md/handler.js +35 -35
- package/dist/bundled/bootstrap-extra-files/handler.d.ts +1 -1
- package/dist/bundled/bootstrap-extra-files/handler.js +1 -1
- package/dist/bundled/command-logger/handler.d.ts +1 -1
- package/dist/bundled/session-memory/handler.d.ts +1 -1
- package/dist/bundled/session-memory/handler.js +36 -36
- package/dist/call-Do7wTSr7.js +39 -0
- package/dist/call-gdDAt07d.js +640 -0
- package/dist/canvas-host/a2ui/.bundle.hash +1 -1
- package/dist/channel-B26pkce0.js +214 -0
- package/dist/channel-BJHp0AQC.js +352 -0
- package/dist/channel-BKFOv51P.js +4681 -0
- package/dist/channel-BNgpOY8v.js +538 -0
- package/dist/channel-BcQAAo2P.js +226 -0
- package/dist/channel-BvNdnhbx.js +1598 -0
- package/dist/channel-C1Rda3Jd.js +306 -0
- package/dist/channel-C87DG-F7.js +803 -0
- package/dist/channel-CIip0kvZ.js +619 -0
- package/dist/channel-CTPxoT_E2.js +316 -0
- package/dist/channel-CklaCzUG.js +562 -0
- package/dist/channel-CoJnAdLs.js +920 -0
- package/dist/channel-D3tafL1_.js +949 -0
- package/dist/channel-DFMrP2uu.js +542 -0
- package/dist/channel-DMd5cJQe.js +397 -0
- package/dist/channel-Dm34kxAJ.js +207 -0
- package/dist/channel-DmwF9udn.js +1321 -0
- package/dist/channel-account-context-Bjur9nlh.js +103 -0
- package/dist/channel-bGnST659.js +943 -0
- package/dist/channel-hIgbkTZf.js +575 -0
- package/dist/channel-m_TGrDKo.js +497 -0
- package/dist/channel-options-DoUPBMa8.js +50 -0
- package/dist/channel-plugin-ids-TZIY4hFs.js +26 -0
- package/dist/channel-summary-qD54bOBO.js +111 -0
- package/dist/channel.runtime-B0H04Dkk.js +199 -0
- package/dist/channel.runtime-BU1f3NkV.js +418 -0
- package/dist/channel.runtime-Bj1sfLep.js +4011 -0
- package/dist/channel.runtime-BtPAAJc3.js +870 -0
- package/dist/channel.runtime-Bx-10m_j.js +171 -0
- package/dist/channel.runtime-CI_TBywQ.js +179 -0
- package/dist/channel.runtime-CSLj14-Z.js +182 -0
- package/dist/channel.runtime-D-lTSYAd.js +404 -0
- package/dist/channel.runtime-DJqIOSji.js +127 -0
- package/dist/channel.runtime-Ec8aQ9V2.js +241 -0
- package/dist/channel.runtime-ax5a1jBm.js +218 -0
- package/dist/channel.setup-B-ncdYLT.js +9 -0
- package/dist/channel.setup-BY4bh5dm.js +9 -0
- package/dist/channel.setup-BovsdMnL.js +57 -0
- package/dist/channel.setup-CXzXA25h.js +6 -0
- package/dist/channel.setup-DcZUEufN.js +8 -0
- package/dist/channel.setup-E6zceRsE.js +8 -0
- package/dist/channel.setup-Pc7nGbdX.js +11 -0
- package/dist/channels/plugins/actions/discord.d.ts +2 -2
- package/dist/channels/plugins/actions/discord.js +35 -35
- package/dist/channels/plugins/actions/signal.d.ts +1 -1
- package/dist/channels/plugins/actions/signal.js +35 -35
- package/dist/channels/plugins/actions/telegram.d.ts +2 -2
- package/dist/channels/plugins/actions/telegram.js +35 -35
- package/dist/channels/plugins/agent-tools/whatsapp-login.d.ts +3 -3
- package/dist/channels/plugins/agent-tools/whatsapp-login.js +35 -35
- package/dist/channels-CPtE5ND6.js +404 -0
- package/dist/channels-Cj8ZolHI.js +1118 -0
- package/dist/channels-cli-D2sKrntt.js +291 -0
- package/dist/channels-status-issues-CzIHODg2.js +16 -0
- package/dist/clawbot-cli-BcwEDmUn.js +118 -0
- package/dist/cleanup-utils-D0L17RsX.js +96 -0
- package/dist/cli/daemon-cli.js +1 -1
- package/dist/cli-BvGVPKnD.js +154 -0
- package/dist/command-registry-CADQzTAg.js +14 -0
- package/dist/command-registry-ktiJNAJd.js +242 -0
- package/dist/command-secret-gateway-CXp10RTM.js +111 -0
- package/dist/compact.runtime-DyKL-Iar.js +116 -0
- package/dist/completion-cli-Bz4STrpt.js +17 -0
- package/dist/completion-cli-pVda2OFb.js +445 -0
- package/dist/config-BbvDRSYp.js +31 -0
- package/dist/config-CwBv71QC.js +44 -0
- package/dist/config-cli-Y0uXHbOw.js +678 -0
- package/dist/config-guard-BpW5g7JE.js +118 -0
- package/dist/config-validation-B-vLIsbo.js +262 -0
- package/dist/config-value-DT3-5958.js +132 -0
- package/dist/configure-B9U-jCqP.js +1100 -0
- package/dist/configure-BJ3Wrs5b.js +243 -0
- package/dist/control-ui-assets-C1YDYi82.js +232 -0
- package/dist/control-ui-shared-Dm5Dh0Lo.js +29 -0
- package/dist/core-BwKq3krw.js +150 -0
- package/dist/core-hjBwfDsW.d.ts +87 -0
- package/dist/cron-cli-DTDgfoMh.js +639 -0
- package/dist/daemon-cli-C-dkAXR1.js +339 -0
- package/dist/daemon-install-Oy0Q5pMF.js +180 -0
- package/dist/deliver-DNGnDqF9.js +111 -0
- package/dist/deliver-runtime-CCNZIhET.js +111 -0
- package/dist/device-id-cli-XvwZbIyC.js +52 -0
- package/dist/device-identity-IG5DngWM.js +365 -0
- package/dist/devices-cli-DIsxj4xp.js +342 -0
- package/dist/diagnostic-DTPopFvh.js +310 -0
- package/dist/directory-cli-DTSY3Ktr.js +311 -0
- package/dist/directory-config-helpers-DpFcAbmo.d.ts +38 -0
- package/dist/directory.static-CBRAUwUW.js +44 -0
- package/dist/discord-CrgxhEWw.js +114 -0
- package/dist/discovery-DrG7wmAR.js +48 -0
- package/dist/dm-policy-shared-DKoGdUpY.d.ts +95 -0
- package/dist/dns-cli-BJiz6CLK.js +217 -0
- package/dist/docs-cli-Dq2Yi5qO.js +174 -0
- package/dist/doctor-completion-D3GeVcFP.js +90 -0
- package/dist/doctor-config-flow-B1cMjr8h.js +112 -0
- package/dist/doctor-config-flow-BUe7JpV3.js +2437 -0
- package/dist/enable-Bc8bCuVe.js +24 -0
- package/dist/entry.js +4 -4
- package/dist/exec-approvals-cli-kLAev6bP.js +421 -0
- package/dist/extensions/acpx/index.d.ts +1 -1
- package/dist/extensions/amazon-bedrock/index.d.ts +1 -1
- package/dist/extensions/amazon-bedrock/index.js +4 -4
- package/dist/extensions/anthropic/index.d.ts +1 -1
- package/dist/extensions/anthropic/index.js +35 -35
- package/dist/extensions/bluebubbles/index.d.ts +1 -1
- package/dist/extensions/bluebubbles/index.js +39 -39
- package/dist/extensions/bluebubbles/setup-entry.d.ts +2 -2
- package/dist/extensions/bluebubbles/setup-entry.js +39 -39
- package/dist/extensions/brave/index.d.ts +1 -1
- package/dist/extensions/brave/index.js +5 -5
- package/dist/extensions/byteplus/index.d.ts +1 -1
- package/dist/extensions/byteplus/index.js +35 -35
- package/dist/extensions/cloudflare-ai-gateway/index.d.ts +1 -1
- package/dist/extensions/cloudflare-ai-gateway/index.js +36 -36
- package/dist/extensions/copilot-proxy/index.d.ts +1 -1
- package/dist/extensions/copilot-proxy/index.js +4 -4
- package/dist/extensions/device-pair/index.d.ts +1 -1
- package/dist/extensions/device-pair/index.js +4 -4
- package/dist/extensions/diagnostics-otel/index.d.ts +1 -1
- package/dist/extensions/diagnostics-otel/index.js +4 -4
- package/dist/extensions/diffs/index.d.ts +1 -1
- package/dist/extensions/discord/index.d.ts +1 -1
- package/dist/extensions/discord/index.js +40 -40
- package/dist/extensions/discord/setup-entry.d.ts +1 -1
- package/dist/extensions/discord/setup-entry.js +38 -38
- package/dist/extensions/elevenlabs/index.d.ts +1 -1
- package/dist/extensions/elevenlabs/index.js +35 -35
- package/dist/extensions/feishu/index.d.ts +2 -2
- package/dist/extensions/feishu/index.js +40 -40
- package/dist/extensions/feishu/setup-entry.d.ts +2 -2
- package/dist/extensions/feishu/setup-entry.js +37 -37
- package/dist/extensions/firecrawl/index.d.ts +1 -1
- package/dist/extensions/firecrawl/index.js +35 -35
- package/dist/extensions/github-copilot/index.d.ts +1 -1
- package/dist/extensions/github-copilot/index.js +35 -35
- package/dist/extensions/google/index.d.ts +1 -1
- package/dist/extensions/google/index.js +35 -35
- package/dist/extensions/googlechat/index.d.ts +1 -1
- package/dist/extensions/googlechat/index.js +38 -38
- package/dist/extensions/googlechat/setup-entry.d.ts +1 -1
- package/dist/extensions/googlechat/setup-entry.js +38 -38
- package/dist/extensions/huggingface/index.d.ts +1 -1
- package/dist/extensions/huggingface/index.js +35 -35
- package/dist/extensions/imessage/index.d.ts +1 -1
- package/dist/extensions/imessage/index.js +39 -39
- package/dist/extensions/imessage/setup-entry.d.ts +1 -1
- package/dist/extensions/imessage/setup-entry.js +39 -39
- package/dist/extensions/irc/index.d.ts +1 -1
- package/dist/extensions/irc/index.js +38 -38
- package/dist/extensions/irc/setup-entry.d.ts +2 -2
- package/dist/extensions/irc/setup-entry.js +38 -38
- package/dist/extensions/kakao-talkchannel/index.d.ts +1 -1
- package/dist/extensions/kakao-talkchannel/index.js +4 -4
- package/dist/extensions/kilocode/index.d.ts +1 -1
- package/dist/extensions/kilocode/index.js +35 -35
- package/dist/extensions/kimi-coding/index.d.ts +1 -1
- package/dist/extensions/kimi-coding/index.js +35 -35
- package/dist/extensions/line/index.d.ts +1 -1
- package/dist/extensions/line/index.js +37 -37
- package/dist/extensions/line/setup-entry.d.ts +1 -1
- package/dist/extensions/line/setup-entry.js +37 -37
- package/dist/extensions/llm-task/index.d.ts +1 -1
- package/dist/extensions/llm-task/index.js +35 -35
- package/dist/extensions/lobster/index.d.ts +1 -1
- package/dist/extensions/lobster/index.js +4 -4
- package/dist/extensions/matrix/index.d.ts +1 -1
- package/dist/extensions/matrix/index.js +40 -40
- package/dist/extensions/matrix/setup-entry.d.ts +2 -2
- package/dist/extensions/matrix/setup-entry.js +40 -40
- package/dist/extensions/mattermost/index.d.ts +1 -1
- package/dist/extensions/mattermost/index.js +37 -37
- package/dist/extensions/mattermost/setup-entry.d.ts +2 -2
- package/dist/extensions/mattermost/setup-entry.js +37 -37
- package/dist/extensions/memory-core/index.d.ts +1 -1
- package/dist/extensions/memory-core/index.js +4 -4
- package/dist/extensions/memory-lancedb/index.d.ts +1 -1
- package/dist/extensions/memory-lancedb/index.js +4 -4
- package/dist/extensions/microsoft/index.d.ts +1 -1
- package/dist/extensions/microsoft/index.js +35 -35
- package/dist/extensions/minimax/index.d.ts +1 -1
- package/dist/extensions/minimax/index.js +35 -35
- package/dist/extensions/mistral/index.d.ts +1 -1
- package/dist/extensions/mistral/index.js +35 -35
- package/dist/extensions/modelstudio/index.d.ts +1 -1
- package/dist/extensions/modelstudio/index.js +35 -35
- package/dist/extensions/moonshot/index.d.ts +1 -1
- package/dist/extensions/moonshot/index.js +35 -35
- package/dist/extensions/msteams/index.d.ts +1 -1
- package/dist/extensions/msteams/index.js +40 -40
- package/dist/extensions/msteams/setup-entry.d.ts +1 -1
- package/dist/extensions/msteams/setup-entry.js +40 -40
- package/dist/extensions/nextcloud-talk/index.d.ts +1 -1
- package/dist/extensions/nextcloud-talk/index.js +37 -37
- package/dist/extensions/nextcloud-talk/setup-entry.d.ts +2 -2
- package/dist/extensions/nextcloud-talk/setup-entry.js +37 -37
- package/dist/extensions/nostr/index.d.ts +1 -1
- package/dist/extensions/nostr/index.js +37 -37
- package/dist/extensions/nostr/setup-entry.d.ts +1 -1
- package/dist/extensions/nostr/setup-entry.js +37 -37
- package/dist/extensions/nvidia/index.d.ts +1 -1
- package/dist/extensions/nvidia/index.js +4 -4
- package/dist/extensions/ollama/index.d.ts +1 -1
- package/dist/extensions/ollama/index.js +7 -7
- package/dist/extensions/open-prose/index.d.ts +1 -1
- package/dist/extensions/open-prose/index.js +4 -4
- package/dist/extensions/openai/index.d.ts +1 -1
- package/dist/extensions/openai/index.js +35 -35
- package/dist/extensions/opencode/index.d.ts +1 -1
- package/dist/extensions/opencode/index.js +35 -35
- package/dist/extensions/opencode-go/index.d.ts +1 -1
- package/dist/extensions/opencode-go/index.js +35 -35
- package/dist/extensions/openrouter/index.d.ts +1 -1
- package/dist/extensions/openrouter/index.js +35 -35
- package/dist/extensions/openshell/index.d.ts +1 -1
- package/dist/extensions/openshell/index.js +35 -35
- package/dist/extensions/perplexity/index.d.ts +1 -1
- package/dist/extensions/perplexity/index.js +5 -5
- package/dist/extensions/phone-control/index.d.ts +1 -1
- package/dist/extensions/phone-control/index.js +4 -4
- package/dist/extensions/qianfan/index.d.ts +1 -1
- package/dist/extensions/qianfan/index.js +35 -35
- package/dist/extensions/qwen-portal-auth/index.d.ts +1 -1
- package/dist/extensions/qwen-portal-auth/index.js +35 -35
- package/dist/extensions/sglang/index.d.ts +1 -1
- package/dist/extensions/sglang/index.js +35 -35
- package/dist/extensions/signal/index.d.ts +1 -1
- package/dist/extensions/signal/index.js +38 -38
- package/dist/extensions/signal/setup-entry.d.ts +1 -1
- package/dist/extensions/signal/setup-entry.js +38 -38
- package/dist/extensions/slack/index.d.ts +1 -1
- package/dist/extensions/slack/index.js +39 -39
- package/dist/extensions/slack/setup-entry.d.ts +1 -1
- package/dist/extensions/slack/setup-entry.js +38 -38
- package/dist/extensions/synology-chat/index.d.ts +1 -1
- package/dist/extensions/synology-chat/index.js +37 -37
- package/dist/extensions/synology-chat/setup-entry.d.ts +1 -1
- package/dist/extensions/synology-chat/setup-entry.js +37 -37
- package/dist/extensions/synthetic/index.d.ts +1 -1
- package/dist/extensions/synthetic/index.js +35 -35
- package/dist/extensions/talk-voice/index.d.ts +1 -1
- package/dist/extensions/talk-voice/index.js +35 -35
- package/dist/extensions/telegram/index.d.ts +1 -1
- package/dist/extensions/telegram/index.js +38 -38
- package/dist/extensions/telegram/setup-entry.d.ts +1 -1
- package/dist/extensions/telegram/setup-entry.js +37 -37
- package/dist/extensions/thread-ownership/index.d.ts +1 -1
- package/dist/extensions/thread-ownership/index.js +4 -4
- package/dist/extensions/tlon/index.d.ts +1 -1
- package/dist/extensions/tlon/index.js +37 -37
- package/dist/extensions/tlon/setup-entry.d.ts +1 -1
- package/dist/extensions/tlon/setup-entry.js +37 -37
- package/dist/extensions/together/index.d.ts +1 -1
- package/dist/extensions/together/index.js +35 -35
- package/dist/extensions/twitch/index.d.ts +2 -2
- package/dist/extensions/twitch/index.js +37 -37
- package/dist/extensions/venice/index.d.ts +1 -1
- package/dist/extensions/venice/index.js +35 -35
- package/dist/extensions/vercel-ai-gateway/index.d.ts +1 -1
- package/dist/extensions/vercel-ai-gateway/index.js +36 -36
- package/dist/extensions/vllm/index.d.ts +1 -1
- package/dist/extensions/vllm/index.js +35 -35
- package/dist/extensions/voice-call/index.d.ts +1 -1
- package/dist/extensions/voice-call/index.js +35 -35
- package/dist/extensions/volcengine/index.d.ts +1 -1
- package/dist/extensions/volcengine/index.js +35 -35
- package/dist/extensions/whatsapp/index.d.ts +1 -1
- package/dist/extensions/whatsapp/index.js +38 -38
- package/dist/extensions/whatsapp/setup-entry.d.ts +1 -1
- package/dist/extensions/whatsapp/setup-entry.js +38 -38
- package/dist/extensions/xai/index.d.ts +1 -1
- package/dist/extensions/xai/index.js +35 -35
- package/dist/extensions/xiaomi/index.d.ts +1 -1
- package/dist/extensions/xiaomi/index.js +35 -35
- package/dist/extensions/zai/index.d.ts +1 -1
- package/dist/extensions/zai/index.js +35 -35
- package/dist/extensions/zalo/index.d.ts +1 -1
- package/dist/extensions/zalo/index.js +39 -39
- package/dist/extensions/zalo/setup-entry.d.ts +1 -1
- package/dist/extensions/zalo/setup-entry.js +39 -39
- package/dist/extensions/zalouser/index.d.ts +1 -1
- package/dist/extensions/zalouser/index.js +40 -40
- package/dist/extensions/zalouser/setup-entry.d.ts +1 -1
- package/dist/extensions/zalouser/setup-entry.js +40 -40
- package/dist/feishu-fIcnHDTd.d.ts +36 -0
- package/dist/gateway-cli-0c-8h93_.js +26437 -0
- package/dist/gateway-install-token-1PwJvrBY.js +163 -0
- package/dist/gateway-rpc-C0Vk51W7.js +26 -0
- package/dist/gateway-runtime-CBm3CCoA.js +69 -0
- package/dist/git-commit-BTWXFY41.js +177 -0
- package/dist/git-commit-D6GTN5Yt.js +2 -0
- package/dist/googlechat-BQr4xgoZ.js +307 -0
- package/dist/googlechat-BvwsCVKl.d.ts +12 -0
- package/dist/group-access-DpiQnd-G.d.ts +61 -0
- package/dist/health-6yZQGADY.js +113 -0
- package/dist/health-C9DYGyRe.js +570 -0
- package/dist/heartbeat-summary-Dct2lqJj.js +57 -0
- package/dist/help-CtwSApfq.js +81 -0
- package/dist/hooks-9gokOxZ5.d.ts +6 -0
- package/dist/hooks-cli-BegKzHZT.js +1000 -0
- package/dist/hooks-status-Bm_pGORf.js +78 -0
- package/dist/http-registry-D-S6a1Na.d.ts +20 -0
- package/dist/identity-file-Diub2a0t.js +60 -0
- package/dist/image-generation-CbIVzmAR.d.ts +9 -0
- package/dist/imessage-Bgok9kfl.js +31 -0
- package/dist/imessage-VIHePprL.js +115 -0
- package/dist/inbound-reply-dispatch-B53GAGWq.js +71 -0
- package/dist/inbound-reply-dispatch-n7U3qg15.d.ts +72 -0
- package/dist/index.js +2 -2
- package/dist/install-target-oz1pjfHH.js +574 -0
- package/dist/installs-CUFm5V8a.js +532 -0
- package/dist/io-BaBxjB1v.js +9739 -0
- package/dist/io-CgHb1Jld.js +29 -0
- package/dist/irc-CaRKzGvW.js +672 -0
- package/dist/library-C5SNBCMb.js +112 -0
- package/dist/lifecycle-core-Dn8PK6nk.js +382 -0
- package/dist/line/accounts.d.ts +2 -2
- package/dist/line/send.d.ts +1 -1
- package/dist/line/send.js +7 -7
- package/dist/line/template-messages.d.ts +1 -1
- package/dist/line-B5QFpgN_.d.ts +75 -0
- package/dist/line-fePrrQOD.js +530 -0
- package/dist/llm-slug-generator-hKae3XDA.js +67 -0
- package/dist/llm-slug-generator.d.ts +1 -1
- package/dist/llm-slug-generator.js +36 -36
- package/dist/logging-CdisccbY.js +13 -0
- package/dist/logging-LKQSgX1d.js +30 -0
- package/dist/login-qr-C1YWh4nE.js +233 -0
- package/dist/login-qr-WFluMDMb.js +112 -0
- package/dist/logs-cli-CNzOvZ2d.js +256 -0
- package/dist/manager-runtime-DgMhLTkR.js +111 -0
- package/dist/manager.runtime-hUWgpPt2.js +715 -0
- package/dist/manifest-registry-CS_p1OBQ.js +1329 -0
- package/dist/matrix-43_RGLZN.d.ts +68 -0
- package/dist/matrix-CCFxHfxa.js +1269 -0
- package/dist/matrix-DWs_qIkJ.js +1495 -0
- package/dist/mcp-cli-Ci2jvv3s.js +87 -0
- package/dist/media-understanding.runtime-Cdr6iTW6.js +116 -0
- package/dist/memory-cli-LZbyF0Iu.js +111 -0
- package/dist/memory-search-BHhETk6u.js +17 -0
- package/dist/memory-search-tTD5o_rU.js +204 -0
- package/dist/method-scopes-B2ZKSsxQ.js +2452 -0
- package/dist/model-auth-markers-LqZ4qhrZ.d.ts +20 -0
- package/dist/model-picker-CTR5mo4v.js +112 -0
- package/dist/model-picker-DG4z_dBs.js +390 -0
- package/dist/model-picker.runtime-DMQ9Pj9_.js +125 -0
- package/dist/model-selection-bBBxfXdb.js +653 -0
- package/dist/model-suppression.runtime-BVG75tZ7.js +116 -0
- package/dist/models-BjkVLfgw.js +2514 -0
- package/dist/models-ZO01Q4cx.js +118 -0
- package/dist/models-cli-DemdF-bm.js +309 -0
- package/dist/models-config-B2Jja8ua.js +111 -0
- package/dist/models-config.providers.discovery-puxTsH39.d.ts +18 -0
- package/dist/moldclaw-root-Cb6HRlUO.js +92 -0
- package/dist/monitor-BP4idxJD.js +782 -0
- package/dist/monitor-B_eP8Eim.js +772 -0
- package/dist/monitor-CRHYNl5J.js +3468 -0
- package/dist/monitor-Ci1Xg4g3.js +113 -0
- package/dist/monitor-DEodDl3z.js +6823 -0
- package/dist/monitor-DJlNKuMz.js +115 -0
- package/dist/monitor-DvFwDS9w.js +3076 -0
- package/dist/monitor-shared--cEjSf8s.js +444 -0
- package/dist/msteams-CV2a8uE8.js +852 -0
- package/dist/node-cli-Of2g7DSd.js +2503 -0
- package/dist/node-resolve-BYC2FbO2.js +835 -0
- package/dist/nodes-cli-CPHM6Upj.js +1380 -0
- package/dist/nostr-BFKRoOlz.d.ts +7 -0
- package/dist/nostr-lHpcBzz4.js +8744 -0
- package/dist/npm-resolution-kqHN85wB.js +60 -0
- package/dist/oauth-env-CLG8KOrz.js +10 -0
- package/dist/onboard-BON0C360.js +48 -0
- package/dist/onboard-CRkIBgOI.js +589 -0
- package/dist/onboard-DsKI17iq.js +25 -0
- package/dist/onboard-channels-BY3IbBBf.js +1241 -0
- package/dist/onboard-channels-CLKdRxvW.js +205 -0
- package/dist/onboard-custom-BjPrMo_R.js +571 -0
- package/dist/onboard-custom-DqcPiZBN.js +114 -0
- package/dist/onboard-helpers-BkrOY5OE.js +113 -0
- package/dist/onboard-helpers-DiSRTpZC.js +335 -0
- package/dist/onboard-hooks-pzEPZAvl.js +72 -0
- package/dist/onboard-remote-ChyLC6Dk.js +181 -0
- package/dist/onboard-remote-DHmK9ntl.js +117 -0
- package/dist/onboard-search-BgA3jEMW.js +302 -0
- package/dist/onboard-skills-BMo_NvnW.js +133 -0
- package/dist/onboard-skills-Bba-Z2p8.js +117 -0
- package/dist/outbound-media-BHD4aJEX.d.ts +11 -0
- package/dist/outbound-media-DSno0N82.js +11 -0
- package/dist/pairing-access-CzHpaM0R.d.ts +21 -0
- package/dist/pairing-cli-CmklqK0q.js +217 -0
- package/dist/perplexity-CXwMDD3u.js +24 -0
- package/dist/persistent-dedupe-B9vrAf8t.d.ts +26 -0
- package/dist/pi-model-discovery-runtime-BrK7tcaO.js +111 -0
- package/dist/pi-tools.before-tool-call.runtime-C5yLUogH.js +381 -0
- package/dist/plugin-install-C4AWJIFP.js +117 -0
- package/dist/plugin-install-CB3J1hfV.js +184 -0
- package/dist/plugin-install-plan-7itZiegi.js +49 -0
- package/dist/plugin-registry-DX_GFoiz.js +113 -0
- package/dist/plugin-registry-e3cxTtvb.js +49 -0
- package/dist/plugin-sdk/account-resolution.js +35 -35
- package/dist/plugin-sdk/acp-runtime.js +35 -35
- package/dist/plugin-sdk/agent-runtime.js +35 -35
- package/dist/plugin-sdk/bluebubbles.js +37 -37
- package/dist/plugin-sdk/channel-config-helpers.js +35 -35
- package/dist/plugin-sdk/channel-policy.js +35 -35
- package/dist/plugin-sdk/channel-runtime.js +35 -35
- package/dist/plugin-sdk/compat.js +36 -36
- package/dist/plugin-sdk/config-runtime.js +35 -35
- package/dist/plugin-sdk/conversation-runtime.js +35 -35
- package/dist/plugin-sdk/copilot-proxy.js +4 -4
- package/dist/plugin-sdk/core.js +4 -4
- package/dist/plugin-sdk/device-pair.js +4 -4
- package/dist/plugin-sdk/discord.js +35 -35
- package/dist/plugin-sdk/feishu.js +35 -35
- package/dist/plugin-sdk/gateway-runtime.js +10 -10
- package/dist/plugin-sdk/googlechat.js +37 -37
- package/dist/plugin-sdk/image-generation-runtime.js +35 -35
- package/dist/plugin-sdk/image-generation.js +35 -35
- package/dist/plugin-sdk/imessage.js +36 -36
- package/dist/plugin-sdk/index.js +35 -35
- package/dist/plugin-sdk/infra-runtime.js +35 -35
- package/dist/plugin-sdk/irc.js +37 -37
- package/dist/plugin-sdk/line.js +36 -36
- package/dist/plugin-sdk/llm-task.js +35 -35
- package/dist/plugin-sdk/lobster.js +4 -4
- package/dist/plugin-sdk/matrix.js +37 -37
- package/dist/plugin-sdk/mattermost.js +36 -36
- package/dist/plugin-sdk/media-runtime.js +35 -35
- package/dist/plugin-sdk/media-understanding-runtime.js +35 -35
- package/dist/plugin-sdk/media-understanding.js +35 -35
- package/dist/plugin-sdk/memory-lancedb.js +4 -4
- package/dist/plugin-sdk/minimax-portal-auth.js +4 -4
- package/dist/plugin-sdk/msteams.js +38 -38
- package/dist/plugin-sdk/nextcloud-talk.js +36 -36
- package/dist/plugin-sdk/nostr.js +36 -36
- package/dist/plugin-sdk/ollama-setup.js +9 -9
- package/dist/plugin-sdk/open-prose.js +4 -4
- package/dist/plugin-sdk/phone-control.js +4 -4
- package/dist/plugin-sdk/plugin-runtime.js +35 -35
- package/dist/plugin-sdk/provider-auth.js +35 -35
- package/dist/plugin-sdk/provider-models.js +5 -5
- package/dist/plugin-sdk/provider-onboard.js +4 -4
- package/dist/plugin-sdk/provider-setup.js +39 -39
- package/dist/plugin-sdk/provider-stream.js +4 -4
- package/dist/plugin-sdk/provider-usage.js +4 -4
- package/dist/plugin-sdk/qwen-portal-auth.js +35 -35
- package/dist/plugin-sdk/reply-history.js +35 -35
- package/dist/plugin-sdk/reply-runtime.js +35 -35
- package/dist/plugin-sdk/routing.js +3 -3
- package/dist/plugin-sdk/sandbox.js +35 -35
- package/dist/plugin-sdk/security-runtime.js +35 -35
- package/dist/plugin-sdk/self-hosted-provider-setup.js +37 -37
- package/dist/plugin-sdk/setup.js +35 -35
- package/dist/plugin-sdk/signal.js +35 -35
- package/dist/plugin-sdk/slack.js +35 -35
- package/dist/plugin-sdk/speech-runtime.js +35 -35
- package/dist/plugin-sdk/speech.js +35 -35
- package/dist/plugin-sdk/src/secrets/secure-file-store.d.ts +26 -0
- package/dist/plugin-sdk/src/subscription/provider.d.ts +5 -3
- package/dist/plugin-sdk/synology-chat.js +36 -36
- package/dist/plugin-sdk/talk-voice.js +4 -4
- package/dist/plugin-sdk/telegram.js +35 -35
- package/dist/plugin-sdk/text-runtime.js +7 -7
- package/dist/plugin-sdk/thread-ownership.js +4 -4
- package/dist/plugin-sdk/tlon.js +36 -36
- package/dist/plugin-sdk/twitch.js +35 -35
- package/dist/plugin-sdk/voice-call.js +35 -35
- package/dist/plugin-sdk/whatsapp.js +35 -35
- package/dist/plugin-sdk/zalo.js +38 -38
- package/dist/plugin-sdk/zalouser.js +38 -38
- package/dist/plugins/runtime/index.d.ts +1 -1
- package/dist/plugins/runtime/index.js +35 -35
- package/dist/plugins-DF5FaTO0.js +111 -0
- package/dist/plugins-cli-CvTJemqC.js +917 -0
- package/dist/policy-CNXISK_a.js +143 -0
- package/dist/preflight-audio.runtime-RP000oxo.js +116 -0
- package/dist/probe-BkM5pykD.js +21 -0
- package/dist/probe-DKbRTJv5.js +1793 -0
- package/dist/probe-DkrfRsjU.js +47 -0
- package/dist/probe-DpcJ0WeP.js +129 -0
- package/dist/probe-auth-BcNjX8hy.js +40 -0
- package/dist/probe-auth-DhuAb8ls.js +48 -0
- package/dist/probe-wciBj-aL.js +6329 -0
- package/dist/program-C8-p0mW5.js +253 -0
- package/dist/prompt-select-styled-DH0pVoc0.js +2673 -0
- package/dist/provider-api-key-auth.runtime-CAFeIQ1u.js +121 -0
- package/dist/provider-auth-choice-CB_HzdTl.js +126 -0
- package/dist/provider-auth-choice-helpers-hzDkh3f1.js +48 -0
- package/dist/provider-auth-choice-preference-BHCXvNSE.js +189 -0
- package/dist/provider-auth-choice.runtime-Dx4ms2C5.js +123 -0
- package/dist/provider-auth-choices-0KaDNPBQ.js +57 -0
- package/dist/provider-auth-guidance-BaAUiNr_.js +34 -0
- package/dist/provider-auth-result-Bto1bYtS.d.ts +18 -0
- package/dist/provider-models-DxOmeToO.d.ts +867 -0
- package/dist/provider-models-xnyxy6mO.js +2113 -0
- package/dist/provider-ollama-setup-DBYK__ov.d.ts +32 -0
- package/dist/provider-ollama-setup-QzgCxj44.js +314 -0
- package/dist/provider-onboard-B9ionepI.js +139 -0
- package/dist/provider-onboard-CURxJ_UX.d.ts +40 -0
- package/dist/provider-runtime.runtime-4xwmsl5L.js +111 -0
- package/dist/provider-self-hosted-setup-BHd24EDG.js +182 -0
- package/dist/provider-self-hosted-setup-qeY8BYSy.d.ts +61 -0
- package/dist/provider-stream-Chz_EFw3.js +512 -0
- package/dist/provider-usage-C11Q7UwS.js +111 -0
- package/dist/provider-usage-kxemdMp2.js +633 -0
- package/dist/provider-wizard-CanJoxNC.js +152 -0
- package/dist/push-apns-Dsajnm8C.js +1038 -0
- package/dist/pw-ai-DUe4BbH2.js +1867 -0
- package/dist/qmd-manager-CAAFp7qK.js +1570 -0
- package/dist/qr-cli-Bu2jqTPY.js +113 -0
- package/dist/qr-cli-Bu9Z-X48.js +369 -0
- package/dist/reactions-Cpfum4iU.js +281 -0
- package/dist/read-only-account-inspect.discord.runtime-BK0LaMgC.js +116 -0
- package/dist/read-only-account-inspect.slack.runtime-DgKiC5wT.js +116 -0
- package/dist/read-only-account-inspect.telegram.runtime-mxfgFVOU.js +116 -0
- package/dist/redact-snapshot-DD8A4tdd.js +2663 -0
- package/dist/register.agent-DU4FtrU2.js +439 -0
- package/dist/register.backup-8nOYtJqg.js +625 -0
- package/dist/register.configure-DmtecqIH.js +252 -0
- package/dist/register.maintenance-Dir3ulKP.js +574 -0
- package/dist/register.message-Cfl-f3Ju.js +709 -0
- package/dist/register.onboard-Bv7WVzEi.js +192 -0
- package/dist/register.setup-BIyeI8RY.js +212 -0
- package/dist/register.status-health-sessions-C69WQcF4.js +498 -0
- package/dist/register.subclis-B_4KCgTd.js +315 -0
- package/dist/register.subclis-BeXsmgBL.js +13 -0
- package/dist/replies-DdcFUmki.js +110 -0
- package/dist/resolve-channels-DRZqPV5o.js +226 -0
- package/dist/resolve-channels-DxW1kqxA.js +262 -0
- package/dist/resolve-route-DdX-HBVt.js +538 -0
- package/dist/resolve-users-rgCQvkLs.js +143 -0
- package/dist/root-help-QAkoA7GD.js +32 -0
- package/dist/routes-CcJNnwTF.js +7097 -0
- package/dist/rpc-DDUAlBbH.js +67 -0
- package/dist/run-main-D9ci5pn7.js +424 -0
- package/dist/runtime-Bitmi8Er.d.ts +26 -0
- package/dist/runtime-discord-ops.runtime-T4sf7aRB.js +9078 -0
- package/dist/runtime-slack-ops.runtime-BQpP48mC.js +4556 -0
- package/dist/runtime-telegram-ops.runtime-cVO5dqOp.js +133 -0
- package/dist/runtime-whatsapp-login.runtime-DtNx0dSY.js +114 -0
- package/dist/runtime-whatsapp-outbound.runtime-Bw47QbFK.js +117 -0
- package/dist/sandbox-cli-DsFwjbjC.js +535 -0
- package/dist/search-manager-BRAK8fEe.js +16 -0
- package/dist/search-manager-BS5Db0A6.js +386 -0
- package/dist/secrets-cli-D3J46TJp.js +2070 -0
- package/dist/security-cli-B866M9cB.js +575 -0
- package/dist/send-B1pX9_Oc.js +283 -0
- package/dist/send-B2RrLg83.js +100 -0
- package/dist/send-DFnV__Aq.js +1025 -0
- package/dist/send-DZIH6CJt.js +629 -0
- package/dist/send-sl9WnKbW.js +631 -0
- package/dist/server-node-events-BT6egg20.js +506 -0
- package/dist/server-zI_K-D05.js +107 -0
- package/dist/sessions-C8kiAcoJ.js +112 -0
- package/dist/sessions-DLBpp52_.js +218 -0
- package/dist/setup-C7eOzMiC.js +387 -0
- package/dist/setup-CFIMq-Pz.d.ts +37 -0
- package/dist/setup-binary-CcAv8NXz.js +406 -0
- package/dist/setup-browser-C4eRV3h6.js +70 -0
- package/dist/setup-core-BnR486P-.js +143 -0
- package/dist/setup-core-CIswIiu5.js +166 -0
- package/dist/setup-core-CcbcrXXg.js +47 -0
- package/dist/setup-core-nZSw5BSv.js +205 -0
- package/dist/setup-surface-C5iSpT4M.js +490 -0
- package/dist/setup-wizard-helpers-r0J6l8ST.d.ts +203 -0
- package/dist/setup.finalize-adiRfo0U.js +522 -0
- package/dist/setup.gateway-config-BwFWKDfT.js +343 -0
- package/dist/shared-12TimyeF.js +182 -0
- package/dist/shared-9EWO34-k.js +298 -0
- package/dist/shared-B4vUbaRR.js +75 -0
- package/dist/shared-bNWpW3Dd.js +96 -0
- package/dist/shared-lU1y5dvS.js +102 -0
- package/dist/signal-DBlETRu9.js +114 -0
- package/dist/skills-Bio8GwTE.js +20 -0
- package/dist/skills-DE_MXFSN.js +853 -0
- package/dist/skills-cli-BGuW-tKw.js +292 -0
- package/dist/skills-install--rnorIoJ.js +763 -0
- package/dist/skills-status-B08PtBc_.js +21 -0
- package/dist/skills-status-CzM008aB.js +169 -0
- package/dist/slack-C4T53Nc-.js +114 -0
- package/dist/slash-commands.runtime-B7fsD8Be.js +128 -0
- package/dist/slash-dispatch.runtime-t0PAX4vQ.js +141 -0
- package/dist/slash-skill-commands.runtime-DIhPnEfR.js +116 -0
- package/dist/src-DrDirlvw.js +1701 -0
- package/dist/status-Bld14WSA.js +131 -0
- package/dist/status-CgeO4RuH.js +43 -0
- package/dist/status-HlvixAOq.js +606 -0
- package/dist/status-Rom_Lf3c.js +1599 -0
- package/dist/status-TwbMH6Am.js +126 -0
- package/dist/status-json-DMW7cmuK.js +288 -0
- package/dist/status.link-channel-V4LkB6Gq.js +143 -0
- package/dist/status.scan.deps.runtime-BE3X-dcP.js +126 -0
- package/dist/status.scan.runtime-BxVY4mty.js +119 -0
- package/dist/status.summary-CzLM0vVr.js +592 -0
- package/dist/status.summary.runtime-BSBnHZ1Q.js +118 -0
- package/dist/status.update-BxblMS7P.js +77 -0
- package/dist/subagent-orphan-recovery-BpRPryEj.js +307 -0
- package/dist/subagent-registry-runtime-DYYU5p3X.js +111 -0
- package/dist/subscription-CpFdxuFS.js +33 -0
- package/dist/subscription-DaA1urx-.js +102 -0
- package/dist/subscription-cli-Bvto9EmO.js +134 -0
- package/dist/synology-chat-3nwk-Nj0.js +297 -0
- package/dist/system-cli-BvNps8sl.js +94 -0
- package/dist/telegram/audit.d.ts +1 -1
- package/dist/telegram/audit.js +1 -1
- package/dist/telegram/token.d.ts +1 -1
- package/dist/telegram/token.js +35 -35
- package/dist/telegram-RtKXoEsF.js +114 -0
- package/dist/text-chunking-BD5mQe2R.js +84 -0
- package/dist/text-chunking-DDUU_vAF.d.ts +79 -0
- package/dist/tlon-z-kYmJE-.js +433 -0
- package/dist/tui-cli-CzSK08Rh.js +137 -0
- package/dist/tui-wV7R1Tlc.js +3834 -0
- package/dist/types-2H_e7eWT.d.ts +45 -0
- package/dist/types-ZKnGUchG.d.ts +22692 -0
- package/dist/types.base-BFiQZ4J9.d.ts +188 -0
- package/dist/ui-BWVHreeR.js +31 -0
- package/dist/update-D1Wgh1Tj.js +1036 -0
- package/dist/update-cli-CZh99uyY.js +1503 -0
- package/dist/update-offset-store-D5xTdUr0.js +112 -0
- package/dist/update-runner-GbKfoCHs.js +1496 -0
- package/dist/upsert-with-lock-BZU7Le8n.js +33 -0
- package/dist/usage-Czgwvg0h.js +115 -0
- package/dist/web-CMczmL90.js +112 -0
- package/dist/web-shared-B5Q0mIJq.d.ts +45 -0
- package/dist/webhook-request-guards-CsKDhZJr.d.ts +76 -0
- package/dist/webhook-targets-BSmFtesN.js +181 -0
- package/dist/webhook-targets-CjxuEE9C.d.ts +106 -0
- package/dist/webhooks-cli-Wl9y6AWW.js +350 -0
- package/dist/whatsapp-VzRW8MdR.js +114 -0
- package/dist/whatsapp-actions-Cg1Wxv8W.js +167 -0
- package/dist/workspace-DJ_S272u.js +484 -0
- package/dist/workspace-DbZSqjw0.js +289 -0
- package/dist/workspace-cli-D93DLmAh.js +154 -0
- package/dist/workspace-dirs-CGeIPpGN.js +2003 -0
- package/dist/zalo-CK2dlGmu.d.ts +9 -0
- package/dist/zalo-Db7s2boL.js +415 -0
- package/dist/zalouser-Jh5YTJX3.js +30911 -0
- package/docs/reference/templates/AGENTS.dev.md +83 -0
- package/docs/reference/templates/AGENTS.md +219 -0
- package/docs/reference/templates/BOOT.md +11 -0
- package/docs/reference/templates/BOOTSTRAP.md +62 -0
- package/docs/reference/templates/HEARTBEAT.md +12 -0
- package/docs/reference/templates/IDENTITY.dev.md +47 -0
- package/docs/reference/templates/IDENTITY.md +29 -0
- package/docs/reference/templates/SOUL.dev.md +76 -0
- package/docs/reference/templates/SOUL.md +43 -0
- package/docs/reference/templates/TOOLS.dev.md +24 -0
- package/docs/reference/templates/TOOLS.md +47 -0
- package/docs/reference/templates/USER.dev.md +18 -0
- package/docs/reference/templates/USER.md +23 -0
- package/extensions/discord/src/monitor/allow-list.ts +8 -1
- package/extensions/discord/src/monitor/message-handler.preflight.ts +4 -1
- package/package.json +2 -1
- package/dist/accounts-CDr-lDaV.d.ts +0 -103
- package/dist/accounts-CS8U4v8C.js +0 -114
- package/dist/acp-cli-BGT0jXcC.js +0 -2093
- package/dist/actions.runtime-BfckTw6c.js +0 -119
- package/dist/actions.runtime-Cl9mBfqH.js +0 -133
- package/dist/agent-scope-C-YmLnnb.js +0 -208
- package/dist/agents-CydD54p8.js +0 -222
- package/dist/agents-DpQsZO6O.js +0 -853
- package/dist/agents.config-XU7IsYE-.js +0 -121
- package/dist/agents.config-ssoQXuvF.js +0 -17
- package/dist/allow-list-Cfn6lmMK.js +0 -81
- package/dist/allowlist-CCYXVpM9.js +0 -142
- package/dist/api-BoXoFKxy.js +0 -117
- package/dist/audit-Bv05N5o9.js +0 -787
- package/dist/audit-CIWW1Aqm.js +0 -54
- package/dist/audit-channel.collect.runtime-Bi7yrdcO.js +0 -605
- package/dist/audit-channel.runtime-C_NDweiW.js +0 -121
- package/dist/audit-extra.async-Dp7OKSXg.js +0 -813
- package/dist/audit-membership-runtime-B8FQ6VtN.js +0 -162
- package/dist/audit.deep.runtime-CXhobL6b.js +0 -25
- package/dist/audit.nondeep.runtime-CrEm3T16.js +0 -832
- package/dist/audit.runtime-CJPKj1Zg.js +0 -118
- package/dist/auth-Byfp0flq.js +0 -101
- package/dist/auth-choice-BgOjdeXN.js +0 -507
- package/dist/auth-choice-CD1Heq0M.js +0 -122
- package/dist/auth-choice-ePNfg0iQ.js +0 -268
- package/dist/auth-choice-options-BlewQWI0.js +0 -123
- package/dist/auth-choice-prompt-BP2b6aXz.js +0 -36
- package/dist/auth-choice-prompt-Cmwl4n97.js +0 -115
- package/dist/auth-choice.apply-helpers-Dq-nxuuX.js +0 -66
- package/dist/auth-choice.plugin-providers.runtime-B23kOUzQ.js +0 -119
- package/dist/auth-profiles-1kPLbBwI.js +0 -127823
- package/dist/auth-profiles.runtime-DAfSjku1.js +0 -116
- package/dist/banner-DeOsobLO.js +0 -342
- package/dist/bluebubbles-BsLGedBM.js +0 -64
- package/dist/bluebubbles-CnT9wiS4.d.ts +0 -6
- package/dist/bot-CuzVYwa_.d.ts +0 -478
- package/dist/brave-BoWimrLe.js +0 -24
- package/dist/browser-cli-D_S3wEYE.js +0 -1494
- package/dist/call-ByEzDJ1_.js +0 -640
- package/dist/call-CHCWVg-O.js +0 -39
- package/dist/channel-3VC0oOMu.js +0 -214
- package/dist/channel-B9fCBPiS.js +0 -207
- package/dist/channel-B9q775cM.js +0 -562
- package/dist/channel-BG3UK54j.js +0 -803
- package/dist/channel-BRQAdMML.js +0 -352
- package/dist/channel-BmlLp933.js +0 -1321
- package/dist/channel-By6KvdTG.js +0 -920
- package/dist/channel-C8rRsdf6.js +0 -226
- package/dist/channel-CLEDBbXE.js +0 -943
- package/dist/channel-CMvBAG7o.js +0 -306
- package/dist/channel-CmlxxjHY.js +0 -1598
- package/dist/channel-CqG6_xN0.js +0 -949
- package/dist/channel-DNueHKs92.js +0 -316
- package/dist/channel-DUtyN7BX.js +0 -4681
- package/dist/channel-DWD6GrfZ.js +0 -538
- package/dist/channel-DaRYMYzj.js +0 -619
- package/dist/channel-Dj6BgLp8.js +0 -575
- package/dist/channel-account-context-Ba3u5D21.js +0 -103
- package/dist/channel-crabk6Em.js +0 -542
- package/dist/channel-i8uqQaK2.js +0 -497
- package/dist/channel-options-xljvwHS2.js +0 -50
- package/dist/channel-plugin-ids-DAgknSG4.js +0 -26
- package/dist/channel-summary-dHTMCG75.js +0 -111
- package/dist/channel-xVWQ96Ni.js +0 -397
- package/dist/channel.runtime-B6PoZ4BV.js +0 -182
- package/dist/channel.runtime-BPZmo57e.js +0 -404
- package/dist/channel.runtime-B_1uGR-U.js +0 -199
- package/dist/channel.runtime-BiXnPU0d.js +0 -218
- package/dist/channel.runtime-BpvDc9sv.js +0 -870
- package/dist/channel.runtime-CUua3W80.js +0 -418
- package/dist/channel.runtime-CaCBTd0A.js +0 -179
- package/dist/channel.runtime-D0FfYvUj.js +0 -4011
- package/dist/channel.runtime-DhoJtpvJ.js +0 -241
- package/dist/channel.runtime-Kj9EXNE0.js +0 -127
- package/dist/channel.runtime-r4tPuPyh.js +0 -171
- package/dist/channel.setup-B7d_grfe.js +0 -6
- package/dist/channel.setup-C0vu1fhi.js +0 -9
- package/dist/channel.setup-CAI0FNHj.js +0 -11
- package/dist/channel.setup-CkDVwv5R.js +0 -57
- package/dist/channel.setup-Cpd00YqQ.js +0 -8
- package/dist/channel.setup-DbBz1-WT.js +0 -9
- package/dist/channel.setup-GZnAvD9g.js +0 -8
- package/dist/channels-5H484RSw.js +0 -1118
- package/dist/channels-BnPudfyx.js +0 -404
- package/dist/channels-cli-WIC-QeH_.js +0 -291
- package/dist/channels-status-issues-RDmzovJU.js +0 -16
- package/dist/clawbot-cli-BgutNwf8.js +0 -118
- package/dist/cleanup-utils-DBl1Aij1.js +0 -96
- package/dist/cli-1P7u6zqu.js +0 -154
- package/dist/command-registry-B8jovrws.js +0 -232
- package/dist/command-registry-DtDl1FVm.js +0 -14
- package/dist/command-secret-gateway-BgUo3FxJ.js +0 -111
- package/dist/compact.runtime-CXbXM0AU.js +0 -116
- package/dist/completion-cli-Cik_owAE.js +0 -17
- package/dist/completion-cli-RU3P2RSl.js +0 -445
- package/dist/config-5HUpB1L1.js +0 -31
- package/dist/config-cli-QHaUHoZI.js +0 -433
- package/dist/config-guard-C9Sn3pE-.js +0 -118
- package/dist/config-sW57gztj.js +0 -44
- package/dist/config-validation-5LkjIKNt.js +0 -262
- package/dist/config-value-CtTWALxG.js +0 -132
- package/dist/configure-BmR2TPLf.js +0 -243
- package/dist/configure-DaLN-5xM.js +0 -1100
- package/dist/control-ui-assets-CH3MYmAo.js +0 -232
- package/dist/control-ui-shared-CA77PTml.js +0 -29
- package/dist/core-CvDzLs7B.js +0 -150
- package/dist/core-jm751KJ9.d.ts +0 -87
- package/dist/cron-cli-tguLpzyq.js +0 -639
- package/dist/daemon-cli-ptosOkL8.js +0 -339
- package/dist/daemon-install-DzU4EnVa.js +0 -180
- package/dist/deliver-DwxFoHM3.js +0 -111
- package/dist/deliver-runtime-DOdDyaPI.js +0 -111
- package/dist/device-id-cli-GopvlxxZ.js +0 -52
- package/dist/device-identity-CRfhC3_s.js +0 -365
- package/dist/devices-cli-ain7ESqU.js +0 -342
- package/dist/diagnostic-D96Xaqrj.js +0 -310
- package/dist/directory-cli-fh1UxGgY.js +0 -311
- package/dist/directory-config-helpers-Coivm0Mt.d.ts +0 -38
- package/dist/directory.static-CKjJUNGl.js +0 -44
- package/dist/discord-CflhwDEM.js +0 -114
- package/dist/discovery-x0ZqY4AB.js +0 -48
- package/dist/dm-policy-shared-DKzsSLlO.d.ts +0 -95
- package/dist/dns-cli-DCHyKjGf.js +0 -217
- package/dist/docs-cli-D3OoqYSP.js +0 -174
- package/dist/doctor-completion-Bq2eP87s.js +0 -90
- package/dist/doctor-config-flow-D8XRG9Ku.js +0 -2437
- package/dist/doctor-config-flow-DGiF1HGc.js +0 -112
- package/dist/enable-0QSF4YGH.js +0 -24
- package/dist/exec-approvals-cli-Bncym0Gd.js +0 -421
- package/dist/feishu-C1dM8pl2.d.ts +0 -36
- package/dist/gateway-cli-DYscsmA-.js +0 -26437
- package/dist/gateway-install-token-CNv17ac9.js +0 -163
- package/dist/gateway-rpc-BGC1Rxvg.js +0 -26
- package/dist/gateway-runtime-D89mSQPB.js +0 -69
- package/dist/git-commit-CeLH5Ozm.js +0 -2
- package/dist/git-commit-DUKRiCP-.js +0 -177
- package/dist/googlechat-BgXeXjd1.js +0 -307
- package/dist/googlechat-CNZQb1jd.d.ts +0 -12
- package/dist/group-access-Deh1tVNr.d.ts +0 -61
- package/dist/health-BEjzWwaB.js +0 -570
- package/dist/health-FjqrWQL6.js +0 -113
- package/dist/heartbeat-summary-CfdSA9M1.js +0 -57
- package/dist/help-BZeVprq1.js +0 -81
- package/dist/hooks-06OUQvAV.d.ts +0 -6
- package/dist/hooks-cli-B7uGJs2O.js +0 -1000
- package/dist/hooks-status-CfceaUSg.js +0 -78
- package/dist/http-registry-DYskWhOr.d.ts +0 -20
- package/dist/identity-file-sshkKKIr.js +0 -60
- package/dist/image-generation-D4o3j8o6.d.ts +0 -9
- package/dist/imessage-BcV3WGx_.js +0 -31
- package/dist/imessage-Dhje7Ty-.js +0 -115
- package/dist/inbound-reply-dispatch-C73_7SOl.js +0 -71
- package/dist/inbound-reply-dispatch-D6_HNqH8.d.ts +0 -72
- package/dist/install-target-D7NRhfzc.js +0 -574
- package/dist/installs-Bj6jblqc.js +0 -532
- package/dist/io-CMfWWPXQ.js +0 -9738
- package/dist/io-CV844hAM.js +0 -29
- package/dist/irc-DKi1fDYI.js +0 -672
- package/dist/library-rygTG3oA.js +0 -112
- package/dist/lifecycle-core-BPlvShWY.js +0 -382
- package/dist/line-B8gTtl3Y.d.ts +0 -75
- package/dist/line-CGsemKWJ.js +0 -530
- package/dist/llm-slug-generator-DlhVyMqT.js +0 -67
- package/dist/logging-5wu9k6w4.js +0 -30
- package/dist/logging-CxP9suT8.js +0 -13
- package/dist/login-qr-BcDsiwHs.js +0 -233
- package/dist/login-qr-Y8pJ5yV4.js +0 -112
- package/dist/logs-cli-XI9oVXpH.js +0 -256
- package/dist/manager-runtime-DkIlXBhD.js +0 -111
- package/dist/manager.runtime-Q0q2rJCC.js +0 -715
- package/dist/manifest-registry-DAd0SRAP.js +0 -1329
- package/dist/matrix-BI0DBBrG.js +0 -1495
- package/dist/matrix-D2JoHzb4.d.ts +0 -68
- package/dist/matrix-DiABGjJR.js +0 -1269
- package/dist/mcp-cli-BOyn_DLL.js +0 -87
- package/dist/media-understanding.runtime-DjUa7Dka.js +0 -116
- package/dist/memory-cli-CJd_vl-Y.js +0 -111
- package/dist/memory-search-CEEItIFR.js +0 -17
- package/dist/memory-search-Cv1SBrn7.js +0 -204
- package/dist/method-scopes-CQE7-bZ-.js +0 -2452
- package/dist/model-auth-markers-BFoM4IPf.d.ts +0 -20
- package/dist/model-picker-D6_89XHg.js +0 -112
- package/dist/model-picker-Svaw-APs.js +0 -390
- package/dist/model-picker.runtime-Chi9nV7A.js +0 -125
- package/dist/model-selection-hL8i1Jbs.js +0 -653
- package/dist/model-suppression.runtime-DjWJZ0X-.js +0 -116
- package/dist/models-7qj1dG_W.js +0 -118
- package/dist/models-BPOB_xJF.js +0 -2514
- package/dist/models-cli-DdlOVUjS.js +0 -309
- package/dist/models-config-CBqUS-jX.js +0 -111
- package/dist/models-config.providers.discovery-Dc905FWG.d.ts +0 -18
- package/dist/moldclaw-root-D6PbhbZk.js +0 -88
- package/dist/monitor-BPYhkEqF.js +0 -782
- package/dist/monitor-BuTcQ24j.js +0 -3468
- package/dist/monitor-CuXvNhFh.js +0 -113
- package/dist/monitor-D-TqSIHF.js +0 -6823
- package/dist/monitor-DRSgo9u2.js +0 -3076
- package/dist/monitor-DcHch39z.js +0 -772
- package/dist/monitor-DsHBMrXp.js +0 -115
- package/dist/monitor-shared-CL8T4gt1.js +0 -444
- package/dist/msteams-7FMwTvQG.js +0 -852
- package/dist/node-cli-BCjaSCZM.js +0 -2503
- package/dist/node-resolve-D5Hvcgyx.js +0 -835
- package/dist/nodes-cli-Dd_SNbkt.js +0 -1380
- package/dist/nostr-DBTFTxKs.js +0 -8744
- package/dist/nostr-DLqaIuZx.d.ts +0 -7
- package/dist/npm-resolution-CYfb3MHG.js +0 -60
- package/dist/oauth-env-zPt5RywA.js +0 -10
- package/dist/onboard-BEFQQeig.js +0 -25
- package/dist/onboard-CJHNyxJh.js +0 -48
- package/dist/onboard-D_3UeLEN.js +0 -589
- package/dist/onboard-channels-B_JL0Djc.js +0 -1241
- package/dist/onboard-channels-CqZzHt2C.js +0 -205
- package/dist/onboard-custom-CER3Ggbq.js +0 -571
- package/dist/onboard-custom-bNRdGECb.js +0 -114
- package/dist/onboard-helpers-BK0Hsb7Y.js +0 -335
- package/dist/onboard-helpers-CXZ5RPoR.js +0 -113
- package/dist/onboard-hooks-1NsxEDjH.js +0 -72
- package/dist/onboard-remote-DuKhC_7W.js +0 -117
- package/dist/onboard-remote-OwRcDuB3.js +0 -181
- package/dist/onboard-search-Cy8dOq2W.js +0 -302
- package/dist/onboard-skills-D5phRa6r.js +0 -117
- package/dist/onboard-skills-c9qWCNe9.js +0 -133
- package/dist/outbound-media-CXKqTh2X.d.ts +0 -11
- package/dist/outbound-media-DYRO2vTD.js +0 -11
- package/dist/pairing-access-BwJu1mkk.d.ts +0 -21
- package/dist/pairing-cli-BOnv0TYn.js +0 -217
- package/dist/perplexity-EZwC3y2b.js +0 -24
- package/dist/persistent-dedupe-hNES5tS1.d.ts +0 -26
- package/dist/pi-model-discovery-runtime-BToY3A6K.js +0 -111
- package/dist/pi-tools.before-tool-call.runtime-D_acPtld.js +0 -381
- package/dist/plugin-install-CgJpSjYd.js +0 -184
- package/dist/plugin-install-Cl1A4EF6.js +0 -117
- package/dist/plugin-install-plan-Dc2Z4DeU.js +0 -49
- package/dist/plugin-registry-B1UaWrQD.js +0 -49
- package/dist/plugin-registry-Cy8biwnn.js +0 -113
- package/dist/plugins-CXwvg50F.js +0 -111
- package/dist/plugins-cli-Uvzp2aYV.js +0 -917
- package/dist/policy-DsMBbEe7.js +0 -143
- package/dist/preflight-audio.runtime-hWsZIYvc.js +0 -116
- package/dist/probe-CNsSf1Uf.js +0 -6329
- package/dist/probe-CqOIrPhb.js +0 -47
- package/dist/probe-DH6gDw-h.js +0 -129
- package/dist/probe-DM16PLf4.js +0 -21
- package/dist/probe-DvAEEWYr.js +0 -1793
- package/dist/probe-auth-COfgCble.js +0 -48
- package/dist/probe-auth-I_5TX1Eh.js +0 -40
- package/dist/program-Dz80sgTU.js +0 -253
- package/dist/prompt-select-styled-wQehwFxK.js +0 -2673
- package/dist/provider-api-key-auth.runtime-BR9GU4ya.js +0 -121
- package/dist/provider-auth-choice-CdhA84kr.js +0 -126
- package/dist/provider-auth-choice-helpers-kabp_0zA.js +0 -48
- package/dist/provider-auth-choice-preference-se3zAM_2.js +0 -189
- package/dist/provider-auth-choice.runtime-BMc8-xNQ.js +0 -123
- package/dist/provider-auth-choices-CYsCViGi.js +0 -57
- package/dist/provider-auth-guidance-CMjUWlNf.js +0 -34
- package/dist/provider-auth-result-5xgWoVGi.d.ts +0 -18
- package/dist/provider-models-BCId_Lfu.js +0 -2113
- package/dist/provider-models-D-eFl9oH.d.ts +0 -867
- package/dist/provider-ollama-setup-B6XJZ0So.js +0 -314
- package/dist/provider-ollama-setup-BF1vhob8.d.ts +0 -32
- package/dist/provider-onboard-BjXHP3IZ.d.ts +0 -40
- package/dist/provider-onboard-Ca0TaNud.js +0 -139
- package/dist/provider-runtime.runtime-DwwkHw_7.js +0 -111
- package/dist/provider-self-hosted-setup-BEKLVGpj.js +0 -182
- package/dist/provider-self-hosted-setup-BQ5BIlpi.d.ts +0 -61
- package/dist/provider-stream-DrUD69ai.js +0 -512
- package/dist/provider-usage-BgKHCnjr.js +0 -111
- package/dist/provider-usage-D8EZpFz9.js +0 -633
- package/dist/provider-wizard-DMdb-zj_.js +0 -152
- package/dist/push-apns-BPH6d4VV.js +0 -1038
- package/dist/pw-ai-DttfldtL.js +0 -1867
- package/dist/qmd-manager-CybcDUfk.js +0 -1570
- package/dist/qr-cli-8NcmJ8Ft.js +0 -369
- package/dist/qr-cli-DWe0Our3.js +0 -113
- package/dist/reactions-D6N0LR16.js +0 -281
- package/dist/read-only-account-inspect.discord.runtime-CqUWTRfl.js +0 -116
- package/dist/read-only-account-inspect.slack.runtime-9-jpln3q.js +0 -116
- package/dist/read-only-account-inspect.telegram.runtime-EKPI1D7n.js +0 -116
- package/dist/redact-snapshot-DwJEIVk9.js +0 -2663
- package/dist/register.agent-D3YdDirP.js +0 -439
- package/dist/register.backup-dR27qCuo.js +0 -625
- package/dist/register.configure-BjFhkkka.js +0 -252
- package/dist/register.maintenance-DiMQJIOa.js +0 -574
- package/dist/register.message-CdZsKYH1.js +0 -709
- package/dist/register.onboard-B0rV1eaO.js +0 -192
- package/dist/register.setup-wKMvohzo.js +0 -212
- package/dist/register.status-health-sessions-BJ68m6pt.js +0 -498
- package/dist/register.subclis-CnnrWt2a.js +0 -315
- package/dist/register.subclis-lSvTkC6z.js +0 -13
- package/dist/replies-BABt9b48.js +0 -110
- package/dist/resolve-channels-BqZFl2Ux.js +0 -262
- package/dist/resolve-channels-DjQLXb7B.js +0 -226
- package/dist/resolve-route-CSHDsa_m.js +0 -538
- package/dist/resolve-users-BG6HaSR5.js +0 -143
- package/dist/root-help-ohmaCyC_.js +0 -32
- package/dist/routes-4k2kpvoT.js +0 -7097
- package/dist/rpc-Cnwn4Q6L.js +0 -67
- package/dist/run-main-VYlacKA0.js +0 -424
- package/dist/runtime-Cy8pqYUB.d.ts +0 -26
- package/dist/runtime-discord-ops.runtime-DafrU-rI.js +0 -9078
- package/dist/runtime-slack-ops.runtime-CdXBKXwd.js +0 -4556
- package/dist/runtime-telegram-ops.runtime-B12sF7gE.js +0 -133
- package/dist/runtime-whatsapp-login.runtime-CqEudH37.js +0 -114
- package/dist/runtime-whatsapp-outbound.runtime-D5m2qyn-.js +0 -117
- package/dist/sandbox-cli-CHJiEWXB.js +0 -535
- package/dist/search-manager-BtNC3-i_.js +0 -16
- package/dist/search-manager-C7J7B3_a.js +0 -386
- package/dist/secrets-cli-C6yIWBbN.js +0 -2070
- package/dist/security-cli-BVu9BkjD.js +0 -575
- package/dist/send-BSreC7rr.js +0 -631
- package/dist/send-BsLHQG_B.js +0 -1025
- package/dist/send-BuNhp8PH.js +0 -283
- package/dist/send-DOCswVar.js +0 -100
- package/dist/send-Dl0LLErk.js +0 -629
- package/dist/server-node-events-Bq2067EG.js +0 -506
- package/dist/server-y38L7N5H.js +0 -107
- package/dist/sessions-BV8gXURR.js +0 -112
- package/dist/sessions-dl1Kc-Ci.js +0 -218
- package/dist/setup-DGszQH0_.js +0 -387
- package/dist/setup-DR5rRw9y.d.ts +0 -37
- package/dist/setup-binary-C17YnmA8.js +0 -406
- package/dist/setup-browser-CPx-nEsr.js +0 -70
- package/dist/setup-core-BByHN1ME.js +0 -143
- package/dist/setup-core-C0KPlBmL.js +0 -47
- package/dist/setup-core-Cq37G6of.js +0 -166
- package/dist/setup-core-uO84_Y75.js +0 -205
- package/dist/setup-surface-BEMi7Rmb.js +0 -490
- package/dist/setup-wizard-helpers-BtuGx_gN.d.ts +0 -203
- package/dist/setup.finalize-BzPBa8zW.js +0 -522
- package/dist/setup.gateway-config-DdwkF-8e.js +0 -343
- package/dist/shared-BCw4SKjB.js +0 -96
- package/dist/shared-CjNzsULP.js +0 -75
- package/dist/shared-Cu1BE7ZE.js +0 -298
- package/dist/shared-DSClmyUn.js +0 -182
- package/dist/shared-DyJdGH6y.js +0 -102
- package/dist/signal-Dyv4NZsB.js +0 -114
- package/dist/skills-CbB5b27M.js +0 -853
- package/dist/skills-CnfI7Szw.js +0 -20
- package/dist/skills-cli-CavB1f_3.js +0 -292
- package/dist/skills-install-B1OBdgd0.js +0 -763
- package/dist/skills-status-B3gAmIbW.js +0 -169
- package/dist/skills-status-DrHhFgU9.js +0 -21
- package/dist/slack-BRzqnoAz.js +0 -114
- package/dist/slash-commands.runtime-BK88kgds.js +0 -128
- package/dist/slash-dispatch.runtime-COGywwJE.js +0 -141
- package/dist/slash-skill-commands.runtime-Ti4brxgh.js +0 -116
- package/dist/src-DUR6OQxI.js +0 -1701
- package/dist/status-C6dgQY9a.js +0 -131
- package/dist/status-CNK0Q7QH.js +0 -606
- package/dist/status-DBcX0DSC.js +0 -43
- package/dist/status-DKgFgbwv.js +0 -1599
- package/dist/status-Wn5lhNAc.js +0 -126
- package/dist/status-json-D2EkWqAl.js +0 -288
- package/dist/status.link-channel-D3ULIdEa.js +0 -143
- package/dist/status.scan.deps.runtime-BsjWTAm4.js +0 -126
- package/dist/status.scan.runtime-D4HbzROD.js +0 -119
- package/dist/status.summary-C3YxPrDK.js +0 -592
- package/dist/status.summary.runtime-DAkXPSaK.js +0 -118
- package/dist/status.update-B4NnN9P1.js +0 -77
- package/dist/subagent-orphan-recovery-QiQEBv36.js +0 -307
- package/dist/subagent-registry-runtime-BJatPQFK.js +0 -111
- package/dist/subscription-BhZORXN9.js +0 -100
- package/dist/subscription-QEUjQRMv.js +0 -33
- package/dist/subscription-cli-HrULlAgc.js +0 -134
- package/dist/synology-chat-DB76GWMN.js +0 -297
- package/dist/system-cli-D8jDwWuL.js +0 -94
- package/dist/telegram-BHiiqKkQ.js +0 -114
- package/dist/text-chunking-Baonm9Lu.js +0 -84
- package/dist/text-chunking-Y3dPBOuZ.d.ts +0 -79
- package/dist/tlon-DLESxNgD.js +0 -433
- package/dist/tui-C75zi2Cl.js +0 -3834
- package/dist/tui-cli-DFwx5e6i.js +0 -137
- package/dist/types-BBJ3Qz7j.d.ts +0 -45
- package/dist/types-Ckufs_BY.d.ts +0 -22692
- package/dist/types.base-Cw0-zIvE.d.ts +0 -188
- package/dist/ui-B55NOIB6.js +0 -31
- package/dist/update--ojavYQ4.js +0 -1036
- package/dist/update-cli-Cvj5aWYM.js +0 -1503
- package/dist/update-offset-store-upatuWwX.js +0 -112
- package/dist/update-runner-DHkY_-76.js +0 -1496
- package/dist/upsert-with-lock-C171GLaR.js +0 -33
- package/dist/usage-N3bxnbmt.js +0 -115
- package/dist/web-RdvT7gKa.js +0 -112
- package/dist/web-shared-HSGD3yGt.d.ts +0 -45
- package/dist/webhook-request-guards-CosLyl01.d.ts +0 -76
- package/dist/webhook-targets-Bfnag-du.js +0 -181
- package/dist/webhook-targets-Di17rt8e.d.ts +0 -106
- package/dist/webhooks-cli-ZpnXrq7G.js +0 -350
- package/dist/whatsapp-DNTAyZHt.js +0 -114
- package/dist/whatsapp-actions-o1zKQzKZ.js +0 -167
- package/dist/workspace-CpWi5wPr.js +0 -479
- package/dist/workspace-Ii7aRS7c.js +0 -289
- package/dist/workspace-dirs-x10McA9t.js +0 -2003
- package/dist/zalo-BN3VCrRY.d.ts +0 -9
- package/dist/zalo-zm_bYCKg.js +0 -415
- package/dist/zalouser-CvVEUvc5.js +0 -30911
- /package/dist/{account-id-B3YSn4hl.d.ts → account-id-B8ce6G_4.d.ts} +0 -0
- /package/dist/{acpx-CnNv70m2.d.ts → acpx-Ci50I9T2.d.ts} +0 -0
- /package/dist/{agent-media-payload-DE2pEcsz.d.ts → agent-media-payload-en-gS5p6.d.ts} +0 -0
- /package/dist/{allow-from-DPpHnT2A.d.ts → allow-from-cMeQ47Ot.d.ts} +0 -0
- /package/dist/{allowlist-resolution-CLFiZ6nE.d.ts → allowlist-resolution-DoAWbfXV.d.ts} +0 -0
- /package/dist/{bluebubbles-Duhu-Jer.d.ts → bluebubbles-C6yYmUl0.d.ts} +0 -0
- /package/dist/{boolean-param-BhFjB3gp.d.ts → boolean-param-CdO2TFTk.d.ts} +0 -0
- /package/dist/{channel-config-schema-DnnVMdjR.d.ts → channel-config-schema-Chp38wel.d.ts} +0 -0
- /package/dist/{channel-policy-Baq-Z06b.d.ts → channel-policy-g2h6AbYQ.d.ts} +0 -0
- /package/dist/{chat-type-DpiBgwuG.d.ts → chat-type-BLt59pPT.d.ts} +0 -0
- /package/dist/{command-format-vi4xq8e8.d.ts → command-format-BDJC05Jp.d.ts} +0 -0
- /package/dist/{diffs-DK7fVSDo.d.ts → diffs-D_iNKCyn.d.ts} +0 -0
- /package/dist/{directory-runtime-BTLPaysA.d.ts → directory-runtime-DhMex6HY.d.ts} +0 -0
- /package/dist/{exec-C01wtBHu.d.ts → exec-pjfUY4KM.d.ts} +0 -0
- /package/dist/{gaxios-fetch-compat-wZ38b3w3.js → gaxios-fetch-compat-B_vtINdV.js} +0 -0
- /package/dist/{history-CwXuP2TW.d.ts → history-aqSS5VGQ.d.ts} +0 -0
- /package/dist/{inbound-envelope-SggrBs9m.d.ts → inbound-envelope-C5hWuZod.d.ts} +0 -0
- /package/dist/{index-apAZHsDo.d.ts → index-DXVQFYGX.d.ts} +0 -0
- /package/dist/{json-store-r75IZGk9.d.ts → json-store-UnqQ5aV3.d.ts} +0 -0
- /package/dist/{keyed-async-queue-DHIr7yNe.d.ts → keyed-async-queue-guucpLw3.d.ts} +0 -0
- /package/dist/{links-HeQ3r_L0.d.ts → links-Bar0meEK.d.ts} +0 -0
- /package/dist/{markdown-to-line-CDb4Jy3V.d.ts → markdown-to-line-D8uH_KOj.d.ts} +0 -0
- /package/dist/{mattermost-DtCsxpgg.d.ts → mattermost-xl7jAFJL.d.ts} +0 -0
- /package/dist/{net-BATPDwdQ.d.ts → net-rGOKGds6.d.ts} +0 -0
- /package/dist/{nextcloud-talk-Bb2wHOwp.d.ts → nextcloud-talk-De2CZ9dV.d.ts} +0 -0
- /package/dist/{oauth-utils-u567CLT0.d.ts → oauth-utils-DzN1AlEH.d.ts} +0 -0
- /package/dist/{parse-finite-number-l3tNlrZh.d.ts → parse-finite-number-odgyqhi0.d.ts} +0 -0
- /package/dist/{provider-usage.types-C6061OVN.d.ts → provider-usage.types-EDE9o-H_.d.ts} +0 -0
- /package/dist/{reply-history-BDsFnZFl.d.ts → reply-history-CVuU31xe.d.ts} +0 -0
- /package/dist/{reply-payload-CCvM4W9u.d.ts → reply-payload-CHkpBYwL.d.ts} +0 -0
- /package/dist/{request-url-C54l4-xC.d.ts → request-url-DHisbiHY.d.ts} +0 -0
- /package/dist/{run-command-D3RqWcHu.d.ts → run-command-y0Cndsb1.d.ts} +0 -0
- /package/dist/{secret-input-schema-BLBt-NAP.d.ts → secret-input-schema-b1vpYDQN.d.ts} +0 -0
- /package/dist/{session-key-BQ2-bR-9.d.ts → session-key-DTHQl57f.d.ts} +0 -0
- /package/dist/{ssh-config-C4mcH9Ly.js → ssh-config-hEHBfU2_.js} +0 -0
- /package/dist/{testing-DLkhGsoz.d.ts → testing-DszuZXgK.d.ts} +0 -0
- /package/dist/{thinking-DRkjX18p.d.ts → thinking-IwXTGSeT.d.ts} +0 -0
- /package/dist/{tool-send-CMMD1uDu.d.ts → tool-send-DWHRmKpz.d.ts} +0 -0
- /package/dist/{vllm-defaults-CcGuf4hL.d.ts → vllm-defaults-CrxZgE6-.d.ts} +0 -0
- /package/dist/{wait-Daog8bxM.d.ts → wait-wDWw_MTI.d.ts} +0 -0
- /package/dist/{webhook-memory-guards-C5MrExwT.d.ts → webhook-memory-guards-DreORuJy.d.ts} +0 -0
- /package/dist/{windows-spawn-j2l-dqu8.d.ts → windows-spawn-BIzH92x2.d.ts} +0 -0
- /package/dist/{zod-schema.agent-runtime-krMrBnIn.d.ts → zod-schema.agent-runtime-CP2rmis3.d.ts} +0 -0
- /package/dist/{zod-schema.core-BNDieZDZ.d.ts → zod-schema.core-Foi1tYwi.d.ts} +0 -0
|
@@ -1,1494 +0,0 @@
|
|
|
1
|
-
import "./redact-fatrROh9.js";
|
|
2
|
-
import "./errors-DOJWZqNo.js";
|
|
3
|
-
import "./logger-BFfIIIKH.js";
|
|
4
|
-
import "./paths-D6AgsMTU.js";
|
|
5
|
-
import "./tmp-moldclaw-dir-DWF-d8qD.js";
|
|
6
|
-
import { r as theme } from "./theme-BSXzMzAA.js";
|
|
7
|
-
import { n as info, t as danger } from "./globals-DESrFYmC.js";
|
|
8
|
-
import { n as defaultRuntime } from "./runtime-_tQz41uA.js";
|
|
9
|
-
import "./ansi-BPhP6LBZ.js";
|
|
10
|
-
import "./subsystem-CPmDTJ2P.js";
|
|
11
|
-
import { t as parseBooleanValue } from "./boolean-B6zcAynR.js";
|
|
12
|
-
import "./env-D42cffog.js";
|
|
13
|
-
import { S as shortenHomePath } from "./utils-C7ykRPCQ.js";
|
|
14
|
-
import { t as formatDocsLink } from "./links-BcahUP5U.js";
|
|
15
|
-
import { n as inheritOptionFromParent } from "./command-options-DYaIHwsu.js";
|
|
16
|
-
import "./model-selection-hL8i1Jbs.js";
|
|
17
|
-
import "./agent-scope-C-YmLnnb.js";
|
|
18
|
-
import "./boundary-file-read-tPYh_8fH.js";
|
|
19
|
-
import "./logger-BGzLUitz.js";
|
|
20
|
-
import "./exec-CvEtXqTZ.js";
|
|
21
|
-
import "./workspace-CpWi5wPr.js";
|
|
22
|
-
import { c as loadConfig } from "./io-CMfWWPXQ.js";
|
|
23
|
-
import "./host-env-security-DQ2i_W12.js";
|
|
24
|
-
import "./safe-text-Cnulee_z.js";
|
|
25
|
-
import "./version-T8nMYUnU.js";
|
|
26
|
-
import "./env-substitution-68cyvF5h.js";
|
|
27
|
-
import "./config-state-h5jUoHya.js";
|
|
28
|
-
import "./network-mode-BtWXzwYn.js";
|
|
29
|
-
import "./registry-C1pRrsQl.js";
|
|
30
|
-
import "./manifest-registry-DAd0SRAP.js";
|
|
31
|
-
import "./ip-C4YAIpr4.js";
|
|
32
|
-
import "./zod-schema.core-DvwgNmpd.js";
|
|
33
|
-
import "./config-sW57gztj.js";
|
|
34
|
-
import "./audit-fs-CMb-YUHX.js";
|
|
35
|
-
import "./resolve-PSlwZjg3.js";
|
|
36
|
-
import "./config-BwkGZjD5.js";
|
|
37
|
-
import { t as formatCliCommand } from "./command-format-C_z0Ru-7.js";
|
|
38
|
-
import "./tailnet-fFTz5Twr.js";
|
|
39
|
-
import "./net-K181nxTH.js";
|
|
40
|
-
import "./credentials-D-5Pb-aZ.js";
|
|
41
|
-
import { G as normalizeBrowserFormFieldValue, R as DEFAULT_UPLOAD_DIR, W as normalizeBrowserFormField, f as redactCdpUrl, z as resolveExistingPathsWithinRoot } from "./routes-4k2kpvoT.js";
|
|
42
|
-
import "./path-alias-guards-BtSO7sk7.js";
|
|
43
|
-
import "./ports-Ca74cFb2.js";
|
|
44
|
-
import "./ports-lsof-CoiADo0p.js";
|
|
45
|
-
import "./image-ops-Ck_D_vpe.js";
|
|
46
|
-
import "./fs-safe-CRXFoBmh.js";
|
|
47
|
-
import "./mime-DGFQe4XX.js";
|
|
48
|
-
import "./message-channel-DFE4FuE_.js";
|
|
49
|
-
import "./method-scopes-CQE7-bZ-.js";
|
|
50
|
-
import "./device-identity-CRfhC3_s.js";
|
|
51
|
-
import "./call-ByEzDJ1_.js";
|
|
52
|
-
import { n as runCommandWithRuntime } from "./cli-utils-BCuSS4l6.js";
|
|
53
|
-
import { t as formatHelpExamples } from "./help-format-BFzPm_8V.js";
|
|
54
|
-
import "./progress-Cwq59vgZ.js";
|
|
55
|
-
import { n as callGatewayFromCli, t as addGatewayClientOptions } from "./gateway-rpc-BGC1Rxvg.js";
|
|
56
|
-
//#region src/cli/browser-cli-shared.ts
|
|
57
|
-
function normalizeQuery(query) {
|
|
58
|
-
if (!query) return;
|
|
59
|
-
const out = {};
|
|
60
|
-
for (const [key, value] of Object.entries(query)) {
|
|
61
|
-
if (value === void 0) continue;
|
|
62
|
-
out[key] = String(value);
|
|
63
|
-
}
|
|
64
|
-
return Object.keys(out).length ? out : void 0;
|
|
65
|
-
}
|
|
66
|
-
async function callBrowserRequest(opts, params, extra) {
|
|
67
|
-
const resolvedTimeoutMs = typeof extra?.timeoutMs === "number" && Number.isFinite(extra.timeoutMs) ? Math.max(1, Math.floor(extra.timeoutMs)) : typeof opts.timeout === "string" ? Number.parseInt(opts.timeout, 10) : void 0;
|
|
68
|
-
const resolvedTimeout = typeof resolvedTimeoutMs === "number" && Number.isFinite(resolvedTimeoutMs) ? resolvedTimeoutMs : void 0;
|
|
69
|
-
const timeout = typeof resolvedTimeout === "number" ? String(resolvedTimeout) : opts.timeout;
|
|
70
|
-
const payload = await callGatewayFromCli("browser.request", {
|
|
71
|
-
...opts,
|
|
72
|
-
timeout
|
|
73
|
-
}, {
|
|
74
|
-
method: params.method,
|
|
75
|
-
path: params.path,
|
|
76
|
-
query: normalizeQuery(params.query),
|
|
77
|
-
body: params.body,
|
|
78
|
-
timeoutMs: resolvedTimeout
|
|
79
|
-
}, { progress: extra?.progress });
|
|
80
|
-
if (payload === void 0) throw new Error("Unexpected browser.request response");
|
|
81
|
-
return payload;
|
|
82
|
-
}
|
|
83
|
-
async function callBrowserResize(opts, params, extra) {
|
|
84
|
-
return callBrowserRequest(opts, {
|
|
85
|
-
method: "POST",
|
|
86
|
-
path: "/act",
|
|
87
|
-
query: params.profile ? { profile: params.profile } : void 0,
|
|
88
|
-
body: {
|
|
89
|
-
kind: "resize",
|
|
90
|
-
width: params.width,
|
|
91
|
-
height: params.height,
|
|
92
|
-
targetId: params.targetId?.trim() || void 0
|
|
93
|
-
}
|
|
94
|
-
}, extra);
|
|
95
|
-
}
|
|
96
|
-
//#endregion
|
|
97
|
-
//#region src/cli/browser-cli-actions-input/shared.ts
|
|
98
|
-
function resolveBrowserActionContext(cmd, parentOpts) {
|
|
99
|
-
const parent = parentOpts(cmd);
|
|
100
|
-
return {
|
|
101
|
-
parent,
|
|
102
|
-
profile: parent?.browserProfile
|
|
103
|
-
};
|
|
104
|
-
}
|
|
105
|
-
async function callBrowserAct(params) {
|
|
106
|
-
return await callBrowserRequest(params.parent, {
|
|
107
|
-
method: "POST",
|
|
108
|
-
path: "/act",
|
|
109
|
-
query: params.profile ? { profile: params.profile } : void 0,
|
|
110
|
-
body: params.body
|
|
111
|
-
}, { timeoutMs: params.timeoutMs ?? 2e4 });
|
|
112
|
-
}
|
|
113
|
-
function logBrowserActionResult(parent, result, successMessage) {
|
|
114
|
-
if (parent?.json) {
|
|
115
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
116
|
-
return;
|
|
117
|
-
}
|
|
118
|
-
defaultRuntime.log(successMessage);
|
|
119
|
-
}
|
|
120
|
-
function requireRef(ref) {
|
|
121
|
-
const refValue = typeof ref === "string" ? ref.trim() : "";
|
|
122
|
-
if (!refValue) {
|
|
123
|
-
defaultRuntime.error(danger("ref is required"));
|
|
124
|
-
defaultRuntime.exit(1);
|
|
125
|
-
return null;
|
|
126
|
-
}
|
|
127
|
-
return refValue;
|
|
128
|
-
}
|
|
129
|
-
async function readFile(path) {
|
|
130
|
-
return await (await import("node:fs/promises")).readFile(path, "utf8");
|
|
131
|
-
}
|
|
132
|
-
async function readFields(opts) {
|
|
133
|
-
const payload = opts.fieldsFile ? await readFile(opts.fieldsFile) : opts.fields ?? "";
|
|
134
|
-
if (!payload.trim()) throw new Error("fields are required");
|
|
135
|
-
const parsed = JSON.parse(payload);
|
|
136
|
-
if (!Array.isArray(parsed)) throw new Error("fields must be an array");
|
|
137
|
-
return parsed.map((entry, index) => {
|
|
138
|
-
if (!entry || typeof entry !== "object") throw new Error(`fields[${index}] must be an object`);
|
|
139
|
-
const rec = entry;
|
|
140
|
-
const parsedField = normalizeBrowserFormField(rec);
|
|
141
|
-
if (!parsedField) throw new Error(`fields[${index}] must include ref`);
|
|
142
|
-
if (rec.value === void 0 || rec.value === null || normalizeBrowserFormFieldValue(rec.value) !== void 0) return parsedField;
|
|
143
|
-
throw new Error(`fields[${index}].value must be string, number, boolean, or null`);
|
|
144
|
-
});
|
|
145
|
-
}
|
|
146
|
-
//#endregion
|
|
147
|
-
//#region src/cli/browser-cli-actions-input/register.element.ts
|
|
148
|
-
function registerBrowserElementCommands(browser, parentOpts) {
|
|
149
|
-
const runElementAction = async (params) => {
|
|
150
|
-
const { parent, profile } = resolveBrowserActionContext(params.cmd, parentOpts);
|
|
151
|
-
try {
|
|
152
|
-
const result = await callBrowserAct({
|
|
153
|
-
parent,
|
|
154
|
-
profile,
|
|
155
|
-
body: params.body,
|
|
156
|
-
timeoutMs: params.timeoutMs
|
|
157
|
-
});
|
|
158
|
-
logBrowserActionResult(parent, result, typeof params.successMessage === "function" ? params.successMessage(result) : params.successMessage);
|
|
159
|
-
} catch (err) {
|
|
160
|
-
defaultRuntime.error(danger(String(err)));
|
|
161
|
-
defaultRuntime.exit(1);
|
|
162
|
-
}
|
|
163
|
-
};
|
|
164
|
-
browser.command("click").description("Click an element by ref from snapshot").argument("<ref>", "Ref id from snapshot").option("--target-id <id>", "CDP target id (or unique prefix)").option("--double", "Double click", false).option("--button <left|right|middle>", "Mouse button to use").option("--modifiers <list>", "Comma-separated modifiers (Shift,Alt,Meta)").action(async (ref, opts, cmd) => {
|
|
165
|
-
const refValue = requireRef(ref);
|
|
166
|
-
if (!refValue) return;
|
|
167
|
-
const modifiers = opts.modifiers ? String(opts.modifiers).split(",").map((v) => v.trim()).filter(Boolean) : void 0;
|
|
168
|
-
await runElementAction({
|
|
169
|
-
cmd,
|
|
170
|
-
body: {
|
|
171
|
-
kind: "click",
|
|
172
|
-
ref: refValue,
|
|
173
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
174
|
-
doubleClick: Boolean(opts.double),
|
|
175
|
-
button: opts.button?.trim() || void 0,
|
|
176
|
-
modifiers
|
|
177
|
-
},
|
|
178
|
-
successMessage: (result) => {
|
|
179
|
-
const url = result.url;
|
|
180
|
-
return `clicked ref ${refValue}${typeof url === "string" && url ? ` on ${url}` : ""}`;
|
|
181
|
-
}
|
|
182
|
-
});
|
|
183
|
-
});
|
|
184
|
-
browser.command("type").description("Type into an element by ref from snapshot").argument("<ref>", "Ref id from snapshot").argument("<text>", "Text to type").option("--submit", "Press Enter after typing", false).option("--slowly", "Type slowly (human-like)", false).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (ref, text, opts, cmd) => {
|
|
185
|
-
const refValue = requireRef(ref);
|
|
186
|
-
if (!refValue) return;
|
|
187
|
-
await runElementAction({
|
|
188
|
-
cmd,
|
|
189
|
-
body: {
|
|
190
|
-
kind: "type",
|
|
191
|
-
ref: refValue,
|
|
192
|
-
text,
|
|
193
|
-
submit: Boolean(opts.submit),
|
|
194
|
-
slowly: Boolean(opts.slowly),
|
|
195
|
-
targetId: opts.targetId?.trim() || void 0
|
|
196
|
-
},
|
|
197
|
-
successMessage: `typed into ref ${refValue}`
|
|
198
|
-
});
|
|
199
|
-
});
|
|
200
|
-
browser.command("press").description("Press a key").argument("<key>", "Key to press (e.g. Enter)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (key, opts, cmd) => {
|
|
201
|
-
await runElementAction({
|
|
202
|
-
cmd,
|
|
203
|
-
body: {
|
|
204
|
-
kind: "press",
|
|
205
|
-
key,
|
|
206
|
-
targetId: opts.targetId?.trim() || void 0
|
|
207
|
-
},
|
|
208
|
-
successMessage: `pressed ${key}`
|
|
209
|
-
});
|
|
210
|
-
});
|
|
211
|
-
browser.command("hover").description("Hover an element by ai ref").argument("<ref>", "Ref id from snapshot").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (ref, opts, cmd) => {
|
|
212
|
-
await runElementAction({
|
|
213
|
-
cmd,
|
|
214
|
-
body: {
|
|
215
|
-
kind: "hover",
|
|
216
|
-
ref,
|
|
217
|
-
targetId: opts.targetId?.trim() || void 0
|
|
218
|
-
},
|
|
219
|
-
successMessage: `hovered ref ${ref}`
|
|
220
|
-
});
|
|
221
|
-
});
|
|
222
|
-
browser.command("scrollintoview").description("Scroll an element into view by ref from snapshot").argument("<ref>", "Ref id from snapshot").option("--target-id <id>", "CDP target id (or unique prefix)").option("--timeout-ms <ms>", "How long to wait for scroll (default: 20000)", (v) => Number(v)).action(async (ref, opts, cmd) => {
|
|
223
|
-
const refValue = requireRef(ref);
|
|
224
|
-
if (!refValue) return;
|
|
225
|
-
const timeoutMs = Number.isFinite(opts.timeoutMs) ? opts.timeoutMs : void 0;
|
|
226
|
-
await runElementAction({
|
|
227
|
-
cmd,
|
|
228
|
-
body: {
|
|
229
|
-
kind: "scrollIntoView",
|
|
230
|
-
ref: refValue,
|
|
231
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
232
|
-
timeoutMs
|
|
233
|
-
},
|
|
234
|
-
timeoutMs,
|
|
235
|
-
successMessage: `scrolled into view: ${refValue}`
|
|
236
|
-
});
|
|
237
|
-
});
|
|
238
|
-
browser.command("drag").description("Drag from one ref to another").argument("<startRef>", "Start ref id").argument("<endRef>", "End ref id").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (startRef, endRef, opts, cmd) => {
|
|
239
|
-
await runElementAction({
|
|
240
|
-
cmd,
|
|
241
|
-
body: {
|
|
242
|
-
kind: "drag",
|
|
243
|
-
startRef,
|
|
244
|
-
endRef,
|
|
245
|
-
targetId: opts.targetId?.trim() || void 0
|
|
246
|
-
},
|
|
247
|
-
successMessage: `dragged ${startRef} → ${endRef}`
|
|
248
|
-
});
|
|
249
|
-
});
|
|
250
|
-
browser.command("select").description("Select option(s) in a select element").argument("<ref>", "Ref id from snapshot").argument("<values...>", "Option values to select").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (ref, values, opts, cmd) => {
|
|
251
|
-
await runElementAction({
|
|
252
|
-
cmd,
|
|
253
|
-
body: {
|
|
254
|
-
kind: "select",
|
|
255
|
-
ref,
|
|
256
|
-
values,
|
|
257
|
-
targetId: opts.targetId?.trim() || void 0
|
|
258
|
-
},
|
|
259
|
-
successMessage: `selected ${values.join(", ")}`
|
|
260
|
-
});
|
|
261
|
-
});
|
|
262
|
-
}
|
|
263
|
-
//#endregion
|
|
264
|
-
//#region src/cli/browser-cli-actions-input/register.files-downloads.ts
|
|
265
|
-
async function normalizeUploadPaths(paths) {
|
|
266
|
-
const result = await resolveExistingPathsWithinRoot({
|
|
267
|
-
rootDir: DEFAULT_UPLOAD_DIR,
|
|
268
|
-
requestedPaths: paths,
|
|
269
|
-
scopeLabel: `uploads directory (${DEFAULT_UPLOAD_DIR})`
|
|
270
|
-
});
|
|
271
|
-
if (!result.ok) throw new Error(result.error);
|
|
272
|
-
return result.paths;
|
|
273
|
-
}
|
|
274
|
-
async function runBrowserPostAction(params) {
|
|
275
|
-
try {
|
|
276
|
-
const result = await callBrowserRequest(params.parent, {
|
|
277
|
-
method: "POST",
|
|
278
|
-
path: params.path,
|
|
279
|
-
query: params.profile ? { profile: params.profile } : void 0,
|
|
280
|
-
body: params.body
|
|
281
|
-
}, { timeoutMs: params.timeoutMs });
|
|
282
|
-
if (params.parent?.json) {
|
|
283
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
284
|
-
return;
|
|
285
|
-
}
|
|
286
|
-
defaultRuntime.log(params.describeSuccess(result));
|
|
287
|
-
} catch (err) {
|
|
288
|
-
defaultRuntime.error(danger(String(err)));
|
|
289
|
-
defaultRuntime.exit(1);
|
|
290
|
-
}
|
|
291
|
-
}
|
|
292
|
-
function registerBrowserFilesAndDownloadsCommands(browser, parentOpts) {
|
|
293
|
-
const resolveTimeoutAndTarget = (opts) => {
|
|
294
|
-
return {
|
|
295
|
-
timeoutMs: Number.isFinite(opts.timeoutMs) ? Number(opts.timeoutMs) : void 0,
|
|
296
|
-
targetId: typeof opts.targetId === "string" ? opts.targetId.trim() || void 0 : void 0
|
|
297
|
-
};
|
|
298
|
-
};
|
|
299
|
-
const runDownloadCommand = async (cmd, opts, request) => {
|
|
300
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
301
|
-
const { timeoutMs, targetId } = resolveTimeoutAndTarget(opts);
|
|
302
|
-
await runBrowserPostAction({
|
|
303
|
-
parent,
|
|
304
|
-
profile,
|
|
305
|
-
path: request.path,
|
|
306
|
-
body: {
|
|
307
|
-
...request.body,
|
|
308
|
-
targetId,
|
|
309
|
-
timeoutMs
|
|
310
|
-
},
|
|
311
|
-
timeoutMs: timeoutMs ?? 2e4,
|
|
312
|
-
describeSuccess: (result) => `downloaded: ${shortenHomePath(result.download.path)}`
|
|
313
|
-
});
|
|
314
|
-
};
|
|
315
|
-
browser.command("upload").description("Arm file upload for the next file chooser").argument("<paths...>", "File paths to upload (must be within moldClaw temp uploads dir, e.g. /tmp/moldclaw/uploads/file.pdf)").option("--ref <ref>", "Ref id from snapshot to click after arming").option("--input-ref <ref>", "Ref id for <input type=file> to set directly").option("--element <selector>", "CSS selector for <input type=file>").option("--target-id <id>", "CDP target id (or unique prefix)").option("--timeout-ms <ms>", "How long to wait for the next file chooser (default: 120000)", (v) => Number(v)).action(async (paths, opts, cmd) => {
|
|
316
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
317
|
-
const normalizedPaths = await normalizeUploadPaths(paths);
|
|
318
|
-
const { timeoutMs, targetId } = resolveTimeoutAndTarget(opts);
|
|
319
|
-
await runBrowserPostAction({
|
|
320
|
-
parent,
|
|
321
|
-
profile,
|
|
322
|
-
path: "/hooks/file-chooser",
|
|
323
|
-
body: {
|
|
324
|
-
paths: normalizedPaths,
|
|
325
|
-
ref: opts.ref?.trim() || void 0,
|
|
326
|
-
inputRef: opts.inputRef?.trim() || void 0,
|
|
327
|
-
element: opts.element?.trim() || void 0,
|
|
328
|
-
targetId,
|
|
329
|
-
timeoutMs
|
|
330
|
-
},
|
|
331
|
-
timeoutMs: timeoutMs ?? 2e4,
|
|
332
|
-
describeSuccess: () => `upload armed for ${paths.length} file(s)`
|
|
333
|
-
});
|
|
334
|
-
});
|
|
335
|
-
browser.command("waitfordownload").description("Wait for the next download (and save it)").argument("[path]", "Save path within moldclaw temp downloads dir (default: /tmp/moldclaw/downloads/...; fallback: os.tmpdir()/moldclaw/downloads/...)").option("--target-id <id>", "CDP target id (or unique prefix)").option("--timeout-ms <ms>", "How long to wait for the next download (default: 120000)", (v) => Number(v)).action(async (outPath, opts, cmd) => {
|
|
336
|
-
await runDownloadCommand(cmd, opts, {
|
|
337
|
-
path: "/wait/download",
|
|
338
|
-
body: { path: outPath?.trim() || void 0 }
|
|
339
|
-
});
|
|
340
|
-
});
|
|
341
|
-
browser.command("download").description("Click a ref and save the resulting download").argument("<ref>", "Ref id from snapshot to click").argument("<path>", "Save path within moldclaw temp downloads dir (e.g. report.pdf or /tmp/moldclaw/downloads/report.pdf)").option("--target-id <id>", "CDP target id (or unique prefix)").option("--timeout-ms <ms>", "How long to wait for the download to start (default: 120000)", (v) => Number(v)).action(async (ref, outPath, opts, cmd) => {
|
|
342
|
-
await runDownloadCommand(cmd, opts, {
|
|
343
|
-
path: "/download",
|
|
344
|
-
body: {
|
|
345
|
-
ref,
|
|
346
|
-
path: outPath
|
|
347
|
-
}
|
|
348
|
-
});
|
|
349
|
-
});
|
|
350
|
-
browser.command("dialog").description("Arm the next modal dialog (alert/confirm/prompt)").option("--accept", "Accept the dialog", false).option("--dismiss", "Dismiss the dialog", false).option("--prompt <text>", "Prompt response text").option("--target-id <id>", "CDP target id (or unique prefix)").option("--timeout-ms <ms>", "How long to wait for the next dialog (default: 120000)", (v) => Number(v)).action(async (opts, cmd) => {
|
|
351
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
352
|
-
const accept = opts.accept ? true : opts.dismiss ? false : void 0;
|
|
353
|
-
if (accept === void 0) {
|
|
354
|
-
defaultRuntime.error(danger("Specify --accept or --dismiss"));
|
|
355
|
-
defaultRuntime.exit(1);
|
|
356
|
-
return;
|
|
357
|
-
}
|
|
358
|
-
const { timeoutMs, targetId } = resolveTimeoutAndTarget(opts);
|
|
359
|
-
await runBrowserPostAction({
|
|
360
|
-
parent,
|
|
361
|
-
profile,
|
|
362
|
-
path: "/hooks/dialog",
|
|
363
|
-
body: {
|
|
364
|
-
accept,
|
|
365
|
-
promptText: opts.prompt?.trim() || void 0,
|
|
366
|
-
targetId,
|
|
367
|
-
timeoutMs
|
|
368
|
-
},
|
|
369
|
-
timeoutMs: timeoutMs ?? 2e4,
|
|
370
|
-
describeSuccess: () => "dialog armed"
|
|
371
|
-
});
|
|
372
|
-
});
|
|
373
|
-
}
|
|
374
|
-
//#endregion
|
|
375
|
-
//#region src/cli/browser-cli-actions-input/register.form-wait-eval.ts
|
|
376
|
-
function registerBrowserFormWaitEvalCommands(browser, parentOpts) {
|
|
377
|
-
browser.command("fill").description("Fill a form with JSON field descriptors").option("--fields <json>", "JSON array of field objects").option("--fields-file <path>", "Read JSON array from a file").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
378
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
379
|
-
try {
|
|
380
|
-
const fields = await readFields({
|
|
381
|
-
fields: opts.fields,
|
|
382
|
-
fieldsFile: opts.fieldsFile
|
|
383
|
-
});
|
|
384
|
-
logBrowserActionResult(parent, await callBrowserAct({
|
|
385
|
-
parent,
|
|
386
|
-
profile,
|
|
387
|
-
body: {
|
|
388
|
-
kind: "fill",
|
|
389
|
-
fields,
|
|
390
|
-
targetId: opts.targetId?.trim() || void 0
|
|
391
|
-
}
|
|
392
|
-
}), `filled ${fields.length} field(s)`);
|
|
393
|
-
} catch (err) {
|
|
394
|
-
defaultRuntime.error(danger(String(err)));
|
|
395
|
-
defaultRuntime.exit(1);
|
|
396
|
-
}
|
|
397
|
-
});
|
|
398
|
-
browser.command("wait").description("Wait for time, selector, URL, load state, or JS conditions").argument("[selector]", "CSS selector to wait for (visible)").option("--time <ms>", "Wait for N milliseconds", (v) => Number(v)).option("--text <value>", "Wait for text to appear").option("--text-gone <value>", "Wait for text to disappear").option("--url <pattern>", "Wait for URL (supports globs like **/dash)").option("--load <load|domcontentloaded|networkidle>", "Wait for load state").option("--fn <js>", "Wait for JS condition (passed to waitForFunction)").option("--timeout-ms <ms>", "How long to wait for each condition (default: 20000)", (v) => Number(v)).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (selector, opts, cmd) => {
|
|
399
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
400
|
-
try {
|
|
401
|
-
const sel = selector?.trim() || void 0;
|
|
402
|
-
const load = opts.load === "load" || opts.load === "domcontentloaded" || opts.load === "networkidle" ? opts.load : void 0;
|
|
403
|
-
const timeoutMs = Number.isFinite(opts.timeoutMs) ? opts.timeoutMs : void 0;
|
|
404
|
-
logBrowserActionResult(parent, await callBrowserAct({
|
|
405
|
-
parent,
|
|
406
|
-
profile,
|
|
407
|
-
body: {
|
|
408
|
-
kind: "wait",
|
|
409
|
-
timeMs: Number.isFinite(opts.time) ? opts.time : void 0,
|
|
410
|
-
text: opts.text?.trim() || void 0,
|
|
411
|
-
textGone: opts.textGone?.trim() || void 0,
|
|
412
|
-
selector: sel,
|
|
413
|
-
url: opts.url?.trim() || void 0,
|
|
414
|
-
loadState: load,
|
|
415
|
-
fn: opts.fn?.trim() || void 0,
|
|
416
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
417
|
-
timeoutMs
|
|
418
|
-
},
|
|
419
|
-
timeoutMs
|
|
420
|
-
}), "wait complete");
|
|
421
|
-
} catch (err) {
|
|
422
|
-
defaultRuntime.error(danger(String(err)));
|
|
423
|
-
defaultRuntime.exit(1);
|
|
424
|
-
}
|
|
425
|
-
});
|
|
426
|
-
browser.command("evaluate").description("Evaluate a function against the page or a ref").option("--fn <code>", "Function source, e.g. (el) => el.textContent").option("--ref <id>", "Ref from snapshot").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
427
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
428
|
-
if (!opts.fn) {
|
|
429
|
-
defaultRuntime.error(danger("Missing --fn"));
|
|
430
|
-
defaultRuntime.exit(1);
|
|
431
|
-
return;
|
|
432
|
-
}
|
|
433
|
-
try {
|
|
434
|
-
const result = await callBrowserAct({
|
|
435
|
-
parent,
|
|
436
|
-
profile,
|
|
437
|
-
body: {
|
|
438
|
-
kind: "evaluate",
|
|
439
|
-
fn: opts.fn,
|
|
440
|
-
ref: opts.ref?.trim() || void 0,
|
|
441
|
-
targetId: opts.targetId?.trim() || void 0
|
|
442
|
-
}
|
|
443
|
-
});
|
|
444
|
-
if (parent?.json) {
|
|
445
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
446
|
-
return;
|
|
447
|
-
}
|
|
448
|
-
defaultRuntime.log(JSON.stringify(result.result ?? null, null, 2));
|
|
449
|
-
} catch (err) {
|
|
450
|
-
defaultRuntime.error(danger(String(err)));
|
|
451
|
-
defaultRuntime.exit(1);
|
|
452
|
-
}
|
|
453
|
-
});
|
|
454
|
-
}
|
|
455
|
-
//#endregion
|
|
456
|
-
//#region src/cli/browser-cli-resize.ts
|
|
457
|
-
async function runBrowserResizeWithOutput(params) {
|
|
458
|
-
const { width, height } = params;
|
|
459
|
-
if (!Number.isFinite(width) || !Number.isFinite(height)) {
|
|
460
|
-
defaultRuntime.error(danger("width and height must be numbers"));
|
|
461
|
-
defaultRuntime.exit(1);
|
|
462
|
-
return;
|
|
463
|
-
}
|
|
464
|
-
const result = await callBrowserResize(params.parent, {
|
|
465
|
-
profile: params.profile,
|
|
466
|
-
width,
|
|
467
|
-
height,
|
|
468
|
-
targetId: params.targetId
|
|
469
|
-
}, { timeoutMs: params.timeoutMs ?? 2e4 });
|
|
470
|
-
if (params.parent?.json) {
|
|
471
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
472
|
-
return;
|
|
473
|
-
}
|
|
474
|
-
defaultRuntime.log(params.successMessage);
|
|
475
|
-
}
|
|
476
|
-
//#endregion
|
|
477
|
-
//#region src/cli/browser-cli-actions-input/register.navigation.ts
|
|
478
|
-
function registerBrowserNavigationCommands(browser, parentOpts) {
|
|
479
|
-
browser.command("navigate").description("Navigate the current tab to a URL").argument("<url>", "URL to navigate to").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (url, opts, cmd) => {
|
|
480
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
481
|
-
try {
|
|
482
|
-
const result = await callBrowserRequest(parent, {
|
|
483
|
-
method: "POST",
|
|
484
|
-
path: "/navigate",
|
|
485
|
-
query: profile ? { profile } : void 0,
|
|
486
|
-
body: {
|
|
487
|
-
url,
|
|
488
|
-
targetId: opts.targetId?.trim() || void 0
|
|
489
|
-
}
|
|
490
|
-
}, { timeoutMs: 2e4 });
|
|
491
|
-
if (parent?.json) {
|
|
492
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
493
|
-
return;
|
|
494
|
-
}
|
|
495
|
-
defaultRuntime.log(`navigated to ${result.url ?? url}`);
|
|
496
|
-
} catch (err) {
|
|
497
|
-
defaultRuntime.error(danger(String(err)));
|
|
498
|
-
defaultRuntime.exit(1);
|
|
499
|
-
}
|
|
500
|
-
});
|
|
501
|
-
browser.command("resize").description("Resize the viewport").argument("<width>", "Viewport width", (v) => Number(v)).argument("<height>", "Viewport height", (v) => Number(v)).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (width, height, opts, cmd) => {
|
|
502
|
-
const { parent, profile } = resolveBrowserActionContext(cmd, parentOpts);
|
|
503
|
-
try {
|
|
504
|
-
await runBrowserResizeWithOutput({
|
|
505
|
-
parent,
|
|
506
|
-
profile,
|
|
507
|
-
width,
|
|
508
|
-
height,
|
|
509
|
-
targetId: opts.targetId,
|
|
510
|
-
timeoutMs: 2e4,
|
|
511
|
-
successMessage: `resized to ${width}x${height}`
|
|
512
|
-
});
|
|
513
|
-
} catch (err) {
|
|
514
|
-
defaultRuntime.error(danger(String(err)));
|
|
515
|
-
defaultRuntime.exit(1);
|
|
516
|
-
}
|
|
517
|
-
});
|
|
518
|
-
}
|
|
519
|
-
//#endregion
|
|
520
|
-
//#region src/cli/browser-cli-actions-input/register.ts
|
|
521
|
-
function registerBrowserActionInputCommands(browser, parentOpts) {
|
|
522
|
-
registerBrowserNavigationCommands(browser, parentOpts);
|
|
523
|
-
registerBrowserElementCommands(browser, parentOpts);
|
|
524
|
-
registerBrowserFilesAndDownloadsCommands(browser, parentOpts);
|
|
525
|
-
registerBrowserFormWaitEvalCommands(browser, parentOpts);
|
|
526
|
-
}
|
|
527
|
-
//#endregion
|
|
528
|
-
//#region src/cli/browser-cli-actions-observe.ts
|
|
529
|
-
function runBrowserObserve(action) {
|
|
530
|
-
return runCommandWithRuntime(defaultRuntime, action, (err) => {
|
|
531
|
-
defaultRuntime.error(danger(String(err)));
|
|
532
|
-
defaultRuntime.exit(1);
|
|
533
|
-
});
|
|
534
|
-
}
|
|
535
|
-
function registerBrowserActionObserveCommands(browser, parentOpts) {
|
|
536
|
-
browser.command("console").description("Get recent console messages").option("--level <level>", "Filter by level (error, warn, info)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
537
|
-
const parent = parentOpts(cmd);
|
|
538
|
-
const profile = parent?.browserProfile;
|
|
539
|
-
await runBrowserObserve(async () => {
|
|
540
|
-
const result = await callBrowserRequest(parent, {
|
|
541
|
-
method: "GET",
|
|
542
|
-
path: "/console",
|
|
543
|
-
query: {
|
|
544
|
-
level: opts.level?.trim() || void 0,
|
|
545
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
546
|
-
profile
|
|
547
|
-
}
|
|
548
|
-
}, { timeoutMs: 2e4 });
|
|
549
|
-
if (parent?.json) {
|
|
550
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
551
|
-
return;
|
|
552
|
-
}
|
|
553
|
-
defaultRuntime.log(JSON.stringify(result.messages, null, 2));
|
|
554
|
-
});
|
|
555
|
-
});
|
|
556
|
-
browser.command("pdf").description("Save page as PDF").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
557
|
-
const parent = parentOpts(cmd);
|
|
558
|
-
const profile = parent?.browserProfile;
|
|
559
|
-
await runBrowserObserve(async () => {
|
|
560
|
-
const result = await callBrowserRequest(parent, {
|
|
561
|
-
method: "POST",
|
|
562
|
-
path: "/pdf",
|
|
563
|
-
query: profile ? { profile } : void 0,
|
|
564
|
-
body: { targetId: opts.targetId?.trim() || void 0 }
|
|
565
|
-
}, { timeoutMs: 2e4 });
|
|
566
|
-
if (parent?.json) {
|
|
567
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
568
|
-
return;
|
|
569
|
-
}
|
|
570
|
-
defaultRuntime.log(`PDF: ${shortenHomePath(result.path)}`);
|
|
571
|
-
});
|
|
572
|
-
});
|
|
573
|
-
browser.command("responsebody").description("Wait for a network response and return its body").argument("<url>", "URL (exact, substring, or glob like **/api)").option("--target-id <id>", "CDP target id (or unique prefix)").option("--timeout-ms <ms>", "How long to wait for the response (default: 20000)", (v) => Number(v)).option("--max-chars <n>", "Max body chars to return (default: 200000)", (v) => Number(v)).action(async (url, opts, cmd) => {
|
|
574
|
-
const parent = parentOpts(cmd);
|
|
575
|
-
const profile = parent?.browserProfile;
|
|
576
|
-
await runBrowserObserve(async () => {
|
|
577
|
-
const timeoutMs = Number.isFinite(opts.timeoutMs) ? opts.timeoutMs : void 0;
|
|
578
|
-
const maxChars = Number.isFinite(opts.maxChars) ? opts.maxChars : void 0;
|
|
579
|
-
const result = await callBrowserRequest(parent, {
|
|
580
|
-
method: "POST",
|
|
581
|
-
path: "/response/body",
|
|
582
|
-
query: profile ? { profile } : void 0,
|
|
583
|
-
body: {
|
|
584
|
-
url,
|
|
585
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
586
|
-
timeoutMs,
|
|
587
|
-
maxChars
|
|
588
|
-
}
|
|
589
|
-
}, { timeoutMs: timeoutMs ?? 2e4 });
|
|
590
|
-
if (parent?.json) {
|
|
591
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
592
|
-
return;
|
|
593
|
-
}
|
|
594
|
-
defaultRuntime.log(result.response.body);
|
|
595
|
-
});
|
|
596
|
-
});
|
|
597
|
-
}
|
|
598
|
-
//#endregion
|
|
599
|
-
//#region src/cli/browser-cli-debug.ts
|
|
600
|
-
const BROWSER_DEBUG_TIMEOUT_MS = 2e4;
|
|
601
|
-
function runBrowserDebug(action) {
|
|
602
|
-
return runCommandWithRuntime(defaultRuntime, action, (err) => {
|
|
603
|
-
defaultRuntime.error(danger(String(err)));
|
|
604
|
-
defaultRuntime.exit(1);
|
|
605
|
-
});
|
|
606
|
-
}
|
|
607
|
-
async function withDebugContext(cmd, parentOpts, action) {
|
|
608
|
-
const parent = parentOpts(cmd);
|
|
609
|
-
await runBrowserDebug(() => action({
|
|
610
|
-
parent,
|
|
611
|
-
profile: parent.browserProfile
|
|
612
|
-
}));
|
|
613
|
-
}
|
|
614
|
-
function printJsonResult$1(parent, result) {
|
|
615
|
-
if (!parent.json) return false;
|
|
616
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
617
|
-
return true;
|
|
618
|
-
}
|
|
619
|
-
async function callDebugRequest(parent, params) {
|
|
620
|
-
return callBrowserRequest(parent, params, { timeoutMs: BROWSER_DEBUG_TIMEOUT_MS });
|
|
621
|
-
}
|
|
622
|
-
function resolveProfileQuery$1(profile) {
|
|
623
|
-
return profile ? { profile } : void 0;
|
|
624
|
-
}
|
|
625
|
-
function resolveDebugQuery(params) {
|
|
626
|
-
return {
|
|
627
|
-
targetId: typeof params.targetId === "string" ? params.targetId.trim() || void 0 : void 0,
|
|
628
|
-
filter: typeof params.filter === "string" ? params.filter.trim() || void 0 : void 0,
|
|
629
|
-
clear: Boolean(params.clear),
|
|
630
|
-
profile: params.profile
|
|
631
|
-
};
|
|
632
|
-
}
|
|
633
|
-
function registerBrowserDebugCommands(browser, parentOpts) {
|
|
634
|
-
browser.command("highlight").description("Highlight an element by ref").argument("<ref>", "Ref id from snapshot").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (ref, opts, cmd) => {
|
|
635
|
-
await withDebugContext(cmd, parentOpts, async ({ parent, profile }) => {
|
|
636
|
-
if (printJsonResult$1(parent, await callDebugRequest(parent, {
|
|
637
|
-
method: "POST",
|
|
638
|
-
path: "/highlight",
|
|
639
|
-
query: resolveProfileQuery$1(profile),
|
|
640
|
-
body: {
|
|
641
|
-
ref: ref.trim(),
|
|
642
|
-
targetId: opts.targetId?.trim() || void 0
|
|
643
|
-
}
|
|
644
|
-
}))) return;
|
|
645
|
-
defaultRuntime.log(`highlighted ${ref.trim()}`);
|
|
646
|
-
});
|
|
647
|
-
});
|
|
648
|
-
browser.command("errors").description("Get recent page errors").option("--clear", "Clear stored errors after reading", false).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
649
|
-
await withDebugContext(cmd, parentOpts, async ({ parent, profile }) => {
|
|
650
|
-
const result = await callDebugRequest(parent, {
|
|
651
|
-
method: "GET",
|
|
652
|
-
path: "/errors",
|
|
653
|
-
query: resolveDebugQuery({
|
|
654
|
-
targetId: opts.targetId,
|
|
655
|
-
clear: opts.clear,
|
|
656
|
-
profile
|
|
657
|
-
})
|
|
658
|
-
});
|
|
659
|
-
if (printJsonResult$1(parent, result)) return;
|
|
660
|
-
if (!result.errors.length) {
|
|
661
|
-
defaultRuntime.log("No page errors.");
|
|
662
|
-
return;
|
|
663
|
-
}
|
|
664
|
-
defaultRuntime.log(result.errors.map((e) => `${e.timestamp} ${e.name ? `${e.name}: ` : ""}${e.message}`).join("\n"));
|
|
665
|
-
});
|
|
666
|
-
});
|
|
667
|
-
browser.command("requests").description("Get recent network requests (best-effort)").option("--filter <text>", "Only show URLs that contain this substring").option("--clear", "Clear stored requests after reading", false).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
668
|
-
await withDebugContext(cmd, parentOpts, async ({ parent, profile }) => {
|
|
669
|
-
const result = await callDebugRequest(parent, {
|
|
670
|
-
method: "GET",
|
|
671
|
-
path: "/requests",
|
|
672
|
-
query: resolveDebugQuery({
|
|
673
|
-
targetId: opts.targetId,
|
|
674
|
-
filter: opts.filter,
|
|
675
|
-
clear: opts.clear,
|
|
676
|
-
profile
|
|
677
|
-
})
|
|
678
|
-
});
|
|
679
|
-
if (printJsonResult$1(parent, result)) return;
|
|
680
|
-
if (!result.requests.length) {
|
|
681
|
-
defaultRuntime.log("No requests recorded.");
|
|
682
|
-
return;
|
|
683
|
-
}
|
|
684
|
-
defaultRuntime.log(result.requests.map((r) => {
|
|
685
|
-
const status = typeof r.status === "number" ? ` ${r.status}` : "";
|
|
686
|
-
const ok = r.ok === true ? " ok" : r.ok === false ? " fail" : "";
|
|
687
|
-
const fail = r.failureText ? ` (${r.failureText})` : "";
|
|
688
|
-
return `${r.timestamp} ${r.method}${status}${ok} ${r.url}${fail}`;
|
|
689
|
-
}).join("\n"));
|
|
690
|
-
});
|
|
691
|
-
});
|
|
692
|
-
const trace = browser.command("trace").description("Record a Playwright trace");
|
|
693
|
-
trace.command("start").description("Start trace recording").option("--target-id <id>", "CDP target id (or unique prefix)").option("--no-screenshots", "Disable screenshots").option("--no-snapshots", "Disable snapshots").option("--sources", "Include sources (bigger traces)", false).action(async (opts, cmd) => {
|
|
694
|
-
await withDebugContext(cmd, parentOpts, async ({ parent, profile }) => {
|
|
695
|
-
if (printJsonResult$1(parent, await callDebugRequest(parent, {
|
|
696
|
-
method: "POST",
|
|
697
|
-
path: "/trace/start",
|
|
698
|
-
query: resolveProfileQuery$1(profile),
|
|
699
|
-
body: {
|
|
700
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
701
|
-
screenshots: Boolean(opts.screenshots),
|
|
702
|
-
snapshots: Boolean(opts.snapshots),
|
|
703
|
-
sources: Boolean(opts.sources)
|
|
704
|
-
}
|
|
705
|
-
}))) return;
|
|
706
|
-
defaultRuntime.log("trace started");
|
|
707
|
-
});
|
|
708
|
-
});
|
|
709
|
-
trace.command("stop").description("Stop trace recording and write a .zip").option("--out <path>", "Output path within moldclaw temp dir (e.g. trace.zip or /tmp/moldclaw/trace.zip)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
710
|
-
await withDebugContext(cmd, parentOpts, async ({ parent, profile }) => {
|
|
711
|
-
const result = await callDebugRequest(parent, {
|
|
712
|
-
method: "POST",
|
|
713
|
-
path: "/trace/stop",
|
|
714
|
-
query: resolveProfileQuery$1(profile),
|
|
715
|
-
body: {
|
|
716
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
717
|
-
path: opts.out?.trim() || void 0
|
|
718
|
-
}
|
|
719
|
-
});
|
|
720
|
-
if (printJsonResult$1(parent, result)) return;
|
|
721
|
-
defaultRuntime.log(`TRACE:${shortenHomePath(result.path)}`);
|
|
722
|
-
});
|
|
723
|
-
});
|
|
724
|
-
}
|
|
725
|
-
//#endregion
|
|
726
|
-
//#region src/cli/browser-cli-examples.ts
|
|
727
|
-
const browserCoreExamples = [
|
|
728
|
-
"moldclaw browser status",
|
|
729
|
-
"moldclaw browser start",
|
|
730
|
-
"moldclaw browser stop",
|
|
731
|
-
"moldclaw browser tabs",
|
|
732
|
-
"moldclaw browser open https://example.com",
|
|
733
|
-
"moldclaw browser focus abcd1234",
|
|
734
|
-
"moldclaw browser close abcd1234",
|
|
735
|
-
"moldclaw browser screenshot",
|
|
736
|
-
"moldclaw browser screenshot --full-page",
|
|
737
|
-
"moldclaw browser screenshot --ref 12",
|
|
738
|
-
"moldclaw browser snapshot",
|
|
739
|
-
"moldclaw browser snapshot --format aria --limit 200",
|
|
740
|
-
"moldclaw browser snapshot --efficient",
|
|
741
|
-
"moldclaw browser snapshot --labels"
|
|
742
|
-
];
|
|
743
|
-
const browserActionExamples = [
|
|
744
|
-
"moldclaw browser navigate https://example.com",
|
|
745
|
-
"moldclaw browser resize 1280 720",
|
|
746
|
-
"moldclaw browser click 12 --double",
|
|
747
|
-
"moldclaw browser type 23 \"hello\" --submit",
|
|
748
|
-
"moldclaw browser press Enter",
|
|
749
|
-
"moldclaw browser hover 44",
|
|
750
|
-
"moldclaw browser drag 10 11",
|
|
751
|
-
"moldclaw browser select 9 OptionA OptionB",
|
|
752
|
-
"moldclaw browser upload /tmp/moldclaw/uploads/file.pdf",
|
|
753
|
-
"moldclaw browser fill --fields '[{\"ref\":\"1\",\"value\":\"Ada\"}]'",
|
|
754
|
-
"moldclaw browser dialog --accept",
|
|
755
|
-
"moldclaw browser wait --text \"Done\"",
|
|
756
|
-
"moldclaw browser evaluate --fn '(el) => el.textContent' --ref 7",
|
|
757
|
-
"moldclaw browser console --level error",
|
|
758
|
-
"moldclaw browser pdf"
|
|
759
|
-
];
|
|
760
|
-
//#endregion
|
|
761
|
-
//#region src/cli/browser-cli-inspect.ts
|
|
762
|
-
function registerBrowserInspectCommands(browser, parentOpts) {
|
|
763
|
-
browser.command("screenshot").description("Capture a screenshot (MEDIA:<path>)").argument("[targetId]", "CDP target id (or unique prefix)").option("--full-page", "Capture full scrollable page", false).option("--ref <ref>", "ARIA ref from ai snapshot").option("--element <selector>", "CSS selector for element screenshot").option("--type <png|jpeg>", "Output type (default: png)", "png").action(async (targetId, opts, cmd) => {
|
|
764
|
-
const parent = parentOpts(cmd);
|
|
765
|
-
const profile = parent?.browserProfile;
|
|
766
|
-
try {
|
|
767
|
-
const result = await callBrowserRequest(parent, {
|
|
768
|
-
method: "POST",
|
|
769
|
-
path: "/screenshot",
|
|
770
|
-
query: profile ? { profile } : void 0,
|
|
771
|
-
body: {
|
|
772
|
-
targetId: targetId?.trim() || void 0,
|
|
773
|
-
fullPage: Boolean(opts.fullPage),
|
|
774
|
-
ref: opts.ref?.trim() || void 0,
|
|
775
|
-
element: opts.element?.trim() || void 0,
|
|
776
|
-
type: opts.type === "jpeg" ? "jpeg" : "png"
|
|
777
|
-
}
|
|
778
|
-
}, { timeoutMs: 2e4 });
|
|
779
|
-
if (parent?.json) {
|
|
780
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
781
|
-
return;
|
|
782
|
-
}
|
|
783
|
-
defaultRuntime.log(`MEDIA:${shortenHomePath(result.path)}`);
|
|
784
|
-
} catch (err) {
|
|
785
|
-
defaultRuntime.error(danger(String(err)));
|
|
786
|
-
defaultRuntime.exit(1);
|
|
787
|
-
}
|
|
788
|
-
});
|
|
789
|
-
browser.command("snapshot").description("Capture a snapshot (default: ai; aria is the accessibility tree)").option("--format <aria|ai>", "Snapshot format (default: ai)", "ai").option("--target-id <id>", "CDP target id (or unique prefix)").option("--limit <n>", "Max nodes (default: 500/800)", (v) => Number(v)).option("--mode <efficient>", "Snapshot preset (efficient)").option("--efficient", "Use the efficient snapshot preset", false).option("--interactive", "Role snapshot: interactive elements only", false).option("--compact", "Role snapshot: compact output", false).option("--depth <n>", "Role snapshot: max depth", (v) => Number(v)).option("--selector <sel>", "Role snapshot: scope to CSS selector").option("--frame <sel>", "Role snapshot: scope to an iframe selector").option("--labels", "Include viewport label overlay screenshot", false).option("--out <path>", "Write snapshot to a file").action(async (opts, cmd) => {
|
|
790
|
-
const parent = parentOpts(cmd);
|
|
791
|
-
const profile = parent?.browserProfile;
|
|
792
|
-
const format = opts.format === "aria" ? "aria" : "ai";
|
|
793
|
-
const configMode = format === "ai" && loadConfig().browser?.snapshotDefaults?.mode === "efficient" ? "efficient" : void 0;
|
|
794
|
-
const mode = opts.efficient === true || opts.mode === "efficient" ? "efficient" : configMode;
|
|
795
|
-
try {
|
|
796
|
-
const result = await callBrowserRequest(parent, {
|
|
797
|
-
method: "GET",
|
|
798
|
-
path: "/snapshot",
|
|
799
|
-
query: {
|
|
800
|
-
format,
|
|
801
|
-
targetId: opts.targetId?.trim() || void 0,
|
|
802
|
-
limit: Number.isFinite(opts.limit) ? opts.limit : void 0,
|
|
803
|
-
interactive: opts.interactive ? true : void 0,
|
|
804
|
-
compact: opts.compact ? true : void 0,
|
|
805
|
-
depth: Number.isFinite(opts.depth) ? opts.depth : void 0,
|
|
806
|
-
selector: opts.selector?.trim() || void 0,
|
|
807
|
-
frame: opts.frame?.trim() || void 0,
|
|
808
|
-
labels: opts.labels ? true : void 0,
|
|
809
|
-
mode,
|
|
810
|
-
profile
|
|
811
|
-
}
|
|
812
|
-
}, { timeoutMs: 2e4 });
|
|
813
|
-
if (opts.out) {
|
|
814
|
-
const fs = await import("node:fs/promises");
|
|
815
|
-
if (result.format === "ai") await fs.writeFile(opts.out, result.snapshot, "utf8");
|
|
816
|
-
else {
|
|
817
|
-
const payload = JSON.stringify(result, null, 2);
|
|
818
|
-
await fs.writeFile(opts.out, payload, "utf8");
|
|
819
|
-
}
|
|
820
|
-
if (parent?.json) defaultRuntime.log(JSON.stringify({
|
|
821
|
-
ok: true,
|
|
822
|
-
out: opts.out,
|
|
823
|
-
...result.format === "ai" && result.imagePath ? { imagePath: result.imagePath } : {}
|
|
824
|
-
}, null, 2));
|
|
825
|
-
else {
|
|
826
|
-
defaultRuntime.log(shortenHomePath(opts.out));
|
|
827
|
-
if (result.format === "ai" && result.imagePath) defaultRuntime.log(`MEDIA:${shortenHomePath(result.imagePath)}`);
|
|
828
|
-
}
|
|
829
|
-
return;
|
|
830
|
-
}
|
|
831
|
-
if (parent?.json) {
|
|
832
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
833
|
-
return;
|
|
834
|
-
}
|
|
835
|
-
if (result.format === "ai") {
|
|
836
|
-
defaultRuntime.log(result.snapshot);
|
|
837
|
-
if (result.imagePath) defaultRuntime.log(`MEDIA:${shortenHomePath(result.imagePath)}`);
|
|
838
|
-
return;
|
|
839
|
-
}
|
|
840
|
-
const nodes = "nodes" in result ? result.nodes : [];
|
|
841
|
-
defaultRuntime.log(nodes.map((n) => {
|
|
842
|
-
const indent = " ".repeat(Math.min(20, n.depth));
|
|
843
|
-
const name = n.name ? ` "${n.name}"` : "";
|
|
844
|
-
const value = n.value ? ` = "${n.value}"` : "";
|
|
845
|
-
return `${indent}- ${n.role}${name}${value}`;
|
|
846
|
-
}).join("\n"));
|
|
847
|
-
} catch (err) {
|
|
848
|
-
defaultRuntime.error(danger(String(err)));
|
|
849
|
-
defaultRuntime.exit(1);
|
|
850
|
-
}
|
|
851
|
-
});
|
|
852
|
-
}
|
|
853
|
-
//#endregion
|
|
854
|
-
//#region src/cli/browser-cli-manage.ts
|
|
855
|
-
const BROWSER_MANAGE_REQUEST_TIMEOUT_MS = 45e3;
|
|
856
|
-
function resolveProfileQuery(profile) {
|
|
857
|
-
return profile ? { profile } : void 0;
|
|
858
|
-
}
|
|
859
|
-
function printJsonResult(parent, payload) {
|
|
860
|
-
if (!parent?.json) return false;
|
|
861
|
-
defaultRuntime.log(JSON.stringify(payload, null, 2));
|
|
862
|
-
return true;
|
|
863
|
-
}
|
|
864
|
-
async function callTabAction(parent, profile, body) {
|
|
865
|
-
return callBrowserRequest(parent, {
|
|
866
|
-
method: "POST",
|
|
867
|
-
path: "/tabs/action",
|
|
868
|
-
query: resolveProfileQuery(profile),
|
|
869
|
-
body
|
|
870
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS });
|
|
871
|
-
}
|
|
872
|
-
async function fetchBrowserStatus(parent, profile) {
|
|
873
|
-
return await callBrowserRequest(parent, {
|
|
874
|
-
method: "GET",
|
|
875
|
-
path: "/",
|
|
876
|
-
query: resolveProfileQuery(profile)
|
|
877
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS });
|
|
878
|
-
}
|
|
879
|
-
async function runBrowserToggle(parent, params) {
|
|
880
|
-
await callBrowserRequest(parent, {
|
|
881
|
-
method: "POST",
|
|
882
|
-
path: params.path,
|
|
883
|
-
query: resolveProfileQuery(params.profile)
|
|
884
|
-
});
|
|
885
|
-
const status = await fetchBrowserStatus(parent, params.profile);
|
|
886
|
-
if (printJsonResult(parent, status)) return;
|
|
887
|
-
const name = status.profile ?? "moldclaw";
|
|
888
|
-
defaultRuntime.log(info(`🪢 browser [${name}] running: ${status.running}`));
|
|
889
|
-
}
|
|
890
|
-
function runBrowserCommand$1(action) {
|
|
891
|
-
return runCommandWithRuntime(defaultRuntime, action, (err) => {
|
|
892
|
-
defaultRuntime.error(danger(String(err)));
|
|
893
|
-
defaultRuntime.exit(1);
|
|
894
|
-
});
|
|
895
|
-
}
|
|
896
|
-
function logBrowserTabs(tabs, json) {
|
|
897
|
-
if (json) {
|
|
898
|
-
defaultRuntime.log(JSON.stringify({ tabs }, null, 2));
|
|
899
|
-
return;
|
|
900
|
-
}
|
|
901
|
-
if (tabs.length === 0) {
|
|
902
|
-
defaultRuntime.log("No tabs (browser closed or no targets).");
|
|
903
|
-
return;
|
|
904
|
-
}
|
|
905
|
-
defaultRuntime.log(tabs.map((t, i) => `${i + 1}. ${t.title || "(untitled)"}\n ${t.url}\n id: ${t.targetId}`).join("\n"));
|
|
906
|
-
}
|
|
907
|
-
function usesChromeMcpTransport(params) {
|
|
908
|
-
return params.transport === "chrome-mcp" || params.driver === "existing-session";
|
|
909
|
-
}
|
|
910
|
-
function formatBrowserConnectionSummary(params) {
|
|
911
|
-
if (usesChromeMcpTransport(params)) {
|
|
912
|
-
const userDataDir = params.userDataDir ? shortenHomePath(params.userDataDir) : null;
|
|
913
|
-
return userDataDir ? `transport: chrome-mcp, userDataDir: ${userDataDir}` : "transport: chrome-mcp";
|
|
914
|
-
}
|
|
915
|
-
if (params.isRemote) return `cdpUrl: ${params.cdpUrl ?? "(unset)"}`;
|
|
916
|
-
return `port: ${params.cdpPort ?? "(unset)"}`;
|
|
917
|
-
}
|
|
918
|
-
function registerBrowserManageCommands(browser, parentOpts) {
|
|
919
|
-
browser.command("status").description("Show browser status").action(async (_opts, cmd) => {
|
|
920
|
-
const parent = parentOpts(cmd);
|
|
921
|
-
await runBrowserCommand$1(async () => {
|
|
922
|
-
const status = await fetchBrowserStatus(parent, parent?.browserProfile);
|
|
923
|
-
if (printJsonResult(parent, status)) return;
|
|
924
|
-
const detectedPath = status.detectedExecutablePath ?? status.executablePath;
|
|
925
|
-
const detectedDisplay = detectedPath ? shortenHomePath(detectedPath) : "auto";
|
|
926
|
-
defaultRuntime.log([
|
|
927
|
-
`profile: ${status.profile ?? "moldclaw"}`,
|
|
928
|
-
`enabled: ${status.enabled}`,
|
|
929
|
-
`running: ${status.running}`,
|
|
930
|
-
`transport: ${usesChromeMcpTransport(status) ? "chrome-mcp" : status.transport ?? "cdp"}`,
|
|
931
|
-
...!usesChromeMcpTransport(status) ? [`cdpPort: ${status.cdpPort ?? "(unset)"}`, `cdpUrl: ${redactCdpUrl(status.cdpUrl ?? `http://127.0.0.1:${status.cdpPort}`)}`] : status.userDataDir ? [`userDataDir: ${shortenHomePath(status.userDataDir)}`] : [],
|
|
932
|
-
`browser: ${status.chosenBrowser ?? "unknown"}`,
|
|
933
|
-
`detectedBrowser: ${status.detectedBrowser ?? "unknown"}`,
|
|
934
|
-
`detectedPath: ${detectedDisplay}`,
|
|
935
|
-
`profileColor: ${status.color}`,
|
|
936
|
-
...status.detectError ? [`detectError: ${status.detectError}`] : []
|
|
937
|
-
].join("\n"));
|
|
938
|
-
});
|
|
939
|
-
});
|
|
940
|
-
browser.command("start").description("Start the browser (no-op if already running)").action(async (_opts, cmd) => {
|
|
941
|
-
const parent = parentOpts(cmd);
|
|
942
|
-
const profile = parent?.browserProfile;
|
|
943
|
-
await runBrowserCommand$1(async () => {
|
|
944
|
-
await runBrowserToggle(parent, {
|
|
945
|
-
profile,
|
|
946
|
-
path: "/start"
|
|
947
|
-
});
|
|
948
|
-
});
|
|
949
|
-
});
|
|
950
|
-
browser.command("stop").description("Stop the browser (best-effort)").action(async (_opts, cmd) => {
|
|
951
|
-
const parent = parentOpts(cmd);
|
|
952
|
-
const profile = parent?.browserProfile;
|
|
953
|
-
await runBrowserCommand$1(async () => {
|
|
954
|
-
await runBrowserToggle(parent, {
|
|
955
|
-
profile,
|
|
956
|
-
path: "/stop"
|
|
957
|
-
});
|
|
958
|
-
});
|
|
959
|
-
});
|
|
960
|
-
browser.command("reset-profile").description("Reset browser profile (moves it to Trash)").action(async (_opts, cmd) => {
|
|
961
|
-
const parent = parentOpts(cmd);
|
|
962
|
-
const profile = parent?.browserProfile;
|
|
963
|
-
await runBrowserCommand$1(async () => {
|
|
964
|
-
const result = await callBrowserRequest(parent, {
|
|
965
|
-
method: "POST",
|
|
966
|
-
path: "/reset-profile",
|
|
967
|
-
query: resolveProfileQuery(profile)
|
|
968
|
-
}, { timeoutMs: 2e4 });
|
|
969
|
-
if (printJsonResult(parent, result)) return;
|
|
970
|
-
if (!result.moved) {
|
|
971
|
-
defaultRuntime.log(info(`🪢 browser profile already missing.`));
|
|
972
|
-
return;
|
|
973
|
-
}
|
|
974
|
-
const dest = result.to ?? result.from;
|
|
975
|
-
defaultRuntime.log(info(`🪢 browser profile moved to Trash (${dest})`));
|
|
976
|
-
});
|
|
977
|
-
});
|
|
978
|
-
browser.command("tabs").description("List open tabs").action(async (_opts, cmd) => {
|
|
979
|
-
const parent = parentOpts(cmd);
|
|
980
|
-
const profile = parent?.browserProfile;
|
|
981
|
-
await runBrowserCommand$1(async () => {
|
|
982
|
-
logBrowserTabs((await callBrowserRequest(parent, {
|
|
983
|
-
method: "GET",
|
|
984
|
-
path: "/tabs",
|
|
985
|
-
query: resolveProfileQuery(profile)
|
|
986
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS })).tabs ?? [], parent?.json);
|
|
987
|
-
});
|
|
988
|
-
});
|
|
989
|
-
const tab = browser.command("tab").description("Tab shortcuts (index-based)").action(async (_opts, cmd) => {
|
|
990
|
-
const parent = parentOpts(cmd);
|
|
991
|
-
const profile = parent?.browserProfile;
|
|
992
|
-
await runBrowserCommand$1(async () => {
|
|
993
|
-
logBrowserTabs((await callBrowserRequest(parent, {
|
|
994
|
-
method: "POST",
|
|
995
|
-
path: "/tabs/action",
|
|
996
|
-
query: resolveProfileQuery(profile),
|
|
997
|
-
body: { action: "list" }
|
|
998
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS })).tabs ?? [], parent?.json);
|
|
999
|
-
});
|
|
1000
|
-
});
|
|
1001
|
-
tab.command("new").description("Open a new tab (about:blank)").action(async (_opts, cmd) => {
|
|
1002
|
-
const parent = parentOpts(cmd);
|
|
1003
|
-
const profile = parent?.browserProfile;
|
|
1004
|
-
await runBrowserCommand$1(async () => {
|
|
1005
|
-
if (printJsonResult(parent, await callTabAction(parent, profile, { action: "new" }))) return;
|
|
1006
|
-
defaultRuntime.log("opened new tab");
|
|
1007
|
-
});
|
|
1008
|
-
});
|
|
1009
|
-
tab.command("select").description("Focus tab by index (1-based)").argument("<index>", "Tab index (1-based)", (v) => Number(v)).action(async (index, _opts, cmd) => {
|
|
1010
|
-
const parent = parentOpts(cmd);
|
|
1011
|
-
const profile = parent?.browserProfile;
|
|
1012
|
-
if (!Number.isFinite(index) || index < 1) {
|
|
1013
|
-
defaultRuntime.error(danger("index must be a positive number"));
|
|
1014
|
-
defaultRuntime.exit(1);
|
|
1015
|
-
return;
|
|
1016
|
-
}
|
|
1017
|
-
await runBrowserCommand$1(async () => {
|
|
1018
|
-
if (printJsonResult(parent, await callTabAction(parent, profile, {
|
|
1019
|
-
action: "select",
|
|
1020
|
-
index: Math.floor(index) - 1
|
|
1021
|
-
}))) return;
|
|
1022
|
-
defaultRuntime.log(`selected tab ${Math.floor(index)}`);
|
|
1023
|
-
});
|
|
1024
|
-
});
|
|
1025
|
-
tab.command("close").description("Close tab by index (1-based); default: first tab").argument("[index]", "Tab index (1-based)", (v) => Number(v)).action(async (index, _opts, cmd) => {
|
|
1026
|
-
const parent = parentOpts(cmd);
|
|
1027
|
-
const profile = parent?.browserProfile;
|
|
1028
|
-
const idx = typeof index === "number" && Number.isFinite(index) ? Math.floor(index) - 1 : void 0;
|
|
1029
|
-
if (typeof idx === "number" && idx < 0) {
|
|
1030
|
-
defaultRuntime.error(danger("index must be >= 1"));
|
|
1031
|
-
defaultRuntime.exit(1);
|
|
1032
|
-
return;
|
|
1033
|
-
}
|
|
1034
|
-
await runBrowserCommand$1(async () => {
|
|
1035
|
-
if (printJsonResult(parent, await callTabAction(parent, profile, {
|
|
1036
|
-
action: "close",
|
|
1037
|
-
index: idx
|
|
1038
|
-
}))) return;
|
|
1039
|
-
defaultRuntime.log("closed tab");
|
|
1040
|
-
});
|
|
1041
|
-
});
|
|
1042
|
-
browser.command("open").description("Open a URL in a new tab").argument("<url>", "URL to open").action(async (url, _opts, cmd) => {
|
|
1043
|
-
const parent = parentOpts(cmd);
|
|
1044
|
-
const profile = parent?.browserProfile;
|
|
1045
|
-
await runBrowserCommand$1(async () => {
|
|
1046
|
-
const tab = await callBrowserRequest(parent, {
|
|
1047
|
-
method: "POST",
|
|
1048
|
-
path: "/tabs/open",
|
|
1049
|
-
query: resolveProfileQuery(profile),
|
|
1050
|
-
body: { url }
|
|
1051
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS });
|
|
1052
|
-
if (printJsonResult(parent, tab)) return;
|
|
1053
|
-
defaultRuntime.log(`opened: ${tab.url}\nid: ${tab.targetId}`);
|
|
1054
|
-
});
|
|
1055
|
-
});
|
|
1056
|
-
browser.command("focus").description("Focus a tab by target id (or unique prefix)").argument("<targetId>", "Target id or unique prefix").action(async (targetId, _opts, cmd) => {
|
|
1057
|
-
const parent = parentOpts(cmd);
|
|
1058
|
-
const profile = parent?.browserProfile;
|
|
1059
|
-
await runBrowserCommand$1(async () => {
|
|
1060
|
-
await callBrowserRequest(parent, {
|
|
1061
|
-
method: "POST",
|
|
1062
|
-
path: "/tabs/focus",
|
|
1063
|
-
query: resolveProfileQuery(profile),
|
|
1064
|
-
body: { targetId }
|
|
1065
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS });
|
|
1066
|
-
if (printJsonResult(parent, { ok: true })) return;
|
|
1067
|
-
defaultRuntime.log(`focused tab ${targetId}`);
|
|
1068
|
-
});
|
|
1069
|
-
});
|
|
1070
|
-
browser.command("close").description("Close a tab (target id optional)").argument("[targetId]", "Target id or unique prefix (optional)").action(async (targetId, _opts, cmd) => {
|
|
1071
|
-
const parent = parentOpts(cmd);
|
|
1072
|
-
const profile = parent?.browserProfile;
|
|
1073
|
-
await runBrowserCommand$1(async () => {
|
|
1074
|
-
if (targetId?.trim()) await callBrowserRequest(parent, {
|
|
1075
|
-
method: "DELETE",
|
|
1076
|
-
path: `/tabs/${encodeURIComponent(targetId.trim())}`,
|
|
1077
|
-
query: resolveProfileQuery(profile)
|
|
1078
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS });
|
|
1079
|
-
else await callBrowserRequest(parent, {
|
|
1080
|
-
method: "POST",
|
|
1081
|
-
path: "/act",
|
|
1082
|
-
query: resolveProfileQuery(profile),
|
|
1083
|
-
body: { kind: "close" }
|
|
1084
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS });
|
|
1085
|
-
if (printJsonResult(parent, { ok: true })) return;
|
|
1086
|
-
defaultRuntime.log("closed tab");
|
|
1087
|
-
});
|
|
1088
|
-
});
|
|
1089
|
-
browser.command("profiles").description("List all browser profiles").action(async (_opts, cmd) => {
|
|
1090
|
-
const parent = parentOpts(cmd);
|
|
1091
|
-
await runBrowserCommand$1(async () => {
|
|
1092
|
-
const profiles = (await callBrowserRequest(parent, {
|
|
1093
|
-
method: "GET",
|
|
1094
|
-
path: "/profiles"
|
|
1095
|
-
}, { timeoutMs: BROWSER_MANAGE_REQUEST_TIMEOUT_MS })).profiles ?? [];
|
|
1096
|
-
if (printJsonResult(parent, { profiles })) return;
|
|
1097
|
-
if (profiles.length === 0) {
|
|
1098
|
-
defaultRuntime.log("No profiles configured.");
|
|
1099
|
-
return;
|
|
1100
|
-
}
|
|
1101
|
-
defaultRuntime.log(profiles.map((p) => {
|
|
1102
|
-
const status = p.running ? "running" : "stopped";
|
|
1103
|
-
const tabs = p.running ? ` (${p.tabCount} tabs)` : "";
|
|
1104
|
-
const def = p.isDefault ? " [default]" : "";
|
|
1105
|
-
const loc = formatBrowserConnectionSummary(p);
|
|
1106
|
-
const remote = p.isRemote ? " [remote]" : "";
|
|
1107
|
-
const driver = p.driver !== "moldclaw" ? ` [${p.driver}]` : "";
|
|
1108
|
-
return `${p.name}: ${status}${tabs}${def}${remote}${driver}\n ${loc}, color: ${p.color}`;
|
|
1109
|
-
}).join("\n"));
|
|
1110
|
-
});
|
|
1111
|
-
});
|
|
1112
|
-
browser.command("create-profile").description("Create a new browser profile").requiredOption("--name <name>", "Profile name (lowercase, numbers, hyphens)").option("--color <hex>", "Profile color (hex format, e.g. #0066CC)").option("--cdp-url <url>", "CDP URL for remote Chrome (http/https)").option("--user-data-dir <path>", "User data dir for existing-session Chromium attach").option("--driver <driver>", "Profile driver (moldclaw|existing-session). Default: moldclaw").action(async (opts, cmd) => {
|
|
1113
|
-
const parent = parentOpts(cmd);
|
|
1114
|
-
await runBrowserCommand$1(async () => {
|
|
1115
|
-
const result = await callBrowserRequest(parent, {
|
|
1116
|
-
method: "POST",
|
|
1117
|
-
path: "/profiles/create",
|
|
1118
|
-
body: {
|
|
1119
|
-
name: opts.name,
|
|
1120
|
-
color: opts.color,
|
|
1121
|
-
cdpUrl: opts.cdpUrl,
|
|
1122
|
-
userDataDir: opts.userDataDir,
|
|
1123
|
-
driver: opts.driver === "existing-session" ? "existing-session" : void 0
|
|
1124
|
-
}
|
|
1125
|
-
}, { timeoutMs: 1e4 });
|
|
1126
|
-
if (printJsonResult(parent, result)) return;
|
|
1127
|
-
const loc = ` ${formatBrowserConnectionSummary(result)}`;
|
|
1128
|
-
defaultRuntime.log(info(`🪢 Created profile "${result.profile}"\n${loc}\n color: ${result.color}${result.userDataDir ? `\n userDataDir: ${shortenHomePath(result.userDataDir)}` : ""}${opts.driver === "existing-session" ? "\n driver: existing-session" : ""}`));
|
|
1129
|
-
});
|
|
1130
|
-
});
|
|
1131
|
-
browser.command("delete-profile").description("Delete a browser profile").requiredOption("--name <name>", "Profile name to delete").action(async (opts, cmd) => {
|
|
1132
|
-
const parent = parentOpts(cmd);
|
|
1133
|
-
await runBrowserCommand$1(async () => {
|
|
1134
|
-
const result = await callBrowserRequest(parent, {
|
|
1135
|
-
method: "DELETE",
|
|
1136
|
-
path: `/profiles/${encodeURIComponent(opts.name)}`
|
|
1137
|
-
}, { timeoutMs: 2e4 });
|
|
1138
|
-
if (printJsonResult(parent, result)) return;
|
|
1139
|
-
const msg = result.deleted ? `🪢 Deleted profile "${result.profile}" (user data removed)` : `🪢 Deleted profile "${result.profile}" (no user data found)`;
|
|
1140
|
-
defaultRuntime.log(info(msg));
|
|
1141
|
-
});
|
|
1142
|
-
});
|
|
1143
|
-
}
|
|
1144
|
-
//#endregion
|
|
1145
|
-
//#region src/cli/browser-cli-state.cookies-storage.ts
|
|
1146
|
-
function resolveUrl(opts, command) {
|
|
1147
|
-
if (typeof opts.url === "string" && opts.url.trim()) return opts.url.trim();
|
|
1148
|
-
const inherited = inheritOptionFromParent(command, "url");
|
|
1149
|
-
if (typeof inherited === "string" && inherited.trim()) return inherited.trim();
|
|
1150
|
-
}
|
|
1151
|
-
function resolveTargetId(rawTargetId, command) {
|
|
1152
|
-
const local = typeof rawTargetId === "string" ? rawTargetId.trim() : "";
|
|
1153
|
-
if (local) return local;
|
|
1154
|
-
const inherited = inheritOptionFromParent(command, "targetId");
|
|
1155
|
-
if (typeof inherited !== "string") return;
|
|
1156
|
-
const trimmed = inherited.trim();
|
|
1157
|
-
return trimmed ? trimmed : void 0;
|
|
1158
|
-
}
|
|
1159
|
-
async function runMutationRequest(params) {
|
|
1160
|
-
try {
|
|
1161
|
-
const result = await callBrowserRequest(params.parent, params.request, { timeoutMs: 2e4 });
|
|
1162
|
-
if (params.parent?.json) {
|
|
1163
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
1164
|
-
return;
|
|
1165
|
-
}
|
|
1166
|
-
defaultRuntime.log(params.successMessage);
|
|
1167
|
-
} catch (err) {
|
|
1168
|
-
defaultRuntime.error(danger(String(err)));
|
|
1169
|
-
defaultRuntime.exit(1);
|
|
1170
|
-
}
|
|
1171
|
-
}
|
|
1172
|
-
function registerBrowserCookiesAndStorageCommands(browser, parentOpts) {
|
|
1173
|
-
const cookies = browser.command("cookies").description("Read/write cookies");
|
|
1174
|
-
cookies.option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
1175
|
-
const parent = parentOpts(cmd);
|
|
1176
|
-
const profile = parent?.browserProfile;
|
|
1177
|
-
const targetId = resolveTargetId(opts.targetId, cmd);
|
|
1178
|
-
try {
|
|
1179
|
-
const result = await callBrowserRequest(parent, {
|
|
1180
|
-
method: "GET",
|
|
1181
|
-
path: "/cookies",
|
|
1182
|
-
query: {
|
|
1183
|
-
targetId,
|
|
1184
|
-
profile
|
|
1185
|
-
}
|
|
1186
|
-
}, { timeoutMs: 2e4 });
|
|
1187
|
-
if (parent?.json) {
|
|
1188
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
1189
|
-
return;
|
|
1190
|
-
}
|
|
1191
|
-
defaultRuntime.log(JSON.stringify(result.cookies ?? [], null, 2));
|
|
1192
|
-
} catch (err) {
|
|
1193
|
-
defaultRuntime.error(danger(String(err)));
|
|
1194
|
-
defaultRuntime.exit(1);
|
|
1195
|
-
}
|
|
1196
|
-
});
|
|
1197
|
-
cookies.command("set").description("Set a cookie (requires --url or domain+path)").argument("<name>", "Cookie name").argument("<value>", "Cookie value").option("--url <url>", "Cookie URL scope (recommended)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (name, value, opts, cmd) => {
|
|
1198
|
-
const parent = parentOpts(cmd);
|
|
1199
|
-
const profile = parent?.browserProfile;
|
|
1200
|
-
const targetId = resolveTargetId(opts.targetId, cmd);
|
|
1201
|
-
const url = resolveUrl(opts, cmd);
|
|
1202
|
-
if (!url) {
|
|
1203
|
-
defaultRuntime.error(danger("Missing required --url option for cookies set"));
|
|
1204
|
-
defaultRuntime.exit(1);
|
|
1205
|
-
return;
|
|
1206
|
-
}
|
|
1207
|
-
await runMutationRequest({
|
|
1208
|
-
parent,
|
|
1209
|
-
request: {
|
|
1210
|
-
method: "POST",
|
|
1211
|
-
path: "/cookies/set",
|
|
1212
|
-
query: profile ? { profile } : void 0,
|
|
1213
|
-
body: {
|
|
1214
|
-
targetId,
|
|
1215
|
-
cookie: {
|
|
1216
|
-
name,
|
|
1217
|
-
value,
|
|
1218
|
-
url
|
|
1219
|
-
}
|
|
1220
|
-
}
|
|
1221
|
-
},
|
|
1222
|
-
successMessage: `cookie set: ${name}`
|
|
1223
|
-
});
|
|
1224
|
-
});
|
|
1225
|
-
cookies.command("clear").description("Clear all cookies").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd) => {
|
|
1226
|
-
const parent = parentOpts(cmd);
|
|
1227
|
-
const profile = parent?.browserProfile;
|
|
1228
|
-
const targetId = resolveTargetId(opts.targetId, cmd);
|
|
1229
|
-
await runMutationRequest({
|
|
1230
|
-
parent,
|
|
1231
|
-
request: {
|
|
1232
|
-
method: "POST",
|
|
1233
|
-
path: "/cookies/clear",
|
|
1234
|
-
query: profile ? { profile } : void 0,
|
|
1235
|
-
body: { targetId }
|
|
1236
|
-
},
|
|
1237
|
-
successMessage: "cookies cleared"
|
|
1238
|
-
});
|
|
1239
|
-
});
|
|
1240
|
-
const storage = browser.command("storage").description("Read/write localStorage/sessionStorage");
|
|
1241
|
-
function registerStorageKind(kind) {
|
|
1242
|
-
const cmd = storage.command(kind).description(`${kind}Storage commands`);
|
|
1243
|
-
cmd.command("get").description(`Get ${kind}Storage (all keys or one key)`).argument("[key]", "Key (optional)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (key, opts, cmd2) => {
|
|
1244
|
-
const parent = parentOpts(cmd2);
|
|
1245
|
-
const profile = parent?.browserProfile;
|
|
1246
|
-
const targetId = resolveTargetId(opts.targetId, cmd2);
|
|
1247
|
-
try {
|
|
1248
|
-
const result = await callBrowserRequest(parent, {
|
|
1249
|
-
method: "GET",
|
|
1250
|
-
path: `/storage/${kind}`,
|
|
1251
|
-
query: {
|
|
1252
|
-
key: key?.trim() || void 0,
|
|
1253
|
-
targetId,
|
|
1254
|
-
profile
|
|
1255
|
-
}
|
|
1256
|
-
}, { timeoutMs: 2e4 });
|
|
1257
|
-
if (parent?.json) {
|
|
1258
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
1259
|
-
return;
|
|
1260
|
-
}
|
|
1261
|
-
defaultRuntime.log(JSON.stringify(result.values ?? {}, null, 2));
|
|
1262
|
-
} catch (err) {
|
|
1263
|
-
defaultRuntime.error(danger(String(err)));
|
|
1264
|
-
defaultRuntime.exit(1);
|
|
1265
|
-
}
|
|
1266
|
-
});
|
|
1267
|
-
cmd.command("set").description(`Set a ${kind}Storage key`).argument("<key>", "Key").argument("<value>", "Value").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (key, value, opts, cmd2) => {
|
|
1268
|
-
const parent = parentOpts(cmd2);
|
|
1269
|
-
const profile = parent?.browserProfile;
|
|
1270
|
-
const targetId = resolveTargetId(opts.targetId, cmd2);
|
|
1271
|
-
await runMutationRequest({
|
|
1272
|
-
parent,
|
|
1273
|
-
request: {
|
|
1274
|
-
method: "POST",
|
|
1275
|
-
path: `/storage/${kind}/set`,
|
|
1276
|
-
query: profile ? { profile } : void 0,
|
|
1277
|
-
body: {
|
|
1278
|
-
key,
|
|
1279
|
-
value,
|
|
1280
|
-
targetId
|
|
1281
|
-
}
|
|
1282
|
-
},
|
|
1283
|
-
successMessage: `${kind}Storage set: ${key}`
|
|
1284
|
-
});
|
|
1285
|
-
});
|
|
1286
|
-
cmd.command("clear").description(`Clear all ${kind}Storage keys`).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (opts, cmd2) => {
|
|
1287
|
-
const parent = parentOpts(cmd2);
|
|
1288
|
-
const profile = parent?.browserProfile;
|
|
1289
|
-
const targetId = resolveTargetId(opts.targetId, cmd2);
|
|
1290
|
-
await runMutationRequest({
|
|
1291
|
-
parent,
|
|
1292
|
-
request: {
|
|
1293
|
-
method: "POST",
|
|
1294
|
-
path: `/storage/${kind}/clear`,
|
|
1295
|
-
query: profile ? { profile } : void 0,
|
|
1296
|
-
body: { targetId }
|
|
1297
|
-
},
|
|
1298
|
-
successMessage: `${kind}Storage cleared`
|
|
1299
|
-
});
|
|
1300
|
-
});
|
|
1301
|
-
}
|
|
1302
|
-
registerStorageKind("local");
|
|
1303
|
-
registerStorageKind("session");
|
|
1304
|
-
}
|
|
1305
|
-
//#endregion
|
|
1306
|
-
//#region src/cli/browser-cli-state.ts
|
|
1307
|
-
function parseOnOff(raw) {
|
|
1308
|
-
const parsed = parseBooleanValue(raw);
|
|
1309
|
-
return parsed === void 0 ? null : parsed;
|
|
1310
|
-
}
|
|
1311
|
-
function runBrowserCommand(action) {
|
|
1312
|
-
return runCommandWithRuntime(defaultRuntime, action, (err) => {
|
|
1313
|
-
defaultRuntime.error(danger(String(err)));
|
|
1314
|
-
defaultRuntime.exit(1);
|
|
1315
|
-
});
|
|
1316
|
-
}
|
|
1317
|
-
async function runBrowserSetRequest(params) {
|
|
1318
|
-
await runBrowserCommand(async () => {
|
|
1319
|
-
const profile = params.parent?.browserProfile;
|
|
1320
|
-
const result = await callBrowserRequest(params.parent, {
|
|
1321
|
-
method: "POST",
|
|
1322
|
-
path: params.path,
|
|
1323
|
-
query: profile ? { profile } : void 0,
|
|
1324
|
-
body: params.body
|
|
1325
|
-
}, { timeoutMs: 2e4 });
|
|
1326
|
-
if (params.parent?.json) {
|
|
1327
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
1328
|
-
return;
|
|
1329
|
-
}
|
|
1330
|
-
defaultRuntime.log(params.successMessage);
|
|
1331
|
-
});
|
|
1332
|
-
}
|
|
1333
|
-
function registerBrowserStateCommands(browser, parentOpts) {
|
|
1334
|
-
registerBrowserCookiesAndStorageCommands(browser, parentOpts);
|
|
1335
|
-
const set = browser.command("set").description("Browser environment settings");
|
|
1336
|
-
set.command("viewport").description("Set viewport size (alias for resize)").argument("<width>", "Viewport width", (v) => Number(v)).argument("<height>", "Viewport height", (v) => Number(v)).option("--target-id <id>", "CDP target id (or unique prefix)").action(async (width, height, opts, cmd) => {
|
|
1337
|
-
const parent = parentOpts(cmd);
|
|
1338
|
-
const profile = parent?.browserProfile;
|
|
1339
|
-
await runBrowserCommand(async () => {
|
|
1340
|
-
await runBrowserResizeWithOutput({
|
|
1341
|
-
parent,
|
|
1342
|
-
profile,
|
|
1343
|
-
width,
|
|
1344
|
-
height,
|
|
1345
|
-
targetId: opts.targetId,
|
|
1346
|
-
timeoutMs: 2e4,
|
|
1347
|
-
successMessage: `viewport set: ${width}x${height}`
|
|
1348
|
-
});
|
|
1349
|
-
});
|
|
1350
|
-
});
|
|
1351
|
-
set.command("offline").description("Toggle offline mode").argument("<on|off>", "on/off").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (value, opts, cmd) => {
|
|
1352
|
-
const parent = parentOpts(cmd);
|
|
1353
|
-
const offline = parseOnOff(value);
|
|
1354
|
-
if (offline === null) {
|
|
1355
|
-
defaultRuntime.error(danger("Expected on|off"));
|
|
1356
|
-
defaultRuntime.exit(1);
|
|
1357
|
-
return;
|
|
1358
|
-
}
|
|
1359
|
-
await runBrowserSetRequest({
|
|
1360
|
-
parent,
|
|
1361
|
-
path: "/set/offline",
|
|
1362
|
-
body: {
|
|
1363
|
-
offline,
|
|
1364
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1365
|
-
},
|
|
1366
|
-
successMessage: `offline: ${offline}`
|
|
1367
|
-
});
|
|
1368
|
-
});
|
|
1369
|
-
set.command("headers").description("Set extra HTTP headers (JSON object)").argument("[headersJson]", "JSON object of headers (alternative to --headers-json)").option("--headers-json <json>", "JSON object of headers").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (headersJson, opts, cmd) => {
|
|
1370
|
-
const parent = parentOpts(cmd);
|
|
1371
|
-
await runBrowserCommand(async () => {
|
|
1372
|
-
const headersJsonValue = typeof opts.headersJson === "string" && opts.headersJson.trim() || (headersJson?.trim() ? headersJson.trim() : void 0);
|
|
1373
|
-
if (!headersJsonValue) throw new Error("Missing headers JSON (pass --headers-json or positional JSON argument)");
|
|
1374
|
-
const parsed = JSON.parse(String(headersJsonValue));
|
|
1375
|
-
if (!parsed || typeof parsed !== "object" || Array.isArray(parsed)) throw new Error("Headers JSON must be a JSON object");
|
|
1376
|
-
const headers = {};
|
|
1377
|
-
for (const [k, v] of Object.entries(parsed)) if (typeof v === "string") headers[k] = v;
|
|
1378
|
-
const profile = parent?.browserProfile;
|
|
1379
|
-
const result = await callBrowserRequest(parent, {
|
|
1380
|
-
method: "POST",
|
|
1381
|
-
path: "/set/headers",
|
|
1382
|
-
query: profile ? { profile } : void 0,
|
|
1383
|
-
body: {
|
|
1384
|
-
headers,
|
|
1385
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1386
|
-
}
|
|
1387
|
-
}, { timeoutMs: 2e4 });
|
|
1388
|
-
if (parent?.json) {
|
|
1389
|
-
defaultRuntime.log(JSON.stringify(result, null, 2));
|
|
1390
|
-
return;
|
|
1391
|
-
}
|
|
1392
|
-
defaultRuntime.log("headers set");
|
|
1393
|
-
});
|
|
1394
|
-
});
|
|
1395
|
-
set.command("credentials").description("Set HTTP basic auth credentials").option("--clear", "Clear credentials", false).argument("[username]", "Username").argument("[password]", "Password").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (username, password, opts, cmd) => {
|
|
1396
|
-
await runBrowserSetRequest({
|
|
1397
|
-
parent: parentOpts(cmd),
|
|
1398
|
-
path: "/set/credentials",
|
|
1399
|
-
body: {
|
|
1400
|
-
username: username?.trim() || void 0,
|
|
1401
|
-
password,
|
|
1402
|
-
clear: Boolean(opts.clear),
|
|
1403
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1404
|
-
},
|
|
1405
|
-
successMessage: opts.clear ? "credentials cleared" : "credentials set"
|
|
1406
|
-
});
|
|
1407
|
-
});
|
|
1408
|
-
set.command("geo").description("Set geolocation (and grant permission)").option("--clear", "Clear geolocation + permissions", false).argument("[latitude]", "Latitude", (v) => Number(v)).argument("[longitude]", "Longitude", (v) => Number(v)).option("--accuracy <m>", "Accuracy in meters", (v) => Number(v)).option("--origin <origin>", "Origin to grant permissions for").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (latitude, longitude, opts, cmd) => {
|
|
1409
|
-
await runBrowserSetRequest({
|
|
1410
|
-
parent: parentOpts(cmd),
|
|
1411
|
-
path: "/set/geolocation",
|
|
1412
|
-
body: {
|
|
1413
|
-
latitude: Number.isFinite(latitude) ? latitude : void 0,
|
|
1414
|
-
longitude: Number.isFinite(longitude) ? longitude : void 0,
|
|
1415
|
-
accuracy: Number.isFinite(opts.accuracy) ? opts.accuracy : void 0,
|
|
1416
|
-
origin: opts.origin?.trim() || void 0,
|
|
1417
|
-
clear: Boolean(opts.clear),
|
|
1418
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1419
|
-
},
|
|
1420
|
-
successMessage: opts.clear ? "geolocation cleared" : "geolocation set"
|
|
1421
|
-
});
|
|
1422
|
-
});
|
|
1423
|
-
set.command("media").description("Emulate prefers-color-scheme").argument("<dark|light|none>", "dark/light/none").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (value, opts, cmd) => {
|
|
1424
|
-
const parent = parentOpts(cmd);
|
|
1425
|
-
const v = value.trim().toLowerCase();
|
|
1426
|
-
const colorScheme = v === "dark" ? "dark" : v === "light" ? "light" : v === "none" ? "none" : null;
|
|
1427
|
-
if (!colorScheme) {
|
|
1428
|
-
defaultRuntime.error(danger("Expected dark|light|none"));
|
|
1429
|
-
defaultRuntime.exit(1);
|
|
1430
|
-
return;
|
|
1431
|
-
}
|
|
1432
|
-
await runBrowserSetRequest({
|
|
1433
|
-
parent,
|
|
1434
|
-
path: "/set/media",
|
|
1435
|
-
body: {
|
|
1436
|
-
colorScheme,
|
|
1437
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1438
|
-
},
|
|
1439
|
-
successMessage: `media colorScheme: ${colorScheme}`
|
|
1440
|
-
});
|
|
1441
|
-
});
|
|
1442
|
-
set.command("timezone").description("Override timezone (CDP)").argument("<timezoneId>", "Timezone ID (e.g. America/New_York)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (timezoneId, opts, cmd) => {
|
|
1443
|
-
await runBrowserSetRequest({
|
|
1444
|
-
parent: parentOpts(cmd),
|
|
1445
|
-
path: "/set/timezone",
|
|
1446
|
-
body: {
|
|
1447
|
-
timezoneId,
|
|
1448
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1449
|
-
},
|
|
1450
|
-
successMessage: `timezone: ${timezoneId}`
|
|
1451
|
-
});
|
|
1452
|
-
});
|
|
1453
|
-
set.command("locale").description("Override locale (CDP)").argument("<locale>", "Locale (e.g. en-US)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (locale, opts, cmd) => {
|
|
1454
|
-
await runBrowserSetRequest({
|
|
1455
|
-
parent: parentOpts(cmd),
|
|
1456
|
-
path: "/set/locale",
|
|
1457
|
-
body: {
|
|
1458
|
-
locale,
|
|
1459
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1460
|
-
},
|
|
1461
|
-
successMessage: `locale: ${locale}`
|
|
1462
|
-
});
|
|
1463
|
-
});
|
|
1464
|
-
set.command("device").description("Apply a Playwright device descriptor (e.g. \"iPhone 14\")").argument("<name>", "Device name (Playwright devices)").option("--target-id <id>", "CDP target id (or unique prefix)").action(async (name, opts, cmd) => {
|
|
1465
|
-
await runBrowserSetRequest({
|
|
1466
|
-
parent: parentOpts(cmd),
|
|
1467
|
-
path: "/set/device",
|
|
1468
|
-
body: {
|
|
1469
|
-
name,
|
|
1470
|
-
targetId: opts.targetId?.trim() || void 0
|
|
1471
|
-
},
|
|
1472
|
-
successMessage: `device: ${name}`
|
|
1473
|
-
});
|
|
1474
|
-
});
|
|
1475
|
-
}
|
|
1476
|
-
//#endregion
|
|
1477
|
-
//#region src/cli/browser-cli.ts
|
|
1478
|
-
function registerBrowserCli(program) {
|
|
1479
|
-
const browser = program.command("browser").description("Manage moldClaw's dedicated browser (Chrome/Chromium)").option("--browser-profile <name>", "Browser profile name (default from config)").option("--json", "Output machine-readable JSON", false).addHelpText("after", () => `\n${theme.heading("Examples:")}\n${formatHelpExamples([...browserCoreExamples, ...browserActionExamples].map((cmd) => [cmd, ""]), true)}\n\n${theme.muted("Docs:")} ${formatDocsLink("/cli/browser", "docs.moldclaw.ai/cli/browser")}\n`).action(() => {
|
|
1480
|
-
browser.outputHelp();
|
|
1481
|
-
defaultRuntime.error(danger(`Missing subcommand. Try: "${formatCliCommand("moldclaw browser status")}"`));
|
|
1482
|
-
defaultRuntime.exit(1);
|
|
1483
|
-
});
|
|
1484
|
-
addGatewayClientOptions(browser);
|
|
1485
|
-
const parentOpts = (cmd) => cmd.parent?.opts?.();
|
|
1486
|
-
registerBrowserManageCommands(browser, parentOpts);
|
|
1487
|
-
registerBrowserInspectCommands(browser, parentOpts);
|
|
1488
|
-
registerBrowserActionInputCommands(browser, parentOpts);
|
|
1489
|
-
registerBrowserActionObserveCommands(browser, parentOpts);
|
|
1490
|
-
registerBrowserDebugCommands(browser, parentOpts);
|
|
1491
|
-
registerBrowserStateCommands(browser, parentOpts);
|
|
1492
|
-
}
|
|
1493
|
-
//#endregion
|
|
1494
|
-
export { registerBrowserCli };
|