weaver-work-cli 0.1.1 → 0.1.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 (351) hide show
  1. package/README.md +187 -76
  2. package/dist/cmd/setup/index.js +5 -5
  3. package/dist/cmd/skills/index.js +1 -1
  4. package/dist/core/hooks.js +7 -0
  5. package/dist/index.js +0 -0
  6. package/dist/internal/e10/auth/commands.js +160 -55
  7. package/dist/internal/e10/auth/crypto.js +7 -22
  8. package/dist/internal/e10/auth/session.js +1 -1
  9. package/dist/internal/e10/auth/xiaoe.js +268 -0
  10. package/dist/internal/e10/context.js +16 -2
  11. package/dist/internal/e10/index.js +1 -0
  12. package/dist/internal/e10/request-runtime.js +344 -0
  13. package/dist/internal/skills/install.js +48 -6
  14. package/dist/internal/skills/reader.js +27 -0
  15. package/dist/shortcuts/archive/continuation.js +70 -0
  16. package/dist/shortcuts/archive/errors.js +53 -0
  17. package/dist/shortcuts/archive/host.js +197 -0
  18. package/dist/shortcuts/archive/index.js +363 -0
  19. package/dist/shortcuts/archive/manifest.js +45 -0
  20. package/dist/shortcuts/archive/operations/archive-info.js +55 -0
  21. package/dist/shortcuts/archive/operations/borrow-car.js +146 -0
  22. package/dist/shortcuts/archive/operations/borrow-list.js +200 -0
  23. package/dist/shortcuts/archive/operations/confirm.js +46 -0
  24. package/dist/shortcuts/archive/operations/download.js +238 -0
  25. package/dist/shortcuts/archive/operations/flow-url.js +240 -0
  26. package/dist/shortcuts/archive/operations/fonds.js +95 -0
  27. package/dist/shortcuts/archive/operations/getPageUrl.js +137 -0
  28. package/dist/shortcuts/archive/operations/registry.js +43 -0
  29. package/dist/shortcuts/archive/operations/search.js +88 -0
  30. package/dist/shortcuts/archive/operations/shared.js +120 -0
  31. package/dist/shortcuts/archive/operations/types.js +23 -0
  32. package/dist/shortcuts/archive/operations/upload.js +182 -0
  33. package/dist/shortcuts/archive/operations.js +13 -0
  34. package/dist/shortcuts/archive/render/search-format.js +276 -0
  35. package/dist/shortcuts/archive/render/search-view.js +125 -0
  36. package/dist/shortcuts/asset/continuation.js +70 -0
  37. package/dist/shortcuts/asset/errors.js +67 -0
  38. package/dist/shortcuts/asset/host.js +438 -0
  39. package/dist/shortcuts/asset/index.js +255 -0
  40. package/dist/shortcuts/asset/manifest.js +471 -0
  41. package/dist/shortcuts/asset/operations/query.js +249 -0
  42. package/dist/shortcuts/asset/operations/registry.js +85 -0
  43. package/dist/shortcuts/asset/operations/shared.js +100 -0
  44. package/dist/shortcuts/asset/operations/type-cache.js +49 -0
  45. package/dist/shortcuts/asset/operations/types.js +1 -0
  46. package/dist/shortcuts/asset/operations/viewlink.js +117 -0
  47. package/dist/shortcuts/asset/operations/write.js +435 -0
  48. package/dist/shortcuts/asset/operations.js +9 -0
  49. package/dist/shortcuts/calendar/continuation.js +70 -0
  50. package/dist/shortcuts/calendar/errors.js +53 -0
  51. package/dist/shortcuts/calendar/host.js +148 -0
  52. package/dist/shortcuts/calendar/index.js +125 -0
  53. package/dist/shortcuts/calendar/manifest.js +26 -0
  54. package/dist/shortcuts/calendar/operations/read.js +259 -0
  55. package/dist/shortcuts/calendar/operations/registry.js +31 -0
  56. package/dist/shortcuts/calendar/operations/shared.js +132 -0
  57. package/dist/shortcuts/calendar/operations/types.js +25 -0
  58. package/dist/shortcuts/calendar/operations/write.js +439 -0
  59. package/dist/shortcuts/calendar/operations.js +8 -0
  60. package/dist/shortcuts/ehr/continuation.js +70 -0
  61. package/dist/shortcuts/ehr/errors.js +53 -0
  62. package/dist/shortcuts/ehr/host.js +213 -0
  63. package/dist/shortcuts/ehr/index.js +205 -0
  64. package/dist/shortcuts/ehr/manifest.js +47 -0
  65. package/dist/shortcuts/ehr/operations/attend-read.js +373 -0
  66. package/dist/shortcuts/ehr/operations/attend-write.js +514 -0
  67. package/dist/shortcuts/ehr/operations/hr-contact.js +363 -0
  68. package/dist/shortcuts/ehr/operations/hr-ds.js +298 -0
  69. package/dist/shortcuts/ehr/operations/hr-report.js +386 -0
  70. package/dist/shortcuts/ehr/operations/recruit-write.js +1629 -0
  71. package/dist/shortcuts/ehr/operations/recruit.js +803 -0
  72. package/dist/shortcuts/ehr/operations/registry.js +43 -0
  73. package/dist/shortcuts/ehr/operations/salary.js +319 -0
  74. package/dist/shortcuts/ehr/operations/shared.js +246 -0
  75. package/dist/shortcuts/ehr/operations/types.js +25 -0
  76. package/dist/shortcuts/ehr/operations.js +25 -0
  77. package/dist/shortcuts/esb/continuation.js +70 -0
  78. package/dist/shortcuts/esb/errors.js +65 -0
  79. package/dist/shortcuts/esb/host.js +187 -0
  80. package/dist/shortcuts/esb/index.js +112 -0
  81. package/dist/shortcuts/esb/manifest.js +91 -0
  82. package/dist/shortcuts/esb/operations/input-format.js +31 -0
  83. package/dist/shortcuts/esb/operations/registry.js +48 -0
  84. package/dist/shortcuts/esb/operations/shared.js +152 -0
  85. package/dist/shortcuts/esb/operations/trigger.js +76 -0
  86. package/dist/shortcuts/esb/operations/types.js +21 -0
  87. package/dist/shortcuts/esb/operations.js +15 -0
  88. package/dist/shortcuts/fna/continuation.js +70 -0
  89. package/dist/shortcuts/fna/errors.js +59 -0
  90. package/dist/shortcuts/fna/host.js +146 -0
  91. package/dist/shortcuts/fna/index.js +111 -0
  92. package/dist/shortcuts/fna/manifest.js +41 -0
  93. package/dist/shortcuts/fna/operations/budget.js +124 -0
  94. package/dist/shortcuts/fna/operations/expense-center.js +148 -0
  95. package/dist/shortcuts/fna/operations/invoice-writeoff.js +212 -0
  96. package/dist/shortcuts/fna/operations/loan.js +195 -0
  97. package/dist/shortcuts/fna/operations/registry.js +35 -0
  98. package/dist/shortcuts/fna/operations/shared.js +210 -0
  99. package/dist/shortcuts/fna/operations/types.js +25 -0
  100. package/dist/shortcuts/fna/operations.js +19 -0
  101. package/dist/shortcuts/hrm/errors.js +38 -0
  102. package/dist/shortcuts/hrm/host.js +156 -0
  103. package/dist/shortcuts/hrm/index.js +111 -0
  104. package/dist/shortcuts/hrm/manifest.js +32 -0
  105. package/dist/shortcuts/hrm/operations/employee.js +338 -0
  106. package/dist/shortcuts/hrm/operations/org.js +110 -0
  107. package/dist/shortcuts/hrm/operations/position.js +176 -0
  108. package/dist/shortcuts/hrm/operations/registry.js +33 -0
  109. package/dist/shortcuts/hrm/operations/shared.js +143 -0
  110. package/dist/shortcuts/hrm/operations/types.js +23 -0
  111. package/dist/shortcuts/hrm/operations.js +19 -0
  112. package/dist/shortcuts/index.js +20 -0
  113. package/dist/shortcuts/invoice/host.js +99 -94
  114. package/dist/shortcuts/invoice/index.js +65 -61
  115. package/dist/shortcuts/invoice/manifest.js +222 -14
  116. package/dist/shortcuts/invoice/operations/browse-field.js +17 -0
  117. package/dist/shortcuts/invoice/operations/issuing.js +198 -0
  118. package/dist/shortcuts/invoice/operations/ocr-preview.js +6 -3
  119. package/dist/shortcuts/invoice/operations/registry.js +17 -0
  120. package/dist/shortcuts/invoice/operations/reim.js +401 -0
  121. package/dist/shortcuts/invoice/operations/shared.js +271 -6
  122. package/dist/shortcuts/invoice/operations/validate-preview.js +1 -1
  123. package/dist/shortcuts/jiuchuanhui/cache.js +441 -0
  124. package/dist/shortcuts/jiuchuanhui/continuation.js +70 -0
  125. package/dist/shortcuts/jiuchuanhui/errors.js +59 -0
  126. package/dist/shortcuts/jiuchuanhui/host.js +159 -0
  127. package/dist/shortcuts/jiuchuanhui/index.js +109 -0
  128. package/dist/shortcuts/jiuchuanhui/manifest.js +469 -0
  129. package/dist/shortcuts/jiuchuanhui/operations/datajson.js +214 -0
  130. package/dist/shortcuts/jiuchuanhui/operations/esb.js +157 -0
  131. package/dist/shortcuts/jiuchuanhui/operations/generic.js +146 -0
  132. package/dist/shortcuts/jiuchuanhui/operations/registry.js +133 -0
  133. package/dist/shortcuts/jiuchuanhui/operations/shared.js +158 -0
  134. package/dist/shortcuts/jiuchuanhui/operations/types.js +1 -0
  135. package/dist/shortcuts/jiuchuanhui/operations.js +8 -0
  136. package/dist/shortcuts/mail/continuation.js +70 -0
  137. package/dist/shortcuts/mail/errors.js +53 -0
  138. package/dist/shortcuts/mail/host.js +182 -0
  139. package/dist/shortcuts/mail/index.js +519 -0
  140. package/dist/shortcuts/mail/manifest.js +38 -0
  141. package/dist/shortcuts/mail/operations/mail-blacklist.js +79 -0
  142. package/dist/shortcuts/mail/operations/mail-contacts.js +195 -0
  143. package/dist/shortcuts/mail/operations/mail-manage.js +335 -0
  144. package/dist/shortcuts/mail/operations/mail-read.js +508 -0
  145. package/dist/shortcuts/mail/operations/mail-send.js +474 -0
  146. package/dist/shortcuts/mail/operations/mail-sign.js +203 -0
  147. package/dist/shortcuts/mail/operations/mail-template.js +170 -0
  148. package/dist/shortcuts/mail/operations/registry.js +41 -0
  149. package/dist/shortcuts/mail/operations/shared.js +64 -0
  150. package/dist/shortcuts/mail/operations/types.js +27 -0
  151. package/dist/shortcuts/mail/operations.js +19 -0
  152. package/dist/shortcuts/plan/continuation.js +70 -0
  153. package/dist/shortcuts/plan/errors.js +70 -0
  154. package/dist/shortcuts/plan/host.js +180 -0
  155. package/dist/shortcuts/plan/index.js +150 -0
  156. package/dist/shortcuts/plan/manifest.js +53 -0
  157. package/dist/shortcuts/plan/operations/link.js +256 -0
  158. package/dist/shortcuts/plan/operations/read.js +259 -0
  159. package/dist/shortcuts/plan/operations/registry.js +33 -0
  160. package/dist/shortcuts/plan/operations/shared.js +246 -0
  161. package/dist/shortcuts/plan/operations/types.js +49 -0
  162. package/dist/shortcuts/plan/operations/version.js +49 -0
  163. package/dist/shortcuts/plan/operations/write.js +710 -0
  164. package/dist/shortcuts/plan/operations.js +8 -0
  165. package/docs/SKILL.md +11 -7
  166. package/docs/_catalog.md +23 -5
  167. package/docs/agent-invoice.md +31 -10
  168. package/docs/agent-skill-install.md +211 -0
  169. package/docs/calendar.md +87 -0
  170. package/docs/e10-auth.md +28 -9
  171. package/docs/ehr.md +186 -0
  172. package/docs/esb.md +64 -0
  173. package/docs/fna.md +72 -0
  174. package/docs/hrm.md +89 -0
  175. package/docs/invoice.md +66 -20
  176. package/docs/jiuchuanhui.md +131 -0
  177. package/docs/operation-manual.md +443 -0
  178. package/docs/plan.md +82 -0
  179. package/docs/wenshuding.md +129 -0
  180. package/docs/ziguanjia.md +89 -0
  181. package/package.json +4 -4
  182. package/scripts/package-skill.mjs +127 -34
  183. package/scripts/postbuild.mjs +13 -0
  184. package/skill-template/business-info.json +13 -2
  185. package/skill-template/domains/calendar.md +15 -0
  186. package/skill-template/domains/esb.md +13 -0
  187. package/skill-template/domains/hrm.md +16 -0
  188. package/skill-template/domains/jiuchuanhui.md +23 -0
  189. package/skill-template/domains/jucailin.md +22 -0
  190. package/skill-template/domains/mail.md +21 -0
  191. package/skill-template/domains/plan.md +17 -0
  192. package/skill-template/domains/qiyecheng.md +17 -0
  193. package/skill-template/domains/shared.md +9 -3
  194. package/skill-template/domains/skill-maker.md +10 -0
  195. package/skill-template/domains/wenshuding.md +22 -0
  196. package/skill-template/domains/{invoice.md → yepiaotong.md} +4 -0
  197. package/skill-template/domains/ziguanjia.md +21 -0
  198. package/skill-template/master-skill-template.md +12 -6
  199. package/skill-template/skill-template.md +40 -9
  200. package/skills/weaver-e10-calendar/SKILL.md +101 -0
  201. package/skills/weaver-e10-calendar/product.json +8 -0
  202. package/skills/weaver-e10-calendar/references/calendar-app-check.md +65 -0
  203. package/skills/weaver-e10-calendar/references/calendar-dict.md +55 -0
  204. package/skills/weaver-e10-calendar/references/calendar-query.md +70 -0
  205. package/skills/weaver-e10-calendar/references/calendar-write.md +97 -0
  206. package/skills/weaver-e10-calendar/references/source-manifest.json +54 -0
  207. package/skills/weaver-e10-esb/SKILL.md +102 -0
  208. package/skills/weaver-e10-esb/product.json +8 -0
  209. package/skills/weaver-e10-esb/references/input-format.md +52 -0
  210. package/skills/weaver-e10-esb/references/source-manifest.json +242 -0
  211. package/skills/weaver-e10-esb/references/trigger.md +99 -0
  212. package/skills/weaver-e10-hrm/SKILL.md +87 -0
  213. package/skills/weaver-e10-hrm/product.json +8 -0
  214. package/skills/weaver-e10-hrm/references/employee.md +109 -0
  215. package/skills/weaver-e10-hrm/references/org.md +95 -0
  216. package/skills/weaver-e10-hrm/references/position.md +95 -0
  217. package/skills/weaver-e10-hrm/references/source-manifest.json +121 -0
  218. package/skills/weaver-e10-jiuchuanhui/SKILL.md +174 -0
  219. package/skills/weaver-e10-jiuchuanhui/product.json +8 -0
  220. package/skills/weaver-e10-jiuchuanhui/references/cache.md +110 -0
  221. package/skills/weaver-e10-jiuchuanhui/references/clue.md +61 -0
  222. package/skills/weaver-e10-jiuchuanhui/references/contact-plan.md +56 -0
  223. package/skills/weaver-e10-jiuchuanhui/references/contact-records.md +48 -0
  224. package/skills/weaver-e10-jiuchuanhui/references/contact.md +56 -0
  225. package/skills/weaver-e10-jiuchuanhui/references/customer.md +69 -0
  226. package/skills/weaver-e10-jiuchuanhui/references/disabled-capabilities.md +24 -0
  227. package/skills/weaver-e10-jiuchuanhui/references/discovery-config.md +60 -0
  228. package/skills/weaver-e10-jiuchuanhui/references/general-helpers.md +59 -0
  229. package/skills/weaver-e10-jiuchuanhui/references/jiuchuanhui-entry.md +60 -0
  230. package/skills/weaver-e10-jiuchuanhui/references/sale.md +72 -0
  231. package/skills/weaver-e10-jiuchuanhui/references/source-manifest.json +2632 -0
  232. package/skills/weaver-e10-jucailin/SKILL.md +101 -0
  233. package/skills/weaver-e10-jucailin/product.json +8 -0
  234. package/skills/weaver-e10-jucailin/references/attend-read.md +73 -0
  235. package/skills/weaver-e10-jucailin/references/attend-write.md +82 -0
  236. package/skills/weaver-e10-jucailin/references/hr-contact.md +92 -0
  237. package/skills/weaver-e10-jucailin/references/hr-datasource.md +104 -0
  238. package/skills/weaver-e10-jucailin/references/hr-report.md +76 -0
  239. package/skills/weaver-e10-jucailin/references/recruit-read.md +76 -0
  240. package/skills/weaver-e10-jucailin/references/recruit-write.md +70 -0
  241. package/skills/weaver-e10-jucailin/references/safety-boundaries.md +35 -0
  242. package/skills/weaver-e10-jucailin/references/salary.md +110 -0
  243. package/skills/weaver-e10-jucailin/references/source-manifest.json +152 -0
  244. package/skills/weaver-e10-mail/SKILL.md +151 -0
  245. package/skills/weaver-e10-mail/product.json +8 -0
  246. package/skills/weaver-e10-mail/references/mail-agent-entry.md +47 -0
  247. package/skills/weaver-e10-mail/references/mail-attachment.md +30 -0
  248. package/skills/weaver-e10-mail/references/mail-blacklist.md +27 -0
  249. package/skills/weaver-e10-mail/references/mail-contacts.md +33 -0
  250. package/skills/weaver-e10-mail/references/mail-manage.md +44 -0
  251. package/skills/weaver-e10-mail/references/mail-read.md +76 -0
  252. package/skills/weaver-e10-mail/references/mail-send.md +43 -0
  253. package/skills/weaver-e10-mail/references/mail-sign.md +33 -0
  254. package/skills/weaver-e10-mail/references/mail-template.md +31 -0
  255. package/skills/weaver-e10-mail/references/safety-boundaries.md +32 -0
  256. package/skills/weaver-e10-plan/SKILL.md +139 -0
  257. package/skills/weaver-e10-plan/product.json +8 -0
  258. package/skills/weaver-e10-plan/references/plan-collect-and-compose.md +123 -0
  259. package/skills/weaver-e10-plan/references/plan-overview-and-routing.md +138 -0
  260. package/skills/weaver-e10-plan/references/plan-report-query.md +154 -0
  261. package/skills/weaver-e10-plan/references/plan-report-remind.md +104 -0
  262. package/skills/weaver-e10-plan/references/plan-report-write.md +162 -0
  263. package/skills/weaver-e10-plan/references/source-manifest.json +858 -0
  264. package/skills/weaver-e10-qiyecheng/SKILL.md +118 -0
  265. package/skills/weaver-e10-qiyecheng/product.json +8 -0
  266. package/skills/weaver-e10-qiyecheng/references/budget.md +65 -0
  267. package/skills/weaver-e10-qiyecheng/references/catalog.md +56 -0
  268. package/skills/weaver-e10-qiyecheng/references/expense-center.md +51 -0
  269. package/skills/weaver-e10-qiyecheng/references/invoice-writeoff.md +57 -0
  270. package/skills/weaver-e10-qiyecheng/references/loan-management.md +59 -0
  271. package/skills/weaver-e10-qiyecheng/references/source-manifest.json +698 -0
  272. package/skills/weaver-e10-shared/SKILL.md +86 -0
  273. package/skills/weaver-e10-shared/references/e10-auth-and-session.md +127 -0
  274. package/skills/weaver-e10-shared/references/json-output-contract.md +120 -0
  275. package/skills/weaver-e10-shared/references/weaver-e10-installation.md +110 -0
  276. package/skills/weaver-e10-skill-maker/SKILL.md +77 -0
  277. package/skills/weaver-e10-skill-maker/product.json +8 -0
  278. package/skills/weaver-e10-skill-maker/references/business-skill-generation.md +124 -0
  279. package/skills/weaver-e10-skill-maker/references/detector-validation.md +101 -0
  280. package/skills/weaver-e10-skill-maker/references/module-cli-generation.md +230 -0
  281. package/skills/weaver-e10-skill-maker/references/post-generation-install.md +105 -0
  282. package/skills/weaver-e10-skill-maker/references/source-update-detection.md +261 -0
  283. package/skills/weaver-e10-skill-maker/references/weaver-skill-style.md +141 -0
  284. package/skills/weaver-e10-wenshuding/SKILL.md +157 -0
  285. package/skills/weaver-e10-wenshuding/product.json +8 -0
  286. package/skills/weaver-e10-wenshuding/references/archive-agent-entry.md +63 -0
  287. package/skills/weaver-e10-wenshuding/references/archive-borrow-car.md +52 -0
  288. package/skills/weaver-e10-wenshuding/references/archive-borrow-list.md +52 -0
  289. package/skills/weaver-e10-wenshuding/references/archive-disabled-capabilities.md +22 -0
  290. package/skills/weaver-e10-wenshuding/references/archive-download.md +48 -0
  291. package/skills/weaver-e10-wenshuding/references/archive-flow.md +46 -0
  292. package/skills/weaver-e10-wenshuding/references/archive-fonds.md +34 -0
  293. package/skills/weaver-e10-wenshuding/references/archive-info.md +33 -0
  294. package/skills/weaver-e10-wenshuding/references/archive-search.md +52 -0
  295. package/skills/weaver-e10-wenshuding/references/archive-upload.md +41 -0
  296. package/skills/weaver-e10-wenshuding/references/source-manifest.json +517 -0
  297. package/skills/weaver-e10-yepiaotong/SKILL.md +184 -0
  298. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-add.md +1 -1
  299. package/skills/weaver-e10-yepiaotong/references/invoice-agent-entry.md +47 -0
  300. package/skills/weaver-e10-yepiaotong/references/invoice-browse-field-data.md +204 -0
  301. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-delete.md +1 -1
  302. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-detail.md +13 -5
  303. package/skills/weaver-e10-yepiaotong/references/invoice-disabled-capabilities.md +28 -0
  304. package/skills/weaver-e10-yepiaotong/references/invoice-download.md +31 -0
  305. package/skills/weaver-e10-yepiaotong/references/invoice-enterprise-list.md +45 -0
  306. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-file-upload.md +15 -4
  307. package/skills/weaver-e10-yepiaotong/references/invoice-import.md +45 -0
  308. package/skills/weaver-e10-yepiaotong/references/invoice-issuing-examples.md +120 -0
  309. package/skills/weaver-e10-yepiaotong/references/invoice-issuing-field-rules.md +161 -0
  310. package/skills/weaver-e10-yepiaotong/references/invoice-issuing.md +99 -0
  311. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-ocr-preview.md +14 -4
  312. package/skills/weaver-e10-yepiaotong/references/invoice-personal-list.md +58 -0
  313. package/skills/weaver-e10-yepiaotong/references/invoice-red.md +261 -0
  314. package/skills/weaver-e10-yepiaotong/references/invoice-reim.md +97 -0
  315. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-update.md +1 -1
  316. package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-validation-preview.md +10 -3
  317. package/skills/weaver-e10-yepiaotong/references/reim-api-reference.md +1340 -0
  318. package/skills/weaver-e10-yepiaotong/references/reim-examples.md +845 -0
  319. package/skills/weaver-e10-yepiaotong/references/reim-expense-subject-rules.md +94 -0
  320. package/skills/weaver-e10-yepiaotong/references/reim-form-fill-rules.md +449 -0
  321. package/skills/weaver-e10-yepiaotong/references/reim-matching-rules.md +266 -0
  322. package/skills/weaver-e10-yepiaotong/references/reim-workflow.md +494 -0
  323. package/skills/weaver-e10-yepiaotong/references/source-manifest.json +1103 -0
  324. package/skills/weaver-e10-ziguanjia/SKILL.md +162 -0
  325. package/skills/weaver-e10-ziguanjia/product.json +8 -0
  326. package/skills/weaver-e10-ziguanjia/references/source-manifest.json +147 -0
  327. package/skills/weaver-e10-ziguanjia/references/ziguanjia-agent-entry.md +65 -0
  328. package/skills/weaver-e10-ziguanjia/references/ziguanjia-create.md +45 -0
  329. package/skills/weaver-e10-ziguanjia/references/ziguanjia-depre.md +48 -0
  330. package/skills/weaver-e10-ziguanjia/references/ziguanjia-disabled-capabilities.md +22 -0
  331. package/skills/weaver-e10-ziguanjia/references/ziguanjia-purch.md +57 -0
  332. package/skills/weaver-e10-ziguanjia/references/ziguanjia-query.md +62 -0
  333. package/skills/weaver-e10-ziguanjia/references/ziguanjia-repair.md +83 -0
  334. package/skills/weaver-e10-ziguanjia/references/ziguanjia-resolve.md +49 -0
  335. package/skills/weaver-e10-ziguanjia/references/ziguanjia-return.md +70 -0
  336. package/skills/weaver-e10-ziguanjia/references/ziguanjia-update.md +45 -0
  337. package/skills/weaver-e10-ziguanjia/references/ziguanjia-use.md +60 -0
  338. package/skills/weaver-e10-ziguanjia/references/ziguanjia-viewlink.md +81 -0
  339. package/skills/weaver-work-cli-invoice/SKILL.md +0 -103
  340. package/skills/weaver-work-cli-invoice/references/invoice-agent-entry.md +0 -38
  341. package/skills/weaver-work-cli-invoice/references/invoice-disabled-capabilities.md +0 -26
  342. package/skills/weaver-work-cli-invoice/references/invoice-download.md +0 -22
  343. package/skills/weaver-work-cli-invoice/references/invoice-enterprise-list.md +0 -35
  344. package/skills/weaver-work-cli-invoice/references/invoice-import.md +0 -28
  345. package/skills/weaver-work-cli-invoice/references/invoice-personal-list.md +0 -47
  346. package/skills/weaver-work-cli-shared/SKILL.md +0 -53
  347. package/skills/weaver-work-cli-shared/references/e10-auth-and-session.md +0 -83
  348. package/skills/weaver-work-cli-shared/references/json-output-contract.md +0 -61
  349. package/skills/weaver-work-cli-shared/references/weaver-work-cli-installation.md +0 -61
  350. /package/skills/{weaver-work-cli-shared → weaver-e10-shared}/references/high-risk-write.md +0 -0
  351. /package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/product.json +0 -0
