@jackwener/opencli 1.3.2 → 1.4.0

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 (508) hide show
  1. package/.github/pull_request_template.md +3 -1
  2. package/.github/workflows/build-extension.yml +7 -1
  3. package/.github/workflows/ci.yml +29 -3
  4. package/.github/workflows/docs.yml +1 -1
  5. package/.github/workflows/e2e-headed.yml +20 -0
  6. package/.github/workflows/release.yml +1 -1
  7. package/.github/workflows/security.yml +0 -3
  8. package/CHANGELOG.md +55 -0
  9. package/CONTRIBUTING.md +6 -3
  10. package/README.md +37 -10
  11. package/README.zh-CN.md +37 -10
  12. package/SKILL.md +7 -2
  13. package/TESTING.md +1 -0
  14. package/chatwise-opencli.ps1 +82 -0
  15. package/dist/analysis.d.ts +38 -0
  16. package/dist/analysis.js +166 -0
  17. package/dist/browser/cdp.d.ts +0 -4
  18. package/dist/browser/cdp.js +59 -38
  19. package/dist/browser/cdp.test.d.ts +1 -0
  20. package/dist/browser/cdp.test.js +52 -0
  21. package/dist/browser/daemon-client.js +2 -1
  22. package/dist/browser/discover.js +2 -1
  23. package/dist/browser/dom-snapshot.d.ts +2 -2
  24. package/dist/browser/dom-snapshot.js +54 -1
  25. package/dist/browser/dom-snapshot.test.js +36 -0
  26. package/dist/browser/errors.js +2 -1
  27. package/dist/browser/index.d.ts +3 -2
  28. package/dist/browser/index.js +2 -1
  29. package/dist/browser/mcp.d.ts +0 -2
  30. package/dist/browser/mcp.js +2 -3
  31. package/dist/browser/page.d.ts +4 -3
  32. package/dist/browser/page.js +44 -35
  33. package/dist/browser/stealth.d.ts +16 -0
  34. package/dist/browser/stealth.js +155 -0
  35. package/dist/browser.test.js +47 -1
  36. package/dist/build-manifest.js +15 -9
  37. package/dist/build-manifest.test.js +12 -0
  38. package/dist/cascade.js +4 -2
  39. package/dist/cli-manifest.json +639 -258
  40. package/dist/cli.js +57 -29
  41. package/dist/clis/_shared/desktop-commands.d.ts +22 -0
  42. package/dist/clis/_shared/desktop-commands.js +108 -0
  43. package/dist/clis/antigravity/serve.js +5 -2
  44. package/dist/clis/arxiv/search.js +1 -1
  45. package/dist/clis/bilibili/dynamic.test.d.ts +1 -0
  46. package/dist/clis/bilibili/dynamic.test.js +68 -0
  47. package/dist/clis/bilibili/favorite.js +4 -2
  48. package/dist/clis/bilibili/following.js +3 -2
  49. package/dist/clis/bilibili/subtitle.js +8 -7
  50. package/dist/clis/bilibili/utils.js +2 -2
  51. package/dist/clis/boss/batchgreet.js +1 -1
  52. package/dist/clis/boss/chatlist.js +1 -1
  53. package/dist/clis/boss/chatmsg.js +1 -1
  54. package/dist/clis/boss/detail.js +1 -1
  55. package/dist/clis/boss/exchange.js +1 -1
  56. package/dist/clis/boss/greet.js +1 -1
  57. package/dist/clis/boss/invite.js +1 -1
  58. package/dist/clis/boss/joblist.js +1 -1
  59. package/dist/clis/boss/mark.js +4 -3
  60. package/dist/clis/boss/recommend.js +1 -1
  61. package/dist/clis/boss/resume.js +1 -1
  62. package/dist/clis/boss/search.js +1 -1
  63. package/dist/clis/boss/send.js +5 -4
  64. package/dist/clis/boss/stats.js +1 -1
  65. package/dist/clis/chatgpt/ask.js +4 -0
  66. package/dist/clis/chatgpt/new.js +5 -1
  67. package/dist/clis/chatgpt/read.js +5 -1
  68. package/dist/clis/chatgpt/send.js +2 -1
  69. package/dist/clis/chatgpt/status.js +5 -1
  70. package/dist/clis/chatwise/ask.js +8 -2
  71. package/dist/clis/chatwise/export.js +2 -0
  72. package/dist/clis/chatwise/history.js +2 -0
  73. package/dist/clis/chatwise/model.js +8 -3
  74. package/dist/clis/chatwise/new.js +3 -18
  75. package/dist/clis/chatwise/read.js +2 -0
  76. package/dist/clis/chatwise/screenshot.js +3 -27
  77. package/dist/clis/chatwise/send.js +8 -2
  78. package/dist/clis/chatwise/shared.d.ts +2 -0
  79. package/dist/clis/chatwise/shared.js +6 -0
  80. package/dist/clis/chatwise/status.js +3 -22
  81. package/dist/clis/codex/ask.js +6 -2
  82. package/dist/clis/codex/dump.js +2 -25
  83. package/dist/clis/codex/new.js +2 -25
  84. package/dist/clis/codex/screenshot.js +2 -27
  85. package/dist/clis/codex/send.js +6 -4
  86. package/dist/clis/codex/status.js +2 -22
  87. package/dist/clis/cursor/ask.js +2 -1
  88. package/dist/clis/cursor/composer.js +2 -1
  89. package/dist/clis/cursor/dump.js +2 -25
  90. package/dist/clis/cursor/new.js +2 -18
  91. package/dist/clis/cursor/read.js +2 -1
  92. package/dist/clis/cursor/screenshot.js +1 -30
  93. package/dist/clis/cursor/send.js +2 -1
  94. package/dist/clis/cursor/status.js +2 -21
  95. package/dist/clis/dictionary/examples.yaml +25 -0
  96. package/dist/clis/dictionary/search.yaml +27 -0
  97. package/dist/clis/dictionary/synonyms.yaml +25 -0
  98. package/dist/clis/douban/book-hot.js +1 -1
  99. package/dist/clis/douban/movie-hot.js +1 -1
  100. package/dist/clis/douban/search.js +1 -1
  101. package/dist/clis/douban/utils.d.ts +4 -1
  102. package/dist/clis/douban/utils.js +156 -1
  103. package/dist/clis/doubao/ask.js +1 -1
  104. package/dist/clis/doubao/new.js +1 -1
  105. package/dist/clis/doubao/read.js +1 -1
  106. package/dist/clis/doubao/send.js +1 -1
  107. package/dist/clis/doubao/status.js +1 -1
  108. package/dist/clis/doubao-app/ask.js +1 -1
  109. package/dist/clis/doubao-app/new.js +1 -1
  110. package/dist/clis/doubao-app/read.js +1 -1
  111. package/dist/clis/doubao-app/send.js +1 -1
  112. package/dist/clis/grok/ask.d.ts +4 -0
  113. package/dist/clis/grok/ask.js +28 -10
  114. package/dist/clis/grok/ask.test.js +18 -0
  115. package/dist/clis/jd/item.d.ts +1 -0
  116. package/dist/clis/jd/item.js +96 -0
  117. package/dist/clis/jd/item.test.d.ts +1 -0
  118. package/dist/clis/jd/item.test.js +28 -0
  119. package/dist/clis/jike/feed.js +1 -1
  120. package/dist/clis/jike/search.js +1 -1
  121. package/dist/clis/linkedin/search.js +5 -4
  122. package/dist/clis/linkedin/timeline.d.ts +21 -0
  123. package/dist/clis/linkedin/timeline.js +503 -0
  124. package/dist/clis/linkedin/timeline.test.d.ts +1 -0
  125. package/dist/clis/linkedin/timeline.test.js +81 -0
  126. package/dist/clis/medium/feed.js +1 -1
  127. package/dist/clis/medium/search.js +1 -1
  128. package/dist/clis/medium/user.js +1 -1
  129. package/dist/clis/medium/{shared.js → utils.js} +2 -1
  130. package/dist/clis/pixiv/detail.yaml +49 -0
  131. package/dist/clis/pixiv/download.d.ts +7 -0
  132. package/dist/clis/pixiv/download.js +78 -0
  133. package/dist/clis/pixiv/download.test.d.ts +1 -0
  134. package/dist/clis/pixiv/download.test.js +87 -0
  135. package/dist/clis/pixiv/illusts.d.ts +8 -0
  136. package/dist/clis/pixiv/illusts.js +65 -0
  137. package/dist/clis/pixiv/illusts.test.d.ts +1 -0
  138. package/dist/clis/pixiv/illusts.test.js +99 -0
  139. package/dist/clis/pixiv/ranking.yaml +53 -0
  140. package/dist/clis/pixiv/search.d.ts +6 -0
  141. package/dist/clis/pixiv/search.js +43 -0
  142. package/dist/clis/pixiv/search.test.d.ts +1 -0
  143. package/dist/clis/pixiv/search.test.js +83 -0
  144. package/dist/clis/pixiv/test-utils.d.ts +12 -0
  145. package/dist/clis/pixiv/test-utils.js +23 -0
  146. package/dist/clis/pixiv/user.yaml +46 -0
  147. package/dist/clis/pixiv/utils.d.ts +27 -0
  148. package/dist/clis/pixiv/utils.js +49 -0
  149. package/dist/clis/reddit/comment.js +2 -1
  150. package/dist/clis/reddit/read.js +4 -3
  151. package/dist/clis/reddit/read.test.d.ts +1 -0
  152. package/dist/clis/reddit/read.test.js +28 -0
  153. package/dist/clis/reddit/save.js +2 -1
  154. package/dist/clis/reddit/saved.js +7 -3
  155. package/dist/clis/reddit/subscribe.js +2 -1
  156. package/dist/clis/reddit/upvote.js +2 -1
  157. package/dist/clis/reddit/upvoted.js +7 -3
  158. package/dist/clis/sinablog/article.js +1 -1
  159. package/dist/clis/sinablog/hot.js +1 -1
  160. package/dist/clis/sinablog/user.js +1 -1
  161. package/dist/clis/substack/feed.js +1 -1
  162. package/dist/clis/substack/publication.js +1 -1
  163. package/dist/clis/substack/search.js +3 -2
  164. package/dist/clis/substack/{shared.js → utils.js} +3 -2
  165. package/dist/clis/tiktok/search.yaml +2 -1
  166. package/dist/clis/twitter/accept.js +2 -1
  167. package/dist/clis/twitter/article.js +4 -1
  168. package/dist/clis/twitter/block.js +2 -1
  169. package/dist/clis/twitter/bookmark.js +2 -1
  170. package/dist/clis/twitter/bookmarks.js +3 -2
  171. package/dist/clis/twitter/delete.js +2 -1
  172. package/dist/clis/twitter/follow.js +2 -1
  173. package/dist/clis/twitter/followers.js +3 -2
  174. package/dist/clis/twitter/following.js +3 -2
  175. package/dist/clis/twitter/hide-reply.js +2 -1
  176. package/dist/clis/twitter/like.js +2 -1
  177. package/dist/clis/twitter/notifications.js +2 -1
  178. package/dist/clis/twitter/post.js +2 -1
  179. package/dist/clis/twitter/profile.js +5 -2
  180. package/dist/clis/twitter/reply-dm.js +2 -1
  181. package/dist/clis/twitter/reply.js +2 -1
  182. package/dist/clis/twitter/search.js +30 -13
  183. package/dist/clis/twitter/search.test.d.ts +1 -0
  184. package/dist/clis/twitter/search.test.js +104 -0
  185. package/dist/clis/twitter/thread.js +2 -2
  186. package/dist/clis/twitter/timeline.js +3 -2
  187. package/dist/clis/twitter/trending.js +3 -2
  188. package/dist/clis/twitter/unblock.js +2 -1
  189. package/dist/clis/twitter/unbookmark.js +2 -1
  190. package/dist/clis/twitter/unfollow.js +2 -1
  191. package/dist/clis/v2ex/daily.js +3 -2
  192. package/dist/clis/v2ex/me.js +3 -2
  193. package/dist/clis/v2ex/notifications.js +4 -4
  194. package/dist/clis/web/read.d.ts +16 -0
  195. package/dist/clis/web/read.js +202 -0
  196. package/dist/clis/xueqiu/danjuan-utils.d.ts +55 -0
  197. package/dist/clis/xueqiu/danjuan-utils.js +126 -0
  198. package/dist/clis/xueqiu/danjuan-utils.test.d.ts +1 -0
  199. package/dist/clis/xueqiu/danjuan-utils.test.js +41 -0
  200. package/dist/clis/xueqiu/fund-holdings.d.ts +1 -0
  201. package/dist/clis/xueqiu/fund-holdings.js +28 -0
  202. package/dist/clis/xueqiu/fund-snapshot.d.ts +1 -0
  203. package/dist/clis/xueqiu/fund-snapshot.js +25 -0
  204. package/dist/clis/youtube/transcript.js +5 -4
  205. package/dist/clis/youtube/video.js +3 -2
  206. package/dist/constants.d.ts +2 -0
  207. package/dist/constants.js +2 -0
  208. package/dist/daemon.js +9 -4
  209. package/dist/discovery.js +11 -10
  210. package/dist/doctor.js +4 -2
  211. package/dist/download/index.d.ts +4 -12
  212. package/dist/download/index.js +33 -12
  213. package/dist/download/index.test.js +79 -2
  214. package/dist/download/media-download.js +4 -2
  215. package/dist/engine.test.js +76 -4
  216. package/dist/execution.d.ts +1 -9
  217. package/dist/execution.js +56 -46
  218. package/dist/explore.js +12 -111
  219. package/dist/external-clis.yaml +0 -8
  220. package/dist/external.js +7 -5
  221. package/dist/external.test.js +4 -0
  222. package/dist/generate.d.ts +0 -9
  223. package/dist/generate.js +4 -20
  224. package/dist/hooks.d.ts +46 -0
  225. package/dist/hooks.js +56 -0
  226. package/dist/hooks.test.d.ts +4 -0
  227. package/dist/hooks.test.js +92 -0
  228. package/dist/interceptor.js +70 -23
  229. package/dist/main.js +2 -0
  230. package/dist/output.js +12 -6
  231. package/dist/pipeline/executor.js +1 -1
  232. package/dist/pipeline/steps/browser.js +1 -3
  233. package/dist/pipeline/steps/download.js +42 -26
  234. package/dist/pipeline/steps/download.test.d.ts +1 -0
  235. package/dist/pipeline/steps/download.test.js +101 -0
  236. package/dist/pipeline/steps/fetch.js +40 -22
  237. package/dist/pipeline/steps/fetch.test.d.ts +1 -0
  238. package/dist/pipeline/steps/fetch.test.js +123 -0
  239. package/dist/pipeline/steps/transform.js +2 -6
  240. package/dist/pipeline/template.js +66 -52
  241. package/dist/pipeline/template.test.js +28 -0
  242. package/dist/pipeline/transform.test.js +18 -0
  243. package/dist/plugin.d.ts +40 -1
  244. package/dist/plugin.js +214 -17
  245. package/dist/plugin.test.d.ts +1 -1
  246. package/dist/plugin.test.js +219 -3
  247. package/dist/record.js +6 -98
  248. package/dist/registry-api.d.ts +2 -0
  249. package/dist/registry-api.js +1 -0
  250. package/dist/registry.d.ts +5 -2
  251. package/dist/registry.js +1 -2
  252. package/dist/runtime.d.ts +0 -1
  253. package/dist/runtime.js +14 -4
  254. package/dist/snapshotFormatter.d.ts +7 -14
  255. package/dist/snapshotFormatter.js +38 -78
  256. package/dist/utils.d.ts +9 -0
  257. package/dist/utils.js +29 -0
  258. package/dist/validate.js +3 -5
  259. package/dist/yaml-schema.d.ts +26 -0
  260. package/dist/yaml-schema.js +5 -0
  261. package/docs/.vitepress/config.mts +3 -0
  262. package/docs/adapters/browser/dictionary.md +27 -0
  263. package/docs/adapters/browser/douban.md +18 -8
  264. package/docs/adapters/browser/jd.md +27 -0
  265. package/docs/adapters/browser/linkedin.md +6 -0
  266. package/docs/adapters/browser/pixiv.md +92 -0
  267. package/docs/adapters/browser/web.md +30 -0
  268. package/docs/adapters/browser/wikipedia.md +0 -9
  269. package/docs/adapters/browser/xueqiu.md +27 -9
  270. package/docs/adapters/desktop/antigravity.md +0 -3
  271. package/docs/adapters/index.md +11 -9
  272. package/docs/comparison.md +125 -0
  273. package/docs/developer/contributing.md +21 -2
  274. package/docs/developer/testing.md +14 -8
  275. package/docs/developer/ts-adapter.md +18 -0
  276. package/docs/developer/yaml-adapter.md +16 -0
  277. package/docs/guide/plugins.md +10 -0
  278. package/docs/zh/guide/plugins.md +10 -0
  279. package/extension/dist/background.js +519 -444
  280. package/extension/manifest.json +1 -1
  281. package/extension/package.json +1 -1
  282. package/extension/src/background.test.ts +46 -1
  283. package/extension/src/background.ts +108 -33
  284. package/extension/src/cdp.ts +9 -9
  285. package/package.json +3 -2
  286. package/scripts/check-doc-coverage.sh +2 -0
  287. package/src/analysis.ts +170 -0
  288. package/src/browser/cdp.test.ts +66 -0
  289. package/src/browser/cdp.ts +64 -41
  290. package/src/browser/daemon-client.ts +4 -3
  291. package/src/browser/discover.ts +2 -1
  292. package/src/browser/dom-snapshot.test.ts +42 -0
  293. package/src/browser/dom-snapshot.ts +56 -3
  294. package/src/browser/errors.ts +2 -1
  295. package/src/browser/index.ts +3 -2
  296. package/src/browser/mcp.ts +2 -4
  297. package/src/browser/page.ts +43 -35
  298. package/src/browser/stealth.ts +156 -0
  299. package/src/browser.test.ts +51 -1
  300. package/src/build-manifest.test.ts +14 -0
  301. package/src/build-manifest.ts +13 -32
  302. package/src/cascade.ts +5 -3
  303. package/src/cli.ts +66 -34
  304. package/src/clis/_shared/desktop-commands.ts +121 -0
  305. package/src/clis/antigravity/serve.ts +6 -3
  306. package/src/clis/arxiv/search.ts +1 -1
  307. package/src/clis/bilibili/dynamic.test.ts +79 -0
  308. package/src/clis/bilibili/favorite.ts +5 -2
  309. package/src/clis/bilibili/following.ts +3 -2
  310. package/src/clis/bilibili/subtitle.ts +8 -7
  311. package/src/clis/bilibili/utils.ts +2 -2
  312. package/src/clis/boss/batchgreet.ts +1 -1
  313. package/src/clis/boss/chatlist.ts +1 -1
  314. package/src/clis/boss/chatmsg.ts +1 -1
  315. package/src/clis/boss/detail.ts +1 -1
  316. package/src/clis/boss/exchange.ts +1 -1
  317. package/src/clis/boss/greet.ts +1 -1
  318. package/src/clis/boss/invite.ts +1 -1
  319. package/src/clis/boss/joblist.ts +1 -1
  320. package/src/clis/boss/mark.ts +4 -3
  321. package/src/clis/boss/recommend.ts +1 -1
  322. package/src/clis/boss/resume.ts +1 -1
  323. package/src/clis/boss/search.ts +1 -1
  324. package/src/clis/boss/send.ts +5 -4
  325. package/src/clis/boss/stats.ts +1 -1
  326. package/src/clis/chatgpt/ask.ts +5 -0
  327. package/src/clis/chatgpt/new.ts +7 -2
  328. package/src/clis/chatgpt/read.ts +7 -2
  329. package/src/clis/chatgpt/send.ts +3 -2
  330. package/src/clis/chatgpt/status.ts +6 -1
  331. package/src/clis/chatwise/ask.ts +7 -2
  332. package/src/clis/chatwise/export.ts +2 -0
  333. package/src/clis/chatwise/history.ts +2 -0
  334. package/src/clis/chatwise/model.ts +7 -3
  335. package/src/clis/chatwise/new.ts +3 -20
  336. package/src/clis/chatwise/read.ts +2 -0
  337. package/src/clis/chatwise/screenshot.ts +3 -32
  338. package/src/clis/chatwise/send.ts +7 -2
  339. package/src/clis/chatwise/shared.ts +8 -0
  340. package/src/clis/chatwise/status.ts +3 -24
  341. package/src/clis/codex/ask.ts +5 -2
  342. package/src/clis/codex/dump.ts +2 -27
  343. package/src/clis/codex/new.ts +2 -28
  344. package/src/clis/codex/screenshot.ts +2 -32
  345. package/src/clis/codex/send.ts +5 -4
  346. package/src/clis/codex/status.ts +2 -24
  347. package/src/clis/cursor/ask.ts +2 -1
  348. package/src/clis/cursor/composer.ts +2 -1
  349. package/src/clis/cursor/dump.ts +2 -27
  350. package/src/clis/cursor/new.ts +2 -20
  351. package/src/clis/cursor/read.ts +2 -1
  352. package/src/clis/cursor/screenshot.ts +1 -36
  353. package/src/clis/cursor/send.ts +2 -1
  354. package/src/clis/cursor/status.ts +2 -22
  355. package/src/clis/dictionary/examples.yaml +25 -0
  356. package/src/clis/dictionary/search.yaml +27 -0
  357. package/src/clis/dictionary/synonyms.yaml +25 -0
  358. package/src/clis/douban/book-hot.ts +1 -1
  359. package/src/clis/douban/movie-hot.ts +1 -1
  360. package/src/clis/douban/search.ts +1 -1
  361. package/src/clis/douban/utils.ts +165 -1
  362. package/src/clis/doubao/ask.ts +1 -1
  363. package/src/clis/doubao/new.ts +1 -1
  364. package/src/clis/doubao/read.ts +1 -1
  365. package/src/clis/doubao/send.ts +1 -1
  366. package/src/clis/doubao/status.ts +1 -1
  367. package/src/clis/doubao-app/ask.ts +1 -1
  368. package/src/clis/doubao-app/new.ts +1 -1
  369. package/src/clis/doubao-app/read.ts +1 -1
  370. package/src/clis/doubao-app/send.ts +1 -1
  371. package/src/clis/grok/ask.test.ts +25 -0
  372. package/src/clis/grok/ask.ts +25 -12
  373. package/src/clis/jd/item.test.ts +35 -0
  374. package/src/clis/jd/item.ts +101 -0
  375. package/src/clis/jike/feed.ts +1 -1
  376. package/src/clis/jike/search.ts +1 -1
  377. package/src/clis/linkedin/search.ts +5 -4
  378. package/src/clis/linkedin/timeline.test.ts +99 -0
  379. package/src/clis/linkedin/timeline.ts +532 -0
  380. package/src/clis/medium/feed.ts +1 -1
  381. package/src/clis/medium/search.ts +1 -1
  382. package/src/clis/medium/user.ts +1 -1
  383. package/src/clis/medium/{shared.ts → utils.ts} +2 -1
  384. package/src/clis/pixiv/detail.yaml +49 -0
  385. package/src/clis/pixiv/download.test.ts +114 -0
  386. package/src/clis/pixiv/download.ts +91 -0
  387. package/src/clis/pixiv/illusts.test.ts +115 -0
  388. package/src/clis/pixiv/illusts.ts +78 -0
  389. package/src/clis/pixiv/ranking.yaml +53 -0
  390. package/src/clis/pixiv/search.test.ts +97 -0
  391. package/src/clis/pixiv/search.ts +53 -0
  392. package/src/clis/pixiv/test-utils.ts +29 -0
  393. package/src/clis/pixiv/user.yaml +46 -0
  394. package/src/clis/pixiv/utils.ts +62 -0
  395. package/src/clis/reddit/comment.ts +2 -1
  396. package/src/clis/reddit/read.test.ts +34 -0
  397. package/src/clis/reddit/read.ts +4 -3
  398. package/src/clis/reddit/save.ts +2 -1
  399. package/src/clis/reddit/saved.ts +6 -2
  400. package/src/clis/reddit/subscribe.ts +2 -1
  401. package/src/clis/reddit/upvote.ts +2 -1
  402. package/src/clis/reddit/upvoted.ts +6 -2
  403. package/src/clis/sinablog/article.ts +1 -1
  404. package/src/clis/sinablog/hot.ts +1 -1
  405. package/src/clis/sinablog/user.ts +1 -1
  406. package/src/clis/substack/feed.ts +1 -1
  407. package/src/clis/substack/publication.ts +1 -1
  408. package/src/clis/substack/search.ts +3 -2
  409. package/src/clis/substack/{shared.ts → utils.ts} +3 -2
  410. package/src/clis/tiktok/search.yaml +2 -1
  411. package/src/clis/twitter/accept.ts +2 -1
  412. package/src/clis/twitter/article.ts +3 -1
  413. package/src/clis/twitter/block.ts +2 -1
  414. package/src/clis/twitter/bookmark.ts +2 -1
  415. package/src/clis/twitter/bookmarks.ts +3 -2
  416. package/src/clis/twitter/delete.ts +2 -1
  417. package/src/clis/twitter/follow.ts +2 -1
  418. package/src/clis/twitter/followers.ts +3 -2
  419. package/src/clis/twitter/following.ts +3 -2
  420. package/src/clis/twitter/hide-reply.ts +2 -1
  421. package/src/clis/twitter/like.ts +2 -1
  422. package/src/clis/twitter/notifications.ts +2 -1
  423. package/src/clis/twitter/post.ts +2 -1
  424. package/src/clis/twitter/profile.ts +4 -2
  425. package/src/clis/twitter/reply-dm.ts +2 -1
  426. package/src/clis/twitter/reply.ts +2 -1
  427. package/src/clis/twitter/search.test.ts +113 -0
  428. package/src/clis/twitter/search.ts +38 -14
  429. package/src/clis/twitter/thread.ts +2 -2
  430. package/src/clis/twitter/timeline.ts +3 -2
  431. package/src/clis/twitter/trending.ts +3 -2
  432. package/src/clis/twitter/unblock.ts +2 -1
  433. package/src/clis/twitter/unbookmark.ts +2 -1
  434. package/src/clis/twitter/unfollow.ts +2 -1
  435. package/src/clis/v2ex/daily.ts +3 -2
  436. package/src/clis/v2ex/me.ts +3 -2
  437. package/src/clis/v2ex/notifications.ts +3 -4
  438. package/src/clis/web/read.ts +210 -0
  439. package/src/clis/xueqiu/danjuan-utils.test.ts +49 -0
  440. package/src/clis/xueqiu/danjuan-utils.ts +176 -0
  441. package/src/clis/xueqiu/fund-holdings.ts +32 -0
  442. package/src/clis/xueqiu/fund-snapshot.ts +27 -0
  443. package/src/clis/youtube/transcript.ts +5 -4
  444. package/src/clis/youtube/video.ts +3 -2
  445. package/src/constants.ts +3 -0
  446. package/src/daemon.ts +7 -5
  447. package/src/discovery.ts +12 -34
  448. package/src/doctor.ts +5 -3
  449. package/src/download/index.test.ts +93 -2
  450. package/src/download/index.ts +44 -23
  451. package/src/download/media-download.ts +5 -3
  452. package/src/engine.test.ts +84 -3
  453. package/src/execution.ts +62 -46
  454. package/src/explore.ts +21 -90
  455. package/src/external-clis.yaml +0 -8
  456. package/src/external.test.ts +9 -0
  457. package/src/external.ts +12 -10
  458. package/src/generate.ts +4 -41
  459. package/src/hooks.test.ts +126 -0
  460. package/src/hooks.ts +90 -0
  461. package/src/interceptor.ts +73 -23
  462. package/src/main.ts +2 -0
  463. package/src/output.ts +14 -6
  464. package/src/pipeline/executor.ts +1 -1
  465. package/src/pipeline/steps/browser.ts +1 -3
  466. package/src/pipeline/steps/download.test.ts +136 -0
  467. package/src/pipeline/steps/download.ts +47 -34
  468. package/src/pipeline/steps/fetch.test.ts +179 -0
  469. package/src/pipeline/steps/fetch.ts +39 -23
  470. package/src/pipeline/steps/transform.ts +2 -6
  471. package/src/pipeline/template.test.ts +28 -0
  472. package/src/pipeline/template.ts +67 -79
  473. package/src/pipeline/transform.test.ts +20 -0
  474. package/src/plugin.test.ts +251 -3
  475. package/src/plugin.ts +265 -21
  476. package/src/record.ts +12 -84
  477. package/src/registry-api.ts +2 -0
  478. package/src/registry.ts +7 -4
  479. package/src/runtime.ts +14 -4
  480. package/src/snapshotFormatter.ts +43 -121
  481. package/src/utils.ts +39 -0
  482. package/src/validate.ts +3 -6
  483. package/src/yaml-schema.ts +28 -0
  484. package/tests/e2e/browser-auth.test.ts +25 -0
  485. package/tests/e2e/plugin-management.test.ts +137 -0
  486. package/tests/e2e/public-commands.test.ts +34 -1
  487. package/vitest.config.ts +19 -1
  488. package/.github/workflows/pkg-pr-new.yml +0 -30
  489. package/dist/clis/douban/shared.d.ts +0 -4
  490. package/dist/clis/douban/shared.js +0 -155
  491. package/src/clis/douban/shared.ts +0 -165
  492. /package/dist/clis/boss/{common.d.ts → utils.d.ts} +0 -0
  493. /package/dist/clis/boss/{common.js → utils.js} +0 -0
  494. /package/dist/clis/doubao/{common.d.ts → utils.d.ts} +0 -0
  495. /package/dist/clis/doubao/{common.js → utils.js} +0 -0
  496. /package/dist/clis/doubao-app/{common.d.ts → utils.d.ts} +0 -0
  497. /package/dist/clis/doubao-app/{common.js → utils.js} +0 -0
  498. /package/dist/clis/jike/{shared.d.ts → utils.d.ts} +0 -0
  499. /package/dist/clis/jike/{shared.js → utils.js} +0 -0
  500. /package/dist/clis/medium/{shared.d.ts → utils.d.ts} +0 -0
  501. /package/dist/clis/sinablog/{shared.d.ts → utils.d.ts} +0 -0
  502. /package/dist/clis/sinablog/{shared.js → utils.js} +0 -0
  503. /package/dist/clis/substack/{shared.d.ts → utils.d.ts} +0 -0
  504. /package/src/clis/boss/{common.ts → utils.ts} +0 -0
  505. /package/src/clis/doubao/{common.ts → utils.ts} +0 -0
  506. /package/src/clis/doubao-app/{common.ts → utils.ts} +0 -0
  507. /package/src/clis/jike/{shared.ts → utils.ts} +0 -0
  508. /package/src/clis/sinablog/{shared.ts → utils.ts} +0 -0
