@huyuan-ai/cli 1.0.0 → 1.0.1
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/package.json +3 -2
- package/vendor/opencli/dist/analysis.d.ts +38 -0
- package/vendor/opencli/dist/analysis.js +166 -0
- package/vendor/opencli/dist/browser/base-page.d.ts +50 -0
- package/vendor/opencli/dist/browser/base-page.js +193 -0
- package/vendor/opencli/dist/browser/bridge.d.ts +21 -0
- package/vendor/opencli/dist/browser/bridge.js +109 -0
- package/vendor/opencli/dist/browser/cdp.d.ts +40 -0
- package/vendor/opencli/dist/browser/cdp.js +310 -0
- package/vendor/opencli/dist/browser/cdp.test.d.ts +1 -0
- package/vendor/opencli/dist/browser/cdp.test.js +52 -0
- package/vendor/opencli/dist/browser/daemon-client.d.ts +74 -0
- package/vendor/opencli/dist/browser/daemon-client.js +113 -0
- package/vendor/opencli/dist/browser/daemon-client.test.d.ts +1 -0
- package/vendor/opencli/dist/browser/daemon-client.test.js +77 -0
- package/vendor/opencli/dist/browser/discover.d.ts +15 -0
- package/vendor/opencli/dist/browser/discover.js +19 -0
- package/vendor/opencli/dist/browser/dom-helpers.d.ts +41 -0
- package/vendor/opencli/dist/browser/dom-helpers.js +227 -0
- package/vendor/opencli/dist/browser/dom-helpers.test.d.ts +1 -0
- package/vendor/opencli/dist/browser/dom-helpers.test.js +105 -0
- package/vendor/opencli/dist/browser/dom-snapshot.d.ts +86 -0
- package/vendor/opencli/dist/browser/dom-snapshot.js +804 -0
- package/vendor/opencli/dist/browser/dom-snapshot.test.d.ts +11 -0
- package/vendor/opencli/dist/browser/dom-snapshot.test.js +248 -0
- package/vendor/opencli/dist/browser/errors.d.ts +13 -0
- package/vendor/opencli/dist/browser/errors.js +40 -0
- package/vendor/opencli/dist/browser/index.d.ts +13 -0
- package/vendor/opencli/dist/browser/index.js +12 -0
- package/vendor/opencli/dist/browser/page.d.ts +62 -0
- package/vendor/opencli/dist/browser/page.js +304 -0
- package/vendor/opencli/dist/browser/page.test.d.ts +1 -0
- package/vendor/opencli/dist/browser/page.test.js +44 -0
- package/vendor/opencli/dist/browser/stealth.d.ts +16 -0
- package/vendor/opencli/dist/browser/stealth.js +353 -0
- package/vendor/opencli/dist/browser/stealth.test.d.ts +1 -0
- package/vendor/opencli/dist/browser/stealth.test.js +134 -0
- package/vendor/opencli/dist/browser/tabs.d.ts +13 -0
- package/vendor/opencli/dist/browser/tabs.js +70 -0
- package/vendor/opencli/dist/browser/utils.d.ts +10 -0
- package/vendor/opencli/dist/browser/utils.js +27 -0
- package/vendor/opencli/dist/browser.test.d.ts +1 -0
- package/vendor/opencli/dist/browser.test.js +159 -0
- package/vendor/opencli/dist/build-manifest.d.ts +47 -0
- package/vendor/opencli/dist/build-manifest.js +225 -0
- package/vendor/opencli/dist/build-manifest.test.d.ts +1 -0
- package/vendor/opencli/dist/build-manifest.test.js +176 -0
- package/vendor/opencli/dist/capabilityRouting.d.ts +4 -0
- package/vendor/opencli/dist/capabilityRouting.js +31 -0
- package/vendor/opencli/dist/capabilityRouting.test.d.ts +1 -0
- package/vendor/opencli/dist/capabilityRouting.test.js +42 -0
- package/vendor/opencli/dist/cascade.d.ts +46 -0
- package/vendor/opencli/dist/cascade.js +149 -0
- package/vendor/opencli/dist/cli-manifest.json +16706 -0
- package/vendor/opencli/dist/cli.d.ts +9 -0
- package/vendor/opencli/dist/cli.js +953 -0
- package/vendor/opencli/dist/cli.test.d.ts +1 -0
- package/vendor/opencli/dist/cli.test.js +88 -0
- package/vendor/opencli/dist/clis/1688/item.d.ts +70 -0
- package/vendor/opencli/dist/clis/1688/item.js +187 -0
- package/vendor/opencli/dist/clis/1688/item.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/1688/item.test.js +67 -0
- package/vendor/opencli/dist/clis/1688/search.d.ts +56 -0
- package/vendor/opencli/dist/clis/1688/search.js +309 -0
- package/vendor/opencli/dist/clis/1688/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/1688/search.test.js +75 -0
- package/vendor/opencli/dist/clis/1688/shared.d.ts +112 -0
- package/vendor/opencli/dist/clis/1688/shared.js +514 -0
- package/vendor/opencli/dist/clis/1688/shared.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/1688/shared.test.js +57 -0
- package/vendor/opencli/dist/clis/1688/store.d.ts +45 -0
- package/vendor/opencli/dist/clis/1688/store.js +226 -0
- package/vendor/opencli/dist/clis/1688/store.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/1688/store.test.js +62 -0
- package/vendor/opencli/dist/clis/36kr/article.d.ts +1 -0
- package/vendor/opencli/dist/clis/36kr/article.js +62 -0
- package/vendor/opencli/dist/clis/36kr/hot.d.ts +3 -0
- package/vendor/opencli/dist/clis/36kr/hot.js +80 -0
- package/vendor/opencli/dist/clis/36kr/hot.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/36kr/hot.test.js +15 -0
- package/vendor/opencli/dist/clis/36kr/news.d.ts +1 -0
- package/vendor/opencli/dist/clis/36kr/news.js +51 -0
- package/vendor/opencli/dist/clis/36kr/news.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/36kr/news.test.js +85 -0
- package/vendor/opencli/dist/clis/36kr/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/36kr/search.js +72 -0
- package/vendor/opencli/dist/clis/_shared/common.d.ts +8 -0
- package/vendor/opencli/dist/clis/_shared/common.js +10 -0
- package/vendor/opencli/dist/clis/_shared/desktop-commands.d.ts +22 -0
- package/vendor/opencli/dist/clis/_shared/desktop-commands.js +108 -0
- package/vendor/opencli/dist/clis/amazon/bestsellers.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/bestsellers.js +7 -0
- package/vendor/opencli/dist/clis/amazon/bestsellers.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/bestsellers.test.js +29 -0
- package/vendor/opencli/dist/clis/amazon/discussion.d.ts +20 -0
- package/vendor/opencli/dist/clis/amazon/discussion.js +91 -0
- package/vendor/opencli/dist/clis/amazon/discussion.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/discussion.test.js +36 -0
- package/vendor/opencli/dist/clis/amazon/movers-shakers.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/movers-shakers.js +7 -0
- package/vendor/opencli/dist/clis/amazon/new-releases.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/new-releases.js +7 -0
- package/vendor/opencli/dist/clis/amazon/offer.d.ts +23 -0
- package/vendor/opencli/dist/clis/amazon/offer.js +140 -0
- package/vendor/opencli/dist/clis/amazon/offer.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/offer.test.js +29 -0
- package/vendor/opencli/dist/clis/amazon/product.d.ts +18 -0
- package/vendor/opencli/dist/clis/amazon/product.js +92 -0
- package/vendor/opencli/dist/clis/amazon/product.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/product.test.js +24 -0
- package/vendor/opencli/dist/clis/amazon/rankings.d.ts +59 -0
- package/vendor/opencli/dist/clis/amazon/rankings.js +226 -0
- package/vendor/opencli/dist/clis/amazon/rankings.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/rankings.test.js +41 -0
- package/vendor/opencli/dist/clis/amazon/search.d.ts +18 -0
- package/vendor/opencli/dist/clis/amazon/search.js +87 -0
- package/vendor/opencli/dist/clis/amazon/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/search.test.js +22 -0
- package/vendor/opencli/dist/clis/amazon/shared.d.ts +75 -0
- package/vendor/opencli/dist/clis/amazon/shared.js +365 -0
- package/vendor/opencli/dist/clis/amazon/shared.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/amazon/shared.test.js +44 -0
- package/vendor/opencli/dist/clis/antigravity/dump.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/dump.js +28 -0
- package/vendor/opencli/dist/clis/antigravity/extract-code.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/extract-code.js +32 -0
- package/vendor/opencli/dist/clis/antigravity/model.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/model.js +44 -0
- package/vendor/opencli/dist/clis/antigravity/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/new.js +25 -0
- package/vendor/opencli/dist/clis/antigravity/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/read.js +34 -0
- package/vendor/opencli/dist/clis/antigravity/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/send.js +35 -0
- package/vendor/opencli/dist/clis/antigravity/serve.d.ts +14 -0
- package/vendor/opencli/dist/clis/antigravity/serve.js +512 -0
- package/vendor/opencli/dist/clis/antigravity/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/status.js +18 -0
- package/vendor/opencli/dist/clis/antigravity/watch.d.ts +1 -0
- package/vendor/opencli/dist/clis/antigravity/watch.js +41 -0
- package/vendor/opencli/dist/clis/apple-podcasts/commands.test.d.ts +2 -0
- package/vendor/opencli/dist/clis/apple-podcasts/commands.test.js +99 -0
- package/vendor/opencli/dist/clis/apple-podcasts/episodes.d.ts +1 -0
- package/vendor/opencli/dist/clis/apple-podcasts/episodes.js +28 -0
- package/vendor/opencli/dist/clis/apple-podcasts/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/apple-podcasts/search.js +30 -0
- package/vendor/opencli/dist/clis/apple-podcasts/top.d.ts +1 -0
- package/vendor/opencli/dist/clis/apple-podcasts/top.js +44 -0
- package/vendor/opencli/dist/clis/apple-podcasts/utils.d.ts +11 -0
- package/vendor/opencli/dist/clis/apple-podcasts/utils.js +30 -0
- package/vendor/opencli/dist/clis/apple-podcasts/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/apple-podcasts/utils.test.js +57 -0
- package/vendor/opencli/dist/clis/arxiv/paper.d.ts +1 -0
- package/vendor/opencli/dist/clis/arxiv/paper.js +21 -0
- package/vendor/opencli/dist/clis/arxiv/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/arxiv/search.js +24 -0
- package/vendor/opencli/dist/clis/arxiv/utils.d.ts +18 -0
- package/vendor/opencli/dist/clis/arxiv/utils.js +49 -0
- package/vendor/opencli/dist/clis/band/bands.d.ts +1 -0
- package/vendor/opencli/dist/clis/band/bands.js +72 -0
- package/vendor/opencli/dist/clis/band/mentions.d.ts +1 -0
- package/vendor/opencli/dist/clis/band/mentions.js +127 -0
- package/vendor/opencli/dist/clis/band/post.d.ts +1 -0
- package/vendor/opencli/dist/clis/band/post.js +175 -0
- package/vendor/opencli/dist/clis/band/posts.d.ts +1 -0
- package/vendor/opencli/dist/clis/band/posts.js +94 -0
- package/vendor/opencli/dist/clis/barchart/flow.d.ts +1 -0
- package/vendor/opencli/dist/clis/barchart/flow.js +115 -0
- package/vendor/opencli/dist/clis/barchart/greeks.d.ts +1 -0
- package/vendor/opencli/dist/clis/barchart/greeks.js +119 -0
- package/vendor/opencli/dist/clis/barchart/options.d.ts +1 -0
- package/vendor/opencli/dist/clis/barchart/options.js +106 -0
- package/vendor/opencli/dist/clis/barchart/quote.d.ts +1 -0
- package/vendor/opencli/dist/clis/barchart/quote.js +133 -0
- package/vendor/opencli/dist/clis/bbc/news.d.ts +1 -0
- package/vendor/opencli/dist/clis/bbc/news.js +41 -0
- package/vendor/opencli/dist/clis/bilibili/comments.d.ts +5 -0
- package/vendor/opencli/dist/clis/bilibili/comments.js +40 -0
- package/vendor/opencli/dist/clis/bilibili/comments.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/comments.test.js +83 -0
- package/vendor/opencli/dist/clis/bilibili/download.d.ts +10 -0
- package/vendor/opencli/dist/clis/bilibili/download.js +81 -0
- package/vendor/opencli/dist/clis/bilibili/dynamic.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/dynamic.js +33 -0
- package/vendor/opencli/dist/clis/bilibili/dynamic.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/dynamic.test.js +68 -0
- package/vendor/opencli/dist/clis/bilibili/favorite.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/favorite.js +41 -0
- package/vendor/opencli/dist/clis/bilibili/feed.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/feed.js +64 -0
- package/vendor/opencli/dist/clis/bilibili/following.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/following.js +42 -0
- package/vendor/opencli/dist/clis/bilibili/history.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/history.js +44 -0
- package/vendor/opencli/dist/clis/bilibili/hot.yaml +38 -0
- package/vendor/opencli/dist/clis/bilibili/me.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/me.js +13 -0
- package/vendor/opencli/dist/clis/bilibili/ranking.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/ranking.js +24 -0
- package/vendor/opencli/dist/clis/bilibili/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/search.js +24 -0
- package/vendor/opencli/dist/clis/bilibili/subtitle.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/subtitle.js +92 -0
- package/vendor/opencli/dist/clis/bilibili/subtitle.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/subtitle.test.js +49 -0
- package/vendor/opencli/dist/clis/bilibili/user-videos.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/user-videos.js +38 -0
- package/vendor/opencli/dist/clis/bilibili/utils.d.ts +19 -0
- package/vendor/opencli/dist/clis/bilibili/utils.js +126 -0
- package/vendor/opencli/dist/clis/bilibili/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/bilibili/utils.test.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/businessweek.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/businessweek.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/economics.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/economics.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/feeds.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/feeds.js +15 -0
- package/vendor/opencli/dist/clis/bloomberg/industries.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/industries.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/main.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/main.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/markets.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/markets.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/news.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/news.js +105 -0
- package/vendor/opencli/dist/clis/bloomberg/opinions.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/opinions.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/politics.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/politics.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/tech.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/tech.js +17 -0
- package/vendor/opencli/dist/clis/bloomberg/utils.d.ts +34 -0
- package/vendor/opencli/dist/clis/bloomberg/utils.js +364 -0
- package/vendor/opencli/dist/clis/bloomberg/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/bloomberg/utils.test.js +129 -0
- package/vendor/opencli/dist/clis/bluesky/feeds.yaml +29 -0
- package/vendor/opencli/dist/clis/bluesky/followers.yaml +33 -0
- package/vendor/opencli/dist/clis/bluesky/following.yaml +33 -0
- package/vendor/opencli/dist/clis/bluesky/profile.yaml +27 -0
- package/vendor/opencli/dist/clis/bluesky/search.yaml +34 -0
- package/vendor/opencli/dist/clis/bluesky/starter-packs.yaml +34 -0
- package/vendor/opencli/dist/clis/bluesky/thread.yaml +32 -0
- package/vendor/opencli/dist/clis/bluesky/trending.yaml +27 -0
- package/vendor/opencli/dist/clis/bluesky/user.yaml +34 -0
- package/vendor/opencli/dist/clis/boss/batchgreet.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/batchgreet.js +60 -0
- package/vendor/opencli/dist/clis/boss/chatlist.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/chatlist.js +33 -0
- package/vendor/opencli/dist/clis/boss/chatmsg.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/chatmsg.js +42 -0
- package/vendor/opencli/dist/clis/boss/detail.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/detail.js +62 -0
- package/vendor/opencli/dist/clis/boss/exchange.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/exchange.js +45 -0
- package/vendor/opencli/dist/clis/boss/greet.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/greet.js +48 -0
- package/vendor/opencli/dist/clis/boss/invite.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/invite.js +63 -0
- package/vendor/opencli/dist/clis/boss/joblist.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/joblist.js +30 -0
- package/vendor/opencli/dist/clis/boss/mark.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/mark.js +69 -0
- package/vendor/opencli/dist/clis/boss/recommend.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/recommend.js +44 -0
- package/vendor/opencli/dist/clis/boss/resume.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/resume.js +149 -0
- package/vendor/opencli/dist/clis/boss/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/search.js +155 -0
- package/vendor/opencli/dist/clis/boss/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/send.js +43 -0
- package/vendor/opencli/dist/clis/boss/stats.d.ts +1 -0
- package/vendor/opencli/dist/clis/boss/stats.js +65 -0
- package/vendor/opencli/dist/clis/boss/utils.d.ts +92 -0
- package/vendor/opencli/dist/clis/boss/utils.js +223 -0
- package/vendor/opencli/dist/clis/chaoxing/assignments.d.ts +1 -0
- package/vendor/opencli/dist/clis/chaoxing/assignments.js +75 -0
- package/vendor/opencli/dist/clis/chaoxing/exams.d.ts +1 -0
- package/vendor/opencli/dist/clis/chaoxing/exams.js +74 -0
- package/vendor/opencli/dist/clis/chaoxing/utils.d.ts +58 -0
- package/vendor/opencli/dist/clis/chaoxing/utils.js +223 -0
- package/vendor/opencli/dist/clis/chaoxing/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/chaoxing/utils.test.js +45 -0
- package/vendor/opencli/dist/clis/chatgpt/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatgpt/ask.js +88 -0
- package/vendor/opencli/dist/clis/chatgpt/ax.d.ts +7 -0
- package/vendor/opencli/dist/clis/chatgpt/ax.js +249 -0
- package/vendor/opencli/dist/clis/chatgpt/model.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatgpt/model.js +24 -0
- package/vendor/opencli/dist/clis/chatgpt/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatgpt/new.js +27 -0
- package/vendor/opencli/dist/clis/chatgpt/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatgpt/read.js +31 -0
- package/vendor/opencli/dist/clis/chatgpt/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatgpt/send.js +52 -0
- package/vendor/opencli/dist/clis/chatgpt/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatgpt/status.js +25 -0
- package/vendor/opencli/dist/clis/chatwise/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/ask.js +80 -0
- package/vendor/opencli/dist/clis/chatwise/export.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/export.js +46 -0
- package/vendor/opencli/dist/clis/chatwise/history.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/history.js +60 -0
- package/vendor/opencli/dist/clis/chatwise/model.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/model.js +84 -0
- package/vendor/opencli/dist/clis/chatwise/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/new.js +2 -0
- package/vendor/opencli/dist/clis/chatwise/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/read.js +39 -0
- package/vendor/opencli/dist/clis/chatwise/screenshot.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/screenshot.js +2 -0
- package/vendor/opencli/dist/clis/chatwise/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/send.js +49 -0
- package/vendor/opencli/dist/clis/chatwise/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/chatwise/status.js +2 -0
- package/vendor/opencli/dist/clis/codex/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/ask.js +71 -0
- package/vendor/opencli/dist/clis/codex/dump.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/dump.js +2 -0
- package/vendor/opencli/dist/clis/codex/export.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/export.js +37 -0
- package/vendor/opencli/dist/clis/codex/extract-diff.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/extract-diff.js +44 -0
- package/vendor/opencli/dist/clis/codex/history.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/history.js +43 -0
- package/vendor/opencli/dist/clis/codex/model.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/model.js +55 -0
- package/vendor/opencli/dist/clis/codex/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/new.js +2 -0
- package/vendor/opencli/dist/clis/codex/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/read.js +34 -0
- package/vendor/opencli/dist/clis/codex/screenshot.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/screenshot.js +2 -0
- package/vendor/opencli/dist/clis/codex/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/send.js +43 -0
- package/vendor/opencli/dist/clis/codex/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/codex/status.js +2 -0
- package/vendor/opencli/dist/clis/coupang/add-to-cart.d.ts +1 -0
- package/vendor/opencli/dist/clis/coupang/add-to-cart.js +140 -0
- package/vendor/opencli/dist/clis/coupang/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/coupang/search.js +451 -0
- package/vendor/opencli/dist/clis/coupang/utils.d.ts +24 -0
- package/vendor/opencli/dist/clis/coupang/utils.js +262 -0
- package/vendor/opencli/dist/clis/coupang/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/coupang/utils.test.js +62 -0
- package/vendor/opencli/dist/clis/ctrip/search.d.ts +14 -0
- package/vendor/opencli/dist/clis/ctrip/search.js +86 -0
- package/vendor/opencli/dist/clis/ctrip/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/ctrip/search.test.js +64 -0
- package/vendor/opencli/dist/clis/cursor/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/ask.js +70 -0
- package/vendor/opencli/dist/clis/cursor/composer.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/composer.js +42 -0
- package/vendor/opencli/dist/clis/cursor/dump.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/dump.js +2 -0
- package/vendor/opencli/dist/clis/cursor/export.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/export.js +51 -0
- package/vendor/opencli/dist/clis/cursor/extract-code.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/extract-code.js +35 -0
- package/vendor/opencli/dist/clis/cursor/history.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/history.js +43 -0
- package/vendor/opencli/dist/clis/cursor/model.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/model.js +53 -0
- package/vendor/opencli/dist/clis/cursor/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/new.js +2 -0
- package/vendor/opencli/dist/clis/cursor/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/read.js +44 -0
- package/vendor/opencli/dist/clis/cursor/screenshot.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/screenshot.js +2 -0
- package/vendor/opencli/dist/clis/cursor/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/send.js +40 -0
- package/vendor/opencli/dist/clis/cursor/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/cursor/status.js +2 -0
- package/vendor/opencli/dist/clis/devto/tag.yaml +34 -0
- package/vendor/opencli/dist/clis/devto/top.yaml +29 -0
- package/vendor/opencli/dist/clis/devto/user.yaml +33 -0
- package/vendor/opencli/dist/clis/dictionary/examples.yaml +25 -0
- package/vendor/opencli/dist/clis/dictionary/search.yaml +27 -0
- package/vendor/opencli/dist/clis/dictionary/synonyms.yaml +25 -0
- package/vendor/opencli/dist/clis/discord-app/channels.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/channels.js +57 -0
- package/vendor/opencli/dist/clis/discord-app/members.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/members.js +38 -0
- package/vendor/opencli/dist/clis/discord-app/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/read.js +45 -0
- package/vendor/opencli/dist/clis/discord-app/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/search.js +56 -0
- package/vendor/opencli/dist/clis/discord-app/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/send.js +27 -0
- package/vendor/opencli/dist/clis/discord-app/servers.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/servers.js +36 -0
- package/vendor/opencli/dist/clis/discord-app/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/discord-app/status.js +16 -0
- package/vendor/opencli/dist/clis/douban/book-hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/book-hot.js +14 -0
- package/vendor/opencli/dist/clis/douban/download.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/download.js +67 -0
- package/vendor/opencli/dist/clis/douban/download.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/download.test.js +170 -0
- package/vendor/opencli/dist/clis/douban/marks.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/marks.js +115 -0
- package/vendor/opencli/dist/clis/douban/movie-hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/movie-hot.js +14 -0
- package/vendor/opencli/dist/clis/douban/photos.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/photos.js +34 -0
- package/vendor/opencli/dist/clis/douban/reviews.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/reviews.js +106 -0
- package/vendor/opencli/dist/clis/douban/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/search.js +16 -0
- package/vendor/opencli/dist/clis/douban/subject.yaml +107 -0
- package/vendor/opencli/dist/clis/douban/top250.yaml +70 -0
- package/vendor/opencli/dist/clis/douban/utils.d.ts +63 -0
- package/vendor/opencli/dist/clis/douban/utils.js +389 -0
- package/vendor/opencli/dist/clis/douban/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douban/utils.test.js +64 -0
- package/vendor/opencli/dist/clis/doubao/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/ask.js +35 -0
- package/vendor/opencli/dist/clis/doubao/detail.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/detail.js +33 -0
- package/vendor/opencli/dist/clis/doubao/detail.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/detail.test.js +42 -0
- package/vendor/opencli/dist/clis/doubao/history.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/history.js +28 -0
- package/vendor/opencli/dist/clis/doubao/history.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/history.test.js +37 -0
- package/vendor/opencli/dist/clis/doubao/meeting-summary.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/meeting-summary.js +39 -0
- package/vendor/opencli/dist/clis/doubao/meeting-transcript.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/meeting-transcript.js +36 -0
- package/vendor/opencli/dist/clis/doubao/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/new.js +20 -0
- package/vendor/opencli/dist/clis/doubao/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/read.js +19 -0
- package/vendor/opencli/dist/clis/doubao/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/send.js +22 -0
- package/vendor/opencli/dist/clis/doubao/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/status.js +24 -0
- package/vendor/opencli/dist/clis/doubao/utils.d.ts +50 -0
- package/vendor/opencli/dist/clis/doubao/utils.js +901 -0
- package/vendor/opencli/dist/clis/doubao/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao/utils.test.js +24 -0
- package/vendor/opencli/dist/clis/doubao-app/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/ask.js +53 -0
- package/vendor/opencli/dist/clis/doubao-app/dump.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/dump.js +24 -0
- package/vendor/opencli/dist/clis/doubao-app/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/new.js +20 -0
- package/vendor/opencli/dist/clis/doubao-app/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/read.js +18 -0
- package/vendor/opencli/dist/clis/doubao-app/screenshot.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/screenshot.js +18 -0
- package/vendor/opencli/dist/clis/doubao-app/send.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/send.js +27 -0
- package/vendor/opencli/dist/clis/doubao-app/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/doubao-app/status.js +16 -0
- package/vendor/opencli/dist/clis/doubao-app/utils.d.ts +37 -0
- package/vendor/opencli/dist/clis/doubao-app/utils.js +110 -0
- package/vendor/opencli/dist/clis/douyin/_shared/browser-fetch.d.ts +10 -0
- package/vendor/opencli/dist/clis/douyin/_shared/browser-fetch.js +30 -0
- package/vendor/opencli/dist/clis/douyin/_shared/browser-fetch.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/browser-fetch.test.js +30 -0
- package/vendor/opencli/dist/clis/douyin/_shared/creation-id.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/creation-id.js +5 -0
- package/vendor/opencli/dist/clis/douyin/_shared/creation-id.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/creation-id.test.js +22 -0
- package/vendor/opencli/dist/clis/douyin/_shared/imagex-upload.d.ts +20 -0
- package/vendor/opencli/dist/clis/douyin/_shared/imagex-upload.js +53 -0
- package/vendor/opencli/dist/clis/douyin/_shared/imagex-upload.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/imagex-upload.test.js +87 -0
- package/vendor/opencli/dist/clis/douyin/_shared/public-api.d.ts +33 -0
- package/vendor/opencli/dist/clis/douyin/_shared/public-api.js +29 -0
- package/vendor/opencli/dist/clis/douyin/_shared/sts2.d.ts +8 -0
- package/vendor/opencli/dist/clis/douyin/_shared/sts2.js +21 -0
- package/vendor/opencli/dist/clis/douyin/_shared/sts2.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/sts2.test.js +27 -0
- package/vendor/opencli/dist/clis/douyin/_shared/text-extra.d.ts +18 -0
- package/vendor/opencli/dist/clis/douyin/_shared/text-extra.js +15 -0
- package/vendor/opencli/dist/clis/douyin/_shared/text-extra.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/text-extra.test.js +37 -0
- package/vendor/opencli/dist/clis/douyin/_shared/timing.d.ts +2 -0
- package/vendor/opencli/dist/clis/douyin/_shared/timing.js +22 -0
- package/vendor/opencli/dist/clis/douyin/_shared/timing.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/timing.test.js +28 -0
- package/vendor/opencli/dist/clis/douyin/_shared/tos-upload-short-read.test.d.ts +11 -0
- package/vendor/opencli/dist/clis/douyin/_shared/tos-upload-short-read.test.js +83 -0
- package/vendor/opencli/dist/clis/douyin/_shared/tos-upload.d.ts +53 -0
- package/vendor/opencli/dist/clis/douyin/_shared/tos-upload.js +295 -0
- package/vendor/opencli/dist/clis/douyin/_shared/tos-upload.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/tos-upload.test.js +229 -0
- package/vendor/opencli/dist/clis/douyin/_shared/transcode.d.ts +27 -0
- package/vendor/opencli/dist/clis/douyin/_shared/transcode.js +45 -0
- package/vendor/opencli/dist/clis/douyin/_shared/transcode.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/_shared/transcode.test.js +91 -0
- package/vendor/opencli/dist/clis/douyin/_shared/types.d.ts +26 -0
- package/vendor/opencli/dist/clis/douyin/_shared/types.js +1 -0
- package/vendor/opencli/dist/clis/douyin/activities.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/activities.js +22 -0
- package/vendor/opencli/dist/clis/douyin/activities.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/activities.test.js +55 -0
- package/vendor/opencli/dist/clis/douyin/collections.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/collections.js +22 -0
- package/vendor/opencli/dist/clis/douyin/collections.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/collections.test.js +45 -0
- package/vendor/opencli/dist/clis/douyin/delete.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/delete.js +18 -0
- package/vendor/opencli/dist/clis/douyin/delete.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/delete.test.js +11 -0
- package/vendor/opencli/dist/clis/douyin/draft.d.ts +11 -0
- package/vendor/opencli/dist/clis/douyin/draft.js +354 -0
- package/vendor/opencli/dist/clis/douyin/draft.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/draft.test.js +364 -0
- package/vendor/opencli/dist/clis/douyin/drafts.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/drafts.js +23 -0
- package/vendor/opencli/dist/clis/douyin/drafts.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/drafts.test.js +11 -0
- package/vendor/opencli/dist/clis/douyin/hashtag.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/hashtag.js +52 -0
- package/vendor/opencli/dist/clis/douyin/hashtag.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/hashtag.test.js +58 -0
- package/vendor/opencli/dist/clis/douyin/location.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/location.js +24 -0
- package/vendor/opencli/dist/clis/douyin/location.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/location.test.js +23 -0
- package/vendor/opencli/dist/clis/douyin/profile.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/profile.js +28 -0
- package/vendor/opencli/dist/clis/douyin/profile.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/profile.test.js +46 -0
- package/vendor/opencli/dist/clis/douyin/publish.d.ts +14 -0
- package/vendor/opencli/dist/clis/douyin/publish.js +288 -0
- package/vendor/opencli/dist/clis/douyin/publish.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/publish.test.js +38 -0
- package/vendor/opencli/dist/clis/douyin/stats.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/stats.js +27 -0
- package/vendor/opencli/dist/clis/douyin/stats.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/stats.test.js +22 -0
- package/vendor/opencli/dist/clis/douyin/update.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/update.js +31 -0
- package/vendor/opencli/dist/clis/douyin/update.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/update.test.js +11 -0
- package/vendor/opencli/dist/clis/douyin/user-videos.d.ts +5 -0
- package/vendor/opencli/dist/clis/douyin/user-videos.js +74 -0
- package/vendor/opencli/dist/clis/douyin/user-videos.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/user-videos.test.js +108 -0
- package/vendor/opencli/dist/clis/douyin/videos.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/videos.js +51 -0
- package/vendor/opencli/dist/clis/douyin/videos.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/douyin/videos.test.js +54 -0
- package/vendor/opencli/dist/clis/facebook/add-friend.yaml +43 -0
- package/vendor/opencli/dist/clis/facebook/events.yaml +44 -0
- package/vendor/opencli/dist/clis/facebook/feed.yaml +63 -0
- package/vendor/opencli/dist/clis/facebook/friends.yaml +42 -0
- package/vendor/opencli/dist/clis/facebook/groups.yaml +50 -0
- package/vendor/opencli/dist/clis/facebook/join-group.yaml +44 -0
- package/vendor/opencli/dist/clis/facebook/memories.yaml +39 -0
- package/vendor/opencli/dist/clis/facebook/notifications.yaml +40 -0
- package/vendor/opencli/dist/clis/facebook/profile.yaml +37 -0
- package/vendor/opencli/dist/clis/facebook/search.test.d.ts +5 -0
- package/vendor/opencli/dist/clis/facebook/search.test.js +58 -0
- package/vendor/opencli/dist/clis/facebook/search.yaml +47 -0
- package/vendor/opencli/dist/clis/gemini/ask.d.ts +1 -0
- package/vendor/opencli/dist/clis/gemini/ask.js +46 -0
- package/vendor/opencli/dist/clis/gemini/ask.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/gemini/ask.test.js +100 -0
- package/vendor/opencli/dist/clis/gemini/image.d.ts +1 -0
- package/vendor/opencli/dist/clis/gemini/image.js +105 -0
- package/vendor/opencli/dist/clis/gemini/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/gemini/new.js +20 -0
- package/vendor/opencli/dist/clis/gemini/reply-state.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/gemini/reply-state.test.js +641 -0
- package/vendor/opencli/dist/clis/gemini/utils.d.ts +77 -0
- package/vendor/opencli/dist/clis/gemini/utils.js +930 -0
- package/vendor/opencli/dist/clis/gemini/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/gemini/utils.test.js +178 -0
- package/vendor/opencli/dist/clis/google/news.d.ts +5 -0
- package/vendor/opencli/dist/clis/google/news.js +58 -0
- package/vendor/opencli/dist/clis/google/search.d.ts +10 -0
- package/vendor/opencli/dist/clis/google/search.js +127 -0
- package/vendor/opencli/dist/clis/google/suggest.d.ts +5 -0
- package/vendor/opencli/dist/clis/google/suggest.js +34 -0
- package/vendor/opencli/dist/clis/google/trends.d.ts +5 -0
- package/vendor/opencli/dist/clis/google/trends.js +38 -0
- package/vendor/opencli/dist/clis/google/utils.d.ts +9 -0
- package/vendor/opencli/dist/clis/google/utils.js +23 -0
- package/vendor/opencli/dist/clis/google/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/google/utils.test.js +75 -0
- package/vendor/opencli/dist/clis/grok/ask.d.ts +19 -0
- package/vendor/opencli/dist/clis/grok/ask.js +292 -0
- package/vendor/opencli/dist/clis/grok/ask.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/grok/ask.test.js +54 -0
- package/vendor/opencli/dist/clis/hackernews/ask.yaml +38 -0
- package/vendor/opencli/dist/clis/hackernews/best.yaml +38 -0
- package/vendor/opencli/dist/clis/hackernews/jobs.yaml +36 -0
- package/vendor/opencli/dist/clis/hackernews/new.yaml +38 -0
- package/vendor/opencli/dist/clis/hackernews/search.yaml +44 -0
- package/vendor/opencli/dist/clis/hackernews/show.yaml +38 -0
- package/vendor/opencli/dist/clis/hackernews/top.yaml +38 -0
- package/vendor/opencli/dist/clis/hackernews/user.yaml +25 -0
- package/vendor/opencli/dist/clis/hf/top.d.ts +1 -0
- package/vendor/opencli/dist/clis/hf/top.js +119 -0
- package/vendor/opencli/dist/clis/hupu/detail.d.ts +1 -0
- package/vendor/opencli/dist/clis/hupu/detail.js +72 -0
- package/vendor/opencli/dist/clis/hupu/hot.yaml +43 -0
- package/vendor/opencli/dist/clis/hupu/like.d.ts +1 -0
- package/vendor/opencli/dist/clis/hupu/like.js +75 -0
- package/vendor/opencli/dist/clis/hupu/reply.d.ts +1 -0
- package/vendor/opencli/dist/clis/hupu/reply.js +71 -0
- package/vendor/opencli/dist/clis/hupu/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/hupu/search.js +59 -0
- package/vendor/opencli/dist/clis/hupu/unlike.d.ts +1 -0
- package/vendor/opencli/dist/clis/hupu/unlike.js +75 -0
- package/vendor/opencli/dist/clis/hupu/utils.d.ts +20 -0
- package/vendor/opencli/dist/clis/hupu/utils.js +319 -0
- package/vendor/opencli/dist/clis/imdb/person.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/person.js +203 -0
- package/vendor/opencli/dist/clis/imdb/reviews.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/reviews.js +88 -0
- package/vendor/opencli/dist/clis/imdb/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/search.js +161 -0
- package/vendor/opencli/dist/clis/imdb/title.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/title.js +93 -0
- package/vendor/opencli/dist/clis/imdb/top.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/top.js +53 -0
- package/vendor/opencli/dist/clis/imdb/trending.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/trending.js +52 -0
- package/vendor/opencli/dist/clis/imdb/utils.d.ts +46 -0
- package/vendor/opencli/dist/clis/imdb/utils.js +285 -0
- package/vendor/opencli/dist/clis/imdb/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/imdb/utils.test.js +88 -0
- package/vendor/opencli/dist/clis/instagram/_shared/private-publish.d.ts +138 -0
- package/vendor/opencli/dist/clis/instagram/_shared/private-publish.js +1030 -0
- package/vendor/opencli/dist/clis/instagram/_shared/private-publish.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/_shared/private-publish.test.js +705 -0
- package/vendor/opencli/dist/clis/instagram/_shared/protocol-capture.d.ts +26 -0
- package/vendor/opencli/dist/clis/instagram/_shared/protocol-capture.js +282 -0
- package/vendor/opencli/dist/clis/instagram/_shared/protocol-capture.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/_shared/protocol-capture.test.js +114 -0
- package/vendor/opencli/dist/clis/instagram/_shared/runtime-info.d.ts +9 -0
- package/vendor/opencli/dist/clis/instagram/_shared/runtime-info.js +81 -0
- package/vendor/opencli/dist/clis/instagram/comment.yaml +52 -0
- package/vendor/opencli/dist/clis/instagram/download.d.ts +16 -0
- package/vendor/opencli/dist/clis/instagram/download.js +225 -0
- package/vendor/opencli/dist/clis/instagram/download.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/download.test.js +118 -0
- package/vendor/opencli/dist/clis/instagram/explore.yaml +43 -0
- package/vendor/opencli/dist/clis/instagram/follow.yaml +41 -0
- package/vendor/opencli/dist/clis/instagram/followers.yaml +51 -0
- package/vendor/opencli/dist/clis/instagram/following.yaml +51 -0
- package/vendor/opencli/dist/clis/instagram/like.yaml +46 -0
- package/vendor/opencli/dist/clis/instagram/note.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/note.js +222 -0
- package/vendor/opencli/dist/clis/instagram/note.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/note.test.js +81 -0
- package/vendor/opencli/dist/clis/instagram/post.d.ts +4 -0
- package/vendor/opencli/dist/clis/instagram/post.js +1496 -0
- package/vendor/opencli/dist/clis/instagram/post.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/post.test.js +1647 -0
- package/vendor/opencli/dist/clis/instagram/profile.yaml +42 -0
- package/vendor/opencli/dist/clis/instagram/reel.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/reel.js +826 -0
- package/vendor/opencli/dist/clis/instagram/reel.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/reel.test.js +167 -0
- package/vendor/opencli/dist/clis/instagram/save.yaml +46 -0
- package/vendor/opencli/dist/clis/instagram/saved.yaml +40 -0
- package/vendor/opencli/dist/clis/instagram/search.yaml +44 -0
- package/vendor/opencli/dist/clis/instagram/story.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/story.js +115 -0
- package/vendor/opencli/dist/clis/instagram/story.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/instagram/story.test.js +167 -0
- package/vendor/opencli/dist/clis/instagram/unfollow.yaml +38 -0
- package/vendor/opencli/dist/clis/instagram/unlike.yaml +46 -0
- package/vendor/opencli/dist/clis/instagram/unsave.yaml +46 -0
- package/vendor/opencli/dist/clis/instagram/user.yaml +54 -0
- package/vendor/opencli/dist/clis/jd/item.d.ts +5 -0
- package/vendor/opencli/dist/clis/jd/item.js +97 -0
- package/vendor/opencli/dist/clis/jd/item.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/jd/item.test.js +43 -0
- package/vendor/opencli/dist/clis/jike/comment.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/comment.js +106 -0
- package/vendor/opencli/dist/clis/jike/create.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/create.js +105 -0
- package/vendor/opencli/dist/clis/jike/feed.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/feed.js +66 -0
- package/vendor/opencli/dist/clis/jike/like.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/like.js +60 -0
- package/vendor/opencli/dist/clis/jike/notifications.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/notifications.js +168 -0
- package/vendor/opencli/dist/clis/jike/post.yaml +59 -0
- package/vendor/opencli/dist/clis/jike/repost.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/repost.js +102 -0
- package/vendor/opencli/dist/clis/jike/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/jike/search.js +66 -0
- package/vendor/opencli/dist/clis/jike/topic.yaml +53 -0
- package/vendor/opencli/dist/clis/jike/user.yaml +52 -0
- package/vendor/opencli/dist/clis/jike/utils.d.ts +19 -0
- package/vendor/opencli/dist/clis/jike/utils.js +25 -0
- package/vendor/opencli/dist/clis/jimeng/generate.yaml +85 -0
- package/vendor/opencli/dist/clis/jimeng/history.yaml +46 -0
- package/vendor/opencli/dist/clis/linkedin/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/linkedin/search.js +367 -0
- package/vendor/opencli/dist/clis/linkedin/timeline.d.ts +21 -0
- package/vendor/opencli/dist/clis/linkedin/timeline.js +503 -0
- package/vendor/opencli/dist/clis/linkedin/timeline.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/linkedin/timeline.test.js +81 -0
- package/vendor/opencli/dist/clis/linux-do/categories.yaml +70 -0
- package/vendor/opencli/dist/clis/linux-do/category.d.ts +1 -0
- package/vendor/opencli/dist/clis/linux-do/category.js +36 -0
- package/vendor/opencli/dist/clis/linux-do/feed.d.ts +45 -0
- package/vendor/opencli/dist/clis/linux-do/feed.js +397 -0
- package/vendor/opencli/dist/clis/linux-do/feed.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/linux-do/feed.test.js +118 -0
- package/vendor/opencli/dist/clis/linux-do/hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/linux-do/hot.js +25 -0
- package/vendor/opencli/dist/clis/linux-do/latest.d.ts +1 -0
- package/vendor/opencli/dist/clis/linux-do/latest.js +18 -0
- package/vendor/opencli/dist/clis/linux-do/search.yaml +48 -0
- package/vendor/opencli/dist/clis/linux-do/tags.yaml +41 -0
- package/vendor/opencli/dist/clis/linux-do/topic.yaml +77 -0
- package/vendor/opencli/dist/clis/linux-do/user-posts.yaml +67 -0
- package/vendor/opencli/dist/clis/linux-do/user-topics.yaml +54 -0
- package/vendor/opencli/dist/clis/lobsters/active.yaml +29 -0
- package/vendor/opencli/dist/clis/lobsters/hot.yaml +29 -0
- package/vendor/opencli/dist/clis/lobsters/newest.yaml +29 -0
- package/vendor/opencli/dist/clis/lobsters/tag.yaml +34 -0
- package/vendor/opencli/dist/clis/medium/feed.d.ts +1 -0
- package/vendor/opencli/dist/clis/medium/feed.js +15 -0
- package/vendor/opencli/dist/clis/medium/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/medium/search.js +15 -0
- package/vendor/opencli/dist/clis/medium/user.d.ts +1 -0
- package/vendor/opencli/dist/clis/medium/user.js +15 -0
- package/vendor/opencli/dist/clis/medium/utils.d.ts +5 -0
- package/vendor/opencli/dist/clis/medium/utils.js +79 -0
- package/vendor/opencli/dist/clis/notebooklm/compat.test.d.ts +3 -0
- package/vendor/opencli/dist/clis/notebooklm/compat.test.js +16 -0
- package/vendor/opencli/dist/clis/notebooklm/current.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/current.js +27 -0
- package/vendor/opencli/dist/clis/notebooklm/get.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/get.js +36 -0
- package/vendor/opencli/dist/clis/notebooklm/history.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/history.js +24 -0
- package/vendor/opencli/dist/clis/notebooklm/history.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/history.test.js +58 -0
- package/vendor/opencli/dist/clis/notebooklm/list.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/list.js +35 -0
- package/vendor/opencli/dist/clis/notebooklm/note-list.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/note-list.js +27 -0
- package/vendor/opencli/dist/clis/notebooklm/note-list.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/note-list.test.js +56 -0
- package/vendor/opencli/dist/clis/notebooklm/notes-get.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/notes-get.js +46 -0
- package/vendor/opencli/dist/clis/notebooklm/notes-get.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/notes-get.test.js +72 -0
- package/vendor/opencli/dist/clis/notebooklm/open.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/open.js +41 -0
- package/vendor/opencli/dist/clis/notebooklm/open.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/open.test.js +63 -0
- package/vendor/opencli/dist/clis/notebooklm/rpc.d.ts +36 -0
- package/vendor/opencli/dist/clis/notebooklm/rpc.js +189 -0
- package/vendor/opencli/dist/clis/notebooklm/rpc.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/rpc.test.js +105 -0
- package/vendor/opencli/dist/clis/notebooklm/shared.d.ts +87 -0
- package/vendor/opencli/dist/clis/notebooklm/shared.js +3 -0
- package/vendor/opencli/dist/clis/notebooklm/source-fulltext.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-fulltext.js +43 -0
- package/vendor/opencli/dist/clis/notebooklm/source-fulltext.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-fulltext.test.js +106 -0
- package/vendor/opencli/dist/clis/notebooklm/source-get.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-get.js +39 -0
- package/vendor/opencli/dist/clis/notebooklm/source-get.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-get.test.js +84 -0
- package/vendor/opencli/dist/clis/notebooklm/source-guide.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-guide.js +43 -0
- package/vendor/opencli/dist/clis/notebooklm/source-guide.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-guide.test.js +104 -0
- package/vendor/opencli/dist/clis/notebooklm/source-list.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/source-list.js +29 -0
- package/vendor/opencli/dist/clis/notebooklm/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/status.js +30 -0
- package/vendor/opencli/dist/clis/notebooklm/summary.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/summary.js +29 -0
- package/vendor/opencli/dist/clis/notebooklm/summary.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/summary.test.js +78 -0
- package/vendor/opencli/dist/clis/notebooklm/utils.d.ts +38 -0
- package/vendor/opencli/dist/clis/notebooklm/utils.js +738 -0
- package/vendor/opencli/dist/clis/notebooklm/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/notebooklm/utils.test.js +390 -0
- package/vendor/opencli/dist/clis/notion/export.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/export.js +31 -0
- package/vendor/opencli/dist/clis/notion/favorites.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/favorites.js +84 -0
- package/vendor/opencli/dist/clis/notion/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/new.js +34 -0
- package/vendor/opencli/dist/clis/notion/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/read.js +30 -0
- package/vendor/opencli/dist/clis/notion/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/search.js +46 -0
- package/vendor/opencli/dist/clis/notion/sidebar.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/sidebar.js +41 -0
- package/vendor/opencli/dist/clis/notion/status.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/status.js +16 -0
- package/vendor/opencli/dist/clis/notion/write.d.ts +1 -0
- package/vendor/opencli/dist/clis/notion/write.js +40 -0
- package/vendor/opencli/dist/clis/ones/common.d.ts +32 -0
- package/vendor/opencli/dist/clis/ones/common.js +144 -0
- package/vendor/opencli/dist/clis/ones/enrich-tasks.d.ts +5 -0
- package/vendor/opencli/dist/clis/ones/enrich-tasks.js +37 -0
- package/vendor/opencli/dist/clis/ones/login.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/login.js +80 -0
- package/vendor/opencli/dist/clis/ones/logout.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/logout.js +17 -0
- package/vendor/opencli/dist/clis/ones/me.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/me.js +30 -0
- package/vendor/opencli/dist/clis/ones/my-tasks.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/my-tasks.js +120 -0
- package/vendor/opencli/dist/clis/ones/resolve-labels.d.ts +10 -0
- package/vendor/opencli/dist/clis/ones/resolve-labels.js +64 -0
- package/vendor/opencli/dist/clis/ones/task-helpers.d.ts +29 -0
- package/vendor/opencli/dist/clis/ones/task-helpers.js +212 -0
- package/vendor/opencli/dist/clis/ones/task-helpers.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/task-helpers.test.js +12 -0
- package/vendor/opencli/dist/clis/ones/task.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/task.js +66 -0
- package/vendor/opencli/dist/clis/ones/tasks.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/tasks.js +79 -0
- package/vendor/opencli/dist/clis/ones/token-info.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/token-info.js +42 -0
- package/vendor/opencli/dist/clis/ones/worklog.d.ts +11 -0
- package/vendor/opencli/dist/clis/ones/worklog.js +267 -0
- package/vendor/opencli/dist/clis/ones/worklog.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/ones/worklog.test.js +20 -0
- package/vendor/opencli/dist/clis/paperreview/commands.test.d.ts +3 -0
- package/vendor/opencli/dist/clis/paperreview/commands.test.js +243 -0
- package/vendor/opencli/dist/clis/paperreview/feedback.d.ts +1 -0
- package/vendor/opencli/dist/clis/paperreview/feedback.js +52 -0
- package/vendor/opencli/dist/clis/paperreview/review.d.ts +1 -0
- package/vendor/opencli/dist/clis/paperreview/review.js +37 -0
- package/vendor/opencli/dist/clis/paperreview/submit.d.ts +1 -0
- package/vendor/opencli/dist/clis/paperreview/submit.js +85 -0
- package/vendor/opencli/dist/clis/paperreview/utils.d.ts +46 -0
- package/vendor/opencli/dist/clis/paperreview/utils.js +197 -0
- package/vendor/opencli/dist/clis/paperreview/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/paperreview/utils.test.js +49 -0
- package/vendor/opencli/dist/clis/pixiv/detail.yaml +49 -0
- package/vendor/opencli/dist/clis/pixiv/download.d.ts +7 -0
- package/vendor/opencli/dist/clis/pixiv/download.js +78 -0
- package/vendor/opencli/dist/clis/pixiv/download.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/pixiv/download.test.js +87 -0
- package/vendor/opencli/dist/clis/pixiv/illusts.d.ts +8 -0
- package/vendor/opencli/dist/clis/pixiv/illusts.js +65 -0
- package/vendor/opencli/dist/clis/pixiv/illusts.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/pixiv/illusts.test.js +99 -0
- package/vendor/opencli/dist/clis/pixiv/ranking.yaml +53 -0
- package/vendor/opencli/dist/clis/pixiv/search.d.ts +6 -0
- package/vendor/opencli/dist/clis/pixiv/search.js +43 -0
- package/vendor/opencli/dist/clis/pixiv/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/pixiv/search.test.js +83 -0
- package/vendor/opencli/dist/clis/pixiv/test-utils.d.ts +12 -0
- package/vendor/opencli/dist/clis/pixiv/test-utils.js +23 -0
- package/vendor/opencli/dist/clis/pixiv/user.yaml +46 -0
- package/vendor/opencli/dist/clis/pixiv/utils.d.ts +27 -0
- package/vendor/opencli/dist/clis/pixiv/utils.js +49 -0
- package/vendor/opencli/dist/clis/producthunt/browse.d.ts +1 -0
- package/vendor/opencli/dist/clis/producthunt/browse.js +99 -0
- package/vendor/opencli/dist/clis/producthunt/hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/producthunt/hot.js +110 -0
- package/vendor/opencli/dist/clis/producthunt/posts.d.ts +1 -0
- package/vendor/opencli/dist/clis/producthunt/posts.js +28 -0
- package/vendor/opencli/dist/clis/producthunt/today.d.ts +1 -0
- package/vendor/opencli/dist/clis/producthunt/today.js +35 -0
- package/vendor/opencli/dist/clis/producthunt/utils.d.ts +29 -0
- package/vendor/opencli/dist/clis/producthunt/utils.js +99 -0
- package/vendor/opencli/dist/clis/producthunt/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/producthunt/utils.test.js +64 -0
- package/vendor/opencli/dist/clis/reddit/comment.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/comment.js +57 -0
- package/vendor/opencli/dist/clis/reddit/frontpage.yaml +30 -0
- package/vendor/opencli/dist/clis/reddit/hot.yaml +47 -0
- package/vendor/opencli/dist/clis/reddit/popular.yaml +40 -0
- package/vendor/opencli/dist/clis/reddit/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/read.js +184 -0
- package/vendor/opencli/dist/clis/reddit/read.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/read.test.js +28 -0
- package/vendor/opencli/dist/clis/reddit/save.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/save.js +51 -0
- package/vendor/opencli/dist/clis/reddit/saved.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/saved.js +49 -0
- package/vendor/opencli/dist/clis/reddit/search.yaml +61 -0
- package/vendor/opencli/dist/clis/reddit/subreddit.yaml +50 -0
- package/vendor/opencli/dist/clis/reddit/subscribe.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/subscribe.js +50 -0
- package/vendor/opencli/dist/clis/reddit/upvote.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/upvote.js +64 -0
- package/vendor/opencli/dist/clis/reddit/upvoted.d.ts +1 -0
- package/vendor/opencli/dist/clis/reddit/upvoted.js +49 -0
- package/vendor/opencli/dist/clis/reddit/user-comments.yaml +46 -0
- package/vendor/opencli/dist/clis/reddit/user-posts.yaml +44 -0
- package/vendor/opencli/dist/clis/reddit/user.yaml +40 -0
- package/vendor/opencli/dist/clis/reuters/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/reuters/search.js +51 -0
- package/vendor/opencli/dist/clis/sinablog/article.d.ts +1 -0
- package/vendor/opencli/dist/clis/sinablog/article.js +14 -0
- package/vendor/opencli/dist/clis/sinablog/hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/sinablog/hot.js +14 -0
- package/vendor/opencli/dist/clis/sinablog/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/sinablog/search.js +51 -0
- package/vendor/opencli/dist/clis/sinablog/user.d.ts +1 -0
- package/vendor/opencli/dist/clis/sinablog/user.js +15 -0
- package/vendor/opencli/dist/clis/sinablog/utils.d.ts +7 -0
- package/vendor/opencli/dist/clis/sinablog/utils.js +186 -0
- package/vendor/opencli/dist/clis/sinafinance/news.d.ts +7 -0
- package/vendor/opencli/dist/clis/sinafinance/news.js +61 -0
- package/vendor/opencli/dist/clis/sinafinance/rolling-news.d.ts +4 -0
- package/vendor/opencli/dist/clis/sinafinance/rolling-news.js +40 -0
- package/vendor/opencli/dist/clis/sinafinance/stock-rank.d.ts +4 -0
- package/vendor/opencli/dist/clis/sinafinance/stock-rank.js +65 -0
- package/vendor/opencli/dist/clis/sinafinance/stock.d.ts +8 -0
- package/vendor/opencli/dist/clis/sinafinance/stock.js +117 -0
- package/vendor/opencli/dist/clis/smzdm/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/smzdm/search.js +54 -0
- package/vendor/opencli/dist/clis/spotify/spotify.d.ts +1 -0
- package/vendor/opencli/dist/clis/spotify/spotify.js +316 -0
- package/vendor/opencli/dist/clis/spotify/utils.d.ts +21 -0
- package/vendor/opencli/dist/clis/spotify/utils.js +66 -0
- package/vendor/opencli/dist/clis/spotify/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/spotify/utils.test.js +67 -0
- package/vendor/opencli/dist/clis/stackoverflow/bounties.yaml +29 -0
- package/vendor/opencli/dist/clis/stackoverflow/hot.yaml +28 -0
- package/vendor/opencli/dist/clis/stackoverflow/search.yaml +33 -0
- package/vendor/opencli/dist/clis/stackoverflow/unanswered.yaml +28 -0
- package/vendor/opencli/dist/clis/steam/top-sellers.yaml +29 -0
- package/vendor/opencli/dist/clis/substack/feed.d.ts +1 -0
- package/vendor/opencli/dist/clis/substack/feed.js +15 -0
- package/vendor/opencli/dist/clis/substack/publication.d.ts +1 -0
- package/vendor/opencli/dist/clis/substack/publication.js +15 -0
- package/vendor/opencli/dist/clis/substack/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/substack/search.js +78 -0
- package/vendor/opencli/dist/clis/substack/utils.d.ts +8 -0
- package/vendor/opencli/dist/clis/substack/utils.js +136 -0
- package/vendor/opencli/dist/clis/substack/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/substack/utils.test.js +44 -0
- package/vendor/opencli/dist/clis/tieba/commands.test.d.ts +4 -0
- package/vendor/opencli/dist/clis/tieba/commands.test.js +79 -0
- package/vendor/opencli/dist/clis/tieba/hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/tieba/hot.js +48 -0
- package/vendor/opencli/dist/clis/tieba/posts.d.ts +1 -0
- package/vendor/opencli/dist/clis/tieba/posts.js +85 -0
- package/vendor/opencli/dist/clis/tieba/read.d.ts +1 -0
- package/vendor/opencli/dist/clis/tieba/read.js +140 -0
- package/vendor/opencli/dist/clis/tieba/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/tieba/search.js +108 -0
- package/vendor/opencli/dist/clis/tieba/utils.d.ts +101 -0
- package/vendor/opencli/dist/clis/tieba/utils.js +240 -0
- package/vendor/opencli/dist/clis/tieba/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/tieba/utils.test.js +290 -0
- package/vendor/opencli/dist/clis/tiktok/comment.yaml +66 -0
- package/vendor/opencli/dist/clis/tiktok/explore.yaml +39 -0
- package/vendor/opencli/dist/clis/tiktok/follow.yaml +39 -0
- package/vendor/opencli/dist/clis/tiktok/following.yaml +46 -0
- package/vendor/opencli/dist/clis/tiktok/friends.yaml +47 -0
- package/vendor/opencli/dist/clis/tiktok/like.yaml +38 -0
- package/vendor/opencli/dist/clis/tiktok/live.yaml +51 -0
- package/vendor/opencli/dist/clis/tiktok/notifications.yaml +52 -0
- package/vendor/opencli/dist/clis/tiktok/profile.yaml +45 -0
- package/vendor/opencli/dist/clis/tiktok/save.yaml +34 -0
- package/vendor/opencli/dist/clis/tiktok/search.yaml +47 -0
- package/vendor/opencli/dist/clis/tiktok/unfollow.yaml +44 -0
- package/vendor/opencli/dist/clis/tiktok/unlike.yaml +38 -0
- package/vendor/opencli/dist/clis/tiktok/unsave.yaml +36 -0
- package/vendor/opencli/dist/clis/tiktok/user.yaml +44 -0
- package/vendor/opencli/dist/clis/twitter/accept.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/accept.js +203 -0
- package/vendor/opencli/dist/clis/twitter/article.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/article.js +163 -0
- package/vendor/opencli/dist/clis/twitter/block.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/block.js +89 -0
- package/vendor/opencli/dist/clis/twitter/bookmark.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/bookmark.js +64 -0
- package/vendor/opencli/dist/clis/twitter/bookmarks.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/bookmarks.js +172 -0
- package/vendor/opencli/dist/clis/twitter/delete.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/delete.js +73 -0
- package/vendor/opencli/dist/clis/twitter/download.d.ts +8 -0
- package/vendor/opencli/dist/clis/twitter/download.js +110 -0
- package/vendor/opencli/dist/clis/twitter/follow.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/follow.js +66 -0
- package/vendor/opencli/dist/clis/twitter/followers.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/followers.js +102 -0
- package/vendor/opencli/dist/clis/twitter/following.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/following.js +95 -0
- package/vendor/opencli/dist/clis/twitter/hide-reply.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/hide-reply.js +67 -0
- package/vendor/opencli/dist/clis/twitter/like.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/like.js +69 -0
- package/vendor/opencli/dist/clis/twitter/likes.d.ts +24 -0
- package/vendor/opencli/dist/clis/twitter/likes.js +217 -0
- package/vendor/opencli/dist/clis/twitter/likes.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/likes.test.js +85 -0
- package/vendor/opencli/dist/clis/twitter/notifications.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/notifications.js +127 -0
- package/vendor/opencli/dist/clis/twitter/post.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/post.js +98 -0
- package/vendor/opencli/dist/clis/twitter/post.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/post.test.js +116 -0
- package/vendor/opencli/dist/clis/twitter/profile.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/profile.js +103 -0
- package/vendor/opencli/dist/clis/twitter/reply-dm.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/reply-dm.js +182 -0
- package/vendor/opencli/dist/clis/twitter/reply.d.ts +13 -0
- package/vendor/opencli/dist/clis/twitter/reply.js +280 -0
- package/vendor/opencli/dist/clis/twitter/reply.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/reply.test.js +151 -0
- package/vendor/opencli/dist/clis/twitter/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/search.js +169 -0
- package/vendor/opencli/dist/clis/twitter/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/search.test.js +236 -0
- package/vendor/opencli/dist/clis/twitter/shared.d.ts +6 -0
- package/vendor/opencli/dist/clis/twitter/shared.js +35 -0
- package/vendor/opencli/dist/clis/twitter/thread.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/thread.js +151 -0
- package/vendor/opencli/dist/clis/twitter/timeline.d.ts +24 -0
- package/vendor/opencli/dist/clis/twitter/timeline.js +204 -0
- package/vendor/opencli/dist/clis/twitter/timeline.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/timeline.test.js +102 -0
- package/vendor/opencli/dist/clis/twitter/trending.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/trending.js +60 -0
- package/vendor/opencli/dist/clis/twitter/unblock.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/unblock.js +72 -0
- package/vendor/opencli/dist/clis/twitter/unbookmark.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/unbookmark.js +63 -0
- package/vendor/opencli/dist/clis/twitter/unfollow.d.ts +1 -0
- package/vendor/opencli/dist/clis/twitter/unfollow.js +72 -0
- package/vendor/opencli/dist/clis/v2ex/daily.d.ts +1 -0
- package/vendor/opencli/dist/clis/v2ex/daily.js +98 -0
- package/vendor/opencli/dist/clis/v2ex/hot.yaml +28 -0
- package/vendor/opencli/dist/clis/v2ex/latest.yaml +28 -0
- package/vendor/opencli/dist/clis/v2ex/me.d.ts +1 -0
- package/vendor/opencli/dist/clis/v2ex/me.js +99 -0
- package/vendor/opencli/dist/clis/v2ex/member.yaml +29 -0
- package/vendor/opencli/dist/clis/v2ex/node.yaml +34 -0
- package/vendor/opencli/dist/clis/v2ex/nodes.yaml +31 -0
- package/vendor/opencli/dist/clis/v2ex/notifications.d.ts +1 -0
- package/vendor/opencli/dist/clis/v2ex/notifications.js +71 -0
- package/vendor/opencli/dist/clis/v2ex/replies.yaml +32 -0
- package/vendor/opencli/dist/clis/v2ex/topic.yaml +33 -0
- package/vendor/opencli/dist/clis/v2ex/user.yaml +34 -0
- package/vendor/opencli/dist/clis/web/read.d.ts +16 -0
- package/vendor/opencli/dist/clis/web/read.js +202 -0
- package/vendor/opencli/dist/clis/weibo/comments.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/comments.js +53 -0
- package/vendor/opencli/dist/clis/weibo/feed.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/feed.js +56 -0
- package/vendor/opencli/dist/clis/weibo/hot.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/hot.js +39 -0
- package/vendor/opencli/dist/clis/weibo/me.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/me.js +76 -0
- package/vendor/opencli/dist/clis/weibo/post.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/post.js +75 -0
- package/vendor/opencli/dist/clis/weibo/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/search.js +73 -0
- package/vendor/opencli/dist/clis/weibo/user.d.ts +1 -0
- package/vendor/opencli/dist/clis/weibo/user.js +63 -0
- package/vendor/opencli/dist/clis/weibo/utils.d.ts +6 -0
- package/vendor/opencli/dist/clis/weibo/utils.js +30 -0
- package/vendor/opencli/dist/clis/weixin/download.d.ts +38 -0
- package/vendor/opencli/dist/clis/weixin/download.js +321 -0
- package/vendor/opencli/dist/clis/weread/book.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/book.js +219 -0
- package/vendor/opencli/dist/clis/weread/commands.test.d.ts +3 -0
- package/vendor/opencli/dist/clis/weread/commands.test.js +374 -0
- package/vendor/opencli/dist/clis/weread/highlights.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/highlights.js +23 -0
- package/vendor/opencli/dist/clis/weread/notebooks.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/notebooks.js +21 -0
- package/vendor/opencli/dist/clis/weread/notes.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/notes.js +29 -0
- package/vendor/opencli/dist/clis/weread/private-api-regression.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/private-api-regression.test.js +369 -0
- package/vendor/opencli/dist/clis/weread/ranking.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/ranking.js +28 -0
- package/vendor/opencli/dist/clis/weread/search-regression.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/search-regression.test.js +407 -0
- package/vendor/opencli/dist/clis/weread/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/search.js +162 -0
- package/vendor/opencli/dist/clis/weread/shelf.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/shelf.js +65 -0
- package/vendor/opencli/dist/clis/weread/utils.d.ts +76 -0
- package/vendor/opencli/dist/clis/weread/utils.js +321 -0
- package/vendor/opencli/dist/clis/weread/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/weread/utils.test.js +128 -0
- package/vendor/opencli/dist/clis/wikipedia/random.d.ts +1 -0
- package/vendor/opencli/dist/clis/wikipedia/random.js +19 -0
- package/vendor/opencli/dist/clis/wikipedia/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/wikipedia/search.js +30 -0
- package/vendor/opencli/dist/clis/wikipedia/summary.d.ts +1 -0
- package/vendor/opencli/dist/clis/wikipedia/summary.js +23 -0
- package/vendor/opencli/dist/clis/wikipedia/trending.d.ts +1 -0
- package/vendor/opencli/dist/clis/wikipedia/trending.js +35 -0
- package/vendor/opencli/dist/clis/wikipedia/utils.d.ts +36 -0
- package/vendor/opencli/dist/clis/wikipedia/utils.js +31 -0
- package/vendor/opencli/dist/clis/xianyu/chat.d.ts +7 -0
- package/vendor/opencli/dist/clis/xianyu/chat.js +146 -0
- package/vendor/opencli/dist/clis/xianyu/chat.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xianyu/chat.test.js +15 -0
- package/vendor/opencli/dist/clis/xianyu/item.d.ts +7 -0
- package/vendor/opencli/dist/clis/xianyu/item.js +152 -0
- package/vendor/opencli/dist/clis/xianyu/item.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xianyu/item.test.js +56 -0
- package/vendor/opencli/dist/clis/xianyu/search.d.ts +10 -0
- package/vendor/opencli/dist/clis/xianyu/search.js +134 -0
- package/vendor/opencli/dist/clis/xianyu/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xianyu/search.test.js +17 -0
- package/vendor/opencli/dist/clis/xianyu/utils.d.ts +1 -0
- package/vendor/opencli/dist/clis/xianyu/utils.js +8 -0
- package/vendor/opencli/dist/clis/xiaoe/catalog.yaml +129 -0
- package/vendor/opencli/dist/clis/xiaoe/content.yaml +43 -0
- package/vendor/opencli/dist/clis/xiaoe/courses.yaml +73 -0
- package/vendor/opencli/dist/clis/xiaoe/detail.yaml +39 -0
- package/vendor/opencli/dist/clis/xiaoe/play-url.yaml +124 -0
- package/vendor/opencli/dist/clis/xiaohongshu/comments.d.ts +8 -0
- package/vendor/opencli/dist/clis/xiaohongshu/comments.js +133 -0
- package/vendor/opencli/dist/clis/xiaohongshu/comments.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/comments.test.js +139 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-note-detail.d.ts +84 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-note-detail.js +341 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-note-detail.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-note-detail.test.js +259 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes-summary.d.ts +28 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes-summary.js +92 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes-summary.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes-summary.test.js +49 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes.d.ts +24 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes.js +227 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-notes.test.js +192 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-profile.d.ts +10 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-profile.js +53 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-stats.d.ts +10 -0
- package/vendor/opencli/dist/clis/xiaohongshu/creator-stats.js +73 -0
- package/vendor/opencli/dist/clis/xiaohongshu/download.d.ts +10 -0
- package/vendor/opencli/dist/clis/xiaohongshu/download.js +167 -0
- package/vendor/opencli/dist/clis/xiaohongshu/download.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/download.test.js +73 -0
- package/vendor/opencli/dist/clis/xiaohongshu/feed.yaml +31 -0
- package/vendor/opencli/dist/clis/xiaohongshu/note-helpers.d.ts +12 -0
- package/vendor/opencli/dist/clis/xiaohongshu/note-helpers.js +23 -0
- package/vendor/opencli/dist/clis/xiaohongshu/note.d.ts +7 -0
- package/vendor/opencli/dist/clis/xiaohongshu/note.js +87 -0
- package/vendor/opencli/dist/clis/xiaohongshu/note.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/note.test.js +183 -0
- package/vendor/opencli/dist/clis/xiaohongshu/notifications.yaml +37 -0
- package/vendor/opencli/dist/clis/xiaohongshu/publish.d.ts +18 -0
- package/vendor/opencli/dist/clis/xiaohongshu/publish.js +531 -0
- package/vendor/opencli/dist/clis/xiaohongshu/publish.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/publish.test.js +195 -0
- package/vendor/opencli/dist/clis/xiaohongshu/search.d.ts +15 -0
- package/vendor/opencli/dist/clis/xiaohongshu/search.js +131 -0
- package/vendor/opencli/dist/clis/xiaohongshu/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/search.test.js +160 -0
- package/vendor/opencli/dist/clis/xiaohongshu/user-helpers.d.ts +16 -0
- package/vendor/opencli/dist/clis/xiaohongshu/user-helpers.js +69 -0
- package/vendor/opencli/dist/clis/xiaohongshu/user-helpers.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/user-helpers.test.js +99 -0
- package/vendor/opencli/dist/clis/xiaohongshu/user.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaohongshu/user.js +56 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/episode.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/episode.js +28 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/podcast-episodes.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/podcast-episodes.js +36 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/podcast.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/podcast.js +27 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/utils.d.ts +16 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/utils.js +55 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xiaoyuzhou/utils.test.js +99 -0
- package/vendor/opencli/dist/clis/xueqiu/comments.d.ts +118 -0
- package/vendor/opencli/dist/clis/xueqiu/comments.js +354 -0
- package/vendor/opencli/dist/clis/xueqiu/comments.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xueqiu/comments.test.js +696 -0
- package/vendor/opencli/dist/clis/xueqiu/danjuan-utils.d.ts +55 -0
- package/vendor/opencli/dist/clis/xueqiu/danjuan-utils.js +126 -0
- package/vendor/opencli/dist/clis/xueqiu/danjuan-utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/xueqiu/danjuan-utils.test.js +41 -0
- package/vendor/opencli/dist/clis/xueqiu/earnings-date.yaml +69 -0
- package/vendor/opencli/dist/clis/xueqiu/feed.yaml +53 -0
- package/vendor/opencli/dist/clis/xueqiu/fund-holdings.d.ts +1 -0
- package/vendor/opencli/dist/clis/xueqiu/fund-holdings.js +28 -0
- package/vendor/opencli/dist/clis/xueqiu/fund-snapshot.d.ts +1 -0
- package/vendor/opencli/dist/clis/xueqiu/fund-snapshot.js +25 -0
- package/vendor/opencli/dist/clis/xueqiu/hot-stock.yaml +49 -0
- package/vendor/opencli/dist/clis/xueqiu/hot.yaml +46 -0
- package/vendor/opencli/dist/clis/xueqiu/search.yaml +55 -0
- package/vendor/opencli/dist/clis/xueqiu/stock.yaml +69 -0
- package/vendor/opencli/dist/clis/xueqiu/watchlist.yaml +46 -0
- package/vendor/opencli/dist/clis/yahoo-finance/quote.d.ts +1 -0
- package/vendor/opencli/dist/clis/yahoo-finance/quote.js +72 -0
- package/vendor/opencli/dist/clis/yollomi/background.d.ts +4 -0
- package/vendor/opencli/dist/clis/yollomi/background.js +45 -0
- package/vendor/opencli/dist/clis/yollomi/edit.d.ts +5 -0
- package/vendor/opencli/dist/clis/yollomi/edit.js +56 -0
- package/vendor/opencli/dist/clis/yollomi/face-swap.d.ts +5 -0
- package/vendor/opencli/dist/clis/yollomi/face-swap.js +43 -0
- package/vendor/opencli/dist/clis/yollomi/generate.d.ts +9 -0
- package/vendor/opencli/dist/clis/yollomi/generate.js +100 -0
- package/vendor/opencli/dist/clis/yollomi/models.d.ts +1 -0
- package/vendor/opencli/dist/clis/yollomi/models.js +33 -0
- package/vendor/opencli/dist/clis/yollomi/object-remover.d.ts +4 -0
- package/vendor/opencli/dist/clis/yollomi/object-remover.js +42 -0
- package/vendor/opencli/dist/clis/yollomi/remove-bg.d.ts +4 -0
- package/vendor/opencli/dist/clis/yollomi/remove-bg.js +38 -0
- package/vendor/opencli/dist/clis/yollomi/restore.d.ts +4 -0
- package/vendor/opencli/dist/clis/yollomi/restore.js +38 -0
- package/vendor/opencli/dist/clis/yollomi/try-on.d.ts +4 -0
- package/vendor/opencli/dist/clis/yollomi/try-on.js +46 -0
- package/vendor/opencli/dist/clis/yollomi/upload.d.ts +7 -0
- package/vendor/opencli/dist/clis/yollomi/upload.js +71 -0
- package/vendor/opencli/dist/clis/yollomi/upscale.d.ts +4 -0
- package/vendor/opencli/dist/clis/yollomi/upscale.js +53 -0
- package/vendor/opencli/dist/clis/yollomi/utils.d.ts +45 -0
- package/vendor/opencli/dist/clis/yollomi/utils.js +180 -0
- package/vendor/opencli/dist/clis/yollomi/video.d.ts +5 -0
- package/vendor/opencli/dist/clis/yollomi/video.js +56 -0
- package/vendor/opencli/dist/clis/youtube/channel.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/channel.js +150 -0
- package/vendor/opencli/dist/clis/youtube/comments.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/comments.js +95 -0
- package/vendor/opencli/dist/clis/youtube/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/search.js +99 -0
- package/vendor/opencli/dist/clis/youtube/transcript-group.d.ts +44 -0
- package/vendor/opencli/dist/clis/youtube/transcript-group.js +226 -0
- package/vendor/opencli/dist/clis/youtube/transcript-group.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/transcript-group.test.js +99 -0
- package/vendor/opencli/dist/clis/youtube/transcript.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/transcript.js +263 -0
- package/vendor/opencli/dist/clis/youtube/utils.d.ts +17 -0
- package/vendor/opencli/dist/clis/youtube/utils.js +92 -0
- package/vendor/opencli/dist/clis/youtube/utils.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/utils.test.js +37 -0
- package/vendor/opencli/dist/clis/youtube/video.d.ts +1 -0
- package/vendor/opencli/dist/clis/youtube/video.js +116 -0
- package/vendor/opencli/dist/clis/yuanbao/ask.d.ts +21 -0
- package/vendor/opencli/dist/clis/yuanbao/ask.js +427 -0
- package/vendor/opencli/dist/clis/yuanbao/ask.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/yuanbao/ask.test.js +124 -0
- package/vendor/opencli/dist/clis/yuanbao/new.d.ts +1 -0
- package/vendor/opencli/dist/clis/yuanbao/new.js +70 -0
- package/vendor/opencli/dist/clis/yuanbao/new.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/yuanbao/new.test.js +30 -0
- package/vendor/opencli/dist/clis/yuanbao/shared.d.ts +13 -0
- package/vendor/opencli/dist/clis/yuanbao/shared.js +49 -0
- package/vendor/opencli/dist/clis/zhihu/download.d.ts +7 -0
- package/vendor/opencli/dist/clis/zhihu/download.js +79 -0
- package/vendor/opencli/dist/clis/zhihu/download.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/zhihu/download.test.js +12 -0
- package/vendor/opencli/dist/clis/zhihu/hot.yaml +46 -0
- package/vendor/opencli/dist/clis/zhihu/question.d.ts +1 -0
- package/vendor/opencli/dist/clis/zhihu/question.js +53 -0
- package/vendor/opencli/dist/clis/zhihu/question.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/zhihu/question.test.js +72 -0
- package/vendor/opencli/dist/clis/zhihu/search.yaml +59 -0
- package/vendor/opencli/dist/clis/zsxq/dynamics.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/dynamics.js +47 -0
- package/vendor/opencli/dist/clis/zsxq/groups.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/groups.js +32 -0
- package/vendor/opencli/dist/clis/zsxq/search.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/search.js +43 -0
- package/vendor/opencli/dist/clis/zsxq/search.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/search.test.js +24 -0
- package/vendor/opencli/dist/clis/zsxq/topic.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/topic.js +47 -0
- package/vendor/opencli/dist/clis/zsxq/topic.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/topic.test.js +29 -0
- package/vendor/opencli/dist/clis/zsxq/topics.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/topics.js +25 -0
- package/vendor/opencli/dist/clis/zsxq/topics.test.d.ts +1 -0
- package/vendor/opencli/dist/clis/zsxq/topics.test.js +24 -0
- package/vendor/opencli/dist/clis/zsxq/utils.d.ts +97 -0
- package/vendor/opencli/dist/clis/zsxq/utils.js +230 -0
- package/vendor/opencli/dist/commanderAdapter.d.ts +22 -0
- package/vendor/opencli/dist/commanderAdapter.js +301 -0
- package/vendor/opencli/dist/commanderAdapter.test.d.ts +1 -0
- package/vendor/opencli/dist/commanderAdapter.test.js +244 -0
- package/vendor/opencli/dist/commands/daemon.d.ts +9 -0
- package/vendor/opencli/dist/commands/daemon.js +85 -0
- package/vendor/opencli/dist/commands/daemon.test.d.ts +1 -0
- package/vendor/opencli/dist/commands/daemon.test.js +160 -0
- package/vendor/opencli/dist/completion.d.ts +21 -0
- package/vendor/opencli/dist/completion.js +120 -0
- package/vendor/opencli/dist/completion.test.d.ts +1 -0
- package/vendor/opencli/dist/completion.test.js +23 -0
- package/vendor/opencli/dist/constants.d.ts +17 -0
- package/vendor/opencli/dist/constants.js +34 -0
- package/vendor/opencli/dist/daemon.d.ts +21 -0
- package/vendor/opencli/dist/daemon.js +303 -0
- package/vendor/opencli/dist/daemon.test.d.ts +1 -0
- package/vendor/opencli/dist/daemon.test.js +65 -0
- package/vendor/opencli/dist/discovery.d.ts +31 -0
- package/vendor/opencli/dist/discovery.js +330 -0
- package/vendor/opencli/dist/doctor.d.ts +38 -0
- package/vendor/opencli/dist/doctor.js +126 -0
- package/vendor/opencli/dist/doctor.test.d.ts +1 -0
- package/vendor/opencli/dist/doctor.test.js +91 -0
- package/vendor/opencli/dist/download/article-download.d.ts +59 -0
- package/vendor/opencli/dist/download/article-download.js +178 -0
- package/vendor/opencli/dist/download/index.d.ts +71 -0
- package/vendor/opencli/dist/download/index.js +345 -0
- package/vendor/opencli/dist/download/index.test.d.ts +1 -0
- package/vendor/opencli/dist/download/index.test.js +118 -0
- package/vendor/opencli/dist/download/media-download.d.ts +49 -0
- package/vendor/opencli/dist/download/media-download.js +114 -0
- package/vendor/opencli/dist/download/progress.d.ts +36 -0
- package/vendor/opencli/dist/download/progress.js +111 -0
- package/vendor/opencli/dist/electron-apps.d.ts +31 -0
- package/vendor/opencli/dist/electron-apps.js +71 -0
- package/vendor/opencli/dist/electron-apps.test.d.ts +1 -0
- package/vendor/opencli/dist/electron-apps.test.js +43 -0
- package/vendor/opencli/dist/engine.test.d.ts +1 -0
- package/vendor/opencli/dist/engine.test.js +297 -0
- package/vendor/opencli/dist/errors.d.ts +76 -0
- package/vendor/opencli/dist/errors.js +119 -0
- package/vendor/opencli/dist/errors.test.d.ts +1 -0
- package/vendor/opencli/dist/errors.test.js +59 -0
- package/vendor/opencli/dist/execution.d.ts +14 -0
- package/vendor/opencli/dist/execution.js +209 -0
- package/vendor/opencli/dist/execution.test.d.ts +1 -0
- package/vendor/opencli/dist/execution.test.js +40 -0
- package/vendor/opencli/dist/explore.d.ts +101 -0
- package/vendor/opencli/dist/explore.js +379 -0
- package/vendor/opencli/dist/extension-manifest-regression.test.d.ts +1 -0
- package/vendor/opencli/dist/extension-manifest-regression.test.js +13 -0
- package/vendor/opencli/dist/external-clis.yaml +56 -0
- package/vendor/opencli/dist/external.d.ts +40 -0
- package/vendor/opencli/dist/external.js +209 -0
- package/vendor/opencli/dist/external.test.d.ts +1 -0
- package/vendor/opencli/dist/external.test.js +68 -0
- package/vendor/opencli/dist/generate.d.ts +41 -0
- package/vendor/opencli/dist/generate.js +121 -0
- package/vendor/opencli/dist/hooks.d.ts +46 -0
- package/vendor/opencli/dist/hooks.js +58 -0
- package/vendor/opencli/dist/hooks.test.d.ts +4 -0
- package/vendor/opencli/dist/hooks.test.js +92 -0
- package/vendor/opencli/dist/idle-manager.d.ts +19 -0
- package/vendor/opencli/dist/idle-manager.js +54 -0
- package/vendor/opencli/dist/interceptor.d.ts +42 -0
- package/vendor/opencli/dist/interceptor.js +186 -0
- package/vendor/opencli/dist/interceptor.test.d.ts +4 -0
- package/vendor/opencli/dist/interceptor.test.js +81 -0
- package/vendor/opencli/dist/launcher.d.ts +40 -0
- package/vendor/opencli/dist/launcher.js +208 -0
- package/vendor/opencli/dist/launcher.test.d.ts +1 -0
- package/vendor/opencli/dist/launcher.test.js +138 -0
- package/vendor/opencli/dist/logger.d.ts +22 -0
- package/vendor/opencli/dist/logger.js +47 -0
- package/vendor/opencli/dist/main.d.ts +5 -0
- package/vendor/opencli/dist/main.js +60 -0
- package/vendor/opencli/dist/node-network.d.ts +10 -0
- package/vendor/opencli/dist/node-network.js +174 -0
- package/vendor/opencli/dist/node-network.test.d.ts +1 -0
- package/vendor/opencli/dist/node-network.test.js +55 -0
- package/vendor/opencli/dist/output.d.ts +14 -0
- package/vendor/opencli/dist/output.js +147 -0
- package/vendor/opencli/dist/output.test.d.ts +1 -0
- package/vendor/opencli/dist/output.test.js +62 -0
- package/vendor/opencli/dist/pipeline/executor.d.ts +11 -0
- package/vendor/opencli/dist/pipeline/executor.js +93 -0
- package/vendor/opencli/dist/pipeline/executor.test.d.ts +4 -0
- package/vendor/opencli/dist/pipeline/executor.test.js +173 -0
- package/vendor/opencli/dist/pipeline/index.d.ts +5 -0
- package/vendor/opencli/dist/pipeline/index.js +5 -0
- package/vendor/opencli/dist/pipeline/registry.d.ts +19 -0
- package/vendor/opencli/dist/pipeline/registry.js +43 -0
- package/vendor/opencli/dist/pipeline/steps/browser.d.ts +12 -0
- package/vendor/opencli/dist/pipeline/steps/browser.js +76 -0
- package/vendor/opencli/dist/pipeline/steps/download.d.ts +34 -0
- package/vendor/opencli/dist/pipeline/steps/download.js +263 -0
- package/vendor/opencli/dist/pipeline/steps/download.test.d.ts +1 -0
- package/vendor/opencli/dist/pipeline/steps/download.test.js +100 -0
- package/vendor/opencli/dist/pipeline/steps/fetch.d.ts +5 -0
- package/vendor/opencli/dist/pipeline/steps/fetch.js +142 -0
- package/vendor/opencli/dist/pipeline/steps/fetch.test.d.ts +1 -0
- package/vendor/opencli/dist/pipeline/steps/fetch.test.js +123 -0
- package/vendor/opencli/dist/pipeline/steps/intercept.d.ts +5 -0
- package/vendor/opencli/dist/pipeline/steps/intercept.js +50 -0
- package/vendor/opencli/dist/pipeline/steps/tap.d.ts +12 -0
- package/vendor/opencli/dist/pipeline/steps/tap.js +92 -0
- package/vendor/opencli/dist/pipeline/steps/transform.d.ts +9 -0
- package/vendor/opencli/dist/pipeline/steps/transform.js +70 -0
- package/vendor/opencli/dist/pipeline/template.d.ts +16 -0
- package/vendor/opencli/dist/pipeline/template.js +276 -0
- package/vendor/opencli/dist/pipeline/template.test.d.ts +4 -0
- package/vendor/opencli/dist/pipeline/template.test.js +172 -0
- package/vendor/opencli/dist/pipeline/transform.test.d.ts +4 -0
- package/vendor/opencli/dist/pipeline/transform.test.js +119 -0
- package/vendor/opencli/dist/plugin-manifest.d.ts +70 -0
- package/vendor/opencli/dist/plugin-manifest.js +160 -0
- package/vendor/opencli/dist/plugin-manifest.test.d.ts +4 -0
- package/vendor/opencli/dist/plugin-manifest.test.js +179 -0
- package/vendor/opencli/dist/plugin-scaffold.d.ts +28 -0
- package/vendor/opencli/dist/plugin-scaffold.js +142 -0
- package/vendor/opencli/dist/plugin-scaffold.test.d.ts +4 -0
- package/vendor/opencli/dist/plugin-scaffold.test.js +83 -0
- package/vendor/opencli/dist/plugin.d.ts +145 -0
- package/vendor/opencli/dist/plugin.js +1221 -0
- package/vendor/opencli/dist/plugin.test.d.ts +4 -0
- package/vendor/opencli/dist/plugin.test.js +1312 -0
- package/vendor/opencli/dist/record.d.ts +97 -0
- package/vendor/opencli/dist/record.js +694 -0
- package/vendor/opencli/dist/record.test.d.ts +1 -0
- package/vendor/opencli/dist/record.test.js +293 -0
- package/vendor/opencli/dist/registry-api.d.ts +13 -0
- package/vendor/opencli/dist/registry-api.js +10 -0
- package/vendor/opencli/dist/registry.d.ts +81 -0
- package/vendor/opencli/dist/registry.js +78 -0
- package/vendor/opencli/dist/registry.test.d.ts +4 -0
- package/vendor/opencli/dist/registry.test.js +113 -0
- package/vendor/opencli/dist/runtime-detect.d.ts +21 -0
- package/vendor/opencli/dist/runtime-detect.js +32 -0
- package/vendor/opencli/dist/runtime-detect.test.d.ts +1 -0
- package/vendor/opencli/dist/runtime-detect.test.js +27 -0
- package/vendor/opencli/dist/runtime.d.ts +36 -0
- package/vendor/opencli/dist/runtime.js +61 -0
- package/vendor/opencli/dist/scripts/framework.d.ts +4 -0
- package/vendor/opencli/dist/scripts/framework.js +21 -0
- package/vendor/opencli/dist/scripts/interact.d.ts +4 -0
- package/vendor/opencli/dist/scripts/interact.js +20 -0
- package/vendor/opencli/dist/scripts/store.d.ts +9 -0
- package/vendor/opencli/dist/scripts/store.js +44 -0
- package/vendor/opencli/dist/serialization.d.ts +38 -0
- package/vendor/opencli/dist/serialization.js +78 -0
- package/vendor/opencli/dist/serialization.test.d.ts +1 -0
- package/vendor/opencli/dist/serialization.test.js +39 -0
- package/vendor/opencli/dist/snapshotFormatter.d.ts +11 -0
- package/vendor/opencli/dist/snapshotFormatter.js +338 -0
- package/vendor/opencli/dist/snapshotFormatter.test.d.ts +7 -0
- package/vendor/opencli/dist/snapshotFormatter.test.js +521 -0
- package/vendor/opencli/dist/synthesize.d.ts +103 -0
- package/vendor/opencli/dist/synthesize.js +216 -0
- package/vendor/opencli/dist/tui.d.ts +29 -0
- package/vendor/opencli/dist/tui.js +192 -0
- package/vendor/opencli/dist/tui.test.d.ts +1 -0
- package/vendor/opencli/dist/tui.test.js +19 -0
- package/vendor/opencli/dist/types.d.ts +98 -0
- package/vendor/opencli/dist/types.js +7 -0
- package/vendor/opencli/dist/update-check.d.ts +22 -0
- package/vendor/opencli/dist/update-check.js +112 -0
- package/vendor/opencli/dist/utils.d.ts +11 -0
- package/vendor/opencli/dist/utils.js +33 -0
- package/vendor/opencli/dist/validate.d.ts +14 -0
- package/vendor/opencli/dist/validate.js +96 -0
- package/vendor/opencli/dist/verify.d.ts +26 -0
- package/vendor/opencli/dist/verify.js +67 -0
- package/vendor/opencli/dist/version.d.ts +4 -0
- package/vendor/opencli/dist/version.js +16 -0
- package/vendor/opencli/dist/weixin-download.test.d.ts +1 -0
- package/vendor/opencli/dist/weixin-download.test.js +44 -0
- package/vendor/opencli/dist/yaml-schema.d.ts +29 -0
- package/vendor/opencli/dist/yaml-schema.js +22 -0
|
@@ -0,0 +1,953 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CLI entry point: registers built-in commands and wires up Commander.
|
|
3
|
+
*
|
|
4
|
+
* Built-in commands are registered inline here (list, validate, explore, etc.).
|
|
5
|
+
* Dynamic adapter commands are registered via commanderAdapter.ts.
|
|
6
|
+
*/
|
|
7
|
+
import { Command } from 'commander';
|
|
8
|
+
import chalk from 'chalk';
|
|
9
|
+
import { fullName, getRegistry, strategyLabel } from './registry.js';
|
|
10
|
+
import { serializeCommand, formatArgSummary } from './serialization.js';
|
|
11
|
+
import { render as renderOutput } from './output.js';
|
|
12
|
+
import { getBrowserFactory, browserSession } from './runtime.js';
|
|
13
|
+
import { PKG_VERSION } from './version.js';
|
|
14
|
+
import { printCompletionScript } from './completion.js';
|
|
15
|
+
import { loadExternalClis, executeExternalCli, installExternalCli, registerExternalCli, isBinaryInstalled } from './external.js';
|
|
16
|
+
import { registerAllCommands } from './commanderAdapter.js';
|
|
17
|
+
import { EXIT_CODES, getErrorMessage } from './errors.js';
|
|
18
|
+
import { daemonStatus, daemonStop, daemonRestart } from './commands/daemon.js';
|
|
19
|
+
/** Create a browser page for operate commands. Uses 'operate' workspace for session persistence. */
|
|
20
|
+
async function getOperatePage() {
|
|
21
|
+
const { BrowserBridge } = await import('./browser/index.js');
|
|
22
|
+
const bridge = new BrowserBridge();
|
|
23
|
+
return bridge.connect({ timeout: 30, workspace: 'operate:default' });
|
|
24
|
+
}
|
|
25
|
+
function applyVerbose(opts) {
|
|
26
|
+
if (opts.verbose)
|
|
27
|
+
process.env.OPENCLI_VERBOSE = '1';
|
|
28
|
+
}
|
|
29
|
+
export function createProgram(BUILTIN_CLIS, USER_CLIS) {
|
|
30
|
+
const program = new Command();
|
|
31
|
+
// enablePositionalOptions: prevents parent from consuming flags meant for subcommands;
|
|
32
|
+
// prerequisite for passThroughOptions to forward --help/--version to external binaries
|
|
33
|
+
program
|
|
34
|
+
.name('opencli')
|
|
35
|
+
.description('Make any website your CLI. Zero setup. AI-powered.')
|
|
36
|
+
.version(PKG_VERSION)
|
|
37
|
+
.enablePositionalOptions();
|
|
38
|
+
// ── Built-in: list ────────────────────────────────────────────────────────
|
|
39
|
+
program
|
|
40
|
+
.command('list')
|
|
41
|
+
.description('List all available CLI commands')
|
|
42
|
+
.option('-f, --format <fmt>', 'Output format: table, json, yaml, md, csv', 'table')
|
|
43
|
+
.option('--json', 'JSON output (deprecated)')
|
|
44
|
+
.action((opts) => {
|
|
45
|
+
const registry = getRegistry();
|
|
46
|
+
const commands = [...new Set(registry.values())].sort((a, b) => fullName(a).localeCompare(fullName(b)));
|
|
47
|
+
const fmt = opts.json && opts.format === 'table' ? 'json' : opts.format;
|
|
48
|
+
const isStructured = fmt === 'json' || fmt === 'yaml';
|
|
49
|
+
if (fmt !== 'table') {
|
|
50
|
+
const rows = isStructured
|
|
51
|
+
? commands.map(serializeCommand)
|
|
52
|
+
: commands.map(c => ({
|
|
53
|
+
command: fullName(c),
|
|
54
|
+
site: c.site,
|
|
55
|
+
name: c.name,
|
|
56
|
+
aliases: c.aliases?.join(', ') ?? '',
|
|
57
|
+
description: c.description,
|
|
58
|
+
strategy: strategyLabel(c),
|
|
59
|
+
browser: !!c.browser,
|
|
60
|
+
args: formatArgSummary(c.args),
|
|
61
|
+
}));
|
|
62
|
+
renderOutput(rows, {
|
|
63
|
+
fmt,
|
|
64
|
+
columns: ['command', 'site', 'name', 'aliases', 'description', 'strategy', 'browser', 'args',
|
|
65
|
+
...(isStructured ? ['columns', 'domain'] : [])],
|
|
66
|
+
title: 'opencli/list',
|
|
67
|
+
source: 'opencli list',
|
|
68
|
+
});
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
// Table (default) — grouped by site
|
|
72
|
+
const sites = new Map();
|
|
73
|
+
for (const cmd of commands) {
|
|
74
|
+
const g = sites.get(cmd.site) ?? [];
|
|
75
|
+
g.push(cmd);
|
|
76
|
+
sites.set(cmd.site, g);
|
|
77
|
+
}
|
|
78
|
+
console.log();
|
|
79
|
+
console.log(chalk.bold(' opencli') + chalk.dim(' — available commands'));
|
|
80
|
+
console.log();
|
|
81
|
+
for (const [site, cmds] of sites) {
|
|
82
|
+
console.log(chalk.bold.cyan(` ${site}`));
|
|
83
|
+
for (const cmd of cmds) {
|
|
84
|
+
const label = strategyLabel(cmd);
|
|
85
|
+
const tag = label === 'public'
|
|
86
|
+
? chalk.green('[public]')
|
|
87
|
+
: chalk.yellow(`[${label}]`);
|
|
88
|
+
const aliases = cmd.aliases?.length ? chalk.dim(` (aliases: ${cmd.aliases.join(', ')})`) : '';
|
|
89
|
+
console.log(` ${cmd.name} ${tag}${aliases}${cmd.description ? chalk.dim(` — ${cmd.description}`) : ''}`);
|
|
90
|
+
}
|
|
91
|
+
console.log();
|
|
92
|
+
}
|
|
93
|
+
const externalClis = loadExternalClis();
|
|
94
|
+
if (externalClis.length > 0) {
|
|
95
|
+
console.log(chalk.bold.cyan(' external CLIs'));
|
|
96
|
+
for (const ext of externalClis) {
|
|
97
|
+
const isInstalled = isBinaryInstalled(ext.binary);
|
|
98
|
+
const tag = isInstalled ? chalk.green('[installed]') : chalk.yellow('[auto-install]');
|
|
99
|
+
console.log(` ${ext.name} ${tag}${ext.description ? chalk.dim(` — ${ext.description}`) : ''}`);
|
|
100
|
+
}
|
|
101
|
+
console.log();
|
|
102
|
+
}
|
|
103
|
+
console.log(chalk.dim(` ${commands.length} built-in commands across ${sites.size} sites, ${externalClis.length} external CLIs`));
|
|
104
|
+
console.log();
|
|
105
|
+
});
|
|
106
|
+
// ── Built-in: validate / verify ───────────────────────────────────────────
|
|
107
|
+
program
|
|
108
|
+
.command('validate')
|
|
109
|
+
.description('Validate CLI definitions')
|
|
110
|
+
.argument('[target]', 'site or site/name')
|
|
111
|
+
.action(async (target) => {
|
|
112
|
+
const { validateClisWithTarget, renderValidationReport } = await import('./validate.js');
|
|
113
|
+
console.log(renderValidationReport(validateClisWithTarget([BUILTIN_CLIS, USER_CLIS], target)));
|
|
114
|
+
});
|
|
115
|
+
program
|
|
116
|
+
.command('verify')
|
|
117
|
+
.description('Validate + smoke test')
|
|
118
|
+
.argument('[target]')
|
|
119
|
+
.option('--smoke', 'Run smoke tests', false)
|
|
120
|
+
.action(async (target, opts) => {
|
|
121
|
+
const { verifyClis, renderVerifyReport } = await import('./verify.js');
|
|
122
|
+
const r = await verifyClis({ builtinClis: BUILTIN_CLIS, userClis: USER_CLIS, target, smoke: opts.smoke });
|
|
123
|
+
console.log(renderVerifyReport(r));
|
|
124
|
+
process.exitCode = r.ok ? EXIT_CODES.SUCCESS : EXIT_CODES.GENERIC_ERROR;
|
|
125
|
+
});
|
|
126
|
+
// ── Built-in: explore / synthesize / generate / cascade ───────────────────
|
|
127
|
+
program
|
|
128
|
+
.command('explore')
|
|
129
|
+
.alias('probe')
|
|
130
|
+
.description('Explore a website: discover APIs, stores, and recommend strategies')
|
|
131
|
+
.argument('<url>')
|
|
132
|
+
.option('--site <name>')
|
|
133
|
+
.option('--goal <text>')
|
|
134
|
+
.option('--wait <s>', '', '3')
|
|
135
|
+
.option('--auto', 'Enable interactive fuzzing')
|
|
136
|
+
.option('--click <labels>', 'Comma-separated labels to click before fuzzing')
|
|
137
|
+
.option('-v, --verbose', 'Debug output')
|
|
138
|
+
.action(async (url, opts) => {
|
|
139
|
+
applyVerbose(opts);
|
|
140
|
+
const { exploreUrl, renderExploreSummary } = await import('./explore.js');
|
|
141
|
+
const clickLabels = opts.click
|
|
142
|
+
? opts.click.split(',').map((s) => s.trim())
|
|
143
|
+
: undefined;
|
|
144
|
+
const workspace = `explore:${inferHost(url, opts.site)}`;
|
|
145
|
+
const result = await exploreUrl(url, {
|
|
146
|
+
BrowserFactory: getBrowserFactory(),
|
|
147
|
+
site: opts.site,
|
|
148
|
+
goal: opts.goal,
|
|
149
|
+
waitSeconds: parseFloat(opts.wait),
|
|
150
|
+
auto: opts.auto,
|
|
151
|
+
clickLabels,
|
|
152
|
+
workspace,
|
|
153
|
+
});
|
|
154
|
+
console.log(renderExploreSummary(result));
|
|
155
|
+
});
|
|
156
|
+
program
|
|
157
|
+
.command('synthesize')
|
|
158
|
+
.description('Synthesize CLIs from explore')
|
|
159
|
+
.argument('<target>')
|
|
160
|
+
.option('--top <n>', '', '3')
|
|
161
|
+
.option('-v, --verbose', 'Debug output')
|
|
162
|
+
.action(async (target, opts) => {
|
|
163
|
+
applyVerbose(opts);
|
|
164
|
+
const { synthesizeFromExplore, renderSynthesizeSummary } = await import('./synthesize.js');
|
|
165
|
+
console.log(renderSynthesizeSummary(synthesizeFromExplore(target, { top: parseInt(opts.top) })));
|
|
166
|
+
});
|
|
167
|
+
program
|
|
168
|
+
.command('generate')
|
|
169
|
+
.description('One-shot: explore → synthesize → register')
|
|
170
|
+
.argument('<url>')
|
|
171
|
+
.option('--goal <text>')
|
|
172
|
+
.option('--site <name>')
|
|
173
|
+
.option('-v, --verbose', 'Debug output')
|
|
174
|
+
.action(async (url, opts) => {
|
|
175
|
+
applyVerbose(opts);
|
|
176
|
+
const { generateCliFromUrl, renderGenerateSummary } = await import('./generate.js');
|
|
177
|
+
const workspace = `generate:${inferHost(url, opts.site)}`;
|
|
178
|
+
const r = await generateCliFromUrl({
|
|
179
|
+
url,
|
|
180
|
+
BrowserFactory: getBrowserFactory(),
|
|
181
|
+
goal: opts.goal,
|
|
182
|
+
site: opts.site,
|
|
183
|
+
workspace,
|
|
184
|
+
});
|
|
185
|
+
console.log(renderGenerateSummary(r));
|
|
186
|
+
process.exitCode = r.ok ? EXIT_CODES.SUCCESS : EXIT_CODES.GENERIC_ERROR;
|
|
187
|
+
});
|
|
188
|
+
// ── Built-in: record ─────────────────────────────────────────────────────
|
|
189
|
+
program
|
|
190
|
+
.command('record')
|
|
191
|
+
.description('Record API calls from a live browser session → generate YAML candidates')
|
|
192
|
+
.argument('<url>', 'URL to open and record')
|
|
193
|
+
.option('--site <name>', 'Site name (inferred from URL if omitted)')
|
|
194
|
+
.option('--out <dir>', 'Output directory for candidates')
|
|
195
|
+
.option('--poll <ms>', 'Poll interval in milliseconds', '2000')
|
|
196
|
+
.option('--timeout <ms>', 'Auto-stop after N milliseconds (default: 60000)', '60000')
|
|
197
|
+
.option('-v, --verbose', 'Debug output')
|
|
198
|
+
.action(async (url, opts) => {
|
|
199
|
+
applyVerbose(opts);
|
|
200
|
+
const { recordSession, renderRecordSummary } = await import('./record.js');
|
|
201
|
+
const result = await recordSession({
|
|
202
|
+
BrowserFactory: getBrowserFactory(),
|
|
203
|
+
url,
|
|
204
|
+
site: opts.site,
|
|
205
|
+
outDir: opts.out,
|
|
206
|
+
pollMs: parseInt(opts.poll, 10),
|
|
207
|
+
timeoutMs: parseInt(opts.timeout, 10),
|
|
208
|
+
});
|
|
209
|
+
console.log(renderRecordSummary(result));
|
|
210
|
+
process.exitCode = result.candidateCount > 0 ? EXIT_CODES.SUCCESS : EXIT_CODES.EMPTY_RESULT;
|
|
211
|
+
});
|
|
212
|
+
program
|
|
213
|
+
.command('cascade')
|
|
214
|
+
.description('Strategy cascade: find simplest working strategy')
|
|
215
|
+
.argument('<url>')
|
|
216
|
+
.option('--site <name>')
|
|
217
|
+
.option('-v, --verbose', 'Debug output')
|
|
218
|
+
.action(async (url, opts) => {
|
|
219
|
+
applyVerbose(opts);
|
|
220
|
+
const { cascadeProbe, renderCascadeResult } = await import('./cascade.js');
|
|
221
|
+
const workspace = `cascade:${inferHost(url, opts.site)}`;
|
|
222
|
+
const result = await browserSession(getBrowserFactory(), async (page) => {
|
|
223
|
+
try {
|
|
224
|
+
const siteUrl = new URL(url);
|
|
225
|
+
await page.goto(`${siteUrl.protocol}//${siteUrl.host}`);
|
|
226
|
+
await page.wait(2);
|
|
227
|
+
}
|
|
228
|
+
catch { }
|
|
229
|
+
return cascadeProbe(page, url);
|
|
230
|
+
}, { workspace });
|
|
231
|
+
console.log(renderCascadeResult(result));
|
|
232
|
+
});
|
|
233
|
+
// ── Built-in: operate (browser control for Claude Code skill) ───────────────
|
|
234
|
+
//
|
|
235
|
+
// Make websites accessible for AI agents.
|
|
236
|
+
// All commands wrapped in operateAction() for consistent error handling.
|
|
237
|
+
const operate = program
|
|
238
|
+
.command('operate')
|
|
239
|
+
.description('Browser control — navigate, click, type, extract, wait (no LLM needed)');
|
|
240
|
+
/** Wrap operate actions with error handling and optional --json output */
|
|
241
|
+
function operateAction(fn) {
|
|
242
|
+
return async (...args) => {
|
|
243
|
+
try {
|
|
244
|
+
const page = await getOperatePage();
|
|
245
|
+
await fn(page, ...args);
|
|
246
|
+
}
|
|
247
|
+
catch (err) {
|
|
248
|
+
const msg = err instanceof Error ? err.message : String(err);
|
|
249
|
+
if (msg.includes('Extension not connected') || msg.includes('Daemon')) {
|
|
250
|
+
console.error(`Browser not connected. Run 'opencli doctor' to diagnose.`);
|
|
251
|
+
}
|
|
252
|
+
else if (msg.includes('attach failed') || msg.includes('chrome-extension://')) {
|
|
253
|
+
console.error(`Browser attach failed — another extension may be interfering. Try disabling 1Password.`);
|
|
254
|
+
}
|
|
255
|
+
else {
|
|
256
|
+
console.error(`Error: ${msg}`);
|
|
257
|
+
}
|
|
258
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
259
|
+
}
|
|
260
|
+
};
|
|
261
|
+
}
|
|
262
|
+
// ── Navigation ──
|
|
263
|
+
/** Network interceptor JS — injected on every open/navigate to capture fetch/XHR */
|
|
264
|
+
const NETWORK_INTERCEPTOR_JS = `(function(){if(window.__opencli_net)return;window.__opencli_net=[];var M=200,B=50000,F=window.fetch;window.fetch=async function(){var r=await F.apply(this,arguments);try{var ct=r.headers.get('content-type')||'';if(ct.includes('json')||ct.includes('text')){var c=r.clone(),t=await c.text();if(window.__opencli_net.length<M){var b=null;if(t.length<=B)try{b=JSON.parse(t)}catch(e){b=t}window.__opencli_net.push({url:r.url||(arguments[0]&&arguments[0].url)||String(arguments[0]),method:(arguments[1]&&arguments[1].method)||'GET',status:r.status,size:t.length,ct:ct,body:b})}}}catch(e){}return r};var X=XMLHttpRequest.prototype,O=X.open,S=X.send;X.open=function(m,u){this._om=m;this._ou=u;return O.apply(this,arguments)};X.send=function(){var x=this;x.addEventListener('load',function(){try{var ct=x.getResponseHeader('content-type')||'';if((ct.includes('json')||ct.includes('text'))&&window.__opencli_net.length<M){var t=x.responseText,b=null;if(t&&t.length<=B)try{b=JSON.parse(t)}catch(e){b=t}window.__opencli_net.push({url:x._ou,method:x._om||'GET',status:x.status,size:t?t.length:0,ct:ct,body:b})}}catch(e){}});return S.apply(this,arguments)}})()`;
|
|
265
|
+
operate.command('open').argument('<url>').description('Open URL in automation window')
|
|
266
|
+
.action(operateAction(async (page, url) => {
|
|
267
|
+
await page.goto(url);
|
|
268
|
+
await page.wait(2);
|
|
269
|
+
// Auto-inject network interceptor for API discovery
|
|
270
|
+
try {
|
|
271
|
+
await page.evaluate(NETWORK_INTERCEPTOR_JS);
|
|
272
|
+
}
|
|
273
|
+
catch { /* non-fatal */ }
|
|
274
|
+
console.log(`Navigated to: ${await page.getCurrentUrl?.() ?? url}`);
|
|
275
|
+
}));
|
|
276
|
+
operate.command('back').description('Go back in browser history')
|
|
277
|
+
.action(operateAction(async (page) => {
|
|
278
|
+
await page.evaluate('history.back()');
|
|
279
|
+
await page.wait(2);
|
|
280
|
+
console.log('Navigated back');
|
|
281
|
+
}));
|
|
282
|
+
operate.command('scroll').argument('<direction>', 'up or down').option('--amount <pixels>', 'Pixels to scroll', '500')
|
|
283
|
+
.description('Scroll page')
|
|
284
|
+
.action(operateAction(async (page, direction, opts) => {
|
|
285
|
+
if (direction !== 'up' && direction !== 'down') {
|
|
286
|
+
console.error(`Invalid direction "${direction}". Use "up" or "down".`);
|
|
287
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
288
|
+
return;
|
|
289
|
+
}
|
|
290
|
+
await page.scroll(direction, parseInt(opts.amount, 10));
|
|
291
|
+
console.log(`Scrolled ${direction}`);
|
|
292
|
+
}));
|
|
293
|
+
// ── Inspect ──
|
|
294
|
+
operate.command('state').description('Page state: URL, title, interactive elements with [N] indices')
|
|
295
|
+
.action(operateAction(async (page) => {
|
|
296
|
+
const snapshot = await page.snapshot({ viewportExpand: 2000 });
|
|
297
|
+
const url = await page.getCurrentUrl?.() ?? '';
|
|
298
|
+
console.log(`URL: ${url}\n`);
|
|
299
|
+
console.log(typeof snapshot === 'string' ? snapshot : JSON.stringify(snapshot, null, 2));
|
|
300
|
+
}));
|
|
301
|
+
operate.command('screenshot').argument('[path]', 'Save to file (base64 if omitted)')
|
|
302
|
+
.description('Take screenshot')
|
|
303
|
+
.action(operateAction(async (page, path) => {
|
|
304
|
+
if (path) {
|
|
305
|
+
await page.screenshot({ path });
|
|
306
|
+
console.log(`Screenshot saved to: ${path}`);
|
|
307
|
+
}
|
|
308
|
+
else {
|
|
309
|
+
console.log(await page.screenshot({ format: 'png' }));
|
|
310
|
+
}
|
|
311
|
+
}));
|
|
312
|
+
// ── Get commands (structured data extraction) ──
|
|
313
|
+
const get = operate.command('get').description('Get page properties');
|
|
314
|
+
get.command('title').description('Page title')
|
|
315
|
+
.action(operateAction(async (page) => {
|
|
316
|
+
console.log(await page.evaluate('document.title'));
|
|
317
|
+
}));
|
|
318
|
+
get.command('url').description('Current page URL')
|
|
319
|
+
.action(operateAction(async (page) => {
|
|
320
|
+
console.log(await page.getCurrentUrl?.() ?? await page.evaluate('location.href'));
|
|
321
|
+
}));
|
|
322
|
+
get.command('text').argument('<index>', 'Element index').description('Element text content')
|
|
323
|
+
.action(operateAction(async (page, index) => {
|
|
324
|
+
const text = await page.evaluate(`document.querySelector('[data-opencli-ref="${index}"]')?.textContent?.trim()`);
|
|
325
|
+
console.log(text ?? '(empty)');
|
|
326
|
+
}));
|
|
327
|
+
get.command('value').argument('<index>', 'Element index').description('Input/textarea value')
|
|
328
|
+
.action(operateAction(async (page, index) => {
|
|
329
|
+
const val = await page.evaluate(`document.querySelector('[data-opencli-ref="${index}"]')?.value`);
|
|
330
|
+
console.log(val ?? '(empty)');
|
|
331
|
+
}));
|
|
332
|
+
get.command('html').option('--selector <css>', 'CSS selector scope').description('Page HTML (or scoped)')
|
|
333
|
+
.action(operateAction(async (page, opts) => {
|
|
334
|
+
const sel = opts.selector ? JSON.stringify(opts.selector) : 'null';
|
|
335
|
+
const html = await page.evaluate(`(${sel} ? document.querySelector(${sel})?.outerHTML : document.documentElement.outerHTML)?.slice(0, 50000)`);
|
|
336
|
+
console.log(html ?? '(empty)');
|
|
337
|
+
}));
|
|
338
|
+
get.command('attributes').argument('<index>', 'Element index').description('Element attributes')
|
|
339
|
+
.action(operateAction(async (page, index) => {
|
|
340
|
+
const attrs = await page.evaluate(`JSON.stringify(Object.fromEntries([...document.querySelector('[data-opencli-ref="${index}"]')?.attributes].map(a=>[a.name,a.value])))`);
|
|
341
|
+
console.log(attrs ?? '{}');
|
|
342
|
+
}));
|
|
343
|
+
// ── Interact ──
|
|
344
|
+
operate.command('click').argument('<index>', 'Element index from state').description('Click element by index')
|
|
345
|
+
.action(operateAction(async (page, index) => {
|
|
346
|
+
await page.click(index);
|
|
347
|
+
console.log(`Clicked element [${index}]`);
|
|
348
|
+
}));
|
|
349
|
+
operate.command('type').argument('<index>', 'Element index').argument('<text>', 'Text to type')
|
|
350
|
+
.description('Click element, then type text')
|
|
351
|
+
.action(operateAction(async (page, index, text) => {
|
|
352
|
+
await page.click(index);
|
|
353
|
+
await page.wait(0.3);
|
|
354
|
+
await page.typeText(index, text);
|
|
355
|
+
// Detect autocomplete/combobox fields and wait for dropdown suggestions
|
|
356
|
+
const isAutocomplete = await page.evaluate(`
|
|
357
|
+
(() => {
|
|
358
|
+
const el = document.querySelector('[data-opencli-ref="${index}"]');
|
|
359
|
+
if (!el) return false;
|
|
360
|
+
const role = el.getAttribute('role');
|
|
361
|
+
const ac = el.getAttribute('aria-autocomplete');
|
|
362
|
+
const list = el.getAttribute('list');
|
|
363
|
+
return role === 'combobox' || ac === 'list' || ac === 'both' || !!list;
|
|
364
|
+
})()
|
|
365
|
+
`);
|
|
366
|
+
if (isAutocomplete) {
|
|
367
|
+
await page.wait(0.4);
|
|
368
|
+
console.log(`Typed "${text}" into autocomplete [${index}] — use state to see suggestions`);
|
|
369
|
+
}
|
|
370
|
+
else {
|
|
371
|
+
console.log(`Typed "${text}" into element [${index}]`);
|
|
372
|
+
}
|
|
373
|
+
}));
|
|
374
|
+
operate.command('select').argument('<index>', 'Element index of <select>').argument('<option>', 'Option text')
|
|
375
|
+
.description('Select dropdown option')
|
|
376
|
+
.action(operateAction(async (page, index, option) => {
|
|
377
|
+
const result = await page.evaluate(`
|
|
378
|
+
(function() {
|
|
379
|
+
var sel = document.querySelector('[data-opencli-ref="${index}"]');
|
|
380
|
+
if (!sel || sel.tagName !== 'SELECT') return { error: 'Not a <select>' };
|
|
381
|
+
var match = Array.from(sel.options).find(o => o.text.trim() === ${JSON.stringify(option)} || o.value === ${JSON.stringify(option)});
|
|
382
|
+
if (!match) return { error: 'Option not found', available: Array.from(sel.options).map(o => o.text.trim()) };
|
|
383
|
+
var setter = Object.getOwnPropertyDescriptor(HTMLSelectElement.prototype, 'value')?.set;
|
|
384
|
+
if (setter) setter.call(sel, match.value); else sel.value = match.value;
|
|
385
|
+
sel.dispatchEvent(new Event('input', {bubbles:true}));
|
|
386
|
+
sel.dispatchEvent(new Event('change', {bubbles:true}));
|
|
387
|
+
return { selected: match.text };
|
|
388
|
+
})()
|
|
389
|
+
`);
|
|
390
|
+
if (result?.error) {
|
|
391
|
+
console.error(`Error: ${result.error}${result.available ? ` — Available: ${result.available.join(', ')}` : ''}`);
|
|
392
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
393
|
+
}
|
|
394
|
+
else {
|
|
395
|
+
console.log(`Selected "${result?.selected}" in element [${index}]`);
|
|
396
|
+
}
|
|
397
|
+
}));
|
|
398
|
+
operate.command('keys').argument('<key>', 'Key to press (Enter, Escape, Tab, Control+a)')
|
|
399
|
+
.description('Press keyboard key')
|
|
400
|
+
.action(operateAction(async (page, key) => {
|
|
401
|
+
await page.pressKey(key);
|
|
402
|
+
console.log(`Pressed: ${key}`);
|
|
403
|
+
}));
|
|
404
|
+
// ── Wait commands ──
|
|
405
|
+
operate.command('wait')
|
|
406
|
+
.argument('<type>', 'selector, text, or time')
|
|
407
|
+
.argument('[value]', 'CSS selector, text string, or seconds')
|
|
408
|
+
.option('--timeout <ms>', 'Timeout in milliseconds', '10000')
|
|
409
|
+
.description('Wait for selector, text, or time (e.g. wait selector ".loaded", wait text "Success", wait time 3)')
|
|
410
|
+
.action(operateAction(async (page, type, value, opts) => {
|
|
411
|
+
const timeout = parseInt(opts.timeout, 10);
|
|
412
|
+
if (type === 'time') {
|
|
413
|
+
const seconds = parseFloat(value ?? '2');
|
|
414
|
+
await page.wait(seconds);
|
|
415
|
+
console.log(`Waited ${seconds}s`);
|
|
416
|
+
}
|
|
417
|
+
else if (type === 'selector') {
|
|
418
|
+
if (!value) {
|
|
419
|
+
console.error('Missing CSS selector');
|
|
420
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
421
|
+
return;
|
|
422
|
+
}
|
|
423
|
+
await page.wait({ selector: value, timeout: timeout / 1000 });
|
|
424
|
+
console.log(`Element "${value}" appeared`);
|
|
425
|
+
}
|
|
426
|
+
else if (type === 'text') {
|
|
427
|
+
if (!value) {
|
|
428
|
+
console.error('Missing text');
|
|
429
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
430
|
+
return;
|
|
431
|
+
}
|
|
432
|
+
await page.wait({ text: value, timeout: timeout / 1000 });
|
|
433
|
+
console.log(`Text "${value}" appeared`);
|
|
434
|
+
}
|
|
435
|
+
else {
|
|
436
|
+
console.error(`Unknown wait type "${type}". Use: selector, text, or time`);
|
|
437
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
438
|
+
}
|
|
439
|
+
}));
|
|
440
|
+
// ── Extract ──
|
|
441
|
+
operate.command('eval').argument('<js>', 'JavaScript code').description('Execute JS in page context, return result')
|
|
442
|
+
.action(operateAction(async (page, js) => {
|
|
443
|
+
const result = await page.evaluate(js);
|
|
444
|
+
if (typeof result === 'string')
|
|
445
|
+
console.log(result);
|
|
446
|
+
else
|
|
447
|
+
console.log(JSON.stringify(result, null, 2));
|
|
448
|
+
}));
|
|
449
|
+
// ── Network (API discovery) ──
|
|
450
|
+
operate.command('network')
|
|
451
|
+
.option('--detail <index>', 'Show full response body of request at index')
|
|
452
|
+
.option('--all', 'Show all requests including static resources')
|
|
453
|
+
.description('Show captured network requests (auto-captured since last open)')
|
|
454
|
+
.action(operateAction(async (page, opts) => {
|
|
455
|
+
const requests = await page.evaluate(`(function(){
|
|
456
|
+
var reqs = window.__opencli_net || [];
|
|
457
|
+
return JSON.stringify(reqs);
|
|
458
|
+
})()`);
|
|
459
|
+
let items = [];
|
|
460
|
+
try {
|
|
461
|
+
items = JSON.parse(requests);
|
|
462
|
+
}
|
|
463
|
+
catch {
|
|
464
|
+
console.log('No network data captured. Run "operate open <url>" first.');
|
|
465
|
+
return;
|
|
466
|
+
}
|
|
467
|
+
if (items.length === 0) {
|
|
468
|
+
console.log('No requests captured.');
|
|
469
|
+
return;
|
|
470
|
+
}
|
|
471
|
+
// Filter out static resources unless --all
|
|
472
|
+
if (!opts.all) {
|
|
473
|
+
items = items.filter(r => (r.ct?.includes('json') || r.ct?.includes('xml') || r.ct?.includes('text/plain')) &&
|
|
474
|
+
!/\.(js|css|png|jpg|gif|svg|woff|ico|map)(\?|$)/i.test(r.url) &&
|
|
475
|
+
!/analytics|tracking|telemetry|beacon|pixel|gtag|fbevents/i.test(r.url));
|
|
476
|
+
}
|
|
477
|
+
if (opts.detail !== undefined) {
|
|
478
|
+
const idx = parseInt(opts.detail, 10);
|
|
479
|
+
const req = items[idx];
|
|
480
|
+
if (!req) {
|
|
481
|
+
console.error(`Request #${idx} not found. ${items.length} requests available.`);
|
|
482
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
483
|
+
return;
|
|
484
|
+
}
|
|
485
|
+
console.log(`${req.method} ${req.url}`);
|
|
486
|
+
console.log(`Status: ${req.status} | Size: ${req.size} | Type: ${req.ct}`);
|
|
487
|
+
console.log('---');
|
|
488
|
+
console.log(typeof req.body === 'string' ? req.body : JSON.stringify(req.body, null, 2));
|
|
489
|
+
}
|
|
490
|
+
else {
|
|
491
|
+
console.log(`Captured ${items.length} API requests:\n`);
|
|
492
|
+
items.forEach((r, i) => {
|
|
493
|
+
const bodyPreview = r.body ? (typeof r.body === 'string' ? r.body.slice(0, 60) : JSON.stringify(r.body).slice(0, 60)) : '';
|
|
494
|
+
console.log(` [${i}] ${r.method} ${r.status} ${r.url.slice(0, 80)}`);
|
|
495
|
+
if (bodyPreview)
|
|
496
|
+
console.log(` ${bodyPreview}...`);
|
|
497
|
+
});
|
|
498
|
+
console.log(`\nUse --detail <index> to see full response body.`);
|
|
499
|
+
}
|
|
500
|
+
}));
|
|
501
|
+
// ── Init (adapter scaffolding) ──
|
|
502
|
+
operate.command('init')
|
|
503
|
+
.argument('<name>', 'Adapter name in site/command format (e.g. hn/top)')
|
|
504
|
+
.description('Generate adapter scaffold in ~/.opencli/clis/')
|
|
505
|
+
.action(async (name) => {
|
|
506
|
+
try {
|
|
507
|
+
const parts = name.split('/');
|
|
508
|
+
if (parts.length !== 2 || !parts[0] || !parts[1]) {
|
|
509
|
+
console.error('Name must be site/command format (e.g. hn/top)');
|
|
510
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
511
|
+
return;
|
|
512
|
+
}
|
|
513
|
+
const [site, command] = parts;
|
|
514
|
+
if (!/^[a-zA-Z0-9_-]+$/.test(site) || !/^[a-zA-Z0-9_-]+$/.test(command)) {
|
|
515
|
+
console.error('Name parts must be alphanumeric/dash/underscore only');
|
|
516
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
517
|
+
return;
|
|
518
|
+
}
|
|
519
|
+
const os = await import('node:os');
|
|
520
|
+
const fs = await import('node:fs');
|
|
521
|
+
const path = await import('node:path');
|
|
522
|
+
const dir = path.join(os.homedir(), '.opencli', 'clis', site);
|
|
523
|
+
const filePath = path.join(dir, `${command}.ts`);
|
|
524
|
+
if (fs.existsSync(filePath)) {
|
|
525
|
+
console.log(`Adapter already exists: ${filePath}`);
|
|
526
|
+
return;
|
|
527
|
+
}
|
|
528
|
+
// Try to detect domain from last operate session
|
|
529
|
+
let domain = site;
|
|
530
|
+
try {
|
|
531
|
+
const page = await getOperatePage();
|
|
532
|
+
const url = await page.getCurrentUrl?.();
|
|
533
|
+
if (url) {
|
|
534
|
+
try {
|
|
535
|
+
domain = new URL(url).hostname;
|
|
536
|
+
}
|
|
537
|
+
catch { }
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
catch { /* no active session */ }
|
|
541
|
+
const template = `import { cli, Strategy } from '@jackwener/opencli/registry';
|
|
542
|
+
|
|
543
|
+
cli({
|
|
544
|
+
site: '${site}',
|
|
545
|
+
name: '${command}',
|
|
546
|
+
description: '', // TODO: describe what this command does
|
|
547
|
+
domain: '${domain}',
|
|
548
|
+
strategy: Strategy.PUBLIC, // TODO: PUBLIC (no auth), COOKIE (needs login), UI (DOM interaction)
|
|
549
|
+
browser: false, // TODO: set true if needs browser
|
|
550
|
+
args: [
|
|
551
|
+
{ name: 'limit', type: 'int', default: 10, help: 'Number of items' },
|
|
552
|
+
],
|
|
553
|
+
columns: [], // TODO: field names for table output (e.g. ['title', 'score', 'url'])
|
|
554
|
+
func: async (page, kwargs) => {
|
|
555
|
+
// TODO: implement data fetching
|
|
556
|
+
// Prefer API calls (fetch) over browser automation
|
|
557
|
+
// page is available if browser: true
|
|
558
|
+
return [];
|
|
559
|
+
},
|
|
560
|
+
});
|
|
561
|
+
`;
|
|
562
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
563
|
+
fs.writeFileSync(filePath, template, 'utf-8');
|
|
564
|
+
console.log(`Created: ${filePath}`);
|
|
565
|
+
console.log(`Edit the file to implement your adapter, then run: opencli operate verify ${name}`);
|
|
566
|
+
}
|
|
567
|
+
catch (err) {
|
|
568
|
+
console.error(`Error: ${err instanceof Error ? err.message : String(err)}`);
|
|
569
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
570
|
+
}
|
|
571
|
+
});
|
|
572
|
+
// ── Verify (test adapter) ──
|
|
573
|
+
operate.command('verify')
|
|
574
|
+
.argument('<name>', 'Adapter name in site/command format (e.g. hn/top)')
|
|
575
|
+
.description('Execute an adapter and show results')
|
|
576
|
+
.action(async (name) => {
|
|
577
|
+
try {
|
|
578
|
+
const parts = name.split('/');
|
|
579
|
+
if (parts.length !== 2) {
|
|
580
|
+
console.error('Name must be site/command format');
|
|
581
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
582
|
+
return;
|
|
583
|
+
}
|
|
584
|
+
const [site, command] = parts;
|
|
585
|
+
if (!/^[a-zA-Z0-9_-]+$/.test(site) || !/^[a-zA-Z0-9_-]+$/.test(command)) {
|
|
586
|
+
console.error('Name parts must be alphanumeric/dash/underscore only');
|
|
587
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
588
|
+
return;
|
|
589
|
+
}
|
|
590
|
+
const { execSync } = await import('node:child_process');
|
|
591
|
+
const os = await import('node:os');
|
|
592
|
+
const path = await import('node:path');
|
|
593
|
+
const filePath = path.join(os.homedir(), '.opencli', 'clis', site, `${command}.ts`);
|
|
594
|
+
const fs = await import('node:fs');
|
|
595
|
+
if (!fs.existsSync(filePath)) {
|
|
596
|
+
console.error(`Adapter not found: ${filePath}`);
|
|
597
|
+
console.error(`Run "opencli operate init ${name}" to create it.`);
|
|
598
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
599
|
+
return;
|
|
600
|
+
}
|
|
601
|
+
console.log(`🔍 Verifying ${name}...\n`);
|
|
602
|
+
console.log(` Loading: ${filePath}`);
|
|
603
|
+
// Read adapter to check if it defines a 'limit' arg
|
|
604
|
+
const adapterSrc = fs.readFileSync(filePath, 'utf-8');
|
|
605
|
+
const hasLimitArg = /['"]limit['"]/.test(adapterSrc);
|
|
606
|
+
const limitFlag = hasLimitArg ? ' --limit 3' : '';
|
|
607
|
+
const verifyCmd = `node dist/main.js ${site} ${command}${limitFlag}`;
|
|
608
|
+
try {
|
|
609
|
+
const output = execSync(verifyCmd, {
|
|
610
|
+
cwd: path.join(path.dirname(import.meta.url.replace('file://', '')), '..'),
|
|
611
|
+
timeout: 30000,
|
|
612
|
+
encoding: 'utf-8',
|
|
613
|
+
env: process.env,
|
|
614
|
+
stdio: ['pipe', 'pipe', 'pipe'],
|
|
615
|
+
});
|
|
616
|
+
console.log(` Executing: opencli ${site} ${command}${limitFlag}\n`);
|
|
617
|
+
console.log(output);
|
|
618
|
+
console.log(`\n ✓ Adapter works!`);
|
|
619
|
+
}
|
|
620
|
+
catch (err) {
|
|
621
|
+
console.log(` Executing: opencli ${site} ${command}${limitFlag}\n`);
|
|
622
|
+
if (err.stdout)
|
|
623
|
+
console.log(err.stdout);
|
|
624
|
+
if (err.stderr)
|
|
625
|
+
console.error(err.stderr.slice(0, 500));
|
|
626
|
+
console.log(`\n ✗ Adapter failed. Fix the code and try again.`);
|
|
627
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
628
|
+
}
|
|
629
|
+
}
|
|
630
|
+
catch (err) {
|
|
631
|
+
console.error(`Error: ${err instanceof Error ? err.message : String(err)}`);
|
|
632
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
633
|
+
}
|
|
634
|
+
});
|
|
635
|
+
// ── Session ──
|
|
636
|
+
operate.command('close').description('Close the automation window')
|
|
637
|
+
.action(operateAction(async (page) => {
|
|
638
|
+
await page.closeWindow?.();
|
|
639
|
+
console.log('Automation window closed');
|
|
640
|
+
}));
|
|
641
|
+
// ── Built-in: doctor / completion ──────────────────────────────────────────
|
|
642
|
+
program
|
|
643
|
+
.command('doctor')
|
|
644
|
+
.description('Diagnose opencli browser bridge connectivity')
|
|
645
|
+
.option('--no-live', 'Skip live browser connectivity test')
|
|
646
|
+
.option('--sessions', 'Show active automation sessions', false)
|
|
647
|
+
.option('-v, --verbose', 'Debug output')
|
|
648
|
+
.action(async (opts) => {
|
|
649
|
+
applyVerbose(opts);
|
|
650
|
+
const { runBrowserDoctor, renderBrowserDoctorReport } = await import('./doctor.js');
|
|
651
|
+
const report = await runBrowserDoctor({ live: opts.live, sessions: opts.sessions, cliVersion: PKG_VERSION });
|
|
652
|
+
console.log(renderBrowserDoctorReport(report));
|
|
653
|
+
});
|
|
654
|
+
program
|
|
655
|
+
.command('completion')
|
|
656
|
+
.description('Output shell completion script')
|
|
657
|
+
.argument('<shell>', 'Shell type: bash, zsh, or fish')
|
|
658
|
+
.action((shell) => {
|
|
659
|
+
printCompletionScript(shell);
|
|
660
|
+
});
|
|
661
|
+
// ── Plugin management ──────────────────────────────────────────────────────
|
|
662
|
+
const pluginCmd = program.command('plugin').description('Manage opencli plugins');
|
|
663
|
+
pluginCmd
|
|
664
|
+
.command('install')
|
|
665
|
+
.description('Install a plugin from a git repository')
|
|
666
|
+
.argument('<source>', 'Plugin source (e.g. github:user/repo)')
|
|
667
|
+
.action(async (source) => {
|
|
668
|
+
const { installPlugin } = await import('./plugin.js');
|
|
669
|
+
const { discoverPlugins } = await import('./discovery.js');
|
|
670
|
+
try {
|
|
671
|
+
const result = installPlugin(source);
|
|
672
|
+
await discoverPlugins();
|
|
673
|
+
if (Array.isArray(result)) {
|
|
674
|
+
if (result.length === 0) {
|
|
675
|
+
console.log(chalk.yellow('No plugins were installed (all skipped or incompatible).'));
|
|
676
|
+
}
|
|
677
|
+
else {
|
|
678
|
+
console.log(chalk.green(`\u2705 Installed ${result.length} plugin(s) from monorepo: ${result.join(', ')}`));
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
else {
|
|
682
|
+
console.log(chalk.green(`\u2705 Plugin "${result}" installed successfully. Commands are ready to use.`));
|
|
683
|
+
}
|
|
684
|
+
}
|
|
685
|
+
catch (err) {
|
|
686
|
+
console.error(chalk.red(`Error: ${getErrorMessage(err)}`));
|
|
687
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
688
|
+
}
|
|
689
|
+
});
|
|
690
|
+
pluginCmd
|
|
691
|
+
.command('uninstall')
|
|
692
|
+
.description('Uninstall a plugin')
|
|
693
|
+
.argument('<name>', 'Plugin name')
|
|
694
|
+
.action(async (name) => {
|
|
695
|
+
const { uninstallPlugin } = await import('./plugin.js');
|
|
696
|
+
try {
|
|
697
|
+
uninstallPlugin(name);
|
|
698
|
+
console.log(chalk.green(`✅ Plugin "${name}" uninstalled.`));
|
|
699
|
+
}
|
|
700
|
+
catch (err) {
|
|
701
|
+
console.error(chalk.red(`Error: ${getErrorMessage(err)}`));
|
|
702
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
703
|
+
}
|
|
704
|
+
});
|
|
705
|
+
pluginCmd
|
|
706
|
+
.command('update')
|
|
707
|
+
.description('Update a plugin (or all plugins) to the latest version')
|
|
708
|
+
.argument('[name]', 'Plugin name (required unless --all is passed)')
|
|
709
|
+
.option('--all', 'Update all installed plugins')
|
|
710
|
+
.action(async (name, opts) => {
|
|
711
|
+
if (!name && !opts.all) {
|
|
712
|
+
console.error(chalk.red('Error: Please specify a plugin name or use the --all flag.'));
|
|
713
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
714
|
+
return;
|
|
715
|
+
}
|
|
716
|
+
if (name && opts.all) {
|
|
717
|
+
console.error(chalk.red('Error: Cannot specify both a plugin name and --all.'));
|
|
718
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
719
|
+
return;
|
|
720
|
+
}
|
|
721
|
+
const { updatePlugin, updateAllPlugins } = await import('./plugin.js');
|
|
722
|
+
const { discoverPlugins } = await import('./discovery.js');
|
|
723
|
+
if (opts.all) {
|
|
724
|
+
const results = updateAllPlugins();
|
|
725
|
+
if (results.length > 0) {
|
|
726
|
+
await discoverPlugins();
|
|
727
|
+
}
|
|
728
|
+
let hasErrors = false;
|
|
729
|
+
console.log(chalk.bold(' Update Results:'));
|
|
730
|
+
for (const result of results) {
|
|
731
|
+
if (result.success) {
|
|
732
|
+
console.log(` ${chalk.green('✓')} ${result.name}`);
|
|
733
|
+
continue;
|
|
734
|
+
}
|
|
735
|
+
hasErrors = true;
|
|
736
|
+
console.log(` ${chalk.red('✗')} ${result.name} — ${chalk.dim(result.error)}`);
|
|
737
|
+
}
|
|
738
|
+
if (results.length === 0) {
|
|
739
|
+
console.log(chalk.dim(' No plugins installed.'));
|
|
740
|
+
return;
|
|
741
|
+
}
|
|
742
|
+
console.log();
|
|
743
|
+
if (hasErrors) {
|
|
744
|
+
console.error(chalk.red('Completed with some errors.'));
|
|
745
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
746
|
+
}
|
|
747
|
+
else {
|
|
748
|
+
console.log(chalk.green('✅ All plugins updated successfully.'));
|
|
749
|
+
}
|
|
750
|
+
return;
|
|
751
|
+
}
|
|
752
|
+
try {
|
|
753
|
+
updatePlugin(name);
|
|
754
|
+
await discoverPlugins();
|
|
755
|
+
console.log(chalk.green(`✅ Plugin "${name}" updated successfully.`));
|
|
756
|
+
}
|
|
757
|
+
catch (err) {
|
|
758
|
+
console.error(chalk.red(`Error: ${getErrorMessage(err)}`));
|
|
759
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
760
|
+
}
|
|
761
|
+
});
|
|
762
|
+
pluginCmd
|
|
763
|
+
.command('list')
|
|
764
|
+
.description('List installed plugins')
|
|
765
|
+
.option('-f, --format <fmt>', 'Output format: table, json', 'table')
|
|
766
|
+
.action(async (opts) => {
|
|
767
|
+
const { listPlugins } = await import('./plugin.js');
|
|
768
|
+
const plugins = listPlugins();
|
|
769
|
+
if (plugins.length === 0) {
|
|
770
|
+
console.log(chalk.dim(' No plugins installed.'));
|
|
771
|
+
console.log(chalk.dim(` Install one with: opencli plugin install github:user/repo`));
|
|
772
|
+
return;
|
|
773
|
+
}
|
|
774
|
+
if (opts.format === 'json') {
|
|
775
|
+
renderOutput(plugins, {
|
|
776
|
+
fmt: 'json',
|
|
777
|
+
columns: ['name', 'commands', 'source'],
|
|
778
|
+
title: 'opencli/plugins',
|
|
779
|
+
source: 'opencli plugin list',
|
|
780
|
+
});
|
|
781
|
+
return;
|
|
782
|
+
}
|
|
783
|
+
console.log();
|
|
784
|
+
console.log(chalk.bold(' Installed plugins'));
|
|
785
|
+
console.log();
|
|
786
|
+
// Group by monorepo
|
|
787
|
+
const standalone = plugins.filter((p) => !p.monorepoName);
|
|
788
|
+
const monoGroups = new Map();
|
|
789
|
+
for (const p of plugins) {
|
|
790
|
+
if (!p.monorepoName)
|
|
791
|
+
continue;
|
|
792
|
+
const g = monoGroups.get(p.monorepoName) ?? [];
|
|
793
|
+
g.push(p);
|
|
794
|
+
monoGroups.set(p.monorepoName, g);
|
|
795
|
+
}
|
|
796
|
+
for (const p of standalone) {
|
|
797
|
+
const version = p.version ? chalk.green(` @${p.version}`) : '';
|
|
798
|
+
const desc = p.description ? chalk.dim(` — ${p.description}`) : '';
|
|
799
|
+
const cmds = p.commands.length > 0 ? chalk.dim(` (${p.commands.join(', ')})`) : '';
|
|
800
|
+
const src = p.source ? chalk.dim(` ← ${p.source}`) : '';
|
|
801
|
+
console.log(` ${chalk.cyan(p.name)}${version}${desc}${cmds}${src}`);
|
|
802
|
+
}
|
|
803
|
+
for (const [mono, group] of monoGroups) {
|
|
804
|
+
console.log();
|
|
805
|
+
console.log(chalk.bold.magenta(` 📦 ${mono}`) + chalk.dim(' (monorepo)'));
|
|
806
|
+
for (const p of group) {
|
|
807
|
+
const version = p.version ? chalk.green(` @${p.version}`) : '';
|
|
808
|
+
const desc = p.description ? chalk.dim(` — ${p.description}`) : '';
|
|
809
|
+
const cmds = p.commands.length > 0 ? chalk.dim(` (${p.commands.join(', ')})`) : '';
|
|
810
|
+
console.log(` ${chalk.cyan(p.name)}${version}${desc}${cmds}`);
|
|
811
|
+
}
|
|
812
|
+
}
|
|
813
|
+
console.log();
|
|
814
|
+
console.log(chalk.dim(` ${plugins.length} plugin(s) installed`));
|
|
815
|
+
console.log();
|
|
816
|
+
});
|
|
817
|
+
pluginCmd
|
|
818
|
+
.command('create')
|
|
819
|
+
.description('Create a new plugin scaffold')
|
|
820
|
+
.argument('<name>', 'Plugin name (lowercase, hyphens allowed)')
|
|
821
|
+
.option('-d, --dir <path>', 'Output directory (default: ./<name>)')
|
|
822
|
+
.option('--description <text>', 'Plugin description')
|
|
823
|
+
.action(async (name, opts) => {
|
|
824
|
+
const { createPluginScaffold } = await import('./plugin-scaffold.js');
|
|
825
|
+
try {
|
|
826
|
+
const result = createPluginScaffold(name, {
|
|
827
|
+
dir: opts.dir,
|
|
828
|
+
description: opts.description,
|
|
829
|
+
});
|
|
830
|
+
console.log(chalk.green(`✅ Plugin scaffold created at ${result.dir}`));
|
|
831
|
+
console.log();
|
|
832
|
+
console.log(chalk.bold(' Files created:'));
|
|
833
|
+
for (const f of result.files) {
|
|
834
|
+
console.log(` ${chalk.cyan(f)}`);
|
|
835
|
+
}
|
|
836
|
+
console.log();
|
|
837
|
+
console.log(chalk.dim(' Next steps:'));
|
|
838
|
+
console.log(chalk.dim(` cd ${result.dir}`));
|
|
839
|
+
console.log(chalk.dim(` opencli plugin install file://${result.dir}`));
|
|
840
|
+
console.log(chalk.dim(` opencli ${name} hello`));
|
|
841
|
+
}
|
|
842
|
+
catch (err) {
|
|
843
|
+
console.error(chalk.red(`Error: ${getErrorMessage(err)}`));
|
|
844
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
845
|
+
}
|
|
846
|
+
});
|
|
847
|
+
// ── Built-in: daemon ──────────────────────────────────────────────────────
|
|
848
|
+
const daemonCmd = program.command('daemon').description('Manage the opencli daemon');
|
|
849
|
+
daemonCmd
|
|
850
|
+
.command('status')
|
|
851
|
+
.description('Show daemon status')
|
|
852
|
+
.action(async () => { await daemonStatus(); });
|
|
853
|
+
daemonCmd
|
|
854
|
+
.command('stop')
|
|
855
|
+
.description('Stop the daemon')
|
|
856
|
+
.action(async () => { await daemonStop(); });
|
|
857
|
+
daemonCmd
|
|
858
|
+
.command('restart')
|
|
859
|
+
.description('Restart the daemon')
|
|
860
|
+
.action(async () => { await daemonRestart(); });
|
|
861
|
+
// ── External CLIs ─────────────────────────────────────────────────────────
|
|
862
|
+
const externalClis = loadExternalClis();
|
|
863
|
+
program
|
|
864
|
+
.command('install')
|
|
865
|
+
.description('Install an external CLI')
|
|
866
|
+
.argument('<name>', 'Name of the external CLI')
|
|
867
|
+
.action((name) => {
|
|
868
|
+
const ext = externalClis.find(e => e.name === name);
|
|
869
|
+
if (!ext) {
|
|
870
|
+
console.error(chalk.red(`External CLI '${name}' not found in registry.`));
|
|
871
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
872
|
+
return;
|
|
873
|
+
}
|
|
874
|
+
installExternalCli(ext);
|
|
875
|
+
});
|
|
876
|
+
program
|
|
877
|
+
.command('register')
|
|
878
|
+
.description('Register an external CLI')
|
|
879
|
+
.argument('<name>', 'Name of the CLI')
|
|
880
|
+
.option('--binary <bin>', 'Binary name if different from name')
|
|
881
|
+
.option('--install <cmd>', 'Auto-install command')
|
|
882
|
+
.option('--desc <text>', 'Description')
|
|
883
|
+
.action((name, opts) => {
|
|
884
|
+
registerExternalCli(name, { binary: opts.binary, install: opts.install, description: opts.desc });
|
|
885
|
+
});
|
|
886
|
+
function passthroughExternal(name, parsedArgs) {
|
|
887
|
+
const args = parsedArgs ?? (() => {
|
|
888
|
+
const idx = process.argv.indexOf(name);
|
|
889
|
+
return process.argv.slice(idx + 1);
|
|
890
|
+
})();
|
|
891
|
+
try {
|
|
892
|
+
executeExternalCli(name, args, externalClis);
|
|
893
|
+
}
|
|
894
|
+
catch (err) {
|
|
895
|
+
console.error(chalk.red(`Error: ${getErrorMessage(err)}`));
|
|
896
|
+
process.exitCode = EXIT_CODES.GENERIC_ERROR;
|
|
897
|
+
}
|
|
898
|
+
}
|
|
899
|
+
for (const ext of externalClis) {
|
|
900
|
+
if (program.commands.some(c => c.name() === ext.name))
|
|
901
|
+
continue;
|
|
902
|
+
program
|
|
903
|
+
.command(ext.name)
|
|
904
|
+
.description(`(External) ${ext.description || ext.name}`)
|
|
905
|
+
.argument('[args...]')
|
|
906
|
+
.allowUnknownOption()
|
|
907
|
+
.passThroughOptions()
|
|
908
|
+
.helpOption(false)
|
|
909
|
+
.action((args) => passthroughExternal(ext.name, args));
|
|
910
|
+
}
|
|
911
|
+
// ── Antigravity serve (long-running, special case) ────────────────────────
|
|
912
|
+
const antigravityCmd = program.command('antigravity').description('antigravity commands');
|
|
913
|
+
antigravityCmd
|
|
914
|
+
.command('serve')
|
|
915
|
+
.description('Start Anthropic-compatible API proxy for Antigravity')
|
|
916
|
+
.option('--port <port>', 'Server port (default: 8082)', '8082')
|
|
917
|
+
.action(async (opts) => {
|
|
918
|
+
const { startServe } = await import('./clis/antigravity/serve.js');
|
|
919
|
+
await startServe({ port: parseInt(opts.port) });
|
|
920
|
+
});
|
|
921
|
+
// ── Dynamic adapter commands ──────────────────────────────────────────────
|
|
922
|
+
const siteGroups = new Map();
|
|
923
|
+
siteGroups.set('antigravity', antigravityCmd);
|
|
924
|
+
registerAllCommands(program, siteGroups);
|
|
925
|
+
// ── Unknown command fallback ──────────────────────────────────────────────
|
|
926
|
+
// Security: do NOT auto-discover and register arbitrary system binaries.
|
|
927
|
+
// Only explicitly registered external CLIs (via `opencli register`) are allowed.
|
|
928
|
+
program.on('command:*', (operands) => {
|
|
929
|
+
const binary = operands[0];
|
|
930
|
+
console.error(chalk.red(`error: unknown command '${binary}'`));
|
|
931
|
+
if (isBinaryInstalled(binary)) {
|
|
932
|
+
console.error(chalk.dim(` Tip: '${binary}' exists on your PATH. Use 'opencli register ${binary}' to add it as an external CLI.`));
|
|
933
|
+
}
|
|
934
|
+
program.outputHelp();
|
|
935
|
+
process.exitCode = EXIT_CODES.USAGE_ERROR;
|
|
936
|
+
});
|
|
937
|
+
return program;
|
|
938
|
+
}
|
|
939
|
+
export function runCli(BUILTIN_CLIS, USER_CLIS) {
|
|
940
|
+
createProgram(BUILTIN_CLIS, USER_CLIS).parse();
|
|
941
|
+
}
|
|
942
|
+
// ── Helpers ─────────────────────────────────────────────────────────────────
|
|
943
|
+
/** Infer a workspace-friendly hostname from a URL, with site override. */
|
|
944
|
+
function inferHost(url, site) {
|
|
945
|
+
if (site)
|
|
946
|
+
return site;
|
|
947
|
+
try {
|
|
948
|
+
return new URL(url).host;
|
|
949
|
+
}
|
|
950
|
+
catch {
|
|
951
|
+
return 'default';
|
|
952
|
+
}
|
|
953
|
+
}
|