@@ -0,0 +1,83 @@
1
+ # 资产报修
2
+
3
+ ## 什么时候读取
4
+
5
+ 用户要提交资产报修时读取本文件。流程是:先查询报修候选(只读)→ 展示候选并附 AI 维修建议 → 用户确认目标(复述确认)→ 执行报修(需确认链)。
6
+
7
+ ## Operation
8
+
9
+ | Operation | 风险 | 说明 |
10
+ | --- | --- | --- |
11
+ | `asset.repair.query` | read-before-write | 查询报修候选,按 `asset_name` 过滤;不写数据、不返回 continuation |
12
+ | `asset.repair.create` | high-risk-write | 执行报修,需 `confirm:true` + `continuation` |
13
+
14
+ ## 输入要点
15
+
16
+ `asset.repair.query`:`detail1`(按 `asset_name` 过滤的候选列表,每条 `asset_name` 必填)。
17
+
18
+ `asset.repair.create`:必填 `detail1`(至少一条;每条 `asset_id`、`fault_desc` 必填,`fault_time` 可选但**必须为 `YYYY-MM-DD HH:mm`(强制带时分,纯日期会被创建动作流拒绝)**,用户未说明时由 Agent 取当前时间)。可选 `repail_name`(未给时由 Agent 生成,≤15 字)、`repail_remark`。需 `prepare -> apply`。
19
+
20
+ ## 展示候选与 AI 维修建议(query 之后、create 之前必做)
21
+
22
+ `asset.repair.query` 返回候选后,**不要直接进入 create**,按顺序完成:
23
+
24
+ 1. **展示候选**:逐条列出资产名称、资产编号、规格型号与数据 ID(数据 ID 仅内部使用,展示用中文字段含义);多条时必须交由用户挑选,不自行取第一条。
25
+ 2. **AI 维修建议**:对每条候选结合用户给出的故障描述,给出简要维修建议(可能原因 / 排查方向 / 处理建议)。该建议由 AI 基于故障描述推理生成,**不是接口返回**,必须明确标注「维修建议由 AI 生成,仅供参考,最终以维修人员判定为准」,不得伪装成系统权威结论;故障描述缺失时说明无法给出针对性建议并请用户补充。**0 条候选时同样要给出维修建议**,并请用户确认资产名称 / 编号是否准确。
26
+ 3. **复述确认**:进入 create 前向用户复述——报修资产名称 / 编号、故障描述、故障发生时间(`YYYY-MM-DD HH:mm`)——用户明确确认后再执行 `asset.repair.create` 的 prepare/apply 确认链。
27
+
28
+ ## 示例
29
+
30
+ Windows PowerShell:
31
+
32
+ ```powershell
33
+ # 1) 只读查询候选
34
+ weaver-work-cli --json asset run asset.repair.query --input-json '{"detail1":[{"asset_name":"EXAMPLE_ASSET"}]}'
35
+ # 1.5) 展示候选 + AI 维修建议(标注仅供参考)+ 复述确认(Agent 行为,非命令)
36
+ # 2) prepare(返回 continuation)
37
+ weaver-work-cli --json asset run asset.repair.create --input-json '{"detail1":[{"asset_id":"EXAMPLE_ASSET_ID","fault_desc":"EXAMPLE_FAULT","fault_time":"2026-09-07 09:30"}]}'
38
+ # 3) apply(用户确认后)
39
+ weaver-work-cli --json asset run asset.repair.create --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
40
+ ```
41
+
42
+ macOS/Linux(bash/zsh):
43
+
44
+ ```bash
45
+ # 1) 只读查询候选
46
+ weaver-work-cli --json asset run asset.repair.query --input-json '{"detail1":[{"asset_name":"EXAMPLE_ASSET"}]}'
47
+ # 1.5) 展示候选 + AI 维修建议(标注仅供参考)+ 复述确认(Agent 行为,非命令)
48
+ # 2) prepare(返回 continuation)
49
+ weaver-work-cli --json asset run asset.repair.create --input-json '{"detail1":[{"asset_id":"EXAMPLE_ASSET_ID","fault_desc":"EXAMPLE_FAULT","fault_time":"2026-09-07 09:30"}]}'
50
+ # 3) apply(用户确认后)
51
+ weaver-work-cli --json asset run asset.repair.create --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
52
+ ```
53
+
54
+ ## 返回
55
+
56
+ `repair.query` 返回候选:统一含 `resultCode`、`resultMsg`、`mainTable`、`customData`、`responseData`(业务数据在 `mainTable`,等价于 `responseData.customData.mainTable`)。
57
+
58
+ `repair.create` 成功返回同样的统一结构,关键字段在 **`mainTable`**:
59
+
60
+ | 业务含义 | 字段 | 用途 |
61
+ | --- | --- | --- |
62
+ | 报修流程 ID | `lcID` | **作为「查看详情」链接(scene=`asset_repail`)的 dataID** |
63
+ | 流程标题 | `lcbt` | 回报给用户;常见为空 |
64
+ | 报修单号 | `repail_no` / `bxdh`(具体 key 以运行时返回为准,不臆造) | 报修单号,回报给用户的关键标识 |
65
+
66
+ 字段名来自源资料实测记录(`references/repair-apply.md`)+ 通用约定(`_common.md`:所有资产域动作流业务值挂在 `actionData.responseData.customData.mainTable`,响应字段 `lcID` / `lcbt` / `lybh` 等)。
67
+
68
+ 建单后按 `asset.viewlink` 的 `asset_repail` 场景拼链接:
69
+
70
+ ```powershell
71
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_repail","ids":["<上一步返回的 lcID>"]}'
72
+ ```
73
+
74
+ 要点:
75
+ - `lcID` / `repail_no` 常在建单时**尚未回填**(单号由流程内流水号在提交后生成)。此时不要判定失败、不要重试建单;可先用 `weaver-e10-workflow` 读回补齐,或如实说明「报修单号生成中、链接暂不可用」。
76
+ - 链接解析失败只说明「链接暂不可用」,**不影响报修单本身**,绝不因此重试 `repair.create`。
77
+
78
+ ## 注意
79
+
80
+ - `asset_id` 应为已确认的资产数据 ID;先用 `asset.repair.query` 或 `asset.detail` 取得。
81
+ - **维修建议是 Agent 行为,不是命令**:候选展示与 AI 维修建议发生在 `repair.query` 与 `repair.create` 之间,由 Agent 按上文「展示候选与 AI 维修建议」执行,不消耗额外 CLI 调用。
82
+ - `fault_time` 传纯日期(如 `2026-09-07`)会被 schema 拒绝;用户只给日期未给时间时,补成该日某时刻或与用户确认,不要原样传入。
83
+ - 出现 `partial/write_uncertain` 时停止,先做一次只读回查,不要重复提交 apply。
@@ -0,0 +1,49 @@
1
+ # 名称解析(存放地点 / 资产状态 / 资产类型)
2
+
3
+ ## 什么时候读取
4
+
5
+ 用户给出资产状态、资产类型或存放地点的中文名称,而写操作需要对应 ID 时读取本文件。
6
+
7
+ ## Operation 与字段
8
+
9
+ | Operation | 名称字段 | 解析得到的 ID 用途 |
10
+ | --- | --- | --- |
11
+ | `asset.resolve.location` | `house_name` | 写入 `location_browse` |
12
+ | `asset.resolve.status` | `status_name` | 写入 `stateid` |
13
+ | `asset.resolve.type` | `type_name` | 写入 `asset_type_browse` |
14
+
15
+ 三个 operation 均为只读,返回 `items`(含 `id` 与 `name`)。解析到 0 条会报 `resolve_not_found`,解析到多条会报 `resolve_ambiguous` 并要求改用 ID。
16
+
17
+ ### 解析规则(源资料 _dict.md)
18
+
19
+ - **精确优先**:先按名称精确匹配;部分环境名称过滤不生效返回空时,自动回退全量枚举(pageSize 50)后在结果中按名称精确匹配。
20
+ - **模糊兜底**:精确与枚举均无命中时,按 contains 模糊匹配(如用户搜「笔记本」命中正式名「便携式计算机」);仅命中单条即采用,返回 `matched:"contains"` 并在 `note` 中注明映射到正式名;命中多条报 `resolve_ambiguous` 候选。
21
+ - **资产类型缓存**:`asset.resolve.type` 首次解析某环境会全量拉取 `zgjasset_type_info` 并落到 skill 包之外 `~/.workbuddy/data/weaver-e10-ziguanjia/asset_type_cache_{env}.json`(按环境隔离,24h 过期),之后本地匹配不再打接口;该缓存严禁写入 skill 包内。
22
+ - **已知名称映射**:本环境正式名如「便携式计算机」而非「笔记本电脑」、「液晶显示器」而非「显示器」、「办公椅」而非「椅子」、「办公桌」而非「桌子」,模糊匹配会按正式名解析;0 命中如实告知用户该名称在字典中不存在,不强行创建。
23
+
24
+ ## 示例
25
+
26
+ Windows PowerShell:
27
+
28
+ ```powershell
29
+ weaver-work-cli --json asset run asset.resolve.type --input-json '{"type_name":"EXAMPLE_TYPE"}'
30
+ weaver-work-cli --json asset run asset.resolve.status --input-json '{"status_name":"EXAMPLE_STATUS"}'
31
+ weaver-work-cli --json asset run asset.resolve.location --input-json '{"house_name":"EXAMPLE_LOCATION"}'
32
+ ```
33
+
34
+ macOS/Linux(bash/zsh):
35
+
36
+ ```bash
37
+ weaver-work-cli --json asset run asset.resolve.type --input-json '{"type_name":"EXAMPLE_TYPE"}'
38
+ weaver-work-cli --json asset run asset.resolve.status --input-json '{"status_name":"EXAMPLE_STATUS"}'
39
+ weaver-work-cli --json asset run asset.resolve.location --input-json '{"house_name":"EXAMPLE_LOCATION"}'
40
+ ```
41
+
42
+ ## 返回
43
+
44
+ 返回 `items`:`[{ "id": "<解析得到的 ID>", "name": "<名称>" }]`。把 `id` 带入后续写操作的 `asset_type_browse` / `stateid` / `location_browse`。
45
+
46
+ ## 注意
47
+
48
+ - 解析结果 `id` 是字符串,后续写操作必须原样使用,不要重新按名称猜测。
49
+ - 解析到多条时,优先向用户确认用哪一条,或要求用户直接提供 ID,不要随机选取。
@@ -0,0 +1,70 @@
1
+ # 资产归还
2
+
3
+ ## 什么时候读取
4
+
5
+ 用户要归还资产时读取本文件。流程是:先查询可归还候选(只读),再执行归还(需确认链)。
6
+
7
+ ## Operation
8
+
9
+ | Operation | 风险 | 说明 |
10
+ | --- | --- | --- |
11
+ | `asset.return.query` | read-before-write | 查询可归还资产候选,返回候选数据;不写数据、不返回 continuation |
12
+ | `asset.return.create` | high-risk-write | 执行归还,需 `confirm:true` + `continuation` |
13
+
14
+ ## 输入要点
15
+
16
+ `asset.return.query`:可选 `return_type`(`0`=全部归还,`1`=部分归还)、`detail1`(按 `asset_name` 过滤的候选列表)。
17
+
18
+ `asset.return.create`:必填 `data_ids`(半角逗号拼接的确认资产数据 ID,来自 `return.query` 的候选);需 `prepare -> apply`。
19
+
20
+ ## 示例
21
+
22
+ Windows PowerShell:
23
+
24
+ ```powershell
25
+ # 1) 只读查询候选
26
+ weaver-work-cli --json asset run asset.return.query --input-json '{"return_type":"0"}'
27
+ # 2) prepare(返回 continuation)
28
+ weaver-work-cli --json asset run asset.return.create --input-json '{"data_ids":"EXAMPLE_DATA_ID_1,EXAMPLE_DATA_ID_2"}'
29
+ # 3) apply(用户确认后)
30
+ weaver-work-cli --json asset run asset.return.create --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
31
+ ```
32
+
33
+ macOS/Linux(bash/zsh):
34
+
35
+ ```bash
36
+ # 1) 只读查询候选
37
+ weaver-work-cli --json asset run asset.return.query --input-json '{"return_type":"0"}'
38
+ # 2) prepare(返回 continuation)
39
+ weaver-work-cli --json asset run asset.return.create --input-json '{"data_ids":"EXAMPLE_DATA_ID_1,EXAMPLE_DATA_ID_2"}'
40
+ # 3) apply(用户确认后)
41
+ weaver-work-cli --json asset run asset.return.create --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
42
+ ```
43
+
44
+ ## 返回
45
+
46
+ `return.query` 返回候选:统一含 `resultCode`、`resultMsg`、`mainTable`、`customData`、`responseData`(业务数据在 `mainTable`,等价于 `responseData.customData.mainTable`)。
47
+
48
+ `return.create` 成功返回同样的统一结构,关键字段在 **`mainTable`**:
49
+
50
+ | 业务含义 | 字段 | 用途 |
51
+ | --- | --- | --- |
52
+ | 归还流程 ID | `lcID` | **作为「查看详情」链接(scene=`asset_return`)的 dataID** |
53
+ | 流程标题 | `lcbt` | 回报给用户 |
54
+ | 归还编号 | `ghbh` | 归还单号,回报给用户的关键标识 |
55
+
56
+ 建单后按 `asset.viewlink` 的 `asset_return` 场景拼链接:
57
+
58
+ ```powershell
59
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_return","ids":["<上一步返回的 lcID>"]}'
60
+ ```
61
+
62
+ 要点:
63
+ - `lcID` 可能在建单返回时为回填中(空值),此时不要判定失败、不要重试建单;可先用 `weaver-e10-workflow` 读回补齐,或如实说明「归还单号生成中、链接暂不可用」。
64
+ - 链接解析失败只说明「链接暂不可用」,**不影响归还单本身**,绝不因此重试 `return.create`。
65
+
66
+ ## 注意
67
+
68
+ - `data_ids` 必须是 `return.query` 返回的候选数据 ID,不要凭空构造。
69
+ - `return.query` 是只读,不带 `confirm` 也不返回 continuation;只有 `return.create` 走确认链。
70
+ - 出现 `partial/write_uncertain` 时停止,先做一次只读回查,不要重复提交 apply。
@@ -0,0 +1,45 @@
1
+ # 修改资产
2
+
3
+ ## 什么时候读取
4
+
5
+ 用户要修改已存在资产的字段(名称、状态、管理人、使用人、地点、单价、价值等)时读取本文件。
6
+
7
+ ## Operation
8
+
9
+ `asset.update`(风险 `high-risk-write`)。必须 `prepare -> apply`:第一次调用不带 `confirm` 返回 continuation 与变更摘要,用户确认后第二次调用带 `confirm:true` 与 `continuation` 执行。
10
+
11
+ ## 输入要点
12
+
13
+ 以 `weaver-work-cli asset schema` 为准。定位目标(三选一):`id`(资产数据 ID)、`asset_number`、`asset_name`(后两者用于查询定位,命中多条会要求改用 ID)。变更内容放 `changes`,至少包含一个字段:`asset_name`、`stateid`、`admin_istrator`、`resourceid`、`location_browse`、`unit_price`、`value`。
14
+
15
+ `stateid` / `location_browse` 必须是已解析的 ID。
16
+
17
+ ## 示例
18
+
19
+ Windows PowerShell:
20
+
21
+ ```powershell
22
+ # prepare(返回 continuation)
23
+ weaver-work-cli --json asset run asset.update --input-json '{"id":"EXAMPLE_ASSET_ID","changes":{"stateid":"EXAMPLE_STATUS_ID"}}'
24
+ # apply(用户确认后)
25
+ weaver-work-cli --json asset run asset.update --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
26
+ ```
27
+
28
+ macOS/Linux(bash/zsh):
29
+
30
+ ```bash
31
+ # prepare(返回 continuation)
32
+ weaver-work-cli --json asset run asset.update --input-json '{"id":"EXAMPLE_ASSET_ID","changes":{"stateid":"EXAMPLE_STATUS_ID"}}'
33
+ # apply(用户确认后)
34
+ weaver-work-cli --json asset run asset.update --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
35
+ ```
36
+
37
+ ## 返回
38
+
39
+ `apply` 成功返回 `dataIds`、`count` 与目标 `id`。
40
+
41
+ ## 注意
42
+
43
+ - `changes` 只提交需要变更的字段,不要传空值覆盖其它字段。
44
+ - 不要修改 `id` 等内部控制字段。
45
+ - 出现 `partial/write_uncertain` 时停止,先做一次 `asset.detail` 只读回查,不要重复提交 apply。
@@ -0,0 +1,60 @@
1
+ # 资产领用
2
+
3
+ ## 什么时候读取
4
+
5
+ 用户要提交资产领用申请(多条领用明细)时读取本文件。
6
+
7
+ ## Operation
8
+
9
+ `asset.use`(风险 `high-risk-write`)。必须 `prepare -> apply`:第一次调用不带 `confirm` 返回 continuation 与预览,用户确认后第二次调用带 `confirm:true` 与 `continuation` 执行。
10
+
11
+ ## 输入要点
12
+
13
+ 以 `weaver-work-cli asset schema` 为准。必填:`detail1`(数组,至少一条;每条 `apply_info` 必填,`asset_spec`、`asset_remark`、`asset_type`、`use_count` 可选)。可选:`use_location`(领用后地点 ID,经 `asset.resolve.location` 解析)、`purpose`。
14
+
15
+ `detail1[].asset_type` 为资产类型 ID。
16
+
17
+ ## 示例
18
+
19
+ Windows PowerShell:
20
+
21
+ ```powershell
22
+ # prepare(返回 continuation)
23
+ weaver-work-cli --json asset run asset.use --input-json '{"detail1":[{"apply_info":"EXAMPLE_APPLY_INFO","asset_type":"EXAMPLE_TYPE_ID","use_count":1}],"use_location":"EXAMPLE_LOCATION_ID","purpose":"EXAMPLE_PURPOSE"}'
24
+ # apply(用户确认后)
25
+ weaver-work-cli --json asset run asset.use --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
26
+ ```
27
+
28
+ macOS/Linux(bash/zsh):
29
+
30
+ ```bash
31
+ # prepare(返回 continuation)
32
+ weaver-work-cli --json asset run asset.use --input-json '{"detail1":[{"apply_info":"EXAMPLE_APPLY_INFO","asset_type":"EXAMPLE_TYPE_ID","use_count":1}],"use_location":"EXAMPLE_LOCATION_ID","purpose":"EXAMPLE_PURPOSE"}'
33
+ # apply(用户确认后)
34
+ weaver-work-cli --json asset run asset.use --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
35
+ ```
36
+
37
+ ## 返回
38
+
39
+ `apply` 成功返回统一结构:`resultCode`、`resultMsg`、`actionData`、`responseData`、`customData`,以及提到顶层的 **`mainTable`**(= `responseData.customData.mainTable`)。
40
+
41
+ 关键字段在 `mainTable`:
42
+
43
+ | 业务含义 | 字段 | 用途 |
44
+ | --- | --- | --- |
45
+ | 领用流程 ID | `lcID` | **作为「查看详情」链接(scene=`asset_use`)的 dataID** |
46
+ | 流程标题 | `lcbt` | 回报给用户 |
47
+ | 领用单号 | `lybh`(具体 key 以运行时为准) | 领用单号,回报给用户的关键标识 |
48
+
49
+ 建单后按 `asset.viewlink` 的 `asset_use` 场景拼链接:
50
+
51
+ ```powershell
52
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_use","ids":["<上一步返回的 lcID>"]}'
53
+ ```
54
+
55
+ 单号可能为回填中(空值),此时不要重试建单;链接解析失败只说明「链接暂不可用」,不影响领用单本身。
56
+
57
+ ## 注意
58
+
59
+ - 不要把中文地点名称作为 `use_location`,先走 `asset.resolve.location`。
60
+ - 出现 `partial/write_uncertain` 时停止,不要重复提交 apply。
@@ -0,0 +1,81 @@
1
+ # 查看链接(查看详情)
2
+
3
+ ## 什么时候读取
4
+
5
+ 查询、新建、修改或动作流**已经成功**之后,需要给用户一个可点击的「查看详情」入口时读取本文件。
6
+
7
+ 典型场景:资产列表、资产详情、领用记录、报修记录、采购申请列表、报修 / 归还的候选资产名,以及折旧计提任务。
8
+
9
+ ## 链接形态
10
+
11
+ | 形态 | 路径模板 | 是否需要解析表单 ID |
12
+ | --- | --- | --- |
13
+ | 卡片链接 | `/sp/ebdfpage/card/0/{表单ID}/{数据ID}` | 需要,经两步 tag 接口实时解析 |
14
+ | 计提任务(viewport) | `/sp/ebdfpage/viewport/1267093228679077888?calc_month={计提年月}` | 不需要,固定页面 |
15
+
16
+ CLI 同时返回 `path`(去域名路径)和 `url`(用当前登录环境地址拼好的完整链接)。优先直接用 `url`;只有在需要自行拼接域名时才用 `path`。
17
+
18
+ ## 场景与数据来源
19
+
20
+ | 场景(`scene`) | 表单标识(tag) | 数据 ID 来源 |
21
+ | --- | --- | --- |
22
+ | `asset_info` | `uf_asset_info` | 资产列表 / 详情每条记录的 `id`;新建返回 `dataIds`;报修·归还候选资产的 `id` |
23
+ | `asset_use` | `uf_asset_use` | 领用记录每条 `id`;领用申请动作流返回的 `lcID` |
24
+ | `asset_return` | `uf_asset_return` | 归还申请动作流返回的 `lcID` |
25
+ | `asset_repail` | `uf_asset_repail` | 报修记录每条 `id`;报修申请动作流返回的 `lcID` |
26
+ | `asset_purch_apply` | `uf_asset_purch_apply` | 采购申请记录每条 `id`;采购申请动作流返回的 `lcID` |
27
+ | `depre_task` | 无(viewport 固定页面) | 传 `calc_month`,取自本次计提操作 |
28
+
29
+ 表单 ID 由「应用标签 → 表单标签」两步接口实时解析(`weaver-asset-eb` → 上表 tag),**不写死常量、不跨环境沿用**,同环境内会复用解析结果。
30
+
31
+ 建单类动作流(领用 / 归还 / 报修 / 采购)的流程 ID 直接取自该次建单返回的 **`mainTable.lcID`**:`asset.use` / `return.create` / `repair.create` / `purch` 的成功返回都会把 `mainTable`(含 `lcID`、`lcbt`、以及各自的单号如 `ghbh`)透传到顶层,无需再翻嵌套结构。单号可能为回填中(空值),此时不要重试建单。
32
+
33
+ ## 输入要点
34
+
35
+ 字段以 `weaver-work-cli asset schema` 为准:
36
+
37
+ - `scene`:必填,取值见上表。
38
+ - `ids`:数据 ID 数组。**一律按字符串传入**(大整数,避免精度丢失);一次可传多个,逐条生成各自链接。
39
+ - `calc_month`:仅 `depre_task` 场景需要,格式 `YYYY-MM`。
40
+ - `anchor`:可选,覆盖默认锚点文字「查看详情」。
41
+
42
+ ## 示例
43
+
44
+ Windows PowerShell:
45
+
46
+ ```powershell
47
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_info","ids":["EXAMPLE_ASSET_ID","EXAMPLE_ASSET_ID_2"]}'
48
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_use","ids":["EXAMPLE_USE_ID"]}'
49
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"depre_task","calc_month":"2026-08"}'
50
+ ```
51
+
52
+ macOS/Linux(bash/zsh):
53
+
54
+ ```bash
55
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_info","ids":["EXAMPLE_ASSET_ID","EXAMPLE_ASSET_ID_2"]}'
56
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"asset_use","ids":["EXAMPLE_USE_ID"]}'
57
+ weaver-work-cli --json asset run asset.viewlink --input-json '{"scene":"depre_task","calc_month":"2026-08"}'
58
+ ```
59
+
60
+ ## 返回
61
+
62
+ - `available` 为 `true` 时,`links` 数组按传入顺序给出每条记录的 `dataId`、`path`、`url`、`anchor`。
63
+ - `available` 为 `false`(状态 `VIEWLINK_UNAVAILABLE`)时 `links` 为空,`warnings` 说明「链接暂不可用」的原因。这**不是失败**,主操作已经成功,照常回报业务结果即可。
64
+
65
+ ## 展示约定
66
+
67
+ - 以**对话内纯 Markdown 链接**呈现:`[查看详情](url)`。
68
+ - **锚点文字固定为「查看详情」**,严禁加「查看详情:」前缀与冒号,严禁把完整 URL 作为纯文本直接展示。
69
+ - 禁用 widget 内链接与旧版「蓝底白字胶囊按钮」样式。
70
+ - 多条记录**逐条生成各自的链接**,不要只给首条或共用一条。
71
+ - 报修 / 归还的**候选资产名**场景使用变体:锚点即资产名称本身,如 `[笔记本电脑](url)`,传 `anchor` 覆盖。
72
+ - 回报时只展示业务中文名称,不展示内部 key(`lcID`、`lcbt`、`lybh`、`ghbh`、`id` 等仅供拼链接使用)。
73
+ - 单据 / 流程编号尚未回填时,不输出空值行;如实说明「XX 单号生成中」。
74
+
75
+ ## 注意
76
+
77
+ - **链接是附加信息**:主查询 / 新建 / 修改 / 动作流已经成功后,链接解析失败只如实说明「链接暂不可用」,**绝不因此重试主操作**——重试会重复查询、重复建单、重复改动数据。
78
+ - **不要臆造表单 ID / 数据 ID**:解析不到就不给链接,不允许用相近 ID 或历史 ID 拼一个可能打不开的链接。
79
+ - **大整数精度**:表单 ID 与数据 ID 均为长整型,全程按字符串处理。
80
+ - **数据 ID 只取本次结果**:每条记录的 ID 取自本次操作返回,不复用其他查询或上一单的 ID。
81
+ - 本链接不涉及附件、图片或文件解析,无需附件安全确认。
@@ -1,103 +0,0 @@
1
- ---
2
- name: weaver-work-cli-invoice
3
- description: "泛微 E10 业票通发票:查询个人/企业票夹、查看详情、上传/OCR/查验预览/下载附件,并通过 prepare/apply 导入、新增、编辑、删除发票。当用户要处理业票通、发票、票夹、OCR、查验或发票附件时使用。共享、转让、标签当前不在范围。"
4
- metadata:
5
- requires:
6
- bins: ["weaver-work-cli"]
7
- cliHelp: "weaver-work-cli invoice --help"
8
- ---
9
-
10
- **CRITICAL — 开始前 MUST 先用 Read 工具读取 [`../weaver-work-cli-shared/SKILL.md`](../weaver-work-cli-shared/SKILL.md),其中包含安装、E10 认证、JSON 输出和高风险写入规则。**
11
- 所有命令通过 `weaver-work-cli --json invoice run <operation> --input -` 执行。调用前先按需读取 references 下对应的文件,查参数结构,不要猜字段;**references 是第一信息源**,`weaver-work-cli invoice schema` 是 operation、字段和风险等级的合约来源。
12
-
13
- ## 路由优先级(先判断是不是业票通发票,再选 operation)
14
-
15
- 业票通发票不是通用 E10 对象。**只要用户的核心对象是业票通发票、个人/企业票夹、发票 OCR、发票查验或发票附件,就优先使用 `weaver-work-cli-invoice`。**
16
-
17
- ### 明确归 `weaver-work-cli-invoice` 的高优先级语义
18
-
19
- 出现以下任一语义时,优先走本 Skill:
20
-
21
- - 业票通 / 发票 / 票夹 / 个人票夹 / 企业票夹 / 发票详情
22
- - 发票上传 / OCR 识别 / 查验预览 / 附件下载
23
- - 导入发票 / 新增发票 / 编辑发票 / 删除发票
24
- - `fid` / `fileId` / 发票号码 / 发票代码 / 查验状态 / 报销状态
25
-
26
- **判定规则:** 只要最终动作是对业票通发票做查询、查看、上传、OCR、查验预览、下载、导入、新增、编辑或删除,就归 `weaver-work-cli-invoice`。只有当用户处理的是非发票类 E10 业务、通用工作流或尚未封装的业票通能力时,才不使用本 Skill。
27
-
28
- ## 选哪个命令
29
- | 想做什么 | 命令 | 按需读取 reference |
30
- |---|---|---|
31
- | 查看可用 operation、字段和风险等级 | `invoice schema` | [`invoice-agent-entry.md`](references/invoice-agent-entry.md) |
32
- | 查询个人票夹 | `invoice run invoice.list` | [`invoice-personal-list.md`](references/invoice-personal-list.md) |
33
- | 查询企业票夹 | `invoice run invoice.enterprise.list` | [`invoice-enterprise-list.md`](references/invoice-enterprise-list.md) |
34
- | 按 `fid` 或 `number` 查看详情 | `invoice run invoice.get` | [`invoice-detail.md`](references/invoice-detail.md) |
35
- | 上传发票文件 | `invoice run invoice.upload` | [`invoice-file-upload.md`](references/invoice-file-upload.md) |
36
- | OCR 预览,不保存到票夹 | `invoice run invoice.ocr.preview` | [`invoice-ocr-preview.md`](references/invoice-ocr-preview.md) |
37
- | 查验预览,不回写查验结果 | `invoice run invoice.validate.preview` | [`invoice-validation-preview.md`](references/invoice-validation-preview.md) |
38
- | 下载发票附件 | `invoice run invoice.download` | [`invoice-download.md`](references/invoice-download.md) |
39
- | 准备/确认导入发票文件 | `invoice run invoice.import.prepare/apply` | [`invoice-import.md`](references/invoice-import.md) |
40
- | 准备/确认手工新增发票 | `invoice run invoice.add.prepare/apply` | [`invoice-add.md`](references/invoice-add.md) |
41
- | 准备/确认编辑发票 | `invoice run invoice.update.prepare/apply` | [`invoice-update.md`](references/invoice-update.md) |
42
- | 准备/确认删除发票 | `invoice run invoice.delete.prepare/apply` | [`invoice-delete.md`](references/invoice-delete.md) |
43
- | 共享、转让、标签或 schema 未列出的能力 | 无可用命令 | [`invoice-disabled-capabilities.md`](references/invoice-disabled-capabilities.md) |
44
-
45
- 处理链:
46
-
47
- - 查票夹/详情:`invoice.list` 或 `invoice.enterprise.list` -> 必要时 `invoice.get`
48
- - OCR 识别预览:`invoice.ocr.preview`;如果先上传,可复用 `invoice.upload` 返回的 `upload`
49
- - 导入文件:`invoice.import.prepare` -> 用户确认 -> `invoice.import.apply` -> 按返回 `fid` 回查/报告
50
- - 手工新增:`invoice.add.prepare` -> 用户确认 -> `invoice.add.apply`
51
- - 编辑发票:`invoice.update.prepare` -> 用户确认 -> `invoice.update.apply`
52
- - 删除发票:`invoice.delete.prepare` -> 用户确认 -> `invoice.delete.apply`
53
-
54
- ## 执行原则(减少误路由、误重试和无效消耗)
55
-
56
- ### 1) 先拿最小必要信息,再执行
57
-
58
- - 只是查票夹时,优先直接用 `invoice.list` 或 `invoice.enterprise.list`
59
- - 用户已经给出 `fid` 时,不要先查列表再过滤,直接用 `invoice.get` 或对应 prepare
60
- - 只有需要附件归属、可编辑/可删除状态或完整票面时,才补 `invoice.get`
61
-
62
- ### 2) 已知对象时直达动作
63
-
64
- - 已拿到 `fid`、`fileId`、本地文件路径或完整 `info` 时,优先调用对应 operation
65
- - 同一轮里如果已有足够的新鲜查询结果,不要重复查询同一票夹或同一详情
66
- - 不要默认走 `list -> filter -> get -> prepare -> apply` 全链路;对象已明确时应压缩步骤
67
-
68
- ### 3) 错误语义驱动,而不是盲目重试
69
-
70
- - 失败后先看进程退出码、`error.type`、`error.subtype` 和 `error.message`
71
- - **除非错误明确提示可恢复或需要补充参数,否则不要重复刷同一个 operation**
72
- - 写请求已经发出后,遇到结果不确定必须停止;不要把 `.apply` 当成可重试读操作
73
- - **错误为 `authentication`(未登录,如 `E10 auth not found`)或 `session_expired`(登录态失效)时:立即停止当前操作,不要用示例占位域名或自行猜域名登录,也不要盲目重试**。先读取共享规则 `../weaver-work-cli-shared/references/e10-auth-and-session.md`,按其中流程用宿主提问/弹框让用户输入 E10 登录域名或选择已有 profile,完成登录后再继续原操作。
74
-
75
- ## 写操作失败处理:`partial/write_uncertain` 决策树
76
-
77
- 当导入 / 新增 / 编辑 / 删除等写操作返回 `partial/write_uncertain`,或提示网络中断、部分成功、回查失败、回查字段不一致时,按下面规则处理:
78
-
79
- 1. **先停止盲目重试**,不要连续重复提交相同 `.apply`
80
- 2. 优先从以下角度解释:
81
- - 写请求可能已经到达服务端,但连接在结果确认前中断
82
- - 服务端可能只处理了部分发票
83
- - 写接口已返回成功,但详情回查失败或与预期不一致
84
- - continuation、目标文件、目标发票或登录上下文可能已经变化
85
- 3. 如需确认,只补 **一次** 只读查询(例如 `invoice.get` 或列表查询),不要陷入 query/write 循环
86
- 4. 最终给用户明确结论、已知 `workflow.state`、成功/失败项和下一步人工确认建议,而不是继续无意义重试
87
-
88
- **特别注意:** 对导入、删除和编辑场景更要严格执行上述规则;这些场景最容易因重复提交造成重复入账、误删或覆盖用户刚修改的数据。
89
-
90
- ```bash
91
- weaver-work-cli invoice schema
92
- printf '%s\n' '{"page_size":10,"start_pos":0}' | weaver-work-cli --json invoice run invoice.list --input -
93
- printf '%s\n' '{"fid":"12345"}' | weaver-work-cli --json invoice run invoice.get --input -
94
- printf '%s\n' '{"file":"./invoice.pdf","validate":false,"syncToOa":false}' | weaver-work-cli --json invoice run invoice.import.prepare --input -
95
- printf '%s\n' '{"file":"./invoice.pdf","continuation":"<prepare返回值>","confirm":true}' | weaver-work-cli --json invoice run invoice.import.apply --input -
96
- ```
97
- ## 不在本 skill 范围
98
-
99
- - 禁止加载原始 `weaver-e10-yepiaotong` Skill 代替 CLI。
100
- - 禁止 curl、fetch、浏览器自动化或直接访问 E10 `/api/inc/*`。
101
- - 禁止读取或复制 CLI runtime 内部 Token、Cookie、ETEAMSID。
102
- - 共享、转让和标签当前未纳入 CLI manifest;需要先补稳定 ID 来源、输入 schema、prepare/apply、写后回查和测试后再开放。
103
- - 非发票类 E10 能力、通用流程编排、表单/审批/组织等业务不由本 Skill 承载。
@@ -1,38 +0,0 @@
1
- # Agent 入口与 Schema
2
-
3
- ## 什么时候读取
4
-
5
- 使用 `weaver-work-cli invoice` 前、编写自动化调用、选择 operation 或确认字段结构时读取本文件。
6
-
7
- ## 准备命令
8
-
9
- ```bash
10
- weaver-work-cli --version
11
- weaver-work-cli doctor --e10
12
- weaver-work-cli invoice schema
13
- ```
14
-
15
- 如未登录,按共享规则读取 `../../weaver-work-cli-shared/references/e10-auth-and-session.md` 后处理。
16
-
17
- ## 固定入口
18
-
19
- Agent 优先调用统一 operation 入口:
20
-
21
- ```bash
22
- weaver-work-cli --json invoice run <operation> --input -
23
- ```
24
-
25
- JSON 通过 stdin 传入,避免 shell 转义和路径注入问题:
26
-
27
- ```bash
28
- printf '%s\n' '{"page_size":10,"start_pos":0}' \
29
- | weaver-work-cli --json invoice run invoice.list --input -
30
- ```
31
-
32
- `weaver-work-cli invoice schema` 是可用 operation、输入字段、固定参数和风险等级的第一信息源。不要用未出现在 schema 中的 operation,也不要把原始 `weaver-e10-yepiaotong` reference 当作可直接调用的 CLI 合约。
33
-
34
- ## 输出处理
35
-
36
- 成功结果在 stdout,失败结果在 stderr。判断规则读取共享 reference:`../../weaver-work-cli-shared/references/json-output-contract.md`。
37
-
38
- 高风险写入读取共享 reference:`../../weaver-work-cli-shared/references/high-risk-write.md`。
@@ -1,26 +0,0 @@
1
- # 暂不暴露的能力
2
-
3
- ## 什么时候读取
4
-
5
- 用户要求共享发票、转让发票、打标签、移除标签,或要求调用 `weaver-work-cli invoice schema` 中不存在的业票通接口时读取本文件。
6
-
7
- ## 当前不暴露
8
-
9
- 以下原始接口文档存在,但当前没有纳入 `weaver-work-cli invoice` manifest,Agent 不能绕过 CLI 直接调用:
10
-
11
- - 共享发票
12
- - 转让发票
13
- - 标记发票或移除标签
14
-
15
- ## 原因
16
-
17
- 这些能力缺少稳定的 Agent 合约:
18
-
19
- - 共享和转让需要接收人的稳定 `appid/cid/uid` 解析来源
20
- - 转让会改变发票持有人,缺少接收人侧归属回查契约
21
- - 标签缺少标签定义来源、当前标签关系查询和移除/替换语义
22
- - 写操作后的读回验证边界不完整
23
-
24
- ## Agent 行为
25
-
26
- 遇到这类请求时,明确说明当前 CLI 未暴露该 operation,不能通过 `curl`、`fetch`、浏览器自动化或原始 E10 `/api/inc/*` 绕过。可以建议用户先由 CLI 维护者补齐 manifest、输入 schema、prepare/apply、回查和测试后再开放。
@@ -1,22 +0,0 @@
1
- # 下载发票附件
2
-
3
- ## 什么时候读取
4
-
5
- 用户要把发票附件下载到本地文件,或已经给出 `fid` 和 `fileId` 时读取本文件。
6
-
7
- ## Operation
8
-
9
- | Operation | 固定规则 |
10
- | --- | --- |
11
- | `invoice.download` | 先校验 `fileId` 属于目标 `fid`,拒绝覆盖输出文件 |
12
-
13
- ## 示例
14
-
15
- ```bash
16
- printf '%s\n' '{"fid":"12345","fileId":"67890","output":"./invoice-12345.pdf"}' \
17
- | weaver-work-cli --json invoice run invoice.download --input -
18
- ```
19
-
20
- ## 注意
21
-
22
- 如果用户没有 `fileId`,先用 `invoice.get` 查看详情里的 `flist`。`output` 已存在时 CLI 会失败,不要自动覆盖用户文件。
@@ -1,35 +0,0 @@
1
- # 查询企业票夹
2
-
3
- ## 什么时候读取
4
-
5
- 用户要查询企业票夹、搜索企业范围发票,或按报销状态筛选企业发票时读取本文件。
6
-
7
- ## Operation
8
-
9
- | Operation | 固定规则 |
10
- | --- | --- |
11
- | `invoice.enterprise.list` | 固定 `flag=6`;默认 `sreim=3`,只查未报销发票 |
12
-
13
- ## 输入
14
-
15
- 列表字段以 `weaver-work-cli invoice schema` 为准,字段语义与个人票夹一致。常用字段包括 `page_size`、`start_pos`、`content`、购销方、日期、金额、票种、查验状态、来源、排序和 `sreim`。
16
-
17
- `sreim` 是查询筛选参数:`0` 获取全部发票,`1` 发票报销中,`2` 报销完成,`3` 获取未报销发票,`4` 获取不可报销。省略时 CLI 默认传 `3`。
18
-
19
- ## 示例
20
-
21
- ```bash
22
- printf '%s\n' '{"page_size":10,"start_pos":0,"buyer_company":"泛微"}' \
23
- | weaver-work-cli --json invoice run invoice.enterprise.list --input -
24
-
25
- printf '%s\n' '{"page_size":10,"start_pos":0,"sreim":2}' \
26
- | weaver-work-cli --json invoice run invoice.enterprise.list --input -
27
- ```
28
-
29
- ## 返回
30
-
31
- 返回 `items`、`total`、`totalAmount`、`totalAmountExcludingTax`、`hasMore` 和 `scope="enterprise"`。
32
-
33
- ## 注意
34
-
35
- 企业票夹权限失败时不要自动降级查询个人票夹,除非用户明确要求改查个人票夹。不要在输入里传 `flag`;CLI 会固定为企业票夹。
@@ -1,28 +0,0 @@
1
- # 导入发票文件
2
-
3
- ## 什么时候读取
4
-
5
- 用户要把本地发票文件导入票夹时读取本文件。开始前也读取共享高风险协议:`../../weaver-work-cli-shared/references/high-risk-write.md`。
6
-
7
- ## Operation
8
-
9
- | 阶段 | Operation | 必填输入 |
10
- | --- | --- | --- |
11
- | 准备导入 | `invoice.import.prepare` | `file`、`validate`、`syncToOa` |
12
- | 确认导入 | `invoice.import.apply` | `file`、`continuation`、`confirm=true` |
13
-
14
- ## 示例
15
-
16
- ```bash
17
- printf '%s\n' '{"file":"./invoice.pdf","validate":false,"syncToOa":false}' \
18
- | weaver-work-cli --json invoice run invoice.import.prepare --input -
19
-
20
- printf '%s\n' '{"file":"./invoice.pdf","continuation":"<prepare返回值>","confirm":true}' \
21
- | weaver-work-cli --json invoice run invoice.import.apply --input -
22
- ```
23
-
24
- ## 注意
25
-
26
- `validate` 和 `syncToOa` 必须显式传布尔值。`validate=true` 分支由服务端固定同步 OA,不能设置 `syncToOa=false`。`validate=false` 表示跳过查验,不能描述为“查验通过”。
27
-
28
- `.prepare` 返回 `preview`、`continuation`、`expiresInSeconds` 和 `workflow.state="AWAITING_CONFIRMATION"`。展示风险后等待用户明确确认,再调用 `.apply`。