@@ -1,4 +1,27 @@
1
1
  [
2
+ {
3
+ "site": "_shared",
4
+ "name": "desktop-commands",
5
+ "description": "Capture a snapshot of the current ${label} window (DOM + Accessibility tree)",
6
+ "strategy": "ui",
7
+ "browser": true,
8
+ "args": [
9
+ {
10
+ "name": "output",
11
+ "type": "str",
12
+ "default": "/tmp/${site",
13
+ "required": false,
14
+ "help": "Output file path (default: /tmp/${site}-snapshot.txt)"
15
+ }
16
+ ],
17
+ "type": "ts",
18
+ "modulePath": "_shared/desktop-commands.js",
19
+ "domain": "localhost",
20
+ "columns": [
21
+ "Status",
22
+ "File"
23
+ ]
24
+ },
2
25
  {
3
26
  "site": "antigravity",
4
27
  "name": "dump",
@@ -1952,20 +1975,6 @@
1952
1975
  "Model"
1953
1976
  ]
1954
1977
  },
1955
- {
1956
- "site": "chatwise",
1957
- "name": "new",
1958
- "description": "Start a new conversation in ChatWise",
1959
- "strategy": "ui",
1960
- "browser": true,
1961
- "args": [],
1962
- "type": "ts",
1963
- "modulePath": "chatwise/new.js",
1964
- "domain": "localhost",
1965
- "columns": [
1966
- "Status"
1967
- ]
1968
- },
1969
1978
  {
1970
1979
  "site": "chatwise",
1971
1980
  "name": "read",
@@ -1980,29 +1989,6 @@
1980
1989
  "Content"
1981
1990
  ]
