weaver-work-cli 0.1.67 → 0.1.69
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/dist/chunks/{archive-WUZKAEZ6.js → archive-VUTREF3P.js} +16 -12
- package/dist/chunks/{archive-oa-PN46RTI2.js → archive-oa-VXXO4RTB.js} +4 -4
- package/dist/chunks/{asset-ZPC5VWZM.js → asset-45U6TY7I.js} +44 -12
- package/dist/chunks/{asset-idle-DHGP3NYY.js → asset-idle-YCRBMTIT.js} +4 -4
- package/dist/chunks/{attachment-content-7SDA6WER.js → attachment-content-7BEDNQ3O.js} +3 -3
- package/dist/chunks/{blog-JC47AIXK.js → blog-5AML4WMG.js} +4 -4
- package/dist/chunks/{caizhilian-IKIHM77A.js → caizhilian-3P7BUNHT.js} +6 -6
- package/dist/chunks/{calendar-GZTSJ57Y.js → calendar-2HUXM3CZ.js} +4 -4
- package/dist/chunks/{chunk-33ANTJWB.js → chunk-3CBURKSY.js} +5 -5
- package/dist/chunks/{chunk-IN6NXQ26.js → chunk-3Q5F4C5B.js} +47 -27
- package/dist/chunks/{chunk-XARLZK6C.js → chunk-3TZURS7M.js} +3 -3
- package/dist/chunks/{chunk-R6GGDZ2C.js → chunk-4XYRTXRR.js} +1 -1
- package/dist/chunks/{chunk-LNWFHNVK.js → chunk-67AN5YJT.js} +379 -55
- package/dist/chunks/{chunk-KS6LXSCA.js → chunk-6DH73Q5H.js} +85 -81
- package/dist/chunks/{chunk-3W5NMGDS.js → chunk-727VKJQK.js} +2 -2
- package/dist/chunks/{chunk-5QYE52LG.js → chunk-7M5OYRK2.js} +18 -9
- package/dist/chunks/{chunk-TXXO4TJT.js → chunk-BEYEXCWU.js} +2 -2
- package/dist/chunks/{chunk-26FCCU5O.js → chunk-DSBV4GRK.js} +3 -3
- package/dist/chunks/{chunk-G7PQWD4L.js → chunk-DVFA3ODS.js} +38 -10
- package/dist/chunks/{chunk-HWA2A25Y.js → chunk-E7VWE2XI.js} +3 -3
- package/dist/chunks/{chunk-DTJZOAO6.js → chunk-ELF5TPSG.js} +7 -7
- package/dist/chunks/{chunk-6ZOSVKMT.js → chunk-ERAE4GHX.js} +1 -1
- package/dist/chunks/{chunk-4PYLZORW.js → chunk-FMAZ42HS.js} +12 -12
- package/dist/chunks/{chunk-TJN4PIYO.js → chunk-GTAFCAVP.js} +2 -0
- package/dist/chunks/{chunk-WSHIOSGM.js → chunk-H2NRTGZR.js} +3 -3
- package/dist/chunks/{chunk-4WCVRDC5.js → chunk-HG6INLH6.js} +13 -0
- package/dist/chunks/{chunk-FDBAFANU.js → chunk-I5XB4MZT.js} +227 -23
- package/dist/chunks/{chunk-RU7ZZQQQ.js → chunk-JAIZY37Z.js} +4 -4
- package/dist/chunks/{chunk-ATEXBEPD.js → chunk-LCM5SSGJ.js} +4 -1
- package/dist/chunks/{chunk-FJUOUSV3.js → chunk-LRKKKO5A.js} +36 -9
- package/dist/chunks/{chunk-HLT6B26P.js → chunk-LSVA7QA6.js} +1 -1
- package/dist/chunks/{chunk-6N4JPNFL.js → chunk-MD5CW4B6.js} +1 -1
- package/dist/chunks/{chunk-MRYKV5HN.js → chunk-MLJK4KLE.js} +37 -37
- package/dist/chunks/{chunk-C4YQJFZV.js → chunk-PAWXVT6H.js} +22 -11
- package/dist/chunks/{chunk-Q6D6PSMH.js → chunk-QYDSTYGG.js} +3 -3
- package/dist/chunks/{chunk-AFZTMYGC.js → chunk-T24EBWAZ.js} +1 -1
- package/dist/chunks/{chunk-6T5X6YWX.js → chunk-U3OO3IZF.js} +3 -3
- package/dist/chunks/{chunk-VLY5RTVO.js → chunk-UVWW5ABZ.js} +3 -3
- package/dist/chunks/{chunk-NP3ZZFGI.js → chunk-VZUH3LKI.js} +16 -5
- package/dist/chunks/{chunk-JU5OPHSY.js → chunk-YR3K53BU.js} +36 -27
- package/dist/chunks/{conflict-DYCSX7CN.js → conflict-VKCRXHUV.js} +2 -2
- package/dist/chunks/{contract-N5WNHKHI.js → contract-3PMHUASH.js} +202 -25
- package/dist/chunks/{cowork-34CBYVQP.js → cowork-FZBTTBYX.js} +4 -4
- package/dist/chunks/{create-flow-PABAGCK2.js → create-flow-WYPLBLRK.js} +6 -6
- package/dist/chunks/{data-QKWI5325.js → data-2YZ6A6TL.js} +32 -5
- package/dist/chunks/{ebuilder-form-ZONRROK4.js → ebuilder-form-AWPTMZBZ.js} +6 -6
- package/dist/chunks/{ehr-2CONM7R6.js → ehr-MNPR4TE5.js} +4 -4
- package/dist/chunks/{employee-PGMY6NI6.js → employee-QX57HEWS.js} +1 -1
- package/dist/chunks/{entry-mode-C2WPJQJM.js → entry-mode-BCJ7RPFC.js} +3 -3
- package/dist/chunks/{env-SEEXUXZF.js → env-SCVCHBN2.js} +2 -2
- package/dist/chunks/{esb-FQASCY2H.js → esb-GSB5QCEX.js} +6 -6
- package/dist/chunks/{factory-WNLDOLJZ.js → factory-CBXYOEBF.js} +1 -1
- package/dist/chunks/{fna-FCLVIWAS.js → fna-XBSNUS2V.js} +4 -4
- package/dist/chunks/{group-chat-DOS4XWUN.js → group-chat-RFL4U7RF.js} +3 -3
- package/dist/chunks/{host-P7G22WNM.js → host-2UMNXX5H.js} +4 -4
- package/dist/chunks/{host-XLCBLNJD.js → host-BD44ASOD.js} +4 -4
- package/dist/chunks/{host-2ED2KC4X.js → host-NVDG3NC6.js} +4 -4
- package/dist/chunks/{host-46NYKDQP.js → host-R7BP3CTI.js} +4 -4
- package/dist/chunks/{host-7IPZKIM4.js → host-SYPCA63D.js} +4 -4
- package/dist/chunks/{host-2UYZEY2V.js → host-XVWBOSEN.js} +4 -4
- package/dist/chunks/{hrm-XKL27NX2.js → hrm-FZUDJAND.js} +20 -14
- package/dist/chunks/{im-NDYIMASG.js → im-F5NENPD7.js} +5 -5
- package/dist/chunks/{invoice-SMODTN2D.js → invoice-DS6FLU55.js} +44 -7
- package/dist/chunks/{jiuchuanhui-3T5X7SB7.js → jiuchuanhui-PY2WEBUH.js} +161 -10
- package/dist/chunks/{lazy-dispatch-K25LTKQY.js → lazy-dispatch-F6O2EPGR.js} +7 -7
- package/dist/chunks/{mail-P7VMUKQW.js → mail-ZEOSANEJ.js} +4 -4
- package/dist/chunks/{meeting-2IWXP5IL.js → meeting-N2AGGLVI.js} +15 -15
- package/dist/chunks/{minute-doc-N4OR5OLP.js → minute-doc-C62EZOJH.js} +4 -4
- package/dist/chunks/{okr-VZXRQGS4.js → okr-OZUMTMCL.js} +11 -5
- package/dist/chunks/{operations-62N6EP3C.js → operations-LQY3FTPH.js} +1 -1
- package/dist/chunks/{operations-MI2BSKZX.js → operations-UTUWFJTX.js} +5 -5
- package/dist/chunks/{org-NFE7X7FK.js → org-MWWIFNAO.js} +1 -1
- package/dist/chunks/{performance-OPEQNW7Y.js → performance-GBKM5G2Y.js} +3 -3
- package/dist/chunks/{plan-TJAS4N5X.js → plan-C2NENH42.js} +4 -4
- package/dist/chunks/{project-CYBGU6K6.js → project-FAJ2P3UR.js} +4 -4
- package/dist/chunks/{reception-3FT2F66K.js → reception-NH6MJFPR.js} +20 -10
- package/dist/chunks/{recruit-stage-WPGB5BDJ.js → recruit-stage-DPEFHLSE.js} +7 -4
- package/dist/chunks/{registry-JMNOXRST.js → registry-4S3RXXWS.js} +3 -3
- package/dist/chunks/{registry-XOUVCSV4.js → registry-7US3QQXV.js} +12 -12
- package/dist/chunks/{registry-E5RQJVWN.js → registry-AC33ZZVH.js} +1 -1
- package/dist/chunks/{registry-QRMXRSCT.js → registry-FTPUUHWC.js} +5 -5
- package/dist/chunks/{registry-ABKBGGGK.js → registry-Y2HWS6JS.js} +4 -4
- package/dist/chunks/{room-recommend-TWIEVY44.js → room-recommend-LMNF76YS.js} +4 -4
- package/dist/chunks/{schedule-XZ4UUX4E.js → schedule-4QE2THAP.js} +4 -4
- package/dist/chunks/{smart-extract-DEBLJPCQ.js → smart-extract-GTYKF5TJ.js} +32 -21
- package/dist/chunks/{workflow-D7LBN5MZ.js → workflow-KXYTQZ2H.js} +81 -12
- package/dist/core/error-codes.js +1 -1
- package/dist/core/host-policy.js +56 -0
- package/dist/core/timing.js +227 -0
- package/dist/index.js +39 -36
- package/dist/internal/e10/auth/commands.js +11 -0
- package/dist/internal/e10/auth/error-log.js +13 -0
- package/dist/internal/e10/auth/messages.js +10 -0
- package/dist/internal/e10/auth/xiaoe.js +12 -2
- package/dist/internal/e10/context.js +39 -12
- package/dist/internal/e10/network-error.js +28 -0
- package/dist/internal/e10/tls-policy.js +260 -0
- package/dist/shortcuts/archive/operations/archive-info.js +9 -5
- package/dist/shortcuts/asset/manifest.js +42 -4
- package/dist/shortcuts/contract/manifest.js +204 -21
- package/dist/shortcuts/data/manifest.js +45 -2
- package/dist/shortcuts/ebuilder-form/manifest.js +38 -10
- package/dist/shortcuts/hrm/index.js +20 -7
- package/dist/shortcuts/hrm/operations/employee.js +22 -11
- package/dist/shortcuts/hrm/operations/org.js +18 -9
- package/dist/shortcuts/hrm/operations/position.js +24 -12
- package/dist/shortcuts/hrm/operations/resolve.js +18 -10
- package/dist/shortcuts/im/operations/group-read.js +4 -1
- package/dist/shortcuts/invoice/manifest.js +44 -1
- package/dist/shortcuts/jiuchuanhui/host.js +76 -4
- package/dist/shortcuts/jiuchuanhui/manifest.js +106 -2
- package/dist/shortcuts/meeting/operations/attachment-content.js +25 -16
- package/dist/shortcuts/meeting/operations/eb/member-expand.js +1 -0
- package/dist/shortcuts/meeting/operations/invitation.js +1 -1
- package/dist/shortcuts/meeting/operations/link.js +20 -17
- package/dist/shortcuts/okr/operations/read.js +7 -1
- package/dist/shortcuts/reception/host.js +19 -5
- package/dist/shortcuts/reception/manifest.js +2 -0
- package/dist/shortcuts/recruit-stage/operations/interview-arrange.js +4 -1
- package/dist/shortcuts/smart-extract/operations/structure.js +13 -10
- package/dist/shortcuts/smart-extract/operations/target.js +15 -7
- package/dist/shortcuts/workflow/index.js +55 -5
- package/dist/shortcuts/workflow/operations/aiDeepRead/collect.js +26 -2
- package/dist/shortcuts/workflow/operations/aiDeepRead/render.js +23 -4
- package/dist/shortcuts/workflow/operations/deepRead.js +295 -4
- package/dist/shortcuts/workflow/operations/read.js +44 -22
- package/dist/shortcuts/workflow/operations/types.js +7 -1
- package/dist/shortcuts/workflow/operations/write.js +20 -2
- package/dist/shortcuts/workflow/operations.js +19 -1
- package/docs/e10-auth.md +48 -1
- package/package.json +1 -1
- package/scripts/xiaoe_env.py +18 -3
- package/skills/weaver-e10-asset-idle/SKILL.md +1 -1
- package/skills/weaver-e10-blog/SKILL.md +2 -2
- package/skills/weaver-e10-calendar/SKILL.md +1 -1
- package/skills/weaver-e10-data/SKILL.md +1 -1
- package/skills/weaver-e10-esb/SKILL.md +1 -1
- package/skills/weaver-e10-esb/references/source-manifest.json +3 -3
- package/skills/weaver-e10-hrm/SKILL.md +1 -1
- package/skills/weaver-e10-jiuchuanhui/references/customer.md +1 -0
- package/skills/weaver-e10-jucailin/SKILL.md +84 -17
- package/skills/weaver-e10-jucailin/agents/openai.yaml +2 -1
- package/skills/weaver-e10-jucailin/references/recruit-create.md +7 -8
- package/skills/weaver-e10-jucailin/references/recruit-implement-INDEX.md +41 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-consult-sop.md +77 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-guardrails.md +41 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-kb-data-update-channels.md +31 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-kb-form-external.md +43 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-kb-talent-base-form.md +32 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-pattern-external-collect-update-talent.md +93 -0
- package/skills/weaver-e10-jucailin/references/recruit-implement-pattern-external-share-edit.md +64 -0
- package/skills/weaver-e10-jucailin/references/recruit-read.md +1 -1
- package/skills/weaver-e10-jucailin/references/recruit-stage-ops.md +1 -1
- package/skills/weaver-e10-jucailin/references/recruit-write.md +4 -11
- package/skills/weaver-e10-jucailin/references/safety-boundaries.md +3 -3
- package/skills/weaver-e10-mail/SKILL.md +52 -10
- package/skills/weaver-e10-mail/references/mail-agent-entry.md +1 -2
- package/skills/weaver-e10-meeting/SKILL.md +1 -1
- package/skills/weaver-e10-meeting/references/meeting-verification.md +1 -1
- package/skills/weaver-e10-okr/SKILL.md +1 -1
- package/skills/weaver-e10-okr/references/source-manifest.json +5 -5
- package/skills/weaver-e10-plan/SKILL.md +2 -2
- package/skills/weaver-e10-plan/references/source-manifest.json +3 -3
- package/skills/weaver-e10-qiyecheng/SKILL.md +2 -2
- package/skills/weaver-e10-qiyecheng/references/source-manifest.json +3 -3
- package/skills/weaver-e10-reception-flow/SKILL.md +53 -16
- package/skills/weaver-e10-shared/SKILL.md +4 -9
- package/skills/weaver-e10-shared/references/e10-auth-and-session.md +2 -2
- package/skills/weaver-e10-shijingran/SKILL.md +14 -6
- package/skills/weaver-e10-shijingran/references/source-manifest.json +5 -4
- package/skills/weaver-e10-workflow/SKILL.md +11 -11
- package/skills/weaver-e10-workflow/aiDeepRead/templates//346/261/207/346/200/273/345/256/241/346/211/271-demo.html +92 -12
- package/skills/weaver-e10-workflow/references/source-manifest.json +3 -3
- package/skills/weaver-e10-workflow/references/todo-smart-convert.md +6 -4
- package/skills/weaver-e10-workflow/references/workflow-agent-entry.md +1 -2
- package/skills/weaver-e10-workflow/references/workflow-deep-read.md +44 -8
- package/skills/weaver-e10-workflow/tools/todo-summary.cjs +84 -12
- package/skills/weaver-e10-yimiaoban/references/source-manifest.json +3 -3
- package/skills/weaver-e10-ziguanjia/SKILL.md +1 -1
- package/skills/weaver-e10-ziguanjia/references/ziguanjia-agent-entry.md +1 -2
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
reportPlatformError
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-MD5CW4B6.js";
|
|
6
6
|
import {
|
|
7
7
|
CONTINUATION_TTL_MS,
|
|
8
8
|
CONTINUATION_TTL_SECONDS
|
|
@@ -12,13 +12,13 @@ import {
|
|
|
12
12
|
createE10RequestRuntime,
|
|
13
13
|
isE10SessionExpiredResponse,
|
|
14
14
|
requireE10Session
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-LRKKKO5A.js";
|
|
16
16
|
import {
|
|
17
17
|
E10_SESSION_EXPIRED_MESSAGE
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-GTAFCAVP.js";
|
|
19
19
|
import {
|
|
20
20
|
getActiveProfile
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-I5XB4MZT.js";
|
|
22
22
|
import {
|
|
23
23
|
CliError,
|
|
24
24
|
isCliError,
|
|
@@ -1122,7 +1122,13 @@ var okrList = {
|
|
|
1122
1122
|
page_no: { type: "integer", minimum: 1, default: 1 },
|
|
1123
1123
|
page_size: { type: "integer", minimum: 1, maximum: 100, default: 10 }
|
|
1124
1124
|
},
|
|
1125
|
-
{
|
|
1125
|
+
{
|
|
1126
|
+
anyOf: [
|
|
1127
|
+
{ required: ["query_scope"], properties: { query_scope: { const: "all" } } },
|
|
1128
|
+
{ required: ["period_type", "period_range"] }
|
|
1129
|
+
],
|
|
1130
|
+
description: "self \u6A21\u5F0F\u5FC5\u586B period_type + period_range\uFF1Ball \u6A21\u5F0F\u9700\u663E\u5F0F\u4F20 query_scope=all\uFF0C\u6309\u9700\u4F20 name / principalid / status"
|
|
1131
|
+
}
|
|
1126
1132
|
),
|
|
1127
1133
|
handler: async (args, { host }) => {
|
|
1128
1134
|
const { pageNo, pageSize } = pageOf(args);
|
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
executeEbuilderFormOperation
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-DVFA3ODS.js";
|
|
6
6
|
import "./chunk-Z3GDFVJR.js";
|
|
7
7
|
import "./chunk-7BDPM5ST.js";
|
|
8
8
|
import "./chunk-UG5G54VL.js";
|
|
@@ -2,13 +2,13 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
executeCaizhilianOperation
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-T24EBWAZ.js";
|
|
6
|
+
import "./chunk-U3OO3IZF.js";
|
|
7
7
|
import "./chunk-P5GQRWDC.js";
|
|
8
8
|
import "./chunk-7BDPM5ST.js";
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-LRKKKO5A.js";
|
|
10
|
+
import "./chunk-GTAFCAVP.js";
|
|
11
|
+
import "./chunk-I5XB4MZT.js";
|
|
12
12
|
import "./chunk-UG5G54VL.js";
|
|
13
13
|
import "./chunk-BUSC6UAE.js";
|
|
14
14
|
export {
|
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
hrmOrgOperations
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-7M5OYRK2.js";
|
|
6
6
|
import "./chunk-JEQHNNSS.js";
|
|
7
7
|
import "./chunk-56EZERK4.js";
|
|
8
8
|
import "./chunk-UG5G54VL.js";
|
|
@@ -8,13 +8,13 @@ import {
|
|
|
8
8
|
createE10RequestRuntime,
|
|
9
9
|
isE10SessionExpiredResponse,
|
|
10
10
|
requireE10Session
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-LRKKKO5A.js";
|
|
12
12
|
import {
|
|
13
13
|
E10_SESSION_EXPIRED_MESSAGE
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-GTAFCAVP.js";
|
|
15
15
|
import {
|
|
16
16
|
getActiveProfile
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-I5XB4MZT.js";
|
|
18
18
|
import {
|
|
19
19
|
CliError,
|
|
20
20
|
isCliError,
|
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
reportPlatformError
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-MD5CW4B6.js";
|
|
6
6
|
import {
|
|
7
7
|
CONTINUATION_TTL_MS,
|
|
8
8
|
CONTINUATION_TTL_SECONDS
|
|
@@ -12,13 +12,13 @@ import {
|
|
|
12
12
|
createE10RequestRuntime,
|
|
13
13
|
isE10SessionExpiredResponse,
|
|
14
14
|
requireE10Session
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-LRKKKO5A.js";
|
|
16
16
|
import {
|
|
17
17
|
E10_SESSION_EXPIRED_MESSAGE
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-GTAFCAVP.js";
|
|
19
19
|
import {
|
|
20
20
|
getActiveProfile
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-I5XB4MZT.js";
|
|
22
22
|
import {
|
|
23
23
|
CliError,
|
|
24
24
|
isCliError,
|
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
reportPlatformError
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-MD5CW4B6.js";
|
|
6
6
|
import {
|
|
7
7
|
CONTINUATION_TTL_MS
|
|
8
8
|
} from "./chunk-7BDPM5ST.js";
|
|
@@ -11,13 +11,13 @@ import {
|
|
|
11
11
|
createE10RequestRuntime,
|
|
12
12
|
isE10SessionExpiredResponse,
|
|
13
13
|
requireE10Session
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-LRKKKO5A.js";
|
|
15
15
|
import {
|
|
16
16
|
E10_SESSION_EXPIRED_MESSAGE
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-GTAFCAVP.js";
|
|
18
18
|
import {
|
|
19
19
|
getActiveProfile
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-I5XB4MZT.js";
|
|
21
21
|
import {
|
|
22
22
|
CliError,
|
|
23
23
|
isCliError,
|
|
@@ -6,13 +6,17 @@ import {
|
|
|
6
6
|
import {
|
|
7
7
|
E10ApiError,
|
|
8
8
|
createE10RequestRuntime,
|
|
9
|
-
getE10Session
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
import
|
|
9
|
+
getE10Session,
|
|
10
|
+
requireE10Session
|
|
11
|
+
} from "./chunk-LRKKKO5A.js";
|
|
12
|
+
import {
|
|
13
|
+
E10_AUTH_REQUIRED_MESSAGE
|
|
14
|
+
} from "./chunk-GTAFCAVP.js";
|
|
15
|
+
import "./chunk-I5XB4MZT.js";
|
|
13
16
|
import {
|
|
14
17
|
CliError,
|
|
15
18
|
isCliError,
|
|
19
|
+
isStructuredError,
|
|
16
20
|
toErrorEnvelope
|
|
17
21
|
} from "./chunk-UG5G54VL.js";
|
|
18
22
|
import "./chunk-BUSC6UAE.js";
|
|
@@ -447,8 +451,9 @@ async function fetchRestaurantRooms(runtime, options = {}) {
|
|
|
447
451
|
|
|
448
452
|
// src/shortcuts/reception/host.ts
|
|
449
453
|
var UPLOAD_TIMEOUT_MS = 18e4;
|
|
450
|
-
function createReceptionHost(ctx) {
|
|
454
|
+
function createReceptionHost(ctx, dependencies = {}) {
|
|
451
455
|
let cached = null;
|
|
456
|
+
const requireSession = dependencies.requireSession || requireE10Session;
|
|
452
457
|
async function resolve2() {
|
|
453
458
|
if (cached) return cached;
|
|
454
459
|
const e10 = await getE10Session(ctx);
|
|
@@ -560,9 +565,12 @@ function createReceptionHost(ctx) {
|
|
|
560
565
|
}
|
|
561
566
|
}
|
|
562
567
|
async function fetchRestaurantRooms2(options = {}) {
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
568
|
+
let e10;
|
|
569
|
+
try {
|
|
570
|
+
e10 = await requireSession(ctx);
|
|
571
|
+
} catch (error) {
|
|
572
|
+
if (isStructuredError(error)) throw error;
|
|
573
|
+
throw receptionEnvironmentError("NO_SESSION", E10_AUTH_REQUIRED_MESSAGE);
|
|
566
574
|
}
|
|
567
575
|
const runtime = createE10RequestRuntime(ctx, e10);
|
|
568
576
|
return fetchRestaurantRooms(runtime, {
|
|
@@ -2376,7 +2384,8 @@ var receptionOperations = [
|
|
|
2376
2384
|
noUpload: { type: "boolean", description: "\u8DF3\u8FC7\u9644\u4EF6\u4E0A\u4F20\uFF0C\u53EA\u51FA\u672C\u5730\u6587\u4EF6" },
|
|
2377
2385
|
snapshot: { type: "string", description: "\u5B57\u6BB5\u5FEB\u7167\u8DEF\u5F84\uFF1B\u540C\u65F6\u7528\u4E8E\u63A8\u5BFC\u6280\u80FD\u5305\u5185 render.py \u4F4D\u7F6E" },
|
|
2378
2386
|
renderPy: { type: "string", description: "\u663E\u5F0F\u6307\u5B9A render.py \u8DEF\u5F84" }
|
|
2379
|
-
}
|
|
2387
|
+
},
|
|
2388
|
+
anyOf: [{ required: ["runId"] }, { required: ["known"] }]
|
|
2380
2389
|
},
|
|
2381
2390
|
outputSchema: {
|
|
2382
2391
|
type: "object",
|
|
@@ -2460,7 +2469,8 @@ var receptionOperations = [
|
|
|
2460
2469
|
enum: ["inline", "popup", "drawer"],
|
|
2461
2470
|
description: "\u586B\u5355\u9875\u6253\u5F00\u5F62\u6001\uFF1Adrawer \u4E3A\u53F3\u4FA7\u62BD\u5C49\uFF08\u9ED8\u8BA4\uFF09"
|
|
2462
2471
|
}
|
|
2463
|
-
}
|
|
2472
|
+
},
|
|
2473
|
+
anyOf: [{ required: ["runId"] }, { required: ["known"] }]
|
|
2464
2474
|
},
|
|
2465
2475
|
outputSchema: {
|
|
2466
2476
|
type: "object",
|
|
@@ -12,13 +12,13 @@ import {
|
|
|
12
12
|
createE10RequestRuntime,
|
|
13
13
|
isE10SessionExpiredResponse,
|
|
14
14
|
requireE10Session
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-LRKKKO5A.js";
|
|
16
16
|
import {
|
|
17
17
|
E10_SESSION_EXPIRED_MESSAGE
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-GTAFCAVP.js";
|
|
19
19
|
import {
|
|
20
20
|
getActiveProfile
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-I5XB4MZT.js";
|
|
22
22
|
import {
|
|
23
23
|
CliError,
|
|
24
24
|
isCliError,
|
|
@@ -4830,7 +4830,10 @@ var interviewArrangeOperations = [
|
|
|
4830
4830
|
summary: "\u9884\u586B\u6A21\u5F0F\uFF08\u4EBA\u5DE5\u4FDD\u5B58\uFF09\uFF1A\u8F93\u51FA\u4EBA\u624D\u5361\u7247 URL + \u9762\u8BD5\u7BA1\u7406\u5217\u8868 URL + \u9009\u9762\u8BD5\u65B9\u5F0F\u7684 jsExpr\uFF0C\u89E6\u53D1\u8868\u5355\u8054\u52A8\u540E\u7531 HR \u6838\u5BF9\u4FDD\u5B58\uFF0C\u4E0D\u843D\u5E93",
|
|
4831
4831
|
capability: "recruit.interview.arrange",
|
|
4832
4832
|
risk: "read",
|
|
4833
|
-
inputSchema:
|
|
4833
|
+
inputSchema: {
|
|
4834
|
+
...schemaOf(baseInput3, {}),
|
|
4835
|
+
anyOf: [{ required: ["talentId"] }, { required: ["mobile"] }, { required: ["name"] }]
|
|
4836
|
+
},
|
|
4834
4837
|
handler: prefill2
|
|
4835
4838
|
},
|
|
4836
4839
|
{
|
|
@@ -4,9 +4,9 @@ import {
|
|
|
4
4
|
getHrmOperation,
|
|
5
5
|
hasHrmOperation,
|
|
6
6
|
hrmOperationDefinitions
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-3Q5F4C5B.js";
|
|
8
|
+
import "./chunk-PAWXVT6H.js";
|
|
9
|
+
import "./chunk-7M5OYRK2.js";
|
|
10
10
|
import "./chunk-JEQHNNSS.js";
|
|
11
11
|
import "./chunk-56EZERK4.js";
|
|
12
12
|
import "./chunk-UG5G54VL.js";
|
|
@@ -4,20 +4,20 @@ import {
|
|
|
4
4
|
getMeetingOperation,
|
|
5
5
|
hasMeetingOperation,
|
|
6
6
|
meetingOperationDefinitions
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-6DH73Q5H.js";
|
|
8
|
+
import "./chunk-MLJK4KLE.js";
|
|
9
|
+
import "./chunk-ELF5TPSG.js";
|
|
10
|
+
import "./chunk-YR3K53BU.js";
|
|
11
11
|
import "./chunk-WMRNO6IU.js";
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
12
|
+
import "./chunk-FMAZ42HS.js";
|
|
13
|
+
import "./chunk-BEYEXCWU.js";
|
|
14
|
+
import "./chunk-3CBURKSY.js";
|
|
15
|
+
import "./chunk-JAIZY37Z.js";
|
|
16
|
+
import "./chunk-ERAE4GHX.js";
|
|
17
|
+
import "./chunk-4XYRTXRR.js";
|
|
18
|
+
import "./chunk-3TZURS7M.js";
|
|
19
19
|
import "./chunk-7BDPM5ST.js";
|
|
20
|
-
import "./chunk-
|
|
20
|
+
import "./chunk-I5XB4MZT.js";
|
|
21
21
|
import "./chunk-UG5G54VL.js";
|
|
22
22
|
import "./chunk-BUSC6UAE.js";
|
|
23
23
|
export {
|
|
@@ -3,7 +3,7 @@ const require = __esbuildCreateRequire(import.meta.url);
|
|
|
3
3
|
import {
|
|
4
4
|
getImOperation,
|
|
5
5
|
imOperationDefinitions
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-LCM5SSGJ.js";
|
|
7
7
|
import "./chunk-IC62NFM5.js";
|
|
8
8
|
import "./chunk-KMRT7NAT.js";
|
|
9
9
|
import "./chunk-UG5G54VL.js";
|
|
@@ -4,13 +4,13 @@ import {
|
|
|
4
4
|
esbOperationDefinitions,
|
|
5
5
|
getEsbOperation,
|
|
6
6
|
hasEsbOperation
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-LSVA7QA6.js";
|
|
8
|
+
import "./chunk-UVWW5ABZ.js";
|
|
9
9
|
import "./chunk-TXUG266F.js";
|
|
10
10
|
import "./chunk-7BDPM5ST.js";
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-LRKKKO5A.js";
|
|
12
|
+
import "./chunk-GTAFCAVP.js";
|
|
13
|
+
import "./chunk-I5XB4MZT.js";
|
|
14
14
|
import "./chunk-UG5G54VL.js";
|
|
15
15
|
import "./chunk-BUSC6UAE.js";
|
|
16
16
|
export {
|
|
@@ -4,14 +4,14 @@ import {
|
|
|
4
4
|
getWorkflowOperation,
|
|
5
5
|
hasWorkflowOperation,
|
|
6
6
|
workflowOperationDefinitions
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-67AN5YJT.js";
|
|
8
8
|
import "./chunk-HP7JIYMT.js";
|
|
9
9
|
import "./chunk-WRXSAVKO.js";
|
|
10
|
-
import "./chunk-
|
|
10
|
+
import "./chunk-HG6INLH6.js";
|
|
11
11
|
import "./chunk-AJ62BGAW.js";
|
|
12
12
|
import "./chunk-7BDPM5ST.js";
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-GTAFCAVP.js";
|
|
14
|
+
import "./chunk-I5XB4MZT.js";
|
|
15
15
|
import "./chunk-UG5G54VL.js";
|
|
16
16
|
import "./chunk-BUSC6UAE.js";
|
|
17
17
|
export {
|
|
@@ -7,10 +7,10 @@ import {
|
|
|
7
7
|
loadRooms,
|
|
8
8
|
recommendRooms,
|
|
9
9
|
rememberFrequentRoom
|
|
10
|
-
} from "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
10
|
+
} from "./chunk-JAIZY37Z.js";
|
|
11
|
+
import "./chunk-ERAE4GHX.js";
|
|
12
|
+
import "./chunk-4XYRTXRR.js";
|
|
13
|
+
import "./chunk-3TZURS7M.js";
|
|
14
14
|
import "./chunk-7BDPM5ST.js";
|
|
15
15
|
import "./chunk-UG5G54VL.js";
|
|
16
16
|
import "./chunk-BUSC6UAE.js";
|
|
@@ -8,10 +8,10 @@ import {
|
|
|
8
8
|
resolveMeetingScheduleTypeIds,
|
|
9
9
|
resolveMemberIdsByName,
|
|
10
10
|
runScheduleConflictFlow
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
11
|
+
} from "./chunk-3CBURKSY.js";
|
|
12
|
+
import "./chunk-ERAE4GHX.js";
|
|
13
|
+
import "./chunk-4XYRTXRR.js";
|
|
14
|
+
import "./chunk-3TZURS7M.js";
|
|
15
15
|
import "./chunk-7BDPM5ST.js";
|
|
16
16
|
import "./chunk-UG5G54VL.js";
|
|
17
17
|
import "./chunk-BUSC6UAE.js";
|
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
defaultResultThresholdChars
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-HG6INLH6.js";
|
|
6
6
|
import {
|
|
7
7
|
stateRoot
|
|
8
8
|
} from "./chunk-AJ62BGAW.js";
|
|
@@ -15,11 +15,11 @@ import {
|
|
|
15
15
|
createE10RequestRuntime,
|
|
16
16
|
isE10SessionExpiredResponse,
|
|
17
17
|
requireE10Session
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
} from "./chunk-LRKKKO5A.js";
|
|
19
|
+
import "./chunk-GTAFCAVP.js";
|
|
20
20
|
import {
|
|
21
21
|
getActiveProfile
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-I5XB4MZT.js";
|
|
23
23
|
import {
|
|
24
24
|
CliError,
|
|
25
25
|
isCliError,
|
|
@@ -1144,16 +1144,19 @@ var formStructure = {
|
|
|
1144
1144
|
name: "smart-extract.form.structure",
|
|
1145
1145
|
risk: "read",
|
|
1146
1146
|
summary: "\u53D6\u8868\u5355\u7ED3\u6784\u5E76\u5F52\u4E00\u5316\uFF1A\u4F20 workflowId(+nodeId\uFF0C\u7F3A\u7701\u81EA\u52A8\u53D6\u53D1\u8D77\u8282\u70B9) \u8D70\u6D41\u7A0B\u8282\u70B9\u5B57\u6BB5\uFF0C\u4F20 formId \u8D70 EB \u8868\u5355\u3002\u8F93\u51FA mainFieldsStr/subFieldsStr \u538B\u7F29\u4E32\uFF0C\u53EF\u76F4\u63A5\u8FDB\u63D0\u793A\u8BCD\u3002",
|
|
1147
|
-
inputSchema:
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1147
|
+
inputSchema: {
|
|
1148
|
+
...schemaOf({
|
|
1149
|
+
workflowId: { ...SCHEMA_ID, description: "\u6D41\u7A0B\u6A21\u677F ID\uFF08wf\uFF09" },
|
|
1150
|
+
nodeId: { ...SCHEMA_ID, description: "\u6D41\u7A0B\u8282\u70B9 ID\uFF1B\u4E0D\u4F20\u65F6\u81EA\u52A8\u53D6\u53D1\u8D77\u8282\u70B9" },
|
|
1151
|
+
formId: { ...SCHEMA_ID, description: "EB \u8868\u5355 ID\uFF08\u4E0E workflowId \u4E8C\u9009\u4E00\uFF09" },
|
|
1152
|
+
targetFieldIdList: {
|
|
1153
|
+
type: "array",
|
|
1154
|
+
items: { type: "string" },
|
|
1155
|
+
description: "\u53EA\u8F93\u51FA\u8FD9\u4E9B\u5B57\u6BB5 ID\uFF08\u53EF\u9009\uFF09"
|
|
1156
|
+
}
|
|
1157
|
+
}),
|
|
1158
|
+
anyOf: [{ required: ["workflowId"] }, { required: ["formId"] }]
|
|
1159
|
+
},
|
|
1157
1160
|
handler: async (args, env) => {
|
|
1158
1161
|
const workflowId = optionalId(args.workflowId, "workflowId");
|
|
1159
1162
|
const formId = optionalId(args.formId, "formId");
|
|
@@ -2602,13 +2605,21 @@ var targetResolve = {
|
|
|
2602
2605
|
name: "smart-extract.target.resolve",
|
|
2603
2606
|
risk: "read",
|
|
2604
2607
|
summary: "\u628A\u76EE\u6807\u6536\u655B\u6210 ID\uFF1AworkflowId/formId/objId \u76F4\u63A5\u56DE\u663E\u6821\u9A8C\uFF1B\u7ED9 workflowKeyword \u65F6\u5217\u51FA\u5F53\u524D\u7528\u6237\u53EF\u53D1\u8D77\u7684\u6D41\u7A0B\u5E76\u505A\u540D\u79F0\u5339\u914D\u3002\u8FD4\u56DE modeType \u4E0E\u547D\u4E2D\u9879\u3002",
|
|
2605
|
-
inputSchema:
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2608
|
+
inputSchema: {
|
|
2609
|
+
...schemaOf({
|
|
2610
|
+
workflowId: { ...SCHEMA_ID, description: "\u6D41\u7A0B\u6A21\u677F ID" },
|
|
2611
|
+
formId: { ...SCHEMA_ID, description: "EB \u8868\u5355 ID" },
|
|
2612
|
+
objId: { ...SCHEMA_ID, description: "EB \u5EFA\u6A21\u5BF9\u8C61 ID\uFF08\u4F1A\u81EA\u52A8\u8F6C\u6362\u6210 formId\uFF09" },
|
|
2613
|
+
workflowKeyword: { type: "string", description: "\u6D41\u7A0B\u540D\u79F0\u5173\u952E\u5B57\uFF08\u53EA\u5728\u53EF\u53D1\u8D77\u6D41\u7A0B\u91CC\u505A\u5305\u542B\u5339\u914D\uFF09" },
|
|
2614
|
+
limit: { type: "integer", description: "\u5173\u952E\u5B57\u5339\u914D\u8FD4\u56DE\u6761\u6570\u4E0A\u9650\uFF0C\u9ED8\u8BA4 10" }
|
|
2615
|
+
}),
|
|
2616
|
+
anyOf: [
|
|
2617
|
+
{ required: ["workflowId"] },
|
|
2618
|
+
{ required: ["formId"] },
|
|
2619
|
+
{ required: ["objId"] },
|
|
2620
|
+
{ required: ["workflowKeyword"] }
|
|
2621
|
+
]
|
|
2622
|
+
},
|
|
2612
2623
|
handler: async (args, env) => {
|
|
2613
2624
|
const workflowId = optionalId(args.workflowId, "workflowId");
|
|
2614
2625
|
const formId = optionalId(args.formId, "formId");
|
|
@@ -2,7 +2,7 @@ import { createRequire as __esbuildCreateRequire } from 'node:module';
|
|
|
2
2
|
const require = __esbuildCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
createWorkflowHost
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-E7VWE2XI.js";
|
|
6
6
|
import {
|
|
7
7
|
USER_INTENT_RULE_FILE,
|
|
8
8
|
aigroupUserDir,
|
|
@@ -17,24 +17,25 @@ import {
|
|
|
17
17
|
validateRuleFile,
|
|
18
18
|
workflowOperationDefinitions,
|
|
19
19
|
workflowSuccess
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-67AN5YJT.js";
|
|
21
21
|
import {
|
|
22
22
|
createWorkflowContinuationSigner
|
|
23
23
|
} from "./chunk-HP7JIYMT.js";
|
|
24
24
|
import {
|
|
25
25
|
CLARIFICATION_SUBTYPE,
|
|
26
26
|
WorkflowCliError,
|
|
27
|
+
workflowPolicyError,
|
|
27
28
|
workflowValidationError
|
|
28
29
|
} from "./chunk-WRXSAVKO.js";
|
|
29
|
-
import "./chunk-
|
|
30
|
+
import "./chunk-HG6INLH6.js";
|
|
30
31
|
import "./chunk-AJ62BGAW.js";
|
|
31
32
|
import {
|
|
32
33
|
reportPlatformError
|
|
33
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-MD5CW4B6.js";
|
|
34
35
|
import "./chunk-7BDPM5ST.js";
|
|
35
|
-
import "./chunk-
|
|
36
|
-
import "./chunk-
|
|
37
|
-
import "./chunk-
|
|
36
|
+
import "./chunk-LRKKKO5A.js";
|
|
37
|
+
import "./chunk-GTAFCAVP.js";
|
|
38
|
+
import "./chunk-I5XB4MZT.js";
|
|
38
39
|
import {
|
|
39
40
|
isCliError,
|
|
40
41
|
toErrorEnvelope
|
|
@@ -70,6 +71,32 @@ var workflowManifest = {
|
|
|
70
71
|
withheldOperations: WITHHELD
|
|
71
72
|
};
|
|
72
73
|
|
|
74
|
+
// src/core/host-policy.ts
|
|
75
|
+
var HOST_ENV_MARKERS = [
|
|
76
|
+
{ host: "doubao", marker: "DOUBAO" }
|
|
77
|
+
];
|
|
78
|
+
var HOST_DENIED_CAPABILITIES = {
|
|
79
|
+
doubao: ["memory"]
|
|
80
|
+
};
|
|
81
|
+
function detectHostByEnv(env = process.env) {
|
|
82
|
+
const keys = Object.keys(env ?? {});
|
|
83
|
+
for (const { host, marker } of HOST_ENV_MARKERS) {
|
|
84
|
+
if (keys.some((key) => key.toUpperCase().includes(marker))) return host;
|
|
85
|
+
}
|
|
86
|
+
return null;
|
|
87
|
+
}
|
|
88
|
+
function hostCapabilityDenial(capability, env = process.env) {
|
|
89
|
+
if (!capability) return null;
|
|
90
|
+
const hostKey = detectHostByEnv(env);
|
|
91
|
+
if (!hostKey) return null;
|
|
92
|
+
const denied = HOST_DENIED_CAPABILITIES[hostKey] ?? [];
|
|
93
|
+
if (!denied.includes(capability)) return null;
|
|
94
|
+
return { host: hostKey === "doubao" ? "\u8C46\u5305" : hostKey, hostKey, capability };
|
|
95
|
+
}
|
|
96
|
+
function isCapabilityDeniedHere(capability, env = process.env) {
|
|
97
|
+
return hostCapabilityDenial(capability, env) !== null;
|
|
98
|
+
}
|
|
99
|
+
|
|
73
100
|
// src/shortcuts/workflow/operations.ts
|
|
74
101
|
function idempotentReplayEnvelope(error, operation) {
|
|
75
102
|
if (!(error instanceof WorkflowCliError) || error.subtype !== "continuation_already_applied") return null;
|
|
@@ -133,8 +160,18 @@ async function settleAppliedContinuation(input, result, context, definition) {
|
|
|
133
160
|
if (!reference) return;
|
|
134
161
|
await context.continuation.settle(reference, result.data, definition.action || definition.name);
|
|
135
162
|
}
|
|
163
|
+
function assertHostAllows(operation, capability) {
|
|
164
|
+
const denial = hostCapabilityDenial(capability);
|
|
165
|
+
if (!denial) return;
|
|
166
|
+
throw workflowPolicyError(
|
|
167
|
+
"host_capability_denied",
|
|
168
|
+
`\u5F53\u524D\u8FD0\u884C\u73AF\u5883\uFF08${denial.host}\uFF09\u4E0D\u63D0\u4F9B\u300C${denial.capability}\u300D\u7C7B\u64CD\u4F5C\uFF0C${operation} \u5DF2\u5728\u8BE5\u73AF\u5883\u7981\u7528\u3002\u8FD9\u4E0D\u662F\u8D26\u53F7\u6743\u9650\u95EE\u9898\uFF0C\u6362\u8D26\u53F7\u3001\u6539\u5199\u53C2\u6570\u6216\u91CD\u8BD5\u90FD\u4E0D\u4F1A\u6210\u529F\uFF1B\u8BF7\u76F4\u63A5\u544A\u77E5\u7528\u6237\u5F53\u524D\u5E73\u53F0\u4E0D\u652F\u6301\u8BE5\u80FD\u529B\uFF0C\u4E0D\u8981\u5C1D\u8BD5\u7ED5\u8FC7\u3002`,
|
|
169
|
+
{ host: denial.host, capability: denial.capability, operation }
|
|
170
|
+
);
|
|
171
|
+
}
|
|
136
172
|
async function executeWorkflowOperation(operation, rawInput, context) {
|
|
137
173
|
const definition = getWorkflowOperation(operation);
|
|
174
|
+
assertHostAllows(operation, definition.capability);
|
|
138
175
|
const input = asObject(rawInput);
|
|
139
176
|
assertNoForbiddenKeys(input);
|
|
140
177
|
let result;
|
|
@@ -329,7 +366,24 @@ function fieldNamesOf(inputSchema) {
|
|
|
329
366
|
if (!properties || typeof properties !== "object" || Array.isArray(properties)) return [];
|
|
330
367
|
return Object.keys(properties);
|
|
331
368
|
}
|
|
369
|
+
function visibleOperations() {
|
|
370
|
+
return workflowManifest.operations.filter((definition) => !isCapabilityDeniedHere(definition.capability));
|
|
371
|
+
}
|
|
372
|
+
function hostWithheldOperations() {
|
|
373
|
+
return workflowManifest.operations.filter((definition) => isCapabilityDeniedHere(definition.capability)).map((definition) => ({
|
|
374
|
+
name: definition.name,
|
|
375
|
+
reason: `\u5F53\u524D\u8FD0\u884C\u73AF\u5883\u4E0D\u63D0\u4F9B\u300C${definition.capability}\u300D\u7C7B\u64CD\u4F5C\uFF0C\u5DF2\u5728\u8BE5\u73AF\u5883\u7981\u7528`
|
|
376
|
+
}));
|
|
377
|
+
}
|
|
378
|
+
function requiredHints(inputSchema) {
|
|
379
|
+
const schema = inputSchema;
|
|
380
|
+
const required = Array.isArray(schema?.required) && schema.required.length ? schema.required : void 0;
|
|
381
|
+
const anyOf = Array.isArray(schema?.anyOf) ? schema.anyOf : null;
|
|
382
|
+
const atLeastOne = anyOf ? [...new Set(anyOf.flatMap((branch) => branch?.required ?? []))] : [];
|
|
383
|
+
return { ...required ? { required } : {}, ...atLeastOne.length ? { atLeastOne } : {} };
|
|
384
|
+
}
|
|
332
385
|
function manifestIndex() {
|
|
386
|
+
const operations = visibleOperations();
|
|
333
387
|
return {
|
|
334
388
|
schemaVersion: workflowManifest.schemaVersion,
|
|
335
389
|
name: workflowManifest.name,
|
|
@@ -339,26 +393,41 @@ function manifestIndex() {
|
|
|
339
393
|
status: workflowManifest.status,
|
|
340
394
|
sourceSkill: workflowManifest.sourceSkill,
|
|
341
395
|
capabilities: workflowManifest.capabilities,
|
|
342
|
-
operationCount:
|
|
343
|
-
operations:
|
|
396
|
+
operationCount: operations.length,
|
|
397
|
+
operations: operations.map((definition) => ({
|
|
344
398
|
name: definition.name,
|
|
345
399
|
resource: definition.resource,
|
|
346
400
|
summary: definition.summary,
|
|
347
401
|
...definition.capability ? { capability: definition.capability } : {},
|
|
348
402
|
risk: definition.risk,
|
|
349
403
|
...definition.requiresConfirmation ? { requiresConfirmation: true } : {},
|
|
350
|
-
fields: fieldNamesOf(definition.inputSchema)
|
|
404
|
+
fields: fieldNamesOf(definition.inputSchema),
|
|
405
|
+
...requiredHints(definition.inputSchema)
|
|
351
406
|
})),
|
|
352
|
-
withheldOperations: workflowManifest.withheldOperations,
|
|
407
|
+
withheldOperations: [...workflowManifest.withheldOperations, ...hostWithheldOperations()],
|
|
353
408
|
operationsHint: "\u9ED8\u8BA4\u53EA\u5217 operation \u4E0E\u5B57\u6BB5\u540D\uFF1B\u5B57\u6BB5\u7C7B\u578B\u3001\u679A\u4E3E\u548C\u586B\u5199\u53E3\u5F84\u7528 `workflow schema --operation <name>` \u5355\u53D6\uFF0C\u6574\u4EFD\u5B8C\u6574 manifest \u7528 `workflow schema --full`\u3002"
|
|
354
409
|
};
|
|
355
410
|
}
|
|
411
|
+
function manifestFull() {
|
|
412
|
+
return {
|
|
413
|
+
...workflowManifest,
|
|
414
|
+
operations: visibleOperations(),
|
|
415
|
+
withheldOperations: [...workflowManifest.withheldOperations, ...hostWithheldOperations()]
|
|
416
|
+
};
|
|
417
|
+
}
|
|
356
418
|
function findOperationContract(name) {
|
|
357
419
|
const full = name.startsWith("workflow.") ? name : `workflow.${name}`;
|
|
358
420
|
const matched = workflowManifest.operations.find((definition) => definition.name === full);
|
|
359
421
|
if (!matched) {
|
|
360
422
|
throw workflowValidationError("operation_unknown", `\u6D41\u7A0B\u6A21\u5757\u4E0D\u652F\u6301\u64CD\u4F5C\uFF1A${name}`);
|
|
361
423
|
}
|
|
424
|
+
if (isCapabilityDeniedHere(matched.capability)) {
|
|
425
|
+
throw workflowPolicyError(
|
|
426
|
+
"host_capability_denied",
|
|
427
|
+
`\u5F53\u524D\u8FD0\u884C\u73AF\u5883\u4E0D\u63D0\u4F9B\u300C${matched.capability}\u300D\u7C7B\u64CD\u4F5C\uFF0C${full} \u5DF2\u5728\u8BE5\u73AF\u5883\u7981\u7528\u3002\u8FD9\u4E0D\u662F\u8D26\u53F7\u6743\u9650\u95EE\u9898\uFF0C\u6362\u8D26\u53F7\u3001\u6539\u5199\u53C2\u6570\u6216\u91CD\u8BD5\u90FD\u4E0D\u4F1A\u6210\u529F\uFF1B\u8BF7\u76F4\u63A5\u544A\u77E5\u7528\u6237\u5F53\u524D\u5E73\u53F0\u4E0D\u652F\u6301\u8BE5\u80FD\u529B\uFF0C\u4E0D\u8981\u5C1D\u8BD5\u7ED5\u8FC7\u3002`,
|
|
428
|
+
{ capability: matched.capability, operation: full }
|
|
429
|
+
);
|
|
430
|
+
}
|
|
362
431
|
return matched;
|
|
363
432
|
}
|
|
364
433
|
function withJsonInputOptions(command) {
|
|
@@ -378,7 +447,7 @@ var workflowShortcut = {
|
|
|
378
447
|
throw workflowValidationError("option_conflict", "\u4E0D\u80FD\u540C\u65F6\u4F20 --operation \u548C --full");
|
|
379
448
|
}
|
|
380
449
|
if (opts.full === true) {
|
|
381
|
-
ctx.output.write(
|
|
450
|
+
ctx.output.write(manifestFull(), { json: true });
|
|
382
451
|
return;
|
|
383
452
|
}
|
|
384
453
|
if (requested) {
|
package/dist/core/error-codes.js
CHANGED
|
@@ -22,7 +22,7 @@ function codeFromStructured(type, subtype, httpStatus) {
|
|
|
22
22
|
if (type === 'authentication') {
|
|
23
23
|
return /expired|invalid_token|token_expired/u.test(subtype) ? 'E-0002' : 'E-0001';
|
|
24
24
|
}
|
|
25
|
-
if (type === 'permission' || type === 'authorization')
|
|
25
|
+
if (type === 'permission' || type === 'authorization' || type === 'policy')
|
|
26
26
|
return 'E-0005';
|
|
27
27
|
if (type === 'validation' || type === 'usage')
|
|
28
28
|
return 'E-0003';
|