@jackwener/opencli 1.0.3 โ†’ 1.0.4

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.
Files changed (190) hide show
  1. package/.github/workflows/build-extension.yml +21 -3
  2. package/.github/workflows/docs.yml +52 -0
  3. package/README.md +28 -28
  4. package/README.zh-CN.md +28 -28
  5. package/dist/browser/cdp.d.ts +16 -1
  6. package/dist/browser/cdp.js +124 -80
  7. package/dist/browser/daemon-client.d.ts +3 -1
  8. package/dist/browser/daemon-client.js +4 -0
  9. package/dist/browser/dom-helpers.d.ts +20 -0
  10. package/dist/browser/dom-helpers.js +109 -0
  11. package/dist/browser/mcp.d.ts +1 -0
  12. package/dist/browser/mcp.js +10 -5
  13. package/dist/browser/page.d.ts +7 -0
  14. package/dist/browser/page.js +37 -100
  15. package/dist/browser.test.js +7 -0
  16. package/dist/build-manifest.js +3 -1
  17. package/dist/build-manifest.test.js +34 -0
  18. package/dist/capabilityRouting.d.ts +2 -0
  19. package/dist/capabilityRouting.js +30 -0
  20. package/dist/capabilityRouting.test.d.ts +1 -0
  21. package/dist/capabilityRouting.test.js +42 -0
  22. package/dist/chaoxing.test.js +11 -4
  23. package/dist/cli-manifest.json +635 -1
  24. package/dist/cli.js +45 -8
  25. package/dist/clis/antigravity/serve.d.ts +14 -0
  26. package/dist/clis/antigravity/serve.js +263 -0
  27. package/dist/clis/bilibili/download.js +4 -14
  28. package/dist/clis/boss/resume.d.ts +1 -0
  29. package/dist/clis/boss/resume.js +249 -0
  30. package/dist/clis/hf/top.d.ts +1 -0
  31. package/dist/clis/hf/top.js +119 -0
  32. package/dist/clis/jike/comment.d.ts +1 -0
  33. package/dist/clis/jike/comment.js +107 -0
  34. package/dist/clis/jike/create.d.ts +1 -0
  35. package/dist/clis/jike/create.js +106 -0
  36. package/dist/clis/jike/feed.d.ts +1 -0
  37. package/dist/clis/jike/feed.js +67 -0
  38. package/dist/clis/jike/like.d.ts +1 -0
  39. package/dist/clis/jike/like.js +61 -0
  40. package/dist/clis/jike/notifications.d.ts +1 -0
  41. package/dist/clis/jike/notifications.js +169 -0
  42. package/dist/clis/jike/post.yaml +58 -0
  43. package/dist/clis/jike/repost.d.ts +1 -0
  44. package/dist/clis/jike/repost.js +103 -0
  45. package/dist/clis/jike/search.d.ts +1 -0
  46. package/dist/clis/jike/search.js +67 -0
  47. package/dist/clis/jike/shared.d.ts +19 -0
  48. package/dist/clis/jike/shared.js +25 -0
  49. package/dist/clis/jike/topic.yaml +52 -0
  50. package/dist/clis/jike/user.yaml +51 -0
  51. package/dist/clis/smzdm/search.js +28 -39
  52. package/dist/clis/stackoverflow/bounties.yaml +29 -0
  53. package/dist/clis/stackoverflow/hot.yaml +28 -0
  54. package/dist/clis/stackoverflow/search.yaml +32 -0
  55. package/dist/clis/stackoverflow/unanswered.yaml +28 -0
  56. package/dist/clis/twitter/download.js +6 -16
  57. package/dist/clis/xiaohongshu/download.js +3 -3
  58. package/dist/clis/zhihu/download.js +3 -3
  59. package/dist/doctor.d.ts +7 -0
  60. package/dist/doctor.js +16 -0
  61. package/dist/download/index.d.ts +12 -8
  62. package/dist/download/index.js +11 -3
  63. package/dist/download/index.test.d.ts +1 -0
  64. package/dist/download/index.test.js +14 -0
  65. package/dist/engine.js +5 -5
  66. package/dist/explore.d.ts +1 -0
  67. package/dist/explore.js +3 -3
  68. package/dist/generate.js +1 -0
  69. package/dist/interceptor.js +3 -2
  70. package/dist/output.d.ts +1 -0
  71. package/dist/output.js +3 -1
  72. package/dist/pipeline/executor.test.js +1 -0
  73. package/dist/pipeline/steps/download.js +14 -18
  74. package/dist/registry.d.ts +1 -0
  75. package/dist/registry.js +5 -2
  76. package/dist/runtime.d.ts +4 -1
  77. package/dist/runtime.js +2 -2
  78. package/dist/types.d.ts +12 -0
  79. package/dist/verify.d.ts +6 -1
  80. package/dist/verify.js +54 -2
  81. package/docs/.vitepress/config.mts +193 -0
  82. package/docs/adapters/browser/apple-podcasts.md +28 -0
  83. package/docs/adapters/browser/bbc.md +26 -0
  84. package/docs/adapters/browser/bilibili.md +38 -0
  85. package/docs/adapters/browser/boss.md +28 -0
  86. package/docs/adapters/browser/coupang.md +28 -0
  87. package/docs/adapters/browser/ctrip.md +27 -0
  88. package/docs/adapters/browser/github.md +26 -0
  89. package/docs/adapters/browser/hackernews.md +26 -0
  90. package/docs/adapters/browser/linkedin.md +27 -0
  91. package/docs/adapters/browser/reddit.md +41 -0
  92. package/docs/adapters/browser/reuters.md +27 -0
  93. package/docs/adapters/browser/smzdm.md +27 -0
  94. package/docs/adapters/browser/twitter.md +47 -0
  95. package/docs/adapters/browser/v2ex.md +32 -0
  96. package/docs/adapters/browser/weibo.md +27 -0
  97. package/docs/adapters/browser/xiaohongshu.md +32 -0
  98. package/docs/adapters/browser/xiaoyuzhou.md +28 -0
  99. package/docs/adapters/browser/xueqiu.md +32 -0
  100. package/docs/adapters/browser/yahoo-finance.md +26 -0
  101. package/docs/adapters/browser/youtube.md +29 -0
  102. package/docs/adapters/browser/zhihu.md +30 -0
  103. package/docs/adapters/desktop/antigravity.md +46 -0
  104. package/docs/adapters/desktop/chatgpt.md +43 -0
  105. package/docs/adapters/desktop/chatwise.md +38 -0
  106. package/docs/adapters/desktop/codex.md +32 -0
  107. package/docs/adapters/desktop/cursor.md +33 -0
  108. package/docs/adapters/desktop/discord.md +28 -0
  109. package/docs/adapters/desktop/feishu.md +20 -0
  110. package/docs/adapters/desktop/neteasemusic.md +31 -0
  111. package/docs/adapters/desktop/notion.md +29 -0
  112. package/docs/adapters/desktop/wechat.md +28 -0
  113. package/docs/adapters/index.md +49 -0
  114. package/docs/advanced/cdp.md +103 -0
  115. package/docs/advanced/download.md +63 -0
  116. package/docs/advanced/electron.md +125 -0
  117. package/docs/advanced/remote-chrome.md +72 -0
  118. package/docs/developer/ai-workflow.md +66 -0
  119. package/docs/developer/architecture.md +90 -0
  120. package/docs/developer/contributing.md +136 -0
  121. package/docs/developer/testing.md +237 -0
  122. package/docs/developer/ts-adapter.md +87 -0
  123. package/docs/developer/yaml-adapter.md +108 -0
  124. package/docs/guide/browser-bridge.md +38 -0
  125. package/docs/guide/getting-started.md +56 -0
  126. package/docs/guide/installation.md +37 -0
  127. package/docs/guide/troubleshooting.md +56 -0
  128. package/docs/index.md +35 -0
  129. package/docs/zh/adapters/index.md +5 -0
  130. package/docs/zh/advanced/cdp.md +3 -0
  131. package/docs/zh/developer/contributing.md +24 -0
  132. package/docs/zh/guide/browser-bridge.md +25 -0
  133. package/docs/zh/guide/getting-started.md +40 -0
  134. package/docs/zh/guide/installation.md +37 -0
  135. package/docs/zh/index.md +29 -0
  136. package/extension/dist/background.js +92 -52
  137. package/extension/package-lock.json +1156 -0
  138. package/extension/src/background.test.ts +151 -0
  139. package/extension/src/background.ts +122 -51
  140. package/extension/src/protocol.ts +3 -1
  141. package/package.json +7 -3
  142. package/src/browser/cdp.ts +154 -82
  143. package/src/browser/daemon-client.ts +7 -1
  144. package/src/browser/dom-helpers.ts +116 -0
  145. package/src/browser/mcp.ts +14 -6
  146. package/src/browser/page.ts +45 -100
  147. package/src/browser.test.ts +10 -0
  148. package/src/build-manifest.test.ts +36 -0
  149. package/src/build-manifest.ts +2 -1
  150. package/src/capabilityRouting.test.ts +47 -0
  151. package/src/capabilityRouting.ts +28 -0
  152. package/src/chaoxing.test.ts +12 -4
  153. package/src/cli.ts +28 -8
  154. package/src/clis/antigravity/serve.ts +329 -0
  155. package/src/clis/bilibili/download.ts +4 -15
  156. package/src/clis/boss/resume.ts +262 -0
  157. package/src/clis/hf/top.ts +141 -0
  158. package/src/clis/jike/comment.ts +113 -0
  159. package/src/clis/jike/create.ts +113 -0
  160. package/src/clis/jike/feed.ts +74 -0
  161. package/src/clis/jike/like.ts +65 -0
  162. package/src/clis/jike/notifications.ts +185 -0
  163. package/src/clis/jike/post.yaml +58 -0
  164. package/src/clis/jike/repost.ts +114 -0
  165. package/src/clis/jike/search.ts +74 -0
  166. package/src/clis/jike/shared.ts +36 -0
  167. package/src/clis/jike/topic.yaml +52 -0
  168. package/src/clis/jike/user.yaml +51 -0
  169. package/src/clis/smzdm/search.ts +30 -39
  170. package/src/clis/stackoverflow/bounties.yaml +29 -0
  171. package/src/clis/stackoverflow/hot.yaml +28 -0
  172. package/src/clis/stackoverflow/search.yaml +32 -0
  173. package/src/clis/stackoverflow/unanswered.yaml +28 -0
  174. package/src/clis/twitter/download.ts +6 -17
  175. package/src/clis/xiaohongshu/download.ts +3 -3
  176. package/src/clis/zhihu/download.ts +3 -3
  177. package/src/doctor.ts +18 -2
  178. package/src/download/index.test.ts +16 -0
  179. package/src/download/index.ts +22 -4
  180. package/src/engine.ts +4 -4
  181. package/src/explore.ts +4 -4
  182. package/src/generate.ts +1 -0
  183. package/src/interceptor.ts +3 -2
  184. package/src/output.ts +3 -1
  185. package/src/pipeline/executor.test.ts +1 -0
  186. package/src/pipeline/steps/download.ts +14 -17
  187. package/src/registry.ts +6 -2
  188. package/src/runtime.ts +3 -2
  189. package/src/types.ts +9 -0
  190. package/src/verify.ts +64 -3