1982
1991
  },
1983
- {
1984
- "site": "chatwise",
1985
- "name": "screenshot",
1986
- "description": "Capture a snapshot of the current ChatWise window (DOM + Accessibility tree)",
1987
- "strategy": "ui",
1988
- "browser": true,
1989
- "args": [
1990
- {
1991
- "name": "output",
1992
- "type": "str",
1993
- "default": "/tmp/chatwise-snapshot)",
1994
- "required": false,
1995
- "help": "Output file path (default: /tmp/chatwise-snapshot)"
1996
- }
1997
- ],
1998
- "type": "ts",
1999
- "modulePath": "chatwise/screenshot.js",
2000
- "domain": "localhost",
2001
- "columns": [
2002
- "Status",
2003
- "File"
2004
- ]
2005
- },
2006
1992
  {
2007
1993
  "site": "chatwise",
2008
1994
  "name": "send",
@@ -2026,22 +2012,6 @@
2026
2012
  "InjectedText"
2027
2013
  ]
2028
2014
  },
2029
- {
2030
- "site": "chatwise",
2031
- "name": "status",
2032
- "description": "Check active CDP connection to ChatWise Desktop",
2033
- "strategy": "ui",
2034
- "browser": true,
2035
- "args": [],
2036
- "type": "ts",
2037
- "modulePath": "chatwise/status.js",
2038
- "domain": "localhost",
2039
- "columns": [
2040
- "Status",
2041
- "Url",
2042
- "Title"
2043
- ]
2044
- },
2045
2015
  {
2046
2016
  "site": "codex",
2047
2017
  "name": "ask",
@@ -2072,21 +2042,6 @@
2072
2042
  "Text"
2073
2043
  ]
