weaver-work-cli 0.1.2 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +176 -78
- package/dist/cmd/setup/index.js +5 -5
- package/dist/cmd/skills/index.js +1 -1
- package/dist/core/hooks.js +7 -0
- package/dist/index.js +0 -0
- package/dist/internal/e10/auth/commands.js +159 -54
- package/dist/internal/e10/auth/xiaoe.js +268 -0
- package/dist/internal/e10/context.js +16 -2
- package/dist/internal/e10/index.js +1 -0
- package/dist/internal/e10/request-runtime.js +345 -0
- package/dist/internal/skills/install.js +48 -6
- package/dist/internal/skills/reader.js +27 -0
- package/dist/shortcuts/archive/continuation.js +70 -0
- package/dist/shortcuts/archive/errors.js +53 -0
- package/dist/shortcuts/archive/host.js +197 -0
- package/dist/shortcuts/archive/index.js +363 -0
- package/dist/shortcuts/archive/manifest.js +45 -0
- package/dist/shortcuts/archive/operations/archive-info.js +55 -0
- package/dist/shortcuts/archive/operations/borrow-car.js +146 -0
- package/dist/shortcuts/archive/operations/borrow-list.js +200 -0
- package/dist/shortcuts/archive/operations/confirm.js +46 -0
- package/dist/shortcuts/archive/operations/download.js +238 -0
- package/dist/shortcuts/archive/operations/flow-url.js +240 -0
- package/dist/shortcuts/archive/operations/fonds.js +95 -0
- package/dist/shortcuts/archive/operations/getPageUrl.js +137 -0
- package/dist/shortcuts/archive/operations/registry.js +43 -0
- package/dist/shortcuts/archive/operations/search.js +88 -0
- package/dist/shortcuts/archive/operations/shared.js +120 -0
- package/dist/shortcuts/archive/operations/types.js +23 -0
- package/dist/shortcuts/archive/operations/upload.js +182 -0
- package/dist/shortcuts/archive/operations.js +13 -0
- package/dist/shortcuts/archive/render/search-format.js +276 -0
- package/dist/shortcuts/archive/render/search-view.js +125 -0
- package/dist/shortcuts/asset/continuation.js +70 -0
- package/dist/shortcuts/asset/errors.js +67 -0
- package/dist/shortcuts/asset/host.js +438 -0
- package/dist/shortcuts/asset/index.js +255 -0
- package/dist/shortcuts/asset/manifest.js +471 -0
- package/dist/shortcuts/asset/operations/query.js +249 -0
- package/dist/shortcuts/asset/operations/registry.js +85 -0
- package/dist/shortcuts/asset/operations/shared.js +100 -0
- package/dist/shortcuts/asset/operations/type-cache.js +49 -0
- package/dist/shortcuts/asset/operations/types.js +1 -0
- package/dist/shortcuts/asset/operations/viewlink.js +117 -0
- package/dist/shortcuts/asset/operations/write.js +435 -0
- package/dist/shortcuts/asset/operations.js +9 -0
- package/dist/shortcuts/calendar/continuation.js +70 -0
- package/dist/shortcuts/calendar/errors.js +53 -0
- package/dist/shortcuts/calendar/host.js +148 -0
- package/dist/shortcuts/calendar/index.js +125 -0
- package/dist/shortcuts/calendar/manifest.js +26 -0
- package/dist/shortcuts/calendar/operations/read.js +259 -0
- package/dist/shortcuts/calendar/operations/registry.js +31 -0
- package/dist/shortcuts/calendar/operations/shared.js +132 -0
- package/dist/shortcuts/calendar/operations/types.js +25 -0
- package/dist/shortcuts/calendar/operations/write.js +439 -0
- package/dist/shortcuts/calendar/operations.js +8 -0
- package/dist/shortcuts/ehr/continuation.js +70 -0
- package/dist/shortcuts/ehr/errors.js +53 -0
- package/dist/shortcuts/ehr/host.js +213 -0
- package/dist/shortcuts/ehr/index.js +205 -0
- package/dist/shortcuts/ehr/manifest.js +47 -0
- package/dist/shortcuts/ehr/operations/attend-read.js +373 -0
- package/dist/shortcuts/ehr/operations/attend-write.js +514 -0
- package/dist/shortcuts/ehr/operations/hr-contact.js +363 -0
- package/dist/shortcuts/ehr/operations/hr-ds.js +298 -0
- package/dist/shortcuts/ehr/operations/hr-report.js +386 -0
- package/dist/shortcuts/ehr/operations/recruit-write.js +1629 -0
- package/dist/shortcuts/ehr/operations/recruit.js +803 -0
- package/dist/shortcuts/ehr/operations/registry.js +43 -0
- package/dist/shortcuts/ehr/operations/salary.js +319 -0
- package/dist/shortcuts/ehr/operations/shared.js +246 -0
- package/dist/shortcuts/ehr/operations/types.js +25 -0
- package/dist/shortcuts/ehr/operations.js +25 -0
- package/dist/shortcuts/esb/continuation.js +70 -0
- package/dist/shortcuts/esb/errors.js +65 -0
- package/dist/shortcuts/esb/host.js +187 -0
- package/dist/shortcuts/esb/index.js +112 -0
- package/dist/shortcuts/esb/manifest.js +91 -0
- package/dist/shortcuts/esb/operations/input-format.js +31 -0
- package/dist/shortcuts/esb/operations/registry.js +48 -0
- package/dist/shortcuts/esb/operations/shared.js +152 -0
- package/dist/shortcuts/esb/operations/trigger.js +76 -0
- package/dist/shortcuts/esb/operations/types.js +21 -0
- package/dist/shortcuts/esb/operations.js +15 -0
- package/dist/shortcuts/fna/continuation.js +70 -0
- package/dist/shortcuts/fna/errors.js +59 -0
- package/dist/shortcuts/fna/host.js +146 -0
- package/dist/shortcuts/fna/index.js +111 -0
- package/dist/shortcuts/fna/manifest.js +41 -0
- package/dist/shortcuts/fna/operations/budget.js +124 -0
- package/dist/shortcuts/fna/operations/expense-center.js +148 -0
- package/dist/shortcuts/fna/operations/invoice-writeoff.js +212 -0
- package/dist/shortcuts/fna/operations/loan.js +195 -0
- package/dist/shortcuts/fna/operations/registry.js +35 -0
- package/dist/shortcuts/fna/operations/shared.js +210 -0
- package/dist/shortcuts/fna/operations/types.js +25 -0
- package/dist/shortcuts/fna/operations.js +19 -0
- package/dist/shortcuts/hrm/errors.js +38 -0
- package/dist/shortcuts/hrm/host.js +156 -0
- package/dist/shortcuts/hrm/index.js +111 -0
- package/dist/shortcuts/hrm/manifest.js +32 -0
- package/dist/shortcuts/hrm/operations/employee.js +338 -0
- package/dist/shortcuts/hrm/operations/org.js +110 -0
- package/dist/shortcuts/hrm/operations/position.js +176 -0
- package/dist/shortcuts/hrm/operations/registry.js +33 -0
- package/dist/shortcuts/hrm/operations/shared.js +143 -0
- package/dist/shortcuts/hrm/operations/types.js +23 -0
- package/dist/shortcuts/hrm/operations.js +19 -0
- package/dist/shortcuts/index.js +24 -0
- package/dist/shortcuts/invoice/host.js +99 -94
- package/dist/shortcuts/invoice/index.js +58 -59
- package/dist/shortcuts/invoice/manifest.js +200 -3
- package/dist/shortcuts/invoice/operations/browse-field.js +17 -0
- package/dist/shortcuts/invoice/operations/issuing.js +198 -0
- package/dist/shortcuts/invoice/operations/registry.js +17 -0
- package/dist/shortcuts/invoice/operations/reim.js +401 -0
- package/dist/shortcuts/invoice/operations/shared.js +247 -0
- package/dist/shortcuts/jiuchuanhui/cache.js +441 -0
- package/dist/shortcuts/jiuchuanhui/continuation.js +70 -0
- package/dist/shortcuts/jiuchuanhui/errors.js +59 -0
- package/dist/shortcuts/jiuchuanhui/host.js +159 -0
- package/dist/shortcuts/jiuchuanhui/index.js +109 -0
- package/dist/shortcuts/jiuchuanhui/manifest.js +469 -0
- package/dist/shortcuts/jiuchuanhui/operations/datajson.js +214 -0
- package/dist/shortcuts/jiuchuanhui/operations/esb.js +157 -0
- package/dist/shortcuts/jiuchuanhui/operations/generic.js +146 -0
- package/dist/shortcuts/jiuchuanhui/operations/registry.js +133 -0
- package/dist/shortcuts/jiuchuanhui/operations/shared.js +158 -0
- package/dist/shortcuts/jiuchuanhui/operations/types.js +1 -0
- package/dist/shortcuts/jiuchuanhui/operations.js +8 -0
- package/dist/shortcuts/mail/continuation.js +70 -0
- package/dist/shortcuts/mail/errors.js +53 -0
- package/dist/shortcuts/mail/host.js +182 -0
- package/dist/shortcuts/mail/index.js +519 -0
- package/dist/shortcuts/mail/manifest.js +38 -0
- package/dist/shortcuts/mail/operations/mail-blacklist.js +79 -0
- package/dist/shortcuts/mail/operations/mail-contacts.js +195 -0
- package/dist/shortcuts/mail/operations/mail-manage.js +335 -0
- package/dist/shortcuts/mail/operations/mail-read.js +508 -0
- package/dist/shortcuts/mail/operations/mail-send.js +474 -0
- package/dist/shortcuts/mail/operations/mail-sign.js +203 -0
- package/dist/shortcuts/mail/operations/mail-template.js +170 -0
- package/dist/shortcuts/mail/operations/registry.js +41 -0
- package/dist/shortcuts/mail/operations/shared.js +64 -0
- package/dist/shortcuts/mail/operations/types.js +27 -0
- package/dist/shortcuts/mail/operations.js +19 -0
- package/dist/shortcuts/meeting/continuation.js +70 -0
- package/dist/shortcuts/meeting/errors.js +63 -0
- package/dist/shortcuts/meeting/host.js +167 -0
- package/dist/shortcuts/meeting/index.js +123 -0
- package/dist/shortcuts/meeting/manifest.js +64 -0
- package/dist/shortcuts/meeting/operations/catalogs.js +58 -0
- package/dist/shortcuts/meeting/operations/change.js +242 -0
- package/dist/shortcuts/meeting/operations/conflicts.js +142 -0
- package/dist/shortcuts/meeting/operations/create.js +349 -0
- package/dist/shortcuts/meeting/operations/env.js +191 -0
- package/dist/shortcuts/meeting/operations/lifecycle.js +139 -0
- package/dist/shortcuts/meeting/operations/meetings.js +73 -0
- package/dist/shortcuts/meeting/operations/receipts.js +195 -0
- package/dist/shortcuts/meeting/operations/registry.js +47 -0
- package/dist/shortcuts/meeting/operations/rooms.js +132 -0
- package/dist/shortcuts/meeting/operations/shared.js +112 -0
- package/dist/shortcuts/meeting/operations/signs.js +41 -0
- package/dist/shortcuts/meeting/operations/types.js +25 -0
- package/dist/shortcuts/meeting/operations.js +19 -0
- package/dist/shortcuts/plan/continuation.js +70 -0
- package/dist/shortcuts/plan/errors.js +70 -0
- package/dist/shortcuts/plan/host.js +180 -0
- package/dist/shortcuts/plan/index.js +150 -0
- package/dist/shortcuts/plan/manifest.js +53 -0
- package/dist/shortcuts/plan/operations/link.js +256 -0
- package/dist/shortcuts/plan/operations/read.js +259 -0
- package/dist/shortcuts/plan/operations/registry.js +33 -0
- package/dist/shortcuts/plan/operations/shared.js +246 -0
- package/dist/shortcuts/plan/operations/types.js +49 -0
- package/dist/shortcuts/plan/operations/version.js +49 -0
- package/dist/shortcuts/plan/operations/write.js +710 -0
- package/dist/shortcuts/plan/operations.js +8 -0
- package/dist/shortcuts/yimiaoban/continuation.js +70 -0
- package/dist/shortcuts/yimiaoban/errors.js +61 -0
- package/dist/shortcuts/yimiaoban/host.js +469 -0
- package/dist/shortcuts/yimiaoban/index.js +271 -0
- package/dist/shortcuts/yimiaoban/manifest.js +28 -0
- package/dist/shortcuts/yimiaoban/operations/file-user.js +288 -0
- package/dist/shortcuts/yimiaoban/operations/group-read.js +477 -0
- package/dist/shortcuts/yimiaoban/operations/group-write.js +591 -0
- package/dist/shortcuts/yimiaoban/operations/msg-parse.js +429 -0
- package/dist/shortcuts/yimiaoban/operations/msg-sync.js +519 -0
- package/dist/shortcuts/yimiaoban/operations/msg-write.js +593 -0
- package/dist/shortcuts/yimiaoban/operations/person.js +102 -0
- package/dist/shortcuts/yimiaoban/operations/registry.js +38 -0
- package/dist/shortcuts/yimiaoban/operations/session.js +437 -0
- package/dist/shortcuts/yimiaoban/operations/shared.js +236 -0
- package/dist/shortcuts/yimiaoban/operations/types.js +27 -0
- package/dist/shortcuts/yimiaoban/operations/write-util.js +78 -0
- package/dist/shortcuts/yimiaoban/operations.js +8 -0
- package/docs/SKILL.md +11 -7
- package/docs/_catalog.md +28 -5
- package/docs/agent-invoice.md +19 -9
- package/docs/agent-skill-install.md +141 -22
- package/docs/calendar.md +87 -0
- package/docs/e10-auth.md +28 -9
- package/docs/ehr.md +186 -0
- package/docs/esb.md +64 -0
- package/docs/fna.md +72 -0
- package/docs/hrm.md +89 -0
- package/docs/invoice.md +61 -20
- package/docs/jiuchuanhui.md +131 -0
- package/docs/meeting.md +48 -0
- package/docs/operation-manual.md +443 -0
- package/docs/plan.md +82 -0
- package/docs/wenshuding.md +129 -0
- package/docs/yimiaoban.md +86 -0
- package/docs/ziguanjia.md +89 -0
- package/package.json +4 -4
- package/scripts/package-skill.mjs +127 -34
- package/scripts/postbuild.mjs +13 -0
- package/skill-template/business-info.json +16 -2
- package/skill-template/domains/calendar.md +15 -0
- package/skill-template/domains/esb.md +13 -0
- package/skill-template/domains/hrm.md +16 -0
- package/skill-template/domains/jiuchuanhui.md +23 -0
- package/skill-template/domains/jucailin.md +22 -0
- package/skill-template/domains/mail.md +21 -0
- package/skill-template/domains/meeting.md +3 -0
- package/skill-template/domains/plan.md +17 -0
- package/skill-template/domains/qiyecheng.md +17 -0
- package/skill-template/domains/shared.md +5 -3
- package/skill-template/domains/skill-maker.md +10 -0
- package/skill-template/domains/wenshuding.md +22 -0
- package/skill-template/domains/{invoice.md → yepiaotong.md} +4 -0
- package/skill-template/domains/yimiaoban.md +21 -0
- package/skill-template/domains/ziguanjia.md +21 -0
- package/skill-template/master-skill-template.md +12 -6
- package/skill-template/skill-template.md +26 -10
- package/skills/weaver-e10-calendar/SKILL.md +102 -0
- package/skills/weaver-e10-calendar/product.json +8 -0
- package/skills/weaver-e10-calendar/references/calendar-app-check.md +65 -0
- package/skills/weaver-e10-calendar/references/calendar-dict.md +55 -0
- package/skills/weaver-e10-calendar/references/calendar-query.md +70 -0
- package/skills/weaver-e10-calendar/references/calendar-write.md +97 -0
- package/skills/weaver-e10-calendar/references/source-manifest.json +54 -0
- package/skills/weaver-e10-esb/SKILL.md +103 -0
- package/skills/weaver-e10-esb/product.json +8 -0
- package/skills/weaver-e10-esb/references/input-format.md +52 -0
- package/skills/weaver-e10-esb/references/source-manifest.json +242 -0
- package/skills/weaver-e10-esb/references/trigger.md +99 -0
- package/skills/weaver-e10-hrm/SKILL.md +88 -0
- package/skills/weaver-e10-hrm/product.json +8 -0
- package/skills/weaver-e10-hrm/references/employee.md +109 -0
- package/skills/weaver-e10-hrm/references/org.md +95 -0
- package/skills/weaver-e10-hrm/references/position.md +95 -0
- package/skills/weaver-e10-hrm/references/source-manifest.json +121 -0
- package/skills/weaver-e10-jiuchuanhui/SKILL.md +175 -0
- package/skills/weaver-e10-jiuchuanhui/product.json +8 -0
- package/skills/weaver-e10-jiuchuanhui/references/cache.md +110 -0
- package/skills/weaver-e10-jiuchuanhui/references/clue.md +61 -0
- package/skills/weaver-e10-jiuchuanhui/references/contact-plan.md +56 -0
- package/skills/weaver-e10-jiuchuanhui/references/contact-records.md +48 -0
- package/skills/weaver-e10-jiuchuanhui/references/contact.md +56 -0
- package/skills/weaver-e10-jiuchuanhui/references/customer.md +69 -0
- package/skills/weaver-e10-jiuchuanhui/references/disabled-capabilities.md +24 -0
- package/skills/weaver-e10-jiuchuanhui/references/discovery-config.md +60 -0
- package/skills/weaver-e10-jiuchuanhui/references/general-helpers.md +59 -0
- package/skills/weaver-e10-jiuchuanhui/references/jiuchuanhui-entry.md +60 -0
- package/skills/weaver-e10-jiuchuanhui/references/sale.md +72 -0
- package/skills/weaver-e10-jiuchuanhui/references/source-manifest.json +2632 -0
- package/skills/weaver-e10-jucailin/SKILL.md +102 -0
- package/skills/weaver-e10-jucailin/product.json +8 -0
- package/skills/weaver-e10-jucailin/references/attend-read.md +73 -0
- package/skills/weaver-e10-jucailin/references/attend-write.md +82 -0
- package/skills/weaver-e10-jucailin/references/hr-contact.md +92 -0
- package/skills/weaver-e10-jucailin/references/hr-datasource.md +104 -0
- package/skills/weaver-e10-jucailin/references/hr-report.md +76 -0
- package/skills/weaver-e10-jucailin/references/recruit-read.md +76 -0
- package/skills/weaver-e10-jucailin/references/recruit-write.md +70 -0
- package/skills/weaver-e10-jucailin/references/safety-boundaries.md +35 -0
- package/skills/weaver-e10-jucailin/references/salary.md +110 -0
- package/skills/weaver-e10-jucailin/references/source-manifest.json +152 -0
- package/skills/weaver-e10-mail/SKILL.md +152 -0
- package/skills/weaver-e10-mail/product.json +8 -0
- package/skills/weaver-e10-mail/references/mail-agent-entry.md +47 -0
- package/skills/weaver-e10-mail/references/mail-attachment.md +30 -0
- package/skills/weaver-e10-mail/references/mail-blacklist.md +27 -0
- package/skills/weaver-e10-mail/references/mail-contacts.md +33 -0
- package/skills/weaver-e10-mail/references/mail-manage.md +44 -0
- package/skills/weaver-e10-mail/references/mail-read.md +76 -0
- package/skills/weaver-e10-mail/references/mail-send.md +43 -0
- package/skills/weaver-e10-mail/references/mail-sign.md +33 -0
- package/skills/weaver-e10-mail/references/mail-template.md +31 -0
- package/skills/weaver-e10-mail/references/safety-boundaries.md +32 -0
- package/skills/weaver-e10-meeting/SKILL.md +106 -0
- package/skills/weaver-e10-meeting/product.json +8 -0
- package/skills/weaver-e10-meeting/references/meeting-change.md +67 -0
- package/skills/weaver-e10-meeting/references/meeting-create.md +52 -0
- package/skills/weaver-e10-meeting/references/meeting-lifecycle.md +57 -0
- package/skills/weaver-e10-meeting/references/meeting-queries.md +61 -0
- package/skills/weaver-e10-meeting/references/meeting-receipts-signs.md +48 -0
- package/skills/weaver-e10-meeting/references/meeting-update.md +7 -0
- package/skills/weaver-e10-meeting/references/source-manifest.json +50 -0
- package/skills/weaver-e10-plan/SKILL.md +140 -0
- package/skills/weaver-e10-plan/product.json +8 -0
- package/skills/weaver-e10-plan/references/plan-collect-and-compose.md +123 -0
- package/skills/weaver-e10-plan/references/plan-overview-and-routing.md +138 -0
- package/skills/weaver-e10-plan/references/plan-report-query.md +154 -0
- package/skills/weaver-e10-plan/references/plan-report-remind.md +104 -0
- package/skills/weaver-e10-plan/references/plan-report-write.md +162 -0
- package/skills/weaver-e10-plan/references/source-manifest.json +858 -0
- package/skills/weaver-e10-qiyecheng/SKILL.md +119 -0
- package/skills/weaver-e10-qiyecheng/product.json +8 -0
- package/skills/weaver-e10-qiyecheng/references/budget.md +65 -0
- package/skills/weaver-e10-qiyecheng/references/catalog.md +56 -0
- package/skills/weaver-e10-qiyecheng/references/expense-center.md +51 -0
- package/skills/weaver-e10-qiyecheng/references/invoice-writeoff.md +57 -0
- package/skills/weaver-e10-qiyecheng/references/loan-management.md +59 -0
- package/skills/weaver-e10-qiyecheng/references/source-manifest.json +698 -0
- package/skills/weaver-e10-shared/SKILL.md +90 -0
- package/skills/weaver-e10-shared/references/e10-auth-and-session.md +127 -0
- package/skills/{weaver-work-cli-shared → weaver-e10-shared}/references/json-output-contract.md +34 -0
- package/skills/weaver-e10-shared/references/weaver-e10-installation.md +110 -0
- package/skills/weaver-e10-skill-maker/SKILL.md +78 -0
- package/skills/weaver-e10-skill-maker/product.json +8 -0
- package/skills/weaver-e10-skill-maker/references/business-skill-generation.md +124 -0
- package/skills/weaver-e10-skill-maker/references/detector-validation.md +101 -0
- package/skills/weaver-e10-skill-maker/references/module-cli-generation.md +230 -0
- package/skills/weaver-e10-skill-maker/references/post-generation-install.md +105 -0
- package/skills/weaver-e10-skill-maker/references/source-update-detection.md +261 -0
- package/skills/weaver-e10-skill-maker/references/weaver-skill-style.md +141 -0
- package/skills/weaver-e10-wenshuding/SKILL.md +158 -0
- package/skills/weaver-e10-wenshuding/product.json +8 -0
- package/skills/weaver-e10-wenshuding/references/archive-agent-entry.md +63 -0
- package/skills/weaver-e10-wenshuding/references/archive-borrow-car.md +52 -0
- package/skills/weaver-e10-wenshuding/references/archive-borrow-list.md +52 -0
- package/skills/weaver-e10-wenshuding/references/archive-disabled-capabilities.md +22 -0
- package/skills/weaver-e10-wenshuding/references/archive-download.md +48 -0
- package/skills/weaver-e10-wenshuding/references/archive-flow.md +46 -0
- package/skills/weaver-e10-wenshuding/references/archive-fonds.md +34 -0
- package/skills/weaver-e10-wenshuding/references/archive-info.md +33 -0
- package/skills/weaver-e10-wenshuding/references/archive-search.md +52 -0
- package/skills/weaver-e10-wenshuding/references/archive-upload.md +41 -0
- package/skills/weaver-e10-wenshuding/references/source-manifest.json +517 -0
- package/skills/weaver-e10-yepiaotong/SKILL.md +184 -0
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-add.md +1 -1
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-agent-entry.md +16 -9
- package/skills/weaver-e10-yepiaotong/references/invoice-browse-field-data.md +204 -0
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-delete.md +1 -1
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-detail.md +13 -5
- package/skills/weaver-e10-yepiaotong/references/invoice-disabled-capabilities.md +28 -0
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-download.md +9 -2
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-enterprise-list.md +12 -4
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-file-upload.md +9 -2
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-import.md +16 -7
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing-examples.md +120 -0
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing-field-rules.md +161 -0
- package/skills/weaver-e10-yepiaotong/references/invoice-issuing.md +99 -0
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-ocr-preview.md +12 -4
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-personal-list.md +12 -4
- package/skills/weaver-e10-yepiaotong/references/invoice-red.md +261 -0
- package/skills/weaver-e10-yepiaotong/references/invoice-reim.md +97 -0
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-update.md +1 -1
- package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/references/invoice-validation-preview.md +9 -2
- package/skills/weaver-e10-yepiaotong/references/reim-api-reference.md +1340 -0
- package/skills/weaver-e10-yepiaotong/references/reim-examples.md +845 -0
- package/skills/weaver-e10-yepiaotong/references/reim-expense-subject-rules.md +94 -0
- package/skills/weaver-e10-yepiaotong/references/reim-form-fill-rules.md +449 -0
- package/skills/weaver-e10-yepiaotong/references/reim-matching-rules.md +266 -0
- package/skills/weaver-e10-yepiaotong/references/reim-workflow.md +494 -0
- package/skills/weaver-e10-yepiaotong/references/source-manifest.json +1103 -0
- package/skills/weaver-e10-yimiaoban/SKILL.md +104 -0
- package/skills/weaver-e10-yimiaoban/product.json +8 -0
- package/skills/weaver-e10-yimiaoban/references/ding-write.md +68 -0
- package/skills/weaver-e10-yimiaoban/references/error-codes.md +85 -0
- package/skills/weaver-e10-yimiaoban/references/field-resolution.md +46 -0
- package/skills/weaver-e10-yimiaoban/references/file-user-i18n.md +54 -0
- package/skills/weaver-e10-yimiaoban/references/group-read.md +55 -0
- package/skills/weaver-e10-yimiaoban/references/group-write.md +72 -0
- package/skills/weaver-e10-yimiaoban/references/msg-read.md +59 -0
- package/skills/weaver-e10-yimiaoban/references/msg-write.md +64 -0
- package/skills/weaver-e10-yimiaoban/references/person.md +44 -0
- package/skills/weaver-e10-yimiaoban/references/safety-boundaries.md +61 -0
- package/skills/weaver-e10-yimiaoban/references/session-sysmsg.md +47 -0
- package/skills/weaver-e10-yimiaoban/references/source-manifest.json +485 -0
- package/skills/weaver-e10-ziguanjia/SKILL.md +163 -0
- package/skills/weaver-e10-ziguanjia/product.json +8 -0
- package/skills/weaver-e10-ziguanjia/references/source-manifest.json +147 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-agent-entry.md +65 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-create.md +45 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-depre.md +48 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-disabled-capabilities.md +22 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-purch.md +57 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-query.md +62 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-repair.md +83 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-resolve.md +49 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-return.md +70 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-update.md +45 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-use.md +60 -0
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-viewlink.md +81 -0
- package/skills/weaver-work-cli-invoice/SKILL.md +0 -122
- package/skills/weaver-work-cli-invoice/references/invoice-disabled-capabilities.md +0 -26
- package/skills/weaver-work-cli-shared/SKILL.md +0 -63
- package/skills/weaver-work-cli-shared/references/e10-auth-and-session.md +0 -90
- package/skills/weaver-work-cli-shared/references/weaver-work-cli-installation.md +0 -73
- /package/skills/{weaver-work-cli-shared → weaver-e10-shared}/references/high-risk-write.md +0 -0
- /package/skills/{weaver-work-cli-invoice → weaver-e10-yepiaotong}/product.json +0 -0
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# 易秒办即时通讯(yimiaoban)
|
|
2
|
+
|
|
3
|
+
`yimiaoban` 是 E10 易秒办即时通讯的聚合命令,覆盖**消息(msg)**、**必达(ding)**、**群组(group)**、**会话(session)**、**系统消息(sysmsg)**,以及支撑能力人员解析(person)、文件上传/预览(file)、用户状态(user)、i18n 标签(i18n)。
|
|
4
|
+
|
|
5
|
+
```text
|
|
6
|
+
weaver-work-cli yimiaoban --help
|
|
7
|
+
weaver-work-cli yimiaoban schema
|
|
8
|
+
weaver-work-cli --json yimiaoban run <operation> --input -
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
`schema` 是能力清单的唯一事实来源,包含每个 operation 的 `inputSchema`、`risk`、`requiresConfirmation`。
|
|
12
|
+
|
|
13
|
+
## 实现位置
|
|
14
|
+
|
|
15
|
+
| 路径 | 职责 |
|
|
16
|
+
| --- | --- |
|
|
17
|
+
| `src/shortcuts/yimiaoban/index.ts` | 命令注册与 JSON envelope |
|
|
18
|
+
| `src/shortcuts/yimiaoban/manifest.ts` | `schema` 契约 |
|
|
19
|
+
| `src/shortcuts/yimiaoban/host.ts` | E10 会话桥接、认证头、executeIm/文件上传、hrm 人员解析、i18n、媒体 URL |
|
|
20
|
+
| `src/shortcuts/yimiaoban/continuation.ts` | 写操作确认链的 HMAC-SHA256 token |
|
|
21
|
+
| `src/shortcuts/yimiaoban/operations/` | 按业务域拆分的 operation 实现 |
|
|
22
|
+
| `src/shortcuts/yimiaoban/operations/registry.ts` | operation 注册表与去重校验 |
|
|
23
|
+
|
|
24
|
+
## 认证
|
|
25
|
+
|
|
26
|
+
复用 `src/internal/e10` 的 E10 会话(`requireE10Session`),请求自动携带 `Cookie`、`eteamsid` 与 `X-Requested-With: XMLHttpRequest`。IM 接口前缀 `/api/em/msg/executeIm`,必达例外走 `/api/em/msg/createDing`。业务代码不接触认证目录,路径强制以 `/api/` 开头。
|
|
27
|
+
|
|
28
|
+
## 红线(模块内强制)
|
|
29
|
+
|
|
30
|
+
- 请求体禁止传操作人字段(user/sender/creator/operator),操作者由 `eteamsid` 识别。
|
|
31
|
+
- 人名一律走 hrm:`/api/hrm/common/getEmployeeByIds` 解析,禁止用 IM 群成员 `name` 字段。
|
|
32
|
+
- uid/cid/群 id 是 uint64,一律字符串传输且非 0。
|
|
33
|
+
- 过滤全部服务端完成;分页单页默认 20(群搜索 100),不自动翻页拉全量。
|
|
34
|
+
- 时间范围查询换算为消息 id 区间(`resolveStartEnd`/`makeMinMaxIdByTm`)。
|
|
35
|
+
- 全空白文本不算内容(拒绝发送空白消息);普通请求 15 秒超时即失败不重试(上传 15/60 秒)。
|
|
36
|
+
- 媒体只给需登录态的 URL,真要看内容用 `file.download` 落地到本地(父目录须存在、拒绝覆盖)。
|
|
37
|
+
- 消息内容完整透出,不截断;展示规则见 Skill `safety-boundaries.md`。
|
|
38
|
+
|
|
39
|
+
## 消息拉取与展示
|
|
40
|
+
|
|
41
|
+
`msg.sync.single`(对方 `fromUid`+`fromCid` 必填)、`msg.sync.group`(`groupId` 必填,type=0 固定)为倒序单页拉取;`actionMsg.code=1303` 表示无聊天记录,按成功空列表处理,并返回 `empty:true` + `emptyReason`(区分当天无消息/时间范围无消息/会话无历史)。单页有更多数据时返回 `nextStart`(下页 `start` 锚点)与 `dedupeHint`(边界消息会重复,需按 `msgid` 去重)。
|
|
42
|
+
|
|
43
|
+
返回的 `messages[]` 已按 msgParser 语义解析为结构化行:
|
|
44
|
+
|
|
45
|
+
- `sender`:自己显示「我」(按会话 uid 判定),他人优先消息 `sname`、其次 hrm 姓名、最后回退 uid;`time`;`typeName`;`content`:完整正文(@ 提及已还原、媒体显示 `[图片]名称`/`[视频]名称`/`[文件]名称`)。
|
|
46
|
+
- `fileName`:媒体消息原始文件名(便于单独渲染);富文本分段解析支持图片/文件/视频/语音/位置。
|
|
47
|
+
- `media`:图片/视频/文件的预览与下载 URL(weappAuthStr 构造,需登录态)。
|
|
48
|
+
- `must`:必达标记。会话副标题媒体消息按 `[类型]名称` 展示,必达保留 `[必达]` 前缀。
|
|
49
|
+
|
|
50
|
+
## 写协议与 continuation
|
|
51
|
+
|
|
52
|
+
所有写操作(send/withdraw/top.set/ding/group 系列)统一 `prepare → apply`:
|
|
53
|
+
|
|
54
|
+
- `prepare`:只读校验(成员解析、源消息读取、接收人计算),返回 `summary` + `continuation`(HMAC-SHA256 签名,10 分钟有效,含 baseUrl/profile/userId 指纹与 snapshot 指纹)。
|
|
55
|
+
- `apply`:必须 `confirm:true` + 有效 continuation;校验租户/账号一致(`context_mismatch`)与目标指纹(`target_changed`);执行后不确定结果返回 `partial/write_uncertain`,禁止自动重试。
|
|
56
|
+
|
|
57
|
+
## 分组速览(以 schema 为准)
|
|
58
|
+
|
|
59
|
+
| 前缀 | 覆盖 |
|
|
60
|
+
| --- | --- |
|
|
61
|
+
| `yimiaoban.person.*` | resolve / resolveByIds |
|
|
62
|
+
| `yimiaoban.msg.sync.*` / `msg.top.sync` / `msg.read.*` | 消息拉取/置顶/阅读状态 |
|
|
63
|
+
| `yimiaoban.msg.send.*` / `msg.withdraw` / `msg.top.set` | 发送/撤回/置顶(写,两段式) |
|
|
64
|
+
| `yimiaoban.ding.send.*` | 必达/转必达(写,两段式) |
|
|
65
|
+
| `yimiaoban.group.search/info/users/admins/exist/userExist/announce.*` | 群读 |
|
|
66
|
+
| `yimiaoban.group.create/invite/kick/exit/destroy/join/modify/rename/announce.modify` | 群写(两段式) |
|
|
67
|
+
| `yimiaoban.session.list` / `sysmsg.*` | 会话与系统消息 |
|
|
68
|
+
| `yimiaoban.file.upload/preview/download` / `user.state` / `i18n.labels` | 文件/状态/翻译 |
|
|
69
|
+
|
|
70
|
+
## 平台示例
|
|
71
|
+
|
|
72
|
+
Windows PowerShell:
|
|
73
|
+
|
|
74
|
+
```powershell
|
|
75
|
+
weaver-work-cli --json yimiaoban run yimiaoban.msg.sync.group --input-json '{"groupId":"1788334281700000004","num":20,"latest":true}'
|
|
76
|
+
weaver-work-cli --json yimiaoban run yimiaoban.group.users --input-json '{"groupId":"1788334281700000004"}'
|
|
77
|
+
weaver-work-cli --json yimiaoban run yimiaoban.session.list --input-json '{"num":20}'
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
macOS/Linux(bash/zsh):
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
weaver-work-cli --json yimiaoban run yimiaoban.msg.sync.group --input-json '{"groupId":"1788334281700000004","num":20,"latest":true}'
|
|
84
|
+
weaver-work-cli --json yimiaoban run yimiaoban.group.users --input-json '{"groupId":"1788334281700000004"}'
|
|
85
|
+
weaver-work-cli --json yimiaoban run yimiaoban.session.list --input-json '{"num":20}'
|
|
86
|
+
```
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# 资管家资产管理 CLI
|
|
2
|
+
|
|
3
|
+
来源目录:`weaver-e10-ziguanjia`,内容版本未知。本模块把源资料中可安全自动化的能力封装为 `weaver-work-cli asset` 命令,供 AI Agent 通过结构化 JSON 调用。
|
|
4
|
+
|
|
5
|
+
源码位于 `src/shortcuts/asset`。命令注册、operation manifest 和业务执行逻辑分离;具体执行逻辑在 `src/shortcuts/asset/operations` 中按 operation class 维护。
|
|
6
|
+
|
|
7
|
+
面向 Agent 的说明位于 `skills/weaver-e10-ziguanjia`。入口 `SKILL.md` 只负责共享规则和 reference 路由;具体细节拆在 `skills/weaver-e10-ziguanjia/references/`,与飞书 CLI 的业务 Skill 组织方式保持一致。
|
|
8
|
+
|
|
9
|
+
## 公共前置
|
|
10
|
+
|
|
11
|
+
先通过 E10 鉴权模块登录:
|
|
12
|
+
|
|
13
|
+
```text
|
|
14
|
+
weaver-work-cli auth login --base-url "https://weapp.xxx.cn" --agent_type "<当前智能体名称>"
|
|
15
|
+
weaver-work-cli auth status --no-check
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
每个资管家业务请求由 CLI 托管:读取当前 `weaver-work-cli auth` Profile 的 E10 会话,并调用 eBuilder 自定义接口(`/api/ebuilder/form/formdata/v2/*`)或 ESB 动作流(`/api/esb/server/event/triggerActionFlow`)。Agent 不得在业务 JSON 中传 Cookie、ETEAMSID、Token 或内部控制字段。
|
|
19
|
+
|
|
20
|
+
## 版本门禁
|
|
21
|
+
|
|
22
|
+
源资料约定:任何资产查询或写操作前,必须先确认 `zgjasset_search_appver` 存在 `ver_name ≥ V14` 的记录。CLI 在每个写操作中内置门禁,并额外暴露 `asset.gate.check` 供只读校验。门禁未通过时写操作会 STOP,不执行任何资产请求,也不走任何降级路径。
|
|
23
|
+
|
|
24
|
+
## Agent 入口
|
|
25
|
+
|
|
26
|
+
优先使用 `asset run <operation>`:
|
|
27
|
+
|
|
28
|
+
Windows PowerShell:
|
|
29
|
+
|
|
30
|
+
```powershell
|
|
31
|
+
weaver-work-cli asset schema
|
|
32
|
+
weaver-work-cli --json asset run asset.list --input-json '{"page_size":10}'
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
macOS/Linux(bash/zsh):
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
weaver-work-cli asset schema
|
|
39
|
+
weaver-work-cli --json asset run asset.list --input-json '{"page_size":10}'
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
成功和失败都使用 JSON envelope。成功写 stdout;失败写 stderr,并设置非 0 退出码。
|
|
43
|
+
|
|
44
|
+
当前输出层是完整 JSON 直接写 stdout,不提供飞书 CLI 的 `--jq`、`--format table/ndjson` 或通用 `--page-all`。Agent 使用时应默认小页读取和摘要渲染:列表先 `page_size=10`,按 `page_no` 继续;回复只展示关键字段和数量,超长详情/OCR/调试 JSON 落本地文件后给路径。
|
|
45
|
+
|
|
46
|
+
## Operation 目录
|
|
47
|
+
|
|
48
|
+
| Operation | 风险 | 固定规则 |
|
|
49
|
+
| --- | --- | --- |
|
|
50
|
+
| `asset.gate.check` | 只读 | 版本门禁校验,返回是否通过 |
|
|
51
|
+
| `asset.list` | 只读 | 资产台账列表,按 mainTable 字段筛选 |
|
|
52
|
+
| `asset.detail` | 只读 | 资产详情,至少传 id / asset_number / asset_name 之一 |
|
|
53
|
+
| `asset.uselist` | 只读 | 领用列表,person_id 缺省查当前登录人 |
|
|
54
|
+
| `asset.repaillist` | 只读 | 报修列表,person_id 缺省查当前登录人 |
|
|
55
|
+
| `asset.purchaselist` | 只读 | 采购申请列表,person_id 缺省查当前登录人 |
|
|
56
|
+
| `asset.resolve.location` | 只读 | 按 house_name 解析存放地点 ID |
|
|
57
|
+
| `asset.resolve.status` | 只读 | 按 status_name 解析资产状态 ID |
|
|
58
|
+
| `asset.resolve.type` | 只读 | 按 type_name 解析资产类型 ID |
|
|
59
|
+
| `asset.create` | 高风险写 | eBuilder saveFormData;prepare 返回 continuation |
|
|
60
|
+
| `asset.update` | 高风险写 | eBuilder updateFormData;prepare 返回 continuation |
|
|
61
|
+
| `asset.use` | 高风险写 | ESB 动作流领用;prepare 返回 continuation |
|
|
62
|
+
| `asset.return.query` | 写前只读 | ESB 动作流查询可归还候选 |
|
|
63
|
+
| `asset.return.create` | 高风险写 | ESB 动作流归还;prepare 返回 continuation |
|
|
64
|
+
| `asset.repair.query` | 写前只读 | ESB 动作流查询报修候选 |
|
|
65
|
+
| `asset.repair.create` | 高风险写 | ESB 动作流报修;prepare 返回 continuation |
|
|
66
|
+
| `asset.purch` | 高风险写 | ESB 动作流采购申请;prepare 返回 continuation |
|
|
67
|
+
| `asset.depre` | 高风险写 | 折旧设置读取 + 预检 + 任务创建;prepare 返回 continuation |
|
|
68
|
+
|
|
69
|
+
暂未暴露:资产调拨(`asset.transfer`)、流程审批(`asset.approve`)、图片上传(`asset.file.upload`)。原因见 `skills/weaver-e10-ziguanjia/references/ziguanjia-disabled-capabilities.md`。
|
|
70
|
+
|
|
71
|
+
## 常用命令
|
|
72
|
+
|
|
73
|
+
```text
|
|
74
|
+
weaver-work-cli --json asset run asset.gate.check --input-json '{}'
|
|
75
|
+
weaver-work-cli --json asset run asset.list --input-json '{"page_size":10}'
|
|
76
|
+
weaver-work-cli --json asset run asset.resolve.type --input-json '{"type_name":"EXAMPLE_TYPE"}'
|
|
77
|
+
weaver-work-cli --json asset run asset.create --input-json '{"asset_name":"EXAMPLE_ASSET","asset_type_browse":"EXAMPLE_TYPE_ID"}'
|
|
78
|
+
weaver-work-cli --json asset run asset.create --input-json '{"continuation":"PREPARE_CONTINUATION","confirm":true}'
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
## 编辑白名单
|
|
82
|
+
|
|
83
|
+
写操作的 `prepare` 阶段只接受 manifest 已声明字段;其中:
|
|
84
|
+
|
|
85
|
+
- `asset.update` 的 `changes` 只允许:`asset_name`、`stateid`、`admin_istrator`、`resourceid`、`location_browse`、`unit_price`、`value`。
|
|
86
|
+
- `asset.create` 不接受 `id`、内部控制字段或文件上传;图片仅接受已上传得到的裸 `file_id`。
|
|
87
|
+
- 所有写操作都不接受 `Cookie`、`ETEAMSID`、`token`、`sedit`、`app_key`、`app_secret`、`access_token` 等内部控制/凭据字段(CLI 会在输入层拒绝)。
|
|
88
|
+
|
|
89
|
+
写请求已发送后如遇网络中断、部分成功或回查失败,CLI 返回 `partial/write_uncertain`,Agent 禁止自动重复提交。
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "weaver-work-cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5",
|
|
4
4
|
"description": "面向泛微工作工具链的可扩展 TypeScript CLI 基础框架(E10 业票通等能力)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -18,11 +18,11 @@
|
|
|
18
18
|
"scripts": {
|
|
19
19
|
"dev": "tsx src/index.ts",
|
|
20
20
|
"clean": "node scripts/clean.mjs",
|
|
21
|
-
"build": "npm run clean && tsc",
|
|
22
|
-
"test": "node --
|
|
21
|
+
"build": "npm run clean && tsc && node scripts/postbuild.mjs",
|
|
22
|
+
"test": "node --import tsx --test $(find test -name '*.test.ts' -type f | sort)",
|
|
23
23
|
"start": "node dist/index.js",
|
|
24
24
|
"build:skill": "node scripts/package-skill.mjs",
|
|
25
|
-
"build:
|
|
25
|
+
"build:yepiaotong-skill": "node scripts/package-skill.mjs yepiaotong",
|
|
26
26
|
"prepublishOnly": "npm run build && npm run test",
|
|
27
27
|
"prepack": "npm run build"
|
|
28
28
|
},
|
|
@@ -1,33 +1,24 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { createHash } from 'node:crypto'
|
|
4
|
-
import { copyFile, mkdir, mkdtemp, readFile, readdir, rm, stat } from 'node:fs/promises'
|
|
4
|
+
import { copyFile, mkdir, mkdtemp, readFile, readdir, rm, stat, writeFile } from 'node:fs/promises'
|
|
5
5
|
import os from 'node:os'
|
|
6
6
|
import path from 'node:path'
|
|
7
|
-
import { spawn } from 'node:child_process'
|
|
8
7
|
import { fileURLToPath } from 'node:url'
|
|
8
|
+
import { deflateRawSync } from 'node:zlib'
|
|
9
9
|
|
|
10
10
|
const repositoryRoot = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..')
|
|
11
11
|
const skillsRoot = path.join(repositoryRoot, 'skills')
|
|
12
|
-
const sharedSkillName = 'weaver-
|
|
12
|
+
const sharedSkillName = 'weaver-e10-shared'
|
|
13
|
+
const legacySharedSkillName = 'weaver-work-cli-shared'
|
|
14
|
+
const skillPrefix = 'weaver-e10-'
|
|
15
|
+
const legacySkillPrefix = 'weaver-work-cli-'
|
|
13
16
|
const [requestedSkillArg, outputArg] = process.argv.slice(2)
|
|
14
17
|
|
|
15
18
|
function sha256(value) {
|
|
16
19
|
return createHash('sha256').update(value).digest('hex')
|
|
17
20
|
}
|
|
18
21
|
|
|
19
|
-
function run(command, args, cwd) {
|
|
20
|
-
return new Promise((resolve, reject) => {
|
|
21
|
-
const child = spawn(command, args, { cwd, stdio: ['ignore', 'pipe', 'pipe'] })
|
|
22
|
-
let stdout = ''
|
|
23
|
-
let stderr = ''
|
|
24
|
-
child.stdout.on('data', (chunk) => { stdout += chunk })
|
|
25
|
-
child.stderr.on('data', (chunk) => { stderr += chunk })
|
|
26
|
-
child.once('error', reject)
|
|
27
|
-
child.once('close', (code) => resolve({ code: code ?? 1, stdout, stderr }))
|
|
28
|
-
})
|
|
29
|
-
}
|
|
30
|
-
|
|
31
22
|
function normalizeSkillName(value) {
|
|
32
23
|
if (!value || value === 'all') return null
|
|
33
24
|
if (value.includes('/') || value.includes('\\') || value === '.' || value === '..') {
|
|
@@ -36,7 +27,8 @@ function normalizeSkillName(value) {
|
|
|
36
27
|
if (!/^[A-Za-z0-9._-]+$/u.test(value)) {
|
|
37
28
|
throw new Error(`非法 Skill 名称:${value}`)
|
|
38
29
|
}
|
|
39
|
-
|
|
30
|
+
if (value.startsWith(legacySkillPrefix)) return `${skillPrefix}${value.slice(legacySkillPrefix.length)}`
|
|
31
|
+
return value.startsWith(skillPrefix) ? value : `${skillPrefix}${value}`
|
|
40
32
|
}
|
|
41
33
|
|
|
42
34
|
async function exists(filename) {
|
|
@@ -76,7 +68,7 @@ function defaultOutput(skillNames) {
|
|
|
76
68
|
return path.join(repositoryRoot, 'dist', `${requestedSkill}-skill.zip`)
|
|
77
69
|
}
|
|
78
70
|
if (skillNames.length === 1) return path.join(repositoryRoot, 'dist', `${skillNames[0]}-skill.zip`)
|
|
79
|
-
return path.join(repositoryRoot, 'dist', 'weaver-
|
|
71
|
+
return path.join(repositoryRoot, 'dist', 'weaver-e10-skills.zip')
|
|
80
72
|
}
|
|
81
73
|
|
|
82
74
|
function shouldSkip(entry, relativePath) {
|
|
@@ -91,9 +83,111 @@ function assertSafeRelativePath(relativePath) {
|
|
|
91
83
|
}
|
|
92
84
|
}
|
|
93
85
|
|
|
94
|
-
|
|
86
|
+
function crc32(buffer) {
|
|
87
|
+
let crc = 0xffffffff
|
|
88
|
+
for (const byte of buffer) {
|
|
89
|
+
crc ^= byte
|
|
90
|
+
for (let bit = 0; bit < 8; bit += 1) {
|
|
91
|
+
crc = (crc >>> 1) ^ (crc & 1 ? 0xedb88320 : 0)
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
return (crc ^ 0xffffffff) >>> 0
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
function dosTimestamp() {
|
|
98
|
+
return { time: 0, date: 33 }
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
function uint16(value) {
|
|
102
|
+
const buffer = Buffer.alloc(2)
|
|
103
|
+
buffer.writeUInt16LE(value)
|
|
104
|
+
return buffer
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
function uint32(value) {
|
|
108
|
+
const buffer = Buffer.alloc(4)
|
|
109
|
+
buffer.writeUInt32LE(value)
|
|
110
|
+
return buffer
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
async function createZipArchive(root, entries) {
|
|
114
|
+
const timestamp = dosTimestamp()
|
|
115
|
+
const localParts = []
|
|
116
|
+
const centralParts = []
|
|
117
|
+
let offset = 0
|
|
118
|
+
|
|
119
|
+
for (const entry of entries) {
|
|
120
|
+
const name = Buffer.from(entry, 'utf8')
|
|
121
|
+
const body = await readFile(path.join(root, ...entry.split('/')))
|
|
122
|
+
const deflated = deflateRawSync(body, { level: 9 })
|
|
123
|
+
const compressed = deflated.length < body.length ? deflated : body
|
|
124
|
+
const method = compressed === deflated ? 8 : 0
|
|
125
|
+
const checksum = crc32(body)
|
|
126
|
+
const flags = 0x0800
|
|
127
|
+
|
|
128
|
+
const localHeader = Buffer.concat([
|
|
129
|
+
uint32(0x04034b50),
|
|
130
|
+
uint16(20),
|
|
131
|
+
uint16(flags),
|
|
132
|
+
uint16(method),
|
|
133
|
+
uint16(timestamp.time),
|
|
134
|
+
uint16(timestamp.date),
|
|
135
|
+
uint32(checksum),
|
|
136
|
+
uint32(compressed.length),
|
|
137
|
+
uint32(body.length),
|
|
138
|
+
uint16(name.length),
|
|
139
|
+
uint16(0),
|
|
140
|
+
name,
|
|
141
|
+
])
|
|
142
|
+
localParts.push(localHeader, compressed)
|
|
143
|
+
|
|
144
|
+
const centralHeader = Buffer.concat([
|
|
145
|
+
uint32(0x02014b50),
|
|
146
|
+
uint16(20),
|
|
147
|
+
uint16(20),
|
|
148
|
+
uint16(flags),
|
|
149
|
+
uint16(method),
|
|
150
|
+
uint16(timestamp.time),
|
|
151
|
+
uint16(timestamp.date),
|
|
152
|
+
uint32(checksum),
|
|
153
|
+
uint32(compressed.length),
|
|
154
|
+
uint32(body.length),
|
|
155
|
+
uint16(name.length),
|
|
156
|
+
uint16(0),
|
|
157
|
+
uint16(0),
|
|
158
|
+
uint16(0),
|
|
159
|
+
uint16(0),
|
|
160
|
+
uint32(0),
|
|
161
|
+
uint32(offset),
|
|
162
|
+
name,
|
|
163
|
+
])
|
|
164
|
+
centralParts.push(centralHeader)
|
|
165
|
+
offset += localHeader.length + compressed.length
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
const centralDirectory = Buffer.concat(centralParts)
|
|
169
|
+
const end = Buffer.concat([
|
|
170
|
+
uint32(0x06054b50),
|
|
171
|
+
uint16(0),
|
|
172
|
+
uint16(0),
|
|
173
|
+
uint16(entries.length),
|
|
174
|
+
uint16(entries.length),
|
|
175
|
+
uint32(centralDirectory.length),
|
|
176
|
+
uint32(offset),
|
|
177
|
+
uint16(0),
|
|
178
|
+
])
|
|
179
|
+
|
|
180
|
+
return Buffer.concat([...localParts, centralDirectory, end])
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
function rewriteSkillContent(skillName, relativePath, content) {
|
|
184
|
+
if (skillName !== legacySharedSkillName || relativePath !== 'SKILL.md') return content
|
|
185
|
+
return content.replace(/^name:\s*weaver-e10-shared\s*$/mu, `name: ${legacySharedSkillName}`)
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
async function copySkill(skillName, stagingRoot, packagedEntries, packageName = skillName) {
|
|
95
189
|
const sourceRoot = path.join(skillsRoot, skillName)
|
|
96
|
-
const packageRoot = path.join(stagingRoot,
|
|
190
|
+
const packageRoot = path.join(stagingRoot, packageName)
|
|
97
191
|
await stat(path.join(sourceRoot, 'SKILL.md'))
|
|
98
192
|
|
|
99
193
|
async function copyDir(relativeDir = '') {
|
|
@@ -113,8 +207,13 @@ async function copySkill(skillName, stagingRoot, packagedEntries) {
|
|
|
113
207
|
await copyDir(relativePath)
|
|
114
208
|
} else if (entry.isFile()) {
|
|
115
209
|
await mkdir(path.dirname(target), { recursive: true, mode: 0o700 })
|
|
116
|
-
|
|
117
|
-
|
|
210
|
+
if (packageName === skillName) {
|
|
211
|
+
await copyFile(source, target)
|
|
212
|
+
} else {
|
|
213
|
+
const content = await readFile(source, 'utf8')
|
|
214
|
+
await writeFile(target, rewriteSkillContent(packageName, relativePath, content))
|
|
215
|
+
}
|
|
216
|
+
packagedEntries.push(`${packageName}/${relativePath}`)
|
|
118
217
|
}
|
|
119
218
|
}
|
|
120
219
|
}
|
|
@@ -134,31 +233,25 @@ const skillNames = await resolveSkillNames()
|
|
|
134
233
|
if (skillNames.length === 0) throw new Error('没有可打包的 Skill')
|
|
135
234
|
|
|
136
235
|
const output = path.resolve(outputArg || defaultOutput(skillNames))
|
|
137
|
-
const stagingRoot = await mkdtemp(path.join(os.tmpdir(), 'weaver-
|
|
236
|
+
const stagingRoot = await mkdtemp(path.join(os.tmpdir(), 'weaver-e10-skill-'))
|
|
138
237
|
const packagedEntries = []
|
|
139
238
|
|
|
140
239
|
try {
|
|
141
240
|
await mkdir(path.dirname(output), { recursive: true, mode: 0o700 })
|
|
142
241
|
for (const skillName of skillNames) {
|
|
143
242
|
await copySkill(skillName, stagingRoot, packagedEntries)
|
|
243
|
+
if (skillName === sharedSkillName) {
|
|
244
|
+
await copySkill(skillName, stagingRoot, packagedEntries, legacySharedSkillName)
|
|
245
|
+
}
|
|
144
246
|
}
|
|
145
247
|
|
|
146
248
|
await rm(output, { force: true })
|
|
147
|
-
const zipResult = await run('zip', ['-X', '-q', '-r', output, ...skillNames], stagingRoot)
|
|
148
|
-
if (zipResult.code !== 0) throw new Error(`Skill ZIP 打包失败:${zipResult.stderr.trim()}`)
|
|
149
|
-
|
|
150
|
-
const archive = await readFile(output)
|
|
151
|
-
const listResult = await run('unzip', ['-Z1', output], repositoryRoot)
|
|
152
|
-
if (listResult.code !== 0) throw new Error(`Skill ZIP 校验失败:${listResult.stderr.trim()}`)
|
|
153
|
-
|
|
154
|
-
const actualEntries = listResult.stdout.trim().split(/\r?\n/u).filter((entry) => entry && !entry.endsWith('/')).sort()
|
|
155
249
|
const expectedEntries = packagedEntries.sort()
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
}
|
|
250
|
+
const archive = await createZipArchive(stagingRoot, expectedEntries)
|
|
251
|
+
await writeFile(output, archive)
|
|
159
252
|
if (archive.length > 256 * 1024) throw new Error(`Skill ZIP 超过 256 KiB:${archive.length}`)
|
|
160
253
|
|
|
161
|
-
console.log(JSON.stringify({ ok: true, output, bytes: (await stat(output)).size, sha256: sha256(archive), skills: skillNames, entries:
|
|
254
|
+
console.log(JSON.stringify({ ok: true, output, bytes: (await stat(output)).size, sha256: sha256(archive), skills: skillNames, entries: expectedEntries }, null, 2))
|
|
162
255
|
} finally {
|
|
163
256
|
await rm(stagingRoot, { recursive: true, force: true })
|
|
164
257
|
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
// 构建后把 bin 入口设为可执行,保证 `npm link` 场景下全局命令可运行。
|
|
4
|
+
// tsc 每次重建 dist/index.js 都会把权限重置为 644,因此放在 build 之后执行。
|
|
5
|
+
import { chmodSync, existsSync } from 'node:fs';
|
|
6
|
+
import { fileURLToPath } from 'node:url';
|
|
7
|
+
|
|
8
|
+
const entry = fileURLToPath(new URL('../dist/index.js', import.meta.url));
|
|
9
|
+
|
|
10
|
+
if (existsSync(entry)) {
|
|
11
|
+
chmodSync(entry, 0o755);
|
|
12
|
+
console.log('postbuild: dist/index.js mode set to 755');
|
|
13
|
+
}
|
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
{
|
|
2
|
-
"weaver-
|
|
3
|
-
"weaver-
|
|
2
|
+
"weaver-e10-calendar": ["日程", "日程管理", "创建日程", "日程列表", "日程详情", "删除日程", "日程类型", "紧急程度", "日历"],
|
|
3
|
+
"weaver-e10-meeting": ["会议", "会议室", "预约会议", "建会", "会议冲突", "签到", "回执", "会议类型", "会议室占用", "今天会议", "下一场会议", "会议列表", "请假回执"],
|
|
4
|
+
"weaver-e10-wenshuding": ["文书定", "档案", "全宗", "预归档", "档案检索", "全文检索", "借阅车", "借阅单", "借阅", "续借", "档案下载", "原文下载", "预归档上传", "电子文件库"],
|
|
5
|
+
"weaver-e10-yepiaotong": ["业票通", "发票", "票夹", "OCR", "查验", "报销发票", "自动填单", "事前申请报销", "开票", "存台账", "发票浏览按钮"],
|
|
6
|
+
"weaver-e10-jucailin": ["聚才林", "人事", "人事档案", "通讯录", "出勤", "考勤", "打卡", "申诉", "薪酬", "工资单", "社保", "招聘", "人才", "候选人", "面试", "Offer", "入职"],
|
|
7
|
+
"weaver-e10-qiyecheng": ["齐业成", "费控", "FNA", "预算", "事前申请", "预算执行", "报销", "借款", "还款提醒", "预付", "核销", "发票核销", "催票", "对公支付"],
|
|
8
|
+
"weaver-e10-hrm": ["组织管理", "员工", "人员", "工号", "下属", "部门", "分部", "组织架构", "岗位", "职位", "批量查人员", "批量查岗位"],
|
|
9
|
+
"weaver-e10-esb": ["ESB", "动作流", "触发动作流", "执行动作流", "自定义触发", "入参模板", "ESB中心"],
|
|
10
|
+
"weaver-e10-mail": ["邮件", "收件箱", "发件箱", "草稿箱", "已删除", "待办邮件", "垃圾箱", "邮件正文", "附件", "发送邮件", "回复", "转发", "存草稿", "标星", "已读", "待办提醒", "移动邮件", "删除邮件", "撤回", "文件夹", "联系人", "联系人分组", "邮件模板", "签名", "二维码名片", "黑名单"],
|
|
11
|
+
"weaver-e10-calendar": ["日程", "日历", "安排", "提醒", "日程列表", "日程详情", "创建日程", "更新日程", "删除日程", "日程类型", "紧急程度", "参与人"],
|
|
12
|
+
"weaver-e10-plan": ["计划报告", "报告", "周报", "月报", "季报", "年报", "年中报告", "工作总结", "汇总工作", "新建报告", "修改报告", "发布报告", "撤回报告", "共享报告", "提交提醒", "报告评论", "报告详情"],
|
|
13
|
+
"weaver-e10-jiuchuanhui": ["九氚汇", "营销管理", "CRM", "客户", "联系人", "商机", "线索", "联系计划", "联系记录", "跟进记录", "公海", "客户公海", "赢单", "输单", "线索转客户", "客户经理"],
|
|
14
|
+
"weaver-e10-skill-maker": ["业务模块 CLI", "业务模块 Skill", "生成 Skill", "生成 operation", "自定义 Skill", "能力封装", "源资料更新检测"],
|
|
15
|
+
"weaver-e10-shared": ["安装", "登录", "认证", "E10", "profile", "JSON 输出", "高风险写入"],
|
|
16
|
+
"weaver-e10-ziguanjia": ["资管家", "资产管理", "固定资产", "资产", "资产领用", "资产归还", "资产报修", "资产采购", "折旧", "资产地点", "资产状态", "资产类型"],
|
|
17
|
+
"weaver-e10-yimiaoban": ["易秒办", "即时通讯", "聊天", "单聊消息", "群聊消息", "群消息", "发消息", "撤回", "置顶", "必达", "Ding", "建群", "拉群", "群成员", "踢人", "退群", "解散群", "群公告", "群主", "管理员", "会话列表", "最近会话", "系统消息", "聊天记录", "历史消息", "发送文件", "发送图片", "在线状态", "下载附件", "查看图片"]
|
|
4
18
|
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
本业务域用于 E10 日程管理。入口 `SKILL.md` 按 weaver 风格组织:CRITICAL 共享前置、路由优先级、高优先级语义、写操作确认链、执行原则、失败处理和「不在范围」。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `calendar-query.md`:日程列表(ESB 流程触发)、日程详情、日程总数。
|
|
4
|
+
- `calendar-dict.md`:日程类型、紧急程度字典(创建/更新前取选项 ID)。
|
|
5
|
+
- `calendar-write.md`:创建、更新(全量覆盖)、删除日程的 `prepare -> apply` 写入协议。
|
|
6
|
+
- `calendar-app-check.md`:应用版本检测与详情卡片页链接。
|
|
7
|
+
|
|
8
|
+
Agent 调优重点:
|
|
9
|
+
|
|
10
|
+
- `weaver-work-cli calendar schema` 是 operation 合约第一信息源。
|
|
11
|
+
- 业务输入不得包含 Cookie、ETEAMSID、Token 或内部控制字段;`header.operator` 由 CLI 自动填充。
|
|
12
|
+
- `agn_type`/`priority` 传选项 ID(先查字典),`participants` 传人员 ID(先由 weaver-e10-hrm 解析姓名)。
|
|
13
|
+
- 写操作只接受 CLI 生成的 continuation,不手工构造或复用;`confirm=true` 必须由用户明确确认后传入。
|
|
14
|
+
- 更新为全量覆盖,`update.prepare` 先查当前详情再合并;删除不可逆,务必 prepare 展示后确认。
|
|
15
|
+
- 结果为 `partial/write_uncertain` 时停止,不自动重放写请求。
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
本业务域用于泛微 E10 ESB 中心的自定义触发动作流(取入参模板 + 触发执行)。入口 `SKILL.md` 先路由到 `weaver-e10-shared/SKILL.md`,再给出触发标识语义、写操作确认链和失败决策树。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `input-format.md`:按动作流 ID 取 `customParams` 模板、识别 `#可选` 占位字段、只读查询的失败处理。
|
|
4
|
+
- `trigger.md`:`esb.trigger.prepare` → `esb.trigger.apply` 确认链、请求体组装、结果判读(`resultCode` / `actionData` / `followUp`)与失败处置。
|
|
5
|
+
- `source-manifest.json`:源资料清单与 sha256 指纹,用于源资料更新检测。
|
|
6
|
+
|
|
7
|
+
调优重点:
|
|
8
|
+
|
|
9
|
+
- `weaver-work-cli esb schema` 是 operation 合约第一信息源;`withheldOperations` 声明按名称解析 ID(`esb.actionflow.resolve`)与唯一值 `primary_key` 查询(`esb.unique-indent.resolve`)两条禁用边界,直接说明不可用,不引导用户绕过。
|
|
10
|
+
- 触发标识 `esbFlowId` 与 `uniqueIndent` 二选一:都传或多缺均为结构化校验错误,不得静默回退;唯一值触发存在「同租户多流同唯一值只执行 create_time 最新一条」的歧义,精确控制要求用户改传 `esbFlowId`。
|
|
11
|
+
- **trigger 是写操作**:必须先 `prepare` 并把 `requestPreview` 展示给用户确认,再 `apply` 且 `confirm: true`。
|
|
12
|
+
- `write_uncertain` 出现时必须立即停止:请求已发出但结果未知,禁止重试,先查动作流运行日志。
|
|
13
|
+
- 限流类错误(`throttled`)只提示稍后重试,不做高频轮询。
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
本业务域用于泛微 E10 组织管理(员工查询 / 组织架构 / 岗位查询,全部只读)。入口 `SKILL.md` 先路由到 `weaver-e10-shared/SKILL.md`,再给出跨模块约定、Reference 路由表和安全边界。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `employee.md`:按工号/姓名/手机/邮箱查员工、批量人员、资料名片、下属查询(当前登录人 + 按 id)、部门成员。
|
|
4
|
+
- `org.md`:分部/部门浏览、组织详情、多级路径 drill-down 编排。
|
|
5
|
+
- `position.md`:岗位浏览、岗位详情、岗位批量(岗位地址簿)。
|
|
6
|
+
- `source-manifest.json`:源资料清单与 sha256 指纹,用于源资料更新检测。
|
|
7
|
+
|
|
8
|
+
调优重点:
|
|
9
|
+
|
|
10
|
+
- `weaver-work-cli hrm schema` 是 operation 合约第一信息源,`withheldOperations` 声明代理商查询禁用边界。
|
|
11
|
+
- 三个业务域统一 `WeaResult` 响应契约,已在 CLI 内归一化;但「员工浏览/下属查询的 total 需额外请求 count/resource」这一差异必须由 Agent 正确解读。
|
|
12
|
+
- 长整型 id 一律按字符串传递;手机号已由 CLI 脱敏。
|
|
13
|
+
- **无条件禁止全量拉取**:`employee.query`/`org.query`/`position.query` 必须带收敛条件;`position.list` 无过滤需显式 `all=true`;`employee.query` 的 `status` 不能单独使用。
|
|
14
|
+
- 姓名/工号/名称模糊匹配多人命中时必须列候选让用户选择,不得自动取第一条;部门重名改传组织 id。
|
|
15
|
+
- 批量查询禁止循环单查:批量人员走 `employee.batch`,岗位批量走 `position.list`。
|
|
16
|
+
- 代理商查询(`containsDls=true`)属禁用边界,直接说明不可用,不引导用户绕过。
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
本业务域用于 E10 九氚汇营销管理 CRM。入口 `SKILL.md` 按飞书 `lark-approval` 风格组织:CRITICAL 共享前置、路由优先级、高优先级语义、逐 operation 命令表、处理链、执行原则、写操作失败决策树和“不在范围”。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `jiuchuanhui-entry.md`:schema、统一 `jiuchuanhui run` 入口、JSON 输入方式。
|
|
4
|
+
- `customer.md`:客户创建/详情/搜索/修改/转移/公海/查重/联系记录的写入协议与搜索约束。
|
|
5
|
+
- `contact.md`:联系人创建/详情/修改/按事项查询。
|
|
6
|
+
- `sale.md`:商机创建/详情/搜索/修改/阶段/赢单/输单/无效/暂停/重启/转移/关联联系人/联系记录。
|
|
7
|
+
- `clue.md`:线索创建/详情/搜索/修改/状态变更/转客户/线索池/跟进记录。
|
|
8
|
+
- `contact-plan.md`:创建/完成联系计划的 `type` 联动规则。
|
|
9
|
+
- `contact-records.md`:按事项或按人员+时间范围查询联系记录。
|
|
10
|
+
- `discovery-config.md`:应用/表单/字段/选项/接口配置/文件预览的发现与配置,含缓存初始化边界。
|
|
11
|
+
- `general-helpers.md`:按名称查事项/人员 ID、当前人员、权限校验、工商照面、字段信息、自定义浏览选项。
|
|
12
|
+
- `disabled-capabilities.md`:缓存初始化、商机阶段推进等未暴露能力的处理边界。
|
|
13
|
+
- `source-manifest.json`:源资料指纹、`sourceChunks`/`operationImpact` 影响索引和产物基线。
|
|
14
|
+
|
|
15
|
+
Agent 调优重点:
|
|
16
|
+
|
|
17
|
+
- `weaver-work-cli jiuchuanhui schema` 是 operation 合约第一信息源。
|
|
18
|
+
- 业务输入不得包含 Cookie、ETEAMSID、Token 或内部控制字段。
|
|
19
|
+
- 写操作只接受 CLI 生成的 continuation,不手工构造或复用。
|
|
20
|
+
- 选项字段先取选项 ID 再传值;`RelateBrowser` 用 `browser-option.search`;行政区划用逗号分隔全路径 ID。
|
|
21
|
+
- 客户搜索必须显式传 `mine`/`all`/`customerSea`,没有 `scope` 快捷参数。
|
|
22
|
+
- 新建客户前先查重;赢单/输单/无效/释放公海前提示不可逆或关键影响。
|
|
23
|
+
- 结果为 `partial/write_uncertain` 时停止,不自动重放写请求。
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
本业务域用于泛微聚才林(E10 人事云)的人事档案、出勤管理、薪酬管理、招聘查询(只读)。入口 `SKILL.md` 先路由到 `weaver-e10-shared/SKILL.md`,再给出跨子系统差异、Reference 路由表和安全边界。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `salary.md`:工资单、福利、调薪记录、社保台账、员工薪资明细查询。
|
|
4
|
+
- `attend-read.md`:出勤统计、异常考勤、打卡记录、外勤轨迹、假期统计、申诉查询。
|
|
5
|
+
- `attend-write.md`:PC 端打卡、创建申诉、处理申诉、报表重算的 `prepare -> apply` 写入协议。
|
|
6
|
+
- `hr-contact.md`:通讯录、字段列表、浏览器选择器、生日查询、人员状态变更台账。
|
|
7
|
+
- `hr-datasource.md`:HR 数据源通用查询(历史时点名册、离职名册、编制、流动分析等)。
|
|
8
|
+
- `hr-report.md`:部门/岗位/职务/职类人数、流失离职、占编人员、流动明细、属性合计。
|
|
9
|
+
- `recruit-read.md`:人才库搜索、招聘需求/职位/入职/录用列表、人才详情卡片(只读)。
|
|
10
|
+
- `safety-boundaries.md`:招聘写操作与移动端打卡的禁用边界,以及通用禁止项。
|
|
11
|
+
- `source-manifest.json`:源资料清单与 sha256 指纹,用于源资料更新检测。
|
|
12
|
+
|
|
13
|
+
调优重点:
|
|
14
|
+
|
|
15
|
+
- `weaver-work-cli ehr schema` 是 operation 合约第一信息源,`dataSourceIds` 提供固定 formId 常量表。
|
|
16
|
+
- 三个子系统的响应成功判定与分页结构不统一,已在 CLI 内归一化;但「通讯录默认在职、状态变更默认含离职」的语义差异必须由 Agent 正确解读。
|
|
17
|
+
- 姓名、工号等模糊条件多人命中时必须列候选让用户选择,浏览器选择器返回多条时看 `requiresDisambiguation`。
|
|
18
|
+
- 占编人员查询的 `cfgId`/`id` 必须先从数据源记录解析,禁止编造。
|
|
19
|
+
- 招聘查询的运行时参数由 CLI 自动五层解析并缓存,业务输入只描述业务对象与意图;人才/需求等模糊命中多人时同样必须列候选让用户确认。
|
|
20
|
+
- 写操作只接受 CLI 生成的 continuation,不手工构造或复用;`apply` 不自动重试。
|
|
21
|
+
- 招聘写操作与移动端打卡属禁用边界,直接说明不可用,不引导用户绕过。
|
|
22
|
+
- 结果为 `partial/write_uncertain` 时停止,先做只读回查。
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
本业务域用于 E10 邮件管理。入口 `SKILL.md` 按飞书风格组织:CRITICAL 共享前置、路由优先级、高优先级语义、逐 operation 命令表、处理链、执行原则、写操作失败决策树和“不在范围”。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `mail-agent-entry.md`:schema、统一 `mail run` 入口、stdin JSON 调用方式。
|
|
4
|
+
- `mail-read.md`:邮件列表/详情/正文/未读统计/配置、收件人解析、联系人/分组/模板/签名/黑名单列表与附件中心。
|
|
5
|
+
- `mail-send.md`:发送/回复/转发/存草稿的 `prepare -> apply` 写入协议。
|
|
6
|
+
- `mail-manage.md`:标星、已读、全部已读、待办、移动、逻辑删除、文件夹、撤回。
|
|
7
|
+
- `mail-contacts.md`:联系人/分组的 `prepare -> apply` 保存与删除。
|
|
8
|
+
- `mail-template.md`:模板的 `prepare -> apply` 保存、编辑、删除与默认。
|
|
9
|
+
- `mail-sign.md`:签名的 `prepare -> apply` 保存、编辑、删除、默认与二维码名片。
|
|
10
|
+
- `mail-blacklist.md`:黑名单新增/删除的 `prepare -> apply` 协议。
|
|
11
|
+
- `mail-attachment.md`:附件上传(预检→上传→绑定)与批量下载。
|
|
12
|
+
- `safety-boundaries.md`:已暂缓的破坏性/缺口 operation(物理永久删除、重发)与高风险写约束。
|
|
13
|
+
|
|
14
|
+
Agent 调优重点:
|
|
15
|
+
|
|
16
|
+
- `weaver-work-cli mail schema` 是 operation 合约第一信息源。
|
|
17
|
+
- 业务输入不得包含 Cookie、ETEAMSID、Token 或内部控制字段。
|
|
18
|
+
- 写操作只接受 CLI 生成的 continuation,不手工构造或复用。
|
|
19
|
+
- 发送、联系人/分组/模板/签名保存、黑名单操作必须先展示摘要并取得明确确认。
|
|
20
|
+
- 结果为 `partial/write_uncertain` 时停止,不自动重放写请求。
|
|
21
|
+
- 物理永久删除(`mail.delete.batch`)与重发(`mail.resend`)未暴露,需单独授权处理。
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
# 会议(meeting)业务域
|
|
2
|
+
|
|
3
|
+
会议域覆盖 E10 标准版会议应用:环境模式探测、会议列表、会议室与占用视图、会议类型、冲突检测、预约会议(prepare/apply 确认链)、回执与签到查询。入口 `SKILL.md` 只做路由;具体命令、字段约束与失败处理拆到 `references/`(meeting-queries / meeting-create / meeting-receipts-signs)。关键安全边界:预约与回执更新是高风险写,必须走 prepare→用户确认→apply;冲突命中(含仅提醒)绝不提供"强制新建"选项;EB 版链路与工作流建会在 v1 未实现,见 manifest 的 withheldOperations。
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
本业务域用于 E10 计划报告管理,覆盖「汇总生成报告」与「查询/管理已有报告」两条链路。入口 `SKILL.md` 按 weaver 风格组织:CRITICAL 共享前置、意图判定 A/B、路由优先级、高优先级语义、写操作确认链、执行原则、失败处理和「不在范围」。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `plan-overview-and-routing.md`:意图判定、版本路由与租户缓存、operation 总表、通用基础规则。
|
|
4
|
+
- `plan-report-query.md`:报告详情、报告分页列表、报告评论及评论输出规则。
|
|
5
|
+
- `plan-report-write.md`:新建/修改/发布/撤回的 `prepare -> apply` 写入协议与查重规则。
|
|
6
|
+
- `plan-report-remind.md`:提交提醒的触发前提、默认文案与发送确认链。
|
|
7
|
+
- `plan-collect-and-compose.md`:A 链路多模块采集作业链、唯一指定技能映射与内容输出规范。
|
|
8
|
+
|
|
9
|
+
Agent 调优重点:
|
|
10
|
+
|
|
11
|
+
- `weaver-work-cli plan schema` 是 operation 合约第一信息源。
|
|
12
|
+
- 意图判定先于接口调用:命中查询类信号走 B 链路,禁止采集业务数据;判定为生成类走 A 链路,必须按作业链采集。
|
|
13
|
+
- 报告接口链路由 CLI 判定并缓存(1 天),Agent 不选接口、不混用链路;采集阶段禁止调用报告侧接口。
|
|
14
|
+
- 业务输入不得包含 Cookie、ETEAMSID、Token 或内部控制字段;需 CLI 自动补的字段(创建人、时间戳)不要手工传。
|
|
15
|
+
- 人员 ID 只取 `id` / `employeeId`,禁止 `userId`;姓名先由 weaver-e10-hrm 解析。
|
|
16
|
+
- 写操作只接受 CLI 生成的 continuation,不手工构造或复用;`confirm=true` 必须由用户明确确认后传入。
|
|
17
|
+
- 结果为 `partial/write_uncertain` 时停止,不自动重放写请求。
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
本业务域用于 E10 齐业成费控中心(FNA)。入口 `SKILL.md` 沿用 weaver 风格:CRITICAL 共享前置、能力范围、路由优先级、逐 operation 命令表、执行原则、写操作失败决策树和“不在本 skill 范围”。具体用法拆到 `references/`:
|
|
2
|
+
|
|
3
|
+
- `catalog.md`:接口目录与按模块路由(四大模块 11 接口 ↔ 13 operations),通用约定与写操作边界。
|
|
4
|
+
- `budget.md`:预算查询(事前申请单预算详情、预算执行报表),含 `formDatas` 二层嵌套与金额列名口径。
|
|
5
|
+
- `expense-center.md`:费用中心(报销金额 / 借款分段 / 预付核销),含日期口径差异、借款接口缺陷与空响应处理。
|
|
6
|
+
- `loan-management.md`:借款管理(汇总/列表/提醒还款 prepare→apply 写链),含 menuCode 核对与回查策略。
|
|
7
|
+
- `invoice-writeoff.md`:发票核销(金额 tab/列表/催票 prepare→apply 写链),含 invoiceStatus 枚举与回查策略。
|
|
8
|
+
- `source-manifest.json`:源资料指纹与生成产物基线,供更新检测。
|
|
9
|
+
|
|
10
|
+
Agent 调优重点:
|
|
11
|
+
|
|
12
|
+
- `weaver-work-cli fna schema` 是 operation 合约第一信息源(inputSchema/required/withheldOperations)。
|
|
13
|
+
- 业务输入只包含数字 ID 与业务字段,不含 Cookie、ETEAMSID、Token 等认证字段。
|
|
14
|
+
- 借款费用中心接口只认数字 ID;`menuCode`/`permissionSetCode` 环境相关需与环境核对。
|
|
15
|
+
- 提醒还款/催票必须走 `fna.*.prepare -> 用户明确确认 -> apply`,只接受 CLI 生成的 continuation,不手工构造。
|
|
16
|
+
- 结果为 `partial/write_uncertain` 时停止并做一次只读回查,不自动重放写请求。
|
|
17
|
+
- 借款金额查询已知只统计首条记录,对外汇报注明口径。
|