@@ -10,7 +10,7 @@
10
10
  import * as fs from 'node:fs';
11
11
  import * as path from 'node:path';
12
12
  import { render } from '../template.js';
13
- import { httpDownload, ytdlpDownload, saveDocument, detectContentType, requiresYtdlp, sanitizeFilename, generateFilename, exportCookiesToNetscape, getTempDir, } from '../../download/index.js';
13
+ import { httpDownload, ytdlpDownload, saveDocument, detectContentType, requiresYtdlp, sanitizeFilename, generateFilename, exportCookiesToNetscape, getTempDir, formatCookieHeader, } from '../../download/index.js';
14
14
  import { DownloadProgressTracker, formatBytes } from '../../download/progress.js';
15
15
  /**
16
16
  * Simple async concurrency limiter for downloads.
@@ -33,9 +33,8 @@ async function mapConcurrent(items, limit, fn) {
33
33
  */
34
34
  async function extractBrowserCookies(page, domain) {
35
35
  try {
36
- // Use browser evaluate to get document.cookie
37
- const cookieString = await page.evaluate(`(() => document.cookie)()`);
38
- return typeof cookieString === 'string' ? cookieString : '';
36
+ const cookies = await page.getCookies(domain ? { domain } : {});
37
+ return formatCookieHeader(cookies);
39
38
  }
40
39
  catch {
41
40
  return '';
@@ -46,20 +45,17 @@ async function extractBrowserCookies(page, domain) {
46
45
  */
47
46
  async function extractCookiesArray(page, domain) {
48
47
  try {
49
- const cookieString = await extractBrowserCookies(page);
50
- if (!cookieString)
51
- return [];
52
- return cookieString.split(';').map((c) => {
53
- const [name, ...rest] = c.trim().split('=');
54
- return {
55
- name: name || '',
56
- value: rest.join('=') || '',
57
- domain,
58
- path: '/',
59
- secure: true,
60
- httpOnly: false,
61
- };
62
- }).filter((c) => c.name);
48
+ const cookies = await page.getCookies({ domain });
49
+ return cookies
50
+ .filter((cookie) => cookie.name)
51
+ .map((cookie) => ({
52
+ name: cookie.name,
53
+ value: cookie.value,
54
+ domain: cookie.domain,
55
+ path: cookie.path ?? '/',
56
+ secure: cookie.secure ?? false,
57
+ httpOnly: cookie.httpOnly ?? false,
58
+ }));
63
59
  }
64
60
  catch {
65
61
  return [];
@@ -31,6 +31,7 @@ export interface CliCommand {
31
31
  pipeline?: Record<string, unknown>[];
32
32
  timeoutSeconds?: number;
33
33
  source?: string;
34
+ footerExtra?: (kwargs: Record<string, any>) => string | undefined;
34
35
  }
35
36
  /** Internal extension for lazy-loaded TS modules (not exposed in public API) */
36
37
  export interface InternalCliCommand extends CliCommand {
package/dist/registry.js CHANGED
@@ -11,18 +11,21 @@ export var Strategy;
11
11
  })(Strategy || (Strategy = {}));
12
12
  const _registry = new Map();
13
13
  export function cli(opts) {
14
+ const strategy = opts.strategy ?? (opts.browser === false ? Strategy.PUBLIC : Strategy.COOKIE);
15
+ const browser = opts.browser ?? (strategy !== Strategy.PUBLIC);
14
16
  const cmd = {
15
17
  site: opts.site,
16
18
  name: opts.name,
17
19
  description: opts.description ?? '',
18
20
  domain: opts.domain,
19
- strategy: opts.strategy ?? (opts.browser === false ? Strategy.PUBLIC : Strategy.COOKIE),
20
- browser: opts.browser ?? (opts.strategy === Strategy.PUBLIC ? false : true),
21
+ strategy,
22
+ browser,
21
23
  args: opts.args ?? [],
22
24
  columns: opts.columns,
23
25
  func: opts.func,
24
26
  pipeline: opts.pipeline,
25
27
  timeoutSeconds: opts.timeoutSeconds,
28
+ footerExtra: opts.footerExtra,
26
29
  };
27
30
  const key = fullName(cmd);
28
31
  _registry.set(key, cmd);
package/dist/runtime.d.ts CHANGED
@@ -18,7 +18,10 @@ export declare function withTimeoutMs<T>(promise: Promise<T>, timeoutMs: number,
18
18
  export interface IBrowserFactory {
19
19
  connect(opts?: {
20
20
  timeout?: number;
21
+ workspace?: string;
21
22
  }): Promise<IPage>;
22
23
  close(): Promise<void>;
23
24
  }
24
- export declare function browserSession<T>(BrowserFactory: new () => IBrowserFactory, fn: (page: IPage) => Promise<T>): Promise<T>;
25
+ export declare function browserSession<T>(BrowserFactory: new () => IBrowserFactory, fn: (page: IPage) => Promise<T>, opts?: {
26
+ workspace?: string;
27
+ }): Promise<T>;
package/dist/runtime.js CHANGED
@@ -17,10 +17,10 @@ export function withTimeoutMs(promise, timeoutMs, message) {
17
17
  promise.then((value) => { clearTimeout(timer); resolve(value); }, (error) => { clearTimeout(timer); reject(error); });
18
18
  });
19
19
  }
20
- export async function browserSession(BrowserFactory, fn) {
20
+ export async function browserSession(BrowserFactory, fn, opts = {}) {
21
21
  const mcp = new BrowserFactory();
22
22
  try {
23
- const page = await mcp.connect({ timeout: DEFAULT_BROWSER_CONNECT_TIMEOUT });
23
+ const page = await mcp.connect({ timeout: DEFAULT_BROWSER_CONNECT_TIMEOUT, workspace: opts.workspace });
24
24
  return await fn(page);
25
25
  }
26
26
  finally {
package/dist/types.d.ts CHANGED
@@ -7,6 +7,18 @@
7
7
  export interface IPage {
8
8
  goto(url: string): Promise<void>;
9
9
  evaluate(js: string): Promise<any>;
10
+ getCookies(opts?: {
11
+ domain?: string;
12
+ url?: string;
13
+ }): Promise<Array<{
14
+ name: string;
15
+ value: string;
16
+ domain: string;
17
+ path?: string;
18
+ secure?: boolean;
19
+ httpOnly?: boolean;
20
+ expirationDate?: number;
21
+ }>>;
10
22
  snapshot(opts?: {
11
23
  interactive?: boolean;
12
24
  compact?: boolean;
package/dist/verify.d.ts CHANGED
@@ -15,7 +15,12 @@ export interface VerifyOptions {
15
15
  export interface VerifyReport {
16
16
  ok: boolean;
17
17
  validation: ValidationReport;
18
- smoke: null;
18
+ smoke: null | {
19
+ requested: boolean;
20
+ executed: boolean;
21
+ ok: boolean;
22
+ summary: string;
23
+ };
19
24
  }
20
25
  export declare function verifyClis(opts: VerifyOptions): Promise<VerifyReport>;
21
26
  export declare function renderVerifyReport(report: VerifyReport): string;
package/dist/verify.js CHANGED
@@ -6,10 +6,62 @@
6
6
  * to the `opencli test` command or CI pipelines.
7
7
  */
8
8
  import { validateClisWithTarget, renderValidationReport } from './validate.js';
9
+ import { spawn } from 'node:child_process';
10
+ import * as fs from 'node:fs';
11
+ import * as path from 'node:path';
9
12
  export async function verifyClis(opts) {
10
13
  const report = validateClisWithTarget([opts.builtinClis, opts.userClis], opts.target);
11
- return { ok: report.ok, validation: report, smoke: null };
14
+ let smoke = null;
15
+ if (opts.smoke) {
16
+ smoke = await runSmokeTests(opts.builtinClis);
17
+ }
18
+ return { ok: report.ok && (smoke?.ok ?? true), validation: report, smoke };
12
19
  }
13
20
  export function renderVerifyReport(report) {
14
- return renderValidationReport(report.validation);
21
+ const base = renderValidationReport(report.validation);
22
+ if (!report.smoke)
23
+ return base;
24
+ const status = report.smoke.ok ? 'PASS' : 'FAIL';
25
+ const mode = report.smoke.executed ? 'executed' : 'skipped';
26
+ return `${base}\nSmoke: ${status} (${mode}) โ€” ${report.smoke.summary}`;
27
+ }
28
+ async function runSmokeTests(builtinClis) {
29
+ const projectRoot = path.resolve(builtinClis, '..', '..');
30
+ const smokeDir = path.join(projectRoot, 'tests', 'smoke');
31
+ if (!fs.existsSync(smokeDir)) {
32
+ return {
33
+ requested: true,
34
+ executed: false,
35
+ ok: false,
36
+ summary: 'Smoke tests are unavailable in this package/environment.',
37
+ };
38
+ }
39
+ const npx = process.platform === 'win32' ? 'npx.cmd' : 'npx';
40
+ return new Promise((resolve) => {
41
+ const child = spawn(npx, ['vitest', 'run', 'tests/smoke/', '--reporter=dot'], {
42
+ cwd: projectRoot,
43
+ env: { ...process.env },
44
+ stdio: ['ignore', 'pipe', 'pipe'],
45
+ });
46
+ let stderr = '';
47
+ child.stderr.on('data', (chunk) => {
48
+ stderr += chunk.toString();
49
+ });
50
+ child.on('error', (error) => {
51
+ resolve({
52
+ requested: true,
53
+ executed: false,
54
+ ok: false,
55
+ summary: `Failed to start smoke tests: ${error.message}`,
56
+ });
57
+ });
58
+ child.on('close', (code) => {
59
+ resolve({
60
+ requested: true,
61
+ executed: true,
62
+ ok: code === 0,
63
+ summary: code === 0 ? 'tests/smoke passed' : (stderr.trim() || `vitest exited with code ${code}`),
64
+ });
65
+ });
66
+ });
15
67
  }
@@ -0,0 +1,193 @@
1
+ import { defineConfig } from 'vitepress'
2
+
3
+ export default defineConfig({
4
+ title: 'OpenCLI',
5
+ description: 'Make any website or Electron App your CLI โ€” AI-powered, account-safe, self-healing.',
6
+
7
+ head: [
8
+ ['meta', { property: 'og:title', content: 'OpenCLI Documentation' }],
9
+ ['meta', { property: 'og:description', content: 'Make any website or Electron App your CLI.' }],
10
+ ['meta', { name: 'twitter:card', content: 'summary_large_image' }],
11
+ ],
12
+
13
+ locales: {
14
+ root: {
15
+ label: 'English',
16
+ lang: 'en',
17
+ themeConfig: {
18
+ nav: [
19
+ { text: 'Guide', link: '/guide/getting-started' },
20
+ { text: 'Adapters', link: '/adapters/' },
21
+ { text: 'Developer', link: '/developer/contributing' },
22
+ { text: 'Advanced', link: '/advanced/cdp' },
23
+ ],
24
+ sidebar: {
25
+ '/guide/': [
26
+ {
27
+ text: 'Guide',
28
+ items: [
29
+ { text: 'Getting Started', link: '/guide/getting-started' },
30
+ { text: 'Installation', link: '/guide/installation' },
31
+ { text: 'Browser Bridge', link: '/guide/browser-bridge' },
32
+ { text: 'Troubleshooting', link: '/guide/troubleshooting' },
33
+ ],
34
+ },
35
+ ],
36
+ '/adapters/': [
37
+ {
38
+ text: 'Adapters Overview',
39
+ items: [
40
+ { text: 'All Adapters', link: '/adapters/' },
41
+ ],
42
+ },
43
+ {
44
+ text: 'Browser Adapters',
45
+ collapsed: false,
46
+ items: [
47
+ { text: 'Twitter / X', link: '/adapters/browser/twitter' },
48
+ { text: 'Reddit', link: '/adapters/browser/reddit' },
49
+ { text: 'Bilibili', link: '/adapters/browser/bilibili' },
50
+ { text: 'Zhihu', link: '/adapters/browser/zhihu' },
51
+ { text: 'Xiaohongshu', link: '/adapters/browser/xiaohongshu' },
52
+ { text: 'Weibo', link: '/adapters/browser/weibo' },
53
+ { text: 'YouTube', link: '/adapters/browser/youtube' },
54
+ { text: 'Xueqiu', link: '/adapters/browser/xueqiu' },
55
+ { text: 'V2EX', link: '/adapters/browser/v2ex' },
56
+ { text: 'LinkedIn', link: '/adapters/browser/linkedin' },
57
+ { text: 'Coupang', link: '/adapters/browser/coupang' },
58
+ { text: 'BOSS Zhipin', link: '/adapters/browser/boss' },
59
+ { text: 'Ctrip', link: '/adapters/browser/ctrip' },
60
+ { text: 'Reuters', link: '/adapters/browser/reuters' },
61
+ { text: 'SMZDM', link: '/adapters/browser/smzdm' },
62
+ ],
63
+ },
64
+ {
65
+ text: 'Public API Adapters',
66
+ collapsed: false,
67
+ items: [
68
+ { text: 'HackerNews', link: '/adapters/browser/hackernews' },
69
+ { text: 'GitHub', link: '/adapters/browser/github' },
70
+ { text: 'BBC', link: '/adapters/browser/bbc' },
71
+ { text: 'Apple Podcasts', link: '/adapters/browser/apple-podcasts' },
72
+ { text: 'Xiaoyuzhou', link: '/adapters/browser/xiaoyuzhou' },
73
+ { text: 'Yahoo Finance', link: '/adapters/browser/yahoo-finance' },
74
+ ],
75
+ },
76
+ {
77
+ text: 'Desktop Adapters',
78
+ collapsed: false,
79
+ items: [
80
+ { text: 'Cursor', link: '/adapters/desktop/cursor' },
81
+ { text: 'Codex', link: '/adapters/desktop/codex' },
82
+ { text: 'Antigravity', link: '/adapters/desktop/antigravity' },
83
+ { text: 'ChatGPT', link: '/adapters/desktop/chatgpt' },
84
+ { text: 'ChatWise', link: '/adapters/desktop/chatwise' },
85
+ { text: 'Notion', link: '/adapters/desktop/notion' },
86
+ { text: 'Discord', link: '/adapters/desktop/discord' },
87
+ { text: 'Feishu', link: '/adapters/desktop/feishu' },
88
+ { text: 'WeChat', link: '/adapters/desktop/wechat' },
89
+ { text: 'NeteaseMusic', link: '/adapters/desktop/neteasemusic' },
90
+ ],
91
+ },
92
+ ],
93
+ '/developer/': [
94
+ {
95
+ text: 'Developer Guide',
96
+ items: [
97
+ { text: 'Contributing', link: '/developer/contributing' },
98
+ { text: 'Testing', link: '/developer/testing' },
99
+ { text: 'Architecture', link: '/developer/architecture' },
100
+ { text: 'YAML Adapter Guide', link: '/developer/yaml-adapter' },
101
+ { text: 'TypeScript Adapter Guide', link: '/developer/ts-adapter' },
102
+ { text: 'AI Workflow', link: '/developer/ai-workflow' },
103
+ ],
104
+ },
105
+ ],
106
+ '/advanced/': [
107
+ {
108
+ text: 'Advanced',
109
+ items: [
110
+ { text: 'Chrome DevTools Protocol', link: '/advanced/cdp' },
111
+ { text: 'Electron Apps', link: '/advanced/electron' },
112
+ { text: 'Remote Chrome', link: '/advanced/remote-chrome' },
113
+ { text: 'Download Support', link: '/advanced/download' },
114
+ ],
115
+ },
116
+ ],
117
+ },
118
+ },
119
+ },
120
+ zh: {
121
+ label: 'ไธญๆ–‡',
122
+ lang: 'zh-CN',
123
+ link: '/zh/',
124
+ themeConfig: {
125
+ nav: [
126
+ { text: 'ๆŒ‡ๅ—', link: '/zh/guide/getting-started' },
127
+ { text: '้€‚้…ๅ™จ', link: '/zh/adapters/' },
128
+ { text: 'ๅผ€ๅ‘่€…', link: '/zh/developer/contributing' },
129
+ { text: '่ฟ›้˜ถ', link: '/zh/advanced/cdp' },
130
+ ],
131
+ sidebar: {
132
+ '/zh/guide/': [
133
+ {
134
+ text: 'ๆŒ‡ๅ—',
135
+ items: [
136
+ { text: 'ๅฟซ้€Ÿๅผ€ๅง‹', link: '/zh/guide/getting-started' },
137
+ { text: 'ๅฎ‰่ฃ…', link: '/zh/guide/installation' },
138
+ { text: 'Browser Bridge', link: '/zh/guide/browser-bridge' },
139
+ { text: '้—ฎ้ข˜ๆŽ’ๆŸฅ', link: '/zh/guide/troubleshooting' },
140
+ ],
141
+ },
142
+ ],
143
+ '/zh/adapters/': [
144
+ {
145
+ text: '้€‚้…ๅ™จๆฆ‚่งˆ',
146
+ items: [
147
+ { text: 'ๆ‰€ๆœ‰้€‚้…ๅ™จ', link: '/zh/adapters/' },
148
+ ],
149
+ },
150
+ ],
151
+ '/zh/developer/': [
152
+ {
153
+ text: 'ๅผ€ๅ‘่€…ๆŒ‡ๅ—',
154
+ items: [
155
+ { text: '่ดก็ŒฎๆŒ‡ๅ—', link: '/zh/developer/contributing' },
156
+ { text: 'ๆต‹่ฏ•', link: '/zh/developer/testing' },
157
+ ],
158
+ },
159
+ ],
160
+ '/zh/advanced/': [
161
+ {
162
+ text: '่ฟ›้˜ถ',
163
+ items: [
164
+ { text: 'Chrome DevTools Protocol', link: '/zh/advanced/cdp' },
165
+ ],
166
+ },
167
+ ],
168
+ },
169
+ },
170
+ },
171
+ },
172
+
173
+ themeConfig: {
174
+ search: {
175
+ provider: 'local',
176
+ },
177
+
178
+ socialLinks: [
179
+ { icon: 'github', link: 'https://github.com/jackwener/opencli' },
180
+ { icon: 'npm', link: 'https://www.npmjs.com/package/@jackwener/opencli' },
181
+ ],
182
+
183
+ editLink: {
184
+ pattern: 'https://github.com/jackwener/opencli/edit/main/docs/:path',
185
+ text: 'Edit this page on GitHub',
186
+ },
187
+
188
+ footer: {
189
+ message: 'Released under the Apache-2.0 License.',
190
+ copyright: 'Copyright ยฉ 2024-present jackwener',
191
+ },
192
+ },
193
+ })
@@ -0,0 +1,28 @@
1
+ # Apple Podcasts
2
+
3
+ **Mode**: ๐ŸŒ Public ยท **Domain**: `podcasts.apple.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli apple-podcasts search` | |
10
+ | `opencli apple-podcasts episodes` | |
11
+ | `opencli apple-podcasts top` | |
12
+
13
+ ## Usage Examples
14
+
15
+ ```bash
16
+ # Quick start
17
+ opencli apple-podcasts search --limit 5
18
+
19
+ # JSON output
20
+ opencli apple-podcasts search -f json
21
+
22
+ # Verbose mode
23
+ opencli apple-podcasts search -v
24
+ ```
25
+
26
+ ## Prerequisites
27
+
28
+ - No browser required โ€” uses public API
@@ -0,0 +1,26 @@
1
+ # BBC News
2
+
3
+ **Mode**: ๐ŸŒ Public ยท **Domain**: `bbc.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli bbc news` | |
10
+
11
+ ## Usage Examples
12
+
13
+ ```bash
14
+ # Quick start
15
+ opencli bbc news --limit 5
16
+
17
+ # JSON output
18
+ opencli bbc news -f json
19
+
20
+ # Verbose mode
21
+ opencli bbc news -v
22
+ ```
23
+
24
+ ## Prerequisites
25
+
26
+ - No browser required โ€” uses public API
@@ -0,0 +1,38 @@
1
+ # Bilibili
2
+
3
+ **Mode**: ๐Ÿ” Browser ยท **Domain**: `bilibili.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli bilibili hot` | |
10
+ | `opencli bilibili search` | |
11
+ | `opencli bilibili me` | |
12
+ | `opencli bilibili favorite` | |
13
+ | `opencli bilibili history` | |
14
+ | `opencli bilibili feed` | |
15
+ | `opencli bilibili subtitle` | |
16
+ | `opencli bilibili dynamic` | |
17
+ | `opencli bilibili ranking` | |
18
+ | `opencli bilibili following` | |
19
+ | `opencli bilibili user-videos` | |
20
+ | `opencli bilibili download` | |
21
+
22
+ ## Usage Examples
23
+
24
+ ```bash
25
+ # Quick start
26
+ opencli bilibili hot --limit 5
27
+
28
+ # JSON output
29
+ opencli bilibili hot -f json
30
+
31
+ # Verbose mode
32
+ opencli bilibili hot -v
33
+ ```
34
+
35
+ ## Prerequisites
36
+
37
+ - Chrome running and **logged into** bilibili.com
38
+ - [Browser Bridge extension](/guide/browser-bridge) installed
@@ -0,0 +1,28 @@
1
+ # BOSS Zhipin
2
+
3
+ **Mode**: ๐Ÿ” Browser ยท **Domain**: `zhipin.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli boss search` | |
10
+ | `opencli boss detail` | |
11
+
12
+ ## Usage Examples
13
+
14
+ ```bash
15
+ # Quick start
16
+ opencli boss search --limit 5
17
+
18
+ # JSON output
19
+ opencli boss search -f json
20
+
21
+ # Verbose mode
22
+ opencli boss search -v
23
+ ```
24
+
25
+ ## Prerequisites
26
+
27
+ - Chrome running and **logged into** zhipin.com
28
+ - [Browser Bridge extension](/guide/browser-bridge) installed
@@ -0,0 +1,28 @@
1
+ # Coupang
2
+
3
+ **Mode**: ๐Ÿ” Browser ยท **Domain**: `coupang.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli coupang search` | |
10
+ | `opencli coupang add-to-cart` | |
11
+
12
+ ## Usage Examples
13
+
14
+ ```bash
15
+ # Quick start
16
+ opencli coupang search --limit 5
17
+
18
+ # JSON output
19
+ opencli coupang search -f json
20
+
21
+ # Verbose mode
22
+ opencli coupang search -v
23
+ ```
24
+
25
+ ## Prerequisites
26
+
27
+ - Chrome running and **logged into** coupang.com
28
+ - [Browser Bridge extension](/guide/browser-bridge) installed
@@ -0,0 +1,27 @@
1
+ # Ctrip (ๆบ็จ‹)
2
+
3
+ **Mode**: ๐Ÿ” Browser ยท **Domain**: `ctrip.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli ctrip search` | |
10
+
11
+ ## Usage Examples
12
+
13
+ ```bash
14
+ # Quick start
15
+ opencli ctrip search --limit 5
16
+
17
+ # JSON output
18
+ opencli ctrip search -f json
19
+
20
+ # Verbose mode
21
+ opencli ctrip search -v
22
+ ```
23
+
24
+ ## Prerequisites
25
+
26
+ - Chrome running and **logged into** ctrip.com
27
+ - [Browser Bridge extension](/guide/browser-bridge) installed
@@ -0,0 +1,26 @@
1
+ # GitHub
2
+
3
+ **Mode**: ๐ŸŒ Public ยท **Domain**: `github.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli github search` | |
10
+
11
+ ## Usage Examples
12
+
13
+ ```bash
14
+ # Quick start
15
+ opencli github search --limit 5
16
+
17
+ # JSON output
18
+ opencli github search -f json
19
+
20
+ # Verbose mode
21
+ opencli github search -v
22
+ ```
23
+
24
+ ## Prerequisites
25
+
26
+ - No browser required โ€” uses public API
@@ -0,0 +1,26 @@
1
+ # HackerNews
2
+
3
+ **Mode**: ๐ŸŒ Public ยท **Domain**: `news.ycombinator.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli hackernews top` | |
10
+
11
+ ## Usage Examples
12
+
13
+ ```bash
14
+ # Quick start
15
+ opencli hackernews top --limit 5
16
+
17
+ # JSON output
18
+ opencli hackernews top -f json
19
+
20
+ # Verbose mode
21
+ opencli hackernews top -v
22
+ ```
23
+
24
+ ## Prerequisites
25
+
26
+ - No browser required โ€” uses public API
@@ -0,0 +1,27 @@
1
+ # LinkedIn
2
+
3
+ **Mode**: ๐Ÿ” Browser ยท **Domain**: `linkedin.com`
4
+
5
+ ## Commands
6
+
7
+ | Command | Description |
8
+ |---------|-------------|
9
+ | `opencli linkedin search` | |
10
+
11
+ ## Usage Examples
12
+
13
+ ```bash
14
+ # Quick start
15
+ opencli linkedin search --limit 5
16
+
17
+ # JSON output
18
+ opencli linkedin search -f json
19
+
20
+ # Verbose mode
21
+ opencli linkedin search -v
22
+ ```
23
+
24
+ ## Prerequisites
25
+
26
+ - Chrome running and **logged into** linkedin.com
27
+ - [Browser Bridge extension](/guide/browser-bridge) installed