2074
2044
  },
2075
- {
2076
- "site": "codex",
2077
- "name": "dump",
2078
- "description": "Dump the DOM and Accessibility tree of Codex for reverse-engineering",
2079
- "strategy": "ui",
2080
- "browser": true,
2081
- "args": [],
2082
- "type": "ts",
2083
- "modulePath": "codex/dump.js",
2084
- "domain": "localhost",
2085
- "columns": [
2086
- "action",
2087
- "files"
2088
- ]
2089
- },
2090
2045
  {
2091
2046
  "site": "codex",
2092
2047
  "name": "export",
@@ -2164,21 +2119,6 @@
2164
2119
  "Model"
2165
2120
  ]
2166
2121
  },
2167
- {
2168
- "site": "codex",
2169
- "name": "new",
2170
- "description": "Start a new Codex conversation thread / isolated workspace",
2171
- "strategy": "ui",
2172
- "browser": true,
2173
- "args": [],
2174
- "type": "ts",
2175
- "modulePath": "codex/new.js",
2176
- "domain": "localhost",
2177
- "columns": [
2178
- "Status",
2179
- "Action"
2180
- ]
2181
- },
2182
2122
  {
2183
2123
  "site": "codex",
2184
2124
  "name": "read",
@@ -2193,29 +2133,6 @@
2193
2133
  "Content"
2194
2134
  ]
2195
2135
  },
2196
- {
2197
- "site": "codex",
2198
- "name": "screenshot",
2199
- "description": "Capture a snapshot of the current Codex window (DOM + Accessibility tree)",
2200
- "strategy": "ui",
2201
- "browser": true,
2202
- "args": [
2203
- {
2204
- "name": "output",
2205
- "type": "str",
2206
- "default": "/tmp/codex-snapshot.txt)",
2207
- "required": false,
2208
- "help": "Output file path (default: /tmp/codex-snapshot.txt)"
2209
- }
2210
- ],
2211
- "type": "ts",
2212
- "modulePath": "codex/screenshot.js",
2213
- "domain": "localhost",
2214
- "columns": [
2215
- "Status",
2216
- "File"
2217
- ]
2218
- },
2219
2136
  {
2220
2137
  "site": "codex",
2221
2138
  "name": "send",
@@ -2239,22 +2156,6 @@
2239
2156
  "InjectedText"
2240
2157
  ]
2241
2158
  },
2242
- {
2243
- "site": "codex",
2244
- "name": "status",
2245
- "description": "Check active CDP connection to OpenAI Codex App",
2246
- "strategy": "ui",
2247
- "browser": true,
2248
- "args": [],
2249
- "type": "ts",
2250
- "modulePath": "codex/status.js",
2251
- "domain": "localhost",
2252
- "columns": [
2253
- "Status",
2254
- "Url",
2255
- "Title"
2256
- ]
2257
- },
2258
2159
  {
2259
2160
  "site": "coupang",
2260
2161
  "name": "add-to-cart",
@@ -2424,21 +2325,6 @@
2424
2325
  "InjectedText"
2425
2326
  ]
2426
2327
  },
2427
- {
2428
- "site": "cursor",
2429
- "name": "dump",
2430
- "description": "Dump the DOM and Accessibility tree of Cursor for reverse-engineering",
2431
- "strategy": "ui",
2432
- "browser": true,
2433
- "args": [],
2434
- "type": "ts",
2435
- "modulePath": "cursor/dump.js",
2436
- "domain": "localhost",
2437
- "columns": [
2438
- "action",
2439
- "files"
2440
- ]
2441
- },
2442
2328
  {
2443
2329
  "site": "cursor",
2444
2330
  "name": "export",
@@ -2515,20 +2401,6 @@
2515
2401
  "Model"
2516
2402
  ]
2517
2403
  },
2518
- {
2519
- "site": "cursor",
2520
- "name": "new",
2521
- "description": "Start a new Cursor chat or Composer session",
2522
- "strategy": "ui",
2523
- "browser": true,
2524
- "args": [],
2525
- "type": "ts",
2526
- "modulePath": "cursor/new.js",
2527
- "domain": "localhost",
2528
- "columns": [
2529
- "Status"
2530
- ]
2531
- },
2532
2404
  {
2533
2405
  "site": "cursor",
2534
2406
  "name": "read",
@@ -2544,29 +2416,6 @@
2544
2416
  "Text"
2545
2417
  ]
2546
2418
  },
2547
- {
2548
- "site": "cursor",
2549
- "name": "screenshot",
2550
- "description": "Capture a snapshot of the current ${site} window (DOM + Accessibility tree)",
2551
- "strategy": "ui",
2552
- "browser": true,
2553
- "args": [
2554
- {
2555
- "name": "output",
2556
- "type": "str",
2557
- "default": "/tmp/${site",
2558
- "required": false,
2559
- "help": "Output file path (default: /tmp/${site}-snapshot.txt)"
2560
- }
2561
- ],
2562
- "type": "ts",
2563
- "modulePath": "cursor/screenshot.js",
2564
- "domain": "localhost",
2565
- "columns": [
2566
- "Status",
2567
- "File"
2568
- ]
2569
- },
2570
2419
  {
2571
2420
  "site": "cursor",
2572
2421
  "name": "send",
@@ -2590,22 +2439,6 @@
2590
2439
  "InjectedText"
2591
2440
  ]
2592
2441
  },
2593
- {
2594
- "site": "cursor",
2595
- "name": "status",
2596
- "description": "Check active CDP connection to Cursor AI Editor",
2597
- "strategy": "ui",
2598
- "browser": true,
2599
- "args": [],
2600
- "type": "ts",
2601
- "modulePath": "cursor/status.js",
2602
- "domain": "localhost",
2603
- "columns": [
2604
- "Status",
2605
- "Url",
2606
- "Title"
2607
- ]
2608
- },
2609
2442
  {
2610
2443
  "site": "devto",
2611
2444
  "name": "tag",
@@ -2759,6 +2592,124 @@
2759
2592
  ],
2760
2593
  "type": "yaml"
2761
2594
  },
2595
+ {
2596
+ "site": "dictionary",
2597
+ "name": "examples",
2598
+ "description": "Read real-world example sentences utilizing the word",
2599
+ "domain": "api.dictionaryapi.dev",
2600
+ "strategy": "public",
2601
+ "browser": false,
2602
+ "args": [
2603
+ {
2604
+ "name": "word",
2605
+ "type": "string",
2606
+ "required": true,
2607
+ "positional": true,
2608
+ "help": "Word to get example sentences for"
2609
+ }
2610
+ ],
2611
+ "columns": [
2612
+ "word",
2613
+ "example"
2614
+ ],
2615
+ "pipeline": [
2616
+ {
2617
+ "fetch": {
2618
+ "url": "https://api.dictionaryapi.dev/api/v2/entries/en/${{ args.word | urlencode }}"
2619
+ }
2620
+ },
2621
+ {
2622
+ "map": {
2623
+ "word": "${{ item.word }}",
2624
+ "example": "${{ (() => { if (item.meanings) { for (const m of item.meanings) { if (m.definitions) { for (const d of m.definitions) { if (d.example) return d.example; } } } } return 'No example found in API.'; })() }}"
2625
+ }
2626
+ },
2627
+ {
2628
+ "limit": 1
2629
+ }
2630
+ ],
2631
+ "type": "yaml"
2632
+ },
2633
+ {
2634
+ "site": "dictionary",
2635
+ "name": "search",
2636
+ "description": "Search the Free Dictionary API for definitions, parts of speech, and pronunciations.",
2637
+ "domain": "api.dictionaryapi.dev",
2638
+ "strategy": "public",
2639
+ "browser": false,
2640
+ "args": [
2641
+ {
2642
+ "name": "word",
2643
+ "type": "string",
2644
+ "required": true,
2645
+ "positional": true,
2646
+ "help": "Word to define (e.g., serendipity)"
2647
+ }
2648
+ ],
2649
+ "columns": [
2650
+ "word",
2651
+ "phonetic",
2652
+ "type",
2653
+ "definition"
2654
+ ],
2655
+ "pipeline": [
2656
+ {
2657
+ "fetch": {
2658
+ "url": "https://api.dictionaryapi.dev/api/v2/entries/en/${{ args.word | urlencode }}"
2659
+ }
2660
+ },
2661
+ {
2662
+ "map": {
2663
+ "word": "${{ item.word }}",
2664
+ "phonetic": "${{ (() => { if (item.phonetic) return item.phonetic; if (item.phonetics) { for (const p of item.phonetics) { if (p.text) return p.text; } } return ''; })() }}",
2665
+ "type": "${{ (() => { if (item.meanings && item.meanings[0] && item.meanings[0].partOfSpeech) return item.meanings[0].partOfSpeech; return 'N/A'; })() }}",
2666
+ "definition": "${{ (() => { if (item.meanings && item.meanings[0] && item.meanings[0].definitions && item.meanings[0].definitions[0] && item.meanings[0].definitions[0].definition) return item.meanings[0].definitions[0].definition; return 'No definition found in API.'; })() }}"
2667
+ }
2668
+ },
2669
+ {
2670
+ "limit": 1
2671
+ }
2672
+ ],
2673
+ "type": "yaml"
2674
+ },
2675
+ {
2676
+ "site": "dictionary",
2677
+ "name": "synonyms",
2678
+ "description": "Find synonyms for a specific word",
2679
+ "domain": "api.dictionaryapi.dev",
2680
+ "strategy": "public",
2681
+ "browser": false,
2682
+ "args": [
2683
+ {
2684
+ "name": "word",
2685
+ "type": "string",
2686
+ "required": true,
2687
+ "positional": true,
2688
+ "help": "Word to find synonyms for (e.g., serendipity)"
2689
+ }
2690
+ ],
2691
+ "columns": [
2692
+ "word",
2693
+ "synonyms"
2694
+ ],
2695
+ "pipeline": [
2696
+ {
2697
+ "fetch": {
2698
+ "url": "https://api.dictionaryapi.dev/api/v2/entries/en/${{ args.word | urlencode }}"
2699
+ }
2700
+ },
2701
+ {
2702
+ "map": {
2703
+ "word": "${{ item.word }}",
2704
+ "synonyms": "${{ (() => { const s = new Set(); if (item.meanings) { for (const m of item.meanings) { if (m.synonyms) { for (const syn of m.synonyms) s.add(syn); } if (m.definitions) { for (const d of m.definitions) { if (d.synonyms) { for (const syn of d.synonyms) s.add(syn); } } } } } const arr = Array.from(s); return arr.length > 0 ? arr.slice(0, 5).join(', ') : 'No synonyms found in API.'; })() }}"
2705
+ }
2706
+ },
2707
+ {
2708
+ "limit": 1
2709
+ }
2710
+ ],
2711
+ "type": "yaml"
2712
+ },
2762
2713
  {
2763
2714
  "site": "discord-app",
2764
2715
  "name": "channels",
@@ -4966,6 +4917,40 @@
4966
4917
  ],
4967
4918
  "type": "yaml"
4968
4919
  },
4920
+ {
4921
+ "site": "jd",
4922
+ "name": "item",
4923
+ "description": "京东商品详情(价格、主图、详情图、规格参数)",
4924
+ "strategy": "cookie",
4925
+ "browser": true,
4926
+ "args": [
4927
+ {
4928
+ "name": "sku",
4929
+ "type": "str",
4930
+ "required": true,
4931
+ "positional": true,
4932
+ "help": "商品 SKU ID(如 100291143898)"
4933
+ },
4934
+ {
4935
+ "name": "images",
4936
+ "type": "int",
4937
+ "default": 10,
4938
+ "required": false,
4939
+ "help": "详情图数量(默认10)"
4940
+ }
4941
+ ],
4942
+ "type": "ts",
4943
+ "modulePath": "jd/item.js",
4944
+ "domain": "item.jd.com",
4945
+ "columns": [
4946
+ "title",
4947
+ "price",
4948
+ "shop",
4949
+ "specs",
4950
+ "mainImages",
4951
+ "detailImages"
4952
+ ]
4953
+ },
4969
4954
  {
4970
4955
  "site": "jike",
4971
4956
  "name": "comment",
@@ -5495,6 +5480,36 @@
5495
5480
  "url"
5496
5481
  ]
5497
5482
  },
5483
+ {
5484
+ "site": "linkedin",
5485
+ "name": "timeline",
5486
+ "description": "Read LinkedIn home timeline posts",
5487
+ "strategy": "cookie",
5488
+ "browser": true,
5489
+ "args": [
5490
+ {
5491
+ "name": "limit",
5492
+ "type": "int",
5493
+ "default": 20,
5494
+ "required": false,
5495
+ "help": "Number of posts to return (max 100)"
5496
+ }
5497
+ ],
5498
+ "type": "ts",
5499
+ "modulePath": "linkedin/timeline.js",
5500
+ "domain": "www.linkedin.com",
5501
+ "columns": [
5502
+ "rank",
5503
+ "author",
5504
+ "author_url",
5505
+ "headline",
5506
+ "text",
5507
+ "posted_at",
5508
+ "reactions",
5509
+ "comments",
5510
+ "url"
5511
+ ]
5512
+ },
5498
5513
  {
5499
5514
  "site": "linux-do",
5500
5515
  "name": "categories",
@@ -6134,117 +6149,386 @@
6134
6149
  ]
6135
6150
  },
6136
6151
  {
6137
- "site": "notion",
6138
- "name": "new",
6139
- "description": "Create a new page in Notion",
6140
- "strategy": "ui",
6152
+ "site": "notion",
6153
+ "name": "new",
6154
+ "description": "Create a new page in Notion",
6155
+ "strategy": "ui",
6156
+ "browser": true,
6157
+ "args": [
6158
+ {
6159
+ "name": "title",
6160
+ "type": "str",
6161
+ "required": false,
6162
+ "positional": true,
6163
+ "help": "Page title (optional)"
6164
+ }
6165
+ ],
6166
+ "type": "ts",
6167
+ "modulePath": "notion/new.js",
6168
+ "domain": "localhost",
6169
+ "columns": [
6170
+ "Status"
6171
+ ]
6172
+ },
6173
+ {
6174
+ "site": "notion",
6175
+ "name": "read",
6176
+ "description": "Read the content of the currently open Notion page",
6177
+ "strategy": "ui",
6178
+ "browser": true,
6179
+ "args": [],
6180
+ "type": "ts",
6181
+ "modulePath": "notion/read.js",
6182
+ "domain": "localhost",
6183
+ "columns": [
6184
+ "Title",
6185
+ "Content"
6186
+ ]
6187
+ },
6188
+ {
6189
+ "site": "notion",
6190
+ "name": "search",
6191
+ "description": "Search pages and databases in Notion via Quick Find (Cmd+P)",
6192
+ "strategy": "ui",
6193
+ "browser": true,
6194
+ "args": [
6195
+ {
6196
+ "name": "query",
6197
+ "type": "str",
6198
+ "required": true,
6199
+ "positional": true,
6200
+ "help": "Search query"
6201
+ }
6202
+ ],
6203
+ "type": "ts",
6204
+ "modulePath": "notion/search.js",
6205
+ "domain": "localhost",
6206
+ "columns": [
6207
+ "Index",
6208
+ "Title"
6209
+ ]
6210
+ },
6211
+ {
6212
+ "site": "notion",
6213
+ "name": "sidebar",
6214
+ "description": "List pages and databases from the Notion sidebar",
6215
+ "strategy": "ui",
6216
+ "browser": true,
6217
+ "args": [],
6218
+ "type": "ts",
6219
+ "modulePath": "notion/sidebar.js",
6220
+ "domain": "localhost",
6221
+ "columns": [
6222
+ "Index",
6223
+ "Title"
6224
+ ]
6225
+ },
6226
+ {
6227
+ "site": "notion",
6228
+ "name": "status",
6229
+ "description": "Check active CDP connection to Notion Desktop",
6230
+ "strategy": "ui",
6231
+ "browser": true,
6232
+ "args": [],
6233
+ "type": "ts",
6234
+ "modulePath": "notion/status.js",
6235
+ "domain": "localhost",
6236
+ "columns": [
6237
+ "Status",
6238
+ "Url",
6239
+ "Title"
6240
+ ]
6241
+ },
6242
+ {
6243
+ "site": "notion",
6244
+ "name": "write",
6245
+ "description": "Append text content to the currently open Notion page",
6246
+ "strategy": "ui",
6247
+ "browser": true,
6248
+ "args": [
6249
+ {
6250
+ "name": "text",
6251
+ "type": "str",
6252
+ "required": true,
6253
+ "positional": true,
6254
+ "help": "Text to append to the page"
6255
+ }
6256
+ ],
6257
+ "type": "ts",
6258
+ "modulePath": "notion/write.js",
6259
+ "domain": "localhost",
6260
+ "columns": [
6261
+ "Status"
6262
+ ]
6263
+ },
6264
+ {
6265
+ "site": "pixiv",
6266
+ "name": "detail",
6267
+ "description": "View illustration details (tags, stats, URLs)",
6268
+ "domain": "www.pixiv.net",
6269
+ "strategy": "cookie",
6270
+ "browser": true,
6271
+ "args": [
6272
+ {
6273
+ "name": "id",
6274
+ "type": "str",
6275
+ "required": true,
6276
+ "positional": true,
6277
+ "help": "Illustration ID"
6278
+ }
6279
+ ],
6280
+ "columns": [
6281
+ "illust_id",
6282
+ "title",
6283
+ "author",
6284
+ "type",
6285
+ "pages",
6286
+ "bookmarks",
6287
+ "likes",
6288
+ "views",
6289
+ "tags",
6290
+ "created",
6291
+ "url"
6292
+ ],
6293
+ "pipeline": [
6294
+ {
6295
+ "navigate": "https://www.pixiv.net"
6296
+ },
6297
+ {
6298
+ "evaluate": "(async () => {\n const id = ${{ args.id | json }};\n const res = await fetch(\n 'https://www.pixiv.net/ajax/illust/' + id,\n { credentials: 'include' }\n );\n if (!res.ok) {\n if (res.status === 401 || res.status === 403) throw new Error('Authentication required — please log in to Pixiv in Chrome');\n if (res.status === 404) throw new Error('Illustration not found: ' + id);\n throw new Error('Pixiv request failed (HTTP ' + res.status + ')');\n }\n const data = await res.json();\n const b = data?.body;\n if (!b) throw new Error('Illustration not found');\n return [{\n illust_id: b.illustId,\n title: b.illustTitle,\n author: b.userName,\n user_id: b.userId,\n type: b.illustType === 0 ? 'illust' : b.illustType === 1 ? 'manga' : b.illustType === 2 ? 'ugoira' : String(b.illustType),\n pages: b.pageCount,\n bookmarks: b.bookmarkCount,\n likes: b.likeCount,\n views: b.viewCount,\n tags: (b.tags?.tags || []).map(t => t.tag).join(', '),\n created: b.createDate?.split('T')[0] || '',\n url: 'https://www.pixiv.net/artworks/' + b.illustId\n }];\n})()\n"
6299
+ }
6300
+ ],
6301
+ "type": "yaml"
6302
+ },
6303
+ {
6304
+ "site": "pixiv",
6305
+ "name": "download",
6306
+ "description": "Download illustration images from Pixiv",
6307
+ "strategy": "cookie",
6141
6308
  "browser": true,
6142
6309
  "args": [
6143
6310
  {
6144
- "name": "title",
6311
+ "name": "illust-id",
6145
6312
  "type": "str",
6146
- "required": false,
6313
+ "required": true,
6147
6314
  "positional": true,
6148
- "help": "Page title (optional)"
6315
+ "help": "Illustration ID"
6316
+ },
6317
+ {
6318
+ "name": "output",
6319
+ "type": "str",
6320
+ "default": "./pixiv-downloads",
6321
+ "required": false,
6322
+ "help": "Output directory"
6149
6323
  }
6150
6324
  ],
6151
6325
  "type": "ts",
6152
- "modulePath": "notion/new.js",
6153
- "domain": "localhost",
6154
- "columns": [
6155
- "Status"
6156
- ]
6157
- },
6158
- {
6159
- "site": "notion",
6160
- "name": "read",
6161
- "description": "Read the content of the currently open Notion page",
6162
- "strategy": "ui",
6163
- "browser": true,
6164
- "args": [],
6165
- "type": "ts",
6166
- "modulePath": "notion/read.js",
6167
- "domain": "localhost",
6326
+ "modulePath": "pixiv/download.js",
6327
+ "domain": "www.pixiv.net",
6168
6328
  "columns": [
6169
- "Title",
6170
- "Content"
6329
+ "index",
6330
+ "type",
6331
+ "status",
6332
+ "size"
6171
6333
  ]
6172
6334
  },
6173
6335
  {
6174
- "site": "notion",
6175
- "name": "search",
6176
- "description": "Search pages and databases in Notion via Quick Find (Cmd+P)",
6177
- "strategy": "ui",
6336
+ "site": "pixiv",
6337
+ "name": "illusts",
6338
+ "description": "List a Pixiv artist",
6339
+ "strategy": "cookie",
6178
6340
  "browser": true,
6179
6341
  "args": [
6180
6342
  {
6181
- "name": "query",
6343
+ "name": "user-id",
6182
6344
  "type": "str",
6183
6345
  "required": true,
6184
6346
  "positional": true,
6185
- "help": "Search query"
6347
+ "help": "Pixiv user ID"
6348
+ },
6349
+ {
6350
+ "name": "limit",
6351
+ "type": "int",
6352
+ "default": 20,
6353
+ "required": false,
6354
+ "help": "Number of results"
6186
6355
  }
6187
6356
  ],
6188
6357
  "type": "ts",
6189
- "modulePath": "notion/search.js",
6190
- "domain": "localhost",
6358
+ "modulePath": "pixiv/illusts.js",
6359
+ "domain": "www.pixiv.net",
6191
6360
  "columns": [
6192
- "Index",
6193
- "Title"
6361
+ "rank",
6362
+ "title",
6363
+ "illust_id",
6364
+ "pages",
6365
+ "bookmarks",
6366
+ "tags",
6367
+ "created"
6194
6368
  ]
6195
6369
  },
6196
6370
  {
6197
- "site": "notion",
6198
- "name": "sidebar",
6199
- "description": "List pages and databases from the Notion sidebar",
6200
- "strategy": "ui",
6371
+ "site": "pixiv",
6372
+ "name": "ranking",
6373
+ "description": "Pixiv illustration rankings (daily/weekly/monthly)",
6374
+ "domain": "www.pixiv.net",
6375
+ "strategy": "cookie",
6201
6376
  "browser": true,
6202
- "args": [],
6203
- "type": "ts",
6204
- "modulePath": "notion/sidebar.js",
6205
- "domain": "localhost",
6377
+ "args": [
6378
+ {
6379
+ "name": "mode",
6380
+ "type": "str",
6381
+ "default": "daily",
6382
+ "required": false,
6383
+ "help": "Ranking mode",
6384
+ "choices": [
6385
+ "daily",
6386
+ "weekly",
6387
+ "monthly",
6388
+ "rookie",
6389
+ "original",
6390
+ "male",
6391
+ "female",
6392
+ "daily_r18",
6393
+ "weekly_r18"
6394
+ ]
6395
+ },
6396
+ {
6397
+ "name": "page",
6398
+ "type": "int",
6399
+ "default": 1,
6400
+ "required": false,
6401
+ "help": "Page number"
6402
+ },
6403
+ {
6404
+ "name": "limit",
6405
+ "type": "int",
6406
+ "default": 20,
6407
+ "required": false,
6408
+ "help": "Number of results"
6409
+ }
6410
+ ],
6206
6411
  "columns": [
6207
- "Index",
6208
- "Title"
6209
- ]
6412
+ "rank",
6413
+ "title",
6414
+ "author",
6415
+ "illust_id",
6416
+ "pages",
6417
+ "bookmarks"
6418
+ ],
6419
+ "pipeline": [
6420
+ {
6421
+ "navigate": "https://www.pixiv.net"
6422
+ },
6423
+ {
6424
+ "evaluate": "(async () => {\n const mode = ${{ args.mode | json }};\n const page = ${{ args.page | json }};\n const limit = ${{ args.limit | json }};\n const res = await fetch(\n 'https://www.pixiv.net/ranking.php?mode=' + mode + '&p=' + page + '&format=json',\n { credentials: 'include' }\n );\n if (!res.ok) {\n if (res.status === 401 || res.status === 403) throw new Error('Authentication required — please log in to Pixiv in Chrome');\n throw new Error('Pixiv request failed (HTTP ' + res.status + ')');\n }\n const data = await res.json();\n const items = (data?.contents || []).slice(0, limit);\n return items.map((item, i) => ({\n rank: item.rank,\n title: item.title,\n author: item.user_name,\n user_id: item.user_id,\n illust_id: item.illust_id,\n pages: item.illust_page_count,\n bookmarks: item.illust_bookmark_count,\n url: 'https://www.pixiv.net/artworks/' + item.illust_id\n }));\n})()\n"
6425
+ }
6426
+ ],
6427
+ "type": "yaml"
6210
6428
  },
6211
6429
  {
6212
- "site": "notion",
6213
- "name": "status",
6214
- "description": "Check active CDP connection to Notion Desktop",
6215
- "strategy": "ui",
6430
+ "site": "pixiv",
6431
+ "name": "search",
6432
+ "description": "Search Pixiv illustrations by keyword",
6433
+ "strategy": "cookie",
6216
6434
  "browser": true,
6217
- "args": [],
6435
+ "args": [
6436
+ {
6437
+ "name": "query",
6438
+ "type": "str",
6439
+ "required": true,
6440
+ "positional": true,
6441
+ "help": "Search keyword or tag"
6442
+ },
6443
+ {
6444
+ "name": "limit",
6445
+ "type": "int",
6446
+ "default": 20,
6447
+ "required": false,
6448
+ "help": "Number of results"
6449
+ },
6450
+ {
6451
+ "name": "order",
6452
+ "type": "str",
6453
+ "default": "date_d",
6454
+ "required": false,
6455
+ "help": "Sort order",
6456
+ "choices": [
6457
+ "date_d",
6458
+ "date",
6459
+ "popular_d",
6460
+ "popular_male_d",
6461
+ "popular_female_d"
6462
+ ]
6463
+ },
6464
+ {
6465
+ "name": "mode",
6466
+ "type": "str",
6467
+ "default": "all",
6468
+ "required": false,
6469
+ "help": "Search mode",
6470
+ "choices": [
6471
+ "all",
6472
+ "safe",
6473
+ "r18"
6474
+ ]
6475
+ },
6476
+ {
6477
+ "name": "page",
6478
+ "type": "int",
6479
+ "default": 1,
6480
+ "required": false,
6481
+ "help": "Page number"
6482
+ }
6483
+ ],
6218
6484
  "type": "ts",
6219
- "modulePath": "notion/status.js",
6220
- "domain": "localhost",
6485
+ "modulePath": "pixiv/search.js",
6486
+ "domain": "www.pixiv.net",
6221
6487
  "columns": [
6222
- "Status",
6223
- "Url",
6224
- "Title"
6488
+ "rank",
6489
+ "title",
6490
+ "author",
6491
+ "illust_id",
6492
+ "pages",
6493
+ "bookmarks",
6494
+ "tags"
6225
6495
  ]
6226
6496
  },
6227
6497
  {
6228
- "site": "notion",
6229
- "name": "write",
6230
- "description": "Append text content to the currently open Notion page",
6231
- "strategy": "ui",
6498
+ "site": "pixiv",
6499
+ "name": "user",
6500
+ "description": "View Pixiv artist profile",
6501
+ "domain": "www.pixiv.net",
6502
+ "strategy": "cookie",
6232
6503
  "browser": true,
6233
6504
  "args": [
6234
6505
  {
6235
- "name": "text",
6506
+ "name": "uid",
6236
6507
  "type": "str",
6237
6508
  "required": true,
6238
6509
  "positional": true,
6239
- "help": "Text to append to the page"
6510
+ "help": "Pixiv user ID"
6240
6511
  }
6241
6512
  ],
6242
- "type": "ts",
6243
- "modulePath": "notion/write.js",
6244
- "domain": "localhost",
6245
6513
  "columns": [
6246
- "Status"
6247
- ]
6514
+ "user_id",
6515
+ "name",
6516
+ "premium",
6517
+ "following",
6518
+ "illusts",
6519
+ "manga",
6520
+ "novels",
6521
+ "comment"
6522
+ ],
6523
+ "pipeline": [
6524
+ {
6525
+ "navigate": "https://www.pixiv.net"
6526
+ },
6527
+ {
6528
+ "evaluate": "(async () => {\n const uid = ${{ args.uid | json }};\n const res = await fetch(\n 'https://www.pixiv.net/ajax/user/' + uid + '?full=1',\n { credentials: 'include' }\n );\n if (!res.ok) {\n if (res.status === 401 || res.status === 403) throw new Error('Authentication required — please log in to Pixiv in Chrome');\n if (res.status === 404) throw new Error('User not found: ' + uid);\n throw new Error('Pixiv request failed (HTTP ' + res.status + ')');\n }\n const data = await res.json();\n const b = data?.body;\n if (!b) throw new Error('User not found');\n return [{\n user_id: uid,\n name: b.name,\n premium: b.premium ? 'Yes' : 'No',\n following: b.following,\n illusts: typeof b.illusts === 'object' ? Object.keys(b.illusts).length : (b.illusts || 0),\n manga: typeof b.manga === 'object' ? Object.keys(b.manga).length : (b.manga || 0),\n novels: typeof b.novels === 'object' ? Object.keys(b.novels).length : (b.novels || 0),\n comment: (b.comment || '').slice(0, 80),\n url: 'https://www.pixiv.net/users/' + uid\n }];\n})()\n"
6529
+ }
6530
+ ],
6531
+ "type": "yaml"
6248
6532
  },
6249
6533
  {
6250
6534
  "site": "reddit",
@@ -7864,6 +8148,7 @@
7864
8148
  "rank",
7865
8149
  "desc",
7866
8150
  "author",
8151
+ "url",
7867
8152
  "plays",
7868
8153
  "likes",
7869
8154
  "comments",
@@ -7877,7 +8162,7 @@
7877
8162
  }
7878
8163
  },
7879
8164
  {
7880
- "evaluate": "(async () => {\n const query = ${{ args.query | json }};\n const limit = ${{ args.limit }};\n const res = await fetch('/api/search/general/full/?keyword=' + encodeURIComponent(query) + '&offset=0&count=' + limit + '&aid=1988', { credentials: 'include' });\n if (!res.ok) throw new Error('Search failed: HTTP ' + res.status);\n const data = await res.json();\n const items = (data.data || []).filter(function(i) { return i.type === 1 && i.item; });\n return items.slice(0, limit).map(function(i, idx) {\n var v = i.item;\n var a = v.author || {};\n var s = v.stats || {};\n return {\n rank: idx + 1,\n desc: (v.desc || '').replace(/\\n/g, ' ').substring(0, 100),\n author: a.uniqueId || '',\n plays: s.playCount || 0,\n likes: s.diggCount || 0,\n comments: s.commentCount || 0,\n shares: s.shareCount || 0,\n };\n });\n})()\n"
8165
+ "evaluate": "(async () => {\n const query = ${{ args.query | json }};\n const limit = ${{ args.limit }};\n const res = await fetch('/api/search/general/full/?keyword=' + encodeURIComponent(query) + '&offset=0&count=' + limit + '&aid=1988', { credentials: 'include' });\n if (!res.ok) throw new Error('Search failed: HTTP ' + res.status);\n const data = await res.json();\n const items = (data.data || []).filter(function(i) { return i.type === 1 && i.item; });\n return items.slice(0, limit).map(function(i, idx) {\n var v = i.item;\n var a = v.author || {};\n var s = v.stats || {};\n return {\n rank: idx + 1,\n desc: (v.desc || '').replace(/\\n/g, ' ').substring(0, 100),\n author: a.uniqueId || '',\n url: (a.uniqueId && v.id) ? 'https://www.tiktok.com/@' + a.uniqueId + '/video/' + v.id : '',\n plays: s.playCount || 0,\n likes: s.diggCount || 0,\n comments: s.commentCount || 0,\n shares: s.shareCount || 0,\n };\n });\n})()\n"
7881
8166
  }
7882
8167
  ],
7883
8168
  "type": "yaml"
@@ -9140,6 +9425,52 @@
9140
9425
  ],
9141
9426
  "type": "yaml"
9142
9427
  },
9428
+ {
9429
+ "site": "web",
9430
+ "name": "read",
9431
+ "description": "Fetch any web page and export as Markdown",
9432
+ "strategy": "cookie",
9433
+ "browser": true,
9434
+ "args": [
9435
+ {
9436
+ "name": "url",
9437
+ "type": "str",
9438
+ "required": true,
9439
+ "help": "Any web page URL"
9440
+ },
9441
+ {
9442
+ "name": "output",
9443
+ "type": "str",
9444
+ "default": "./web-articles",
9445
+ "required": false,
9446
+ "help": "Output directory"
9447
+ },
9448
+ {
9449
+ "name": "download-images",
9450
+ "type": "boolean",
9451
+ "default": true,
9452
+ "required": false,
9453
+ "help": "Download images locally"
9454
+ },
9455
+ {
9456
+ "name": "wait",
9457
+ "type": "int",
9458
+ "default": 3,
9459
+ "required": false,
9460
+ "help": "Seconds to wait after page load"
9461
+ }
9462
+ ],
9463
+ "type": "ts",
9464
+ "modulePath": "web/read.js",
9465
+ "columns": [
9466
+ "title",
9467
+ "author",
9468
+ "publish_time",
9469
+ "status",
9470
+ "size"
9471
+ ],
9472
+ "navigateBefore": false
9473
+ },
9143
9474
  {
9144
9475
  "site": "weibo",
9145
9476
  "name": "hot",
@@ -10149,6 +10480,56 @@
10149
10480
  ],
10150
10481
  "type": "yaml"
10151
10482
  },
10483
+ {
10484
+ "site": "xueqiu",
10485
+ "name": "fund-holdings",
10486
+ "description": "获取蛋卷基金持仓明细(可用 --account 按子账户过滤)",
10487
+ "strategy": "cookie",
10488
+ "browser": true,
10489
+ "args": [
10490
+ {
10491
+ "name": "account",
10492
+ "type": "str",
10493
+ "default": "",
10494
+ "required": false,
10495
+ "help": "按子账户名称或 ID 过滤"
10496
+ }
10497
+ ],
10498
+ "type": "ts",
10499
+ "modulePath": "xueqiu/fund-holdings.js",
10500
+ "domain": "danjuanfunds.com",
10501
+ "columns": [
10502
+ "accountName",
10503
+ "fdCode",
10504
+ "fdName",
10505
+ "marketValue",
10506
+ "volume",
10507
+ "dailyGain",
10508
+ "holdGain",
10509
+ "holdGainRate",
10510
+ "marketPercent"
10511
+ ],
10512
+ "navigateBefore": "https://danjuanfunds.com/my-money"
10513
+ },
10514
+ {
10515
+ "site": "xueqiu",
10516
+ "name": "fund-snapshot",
10517
+ "description": "获取蛋卷基金快照(总资产、子账户、持仓,推荐 -f json 输出)",
10518
+ "strategy": "cookie",
10519
+ "browser": true,
10520
+ "args": [],
10521
+ "type": "ts",
10522
+ "modulePath": "xueqiu/fund-snapshot.js",
10523
+ "domain": "danjuanfunds.com",
10524
+ "columns": [
10525
+ "asOf",
10526
+ "totalAssetAmount",
10527
+ "totalFundMarketValue",
10528
+ "accountCount",
10529
+ "holdingCount"
10530
+ ],
10531
+ "navigateBefore": "https://danjuanfunds.com/my-money"
10532
+ },
10152
10533
  {
10153
10534
  "site": "xueqiu",
10154
10535
  "name": "hot-stock",