@vm0/cli 9.251.0 → 9.252.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (107) hide show
  1. package/{agent-3IQFM2KY.js → agent-DJY6SYVC.js} +7 -7
  2. package/{banking-EYUWBTLB.js → banking-SV5ZIH44.js} +5 -5
  3. package/{chat-S7Z2SOGU.js → chat-G2KQYYK5.js} +6 -6
  4. package/{chunk-KVNHL3NQ.js → chunk-AWLNHCAC.js} +4 -4
  5. package/{chunk-THDGMML6.js → chunk-BKSVVARX.js} +2 -2
  6. package/{chunk-2USAOUQI.js → chunk-BSDS7GCS.js} +5 -4
  7. package/chunk-BSDS7GCS.js.map +1 -0
  8. package/{chunk-5CVPQC2F.js → chunk-CUAL7MH6.js} +2 -2
  9. package/{chunk-K3F4FDYI.js → chunk-DK3C2ME6.js} +14 -3
  10. package/chunk-DK3C2ME6.js.map +1 -0
  11. package/{chunk-CGLTWZX7.js → chunk-E2DKMMGY.js} +3 -3
  12. package/{chunk-OJM5IFC3.js → chunk-I56DJKTX.js} +3 -7
  13. package/chunk-I56DJKTX.js.map +1 -0
  14. package/{chunk-H46N52S6.js → chunk-IX2GN2TI.js} +2 -2
  15. package/{chunk-ZSP7ISNV.js → chunk-QL2BWE6J.js} +390 -20
  16. package/chunk-QL2BWE6J.js.map +1 -0
  17. package/{chunk-WIO4VCT5.js → chunk-RGHA7C2O.js} +2 -2
  18. package/{chunk-QHG7ITIT.js → chunk-TRFIH4R5.js} +2 -2
  19. package/{computer-use-ZI4I63OA.js → computer-use-FUBM53XG.js} +5 -5
  20. package/{connector-JEISK7OP.js → connector-3GCLB6HW.js} +8 -8
  21. package/{credit-DZLGKM5H.js → credit-SXRYMKSD.js} +7 -7
  22. package/{developer-support-GKND4K5Y.js → developer-support-LQHWOQLY.js} +5 -5
  23. package/{doctor-IDEBPM3X.js → doctor-RVC32BKE.js} +7 -7
  24. package/feishu-62E2QMM5.js +277 -0
  25. package/feishu-62E2QMM5.js.map +1 -0
  26. package/{finance-QRFJGKEW.js → finance-HP4WFZUY.js} +5 -5
  27. package/{generate-SDDS6YWC.js → generate-PTBOIM6B.js} +7 -7
  28. package/{github-6KEMKHRG.js → github-62XSFEWF.js} +5 -5
  29. package/{goal-5ER7N3Z3.js → goal-VRWB2AS3.js} +5 -5
  30. package/{host-JYOXNY2B.js → host-OKISPSSS.js} +5 -5
  31. package/{logs-7AGKFCY3.js → logs-53CMUU4J.js} +6 -6
  32. package/{mail-LJKDHK2A.js → mail-E6R5V6F6.js} +7 -7
  33. package/{maps-HRMZ7QBC.js → maps-B7F3CODU.js} +5 -5
  34. package/{model-RXY3MPL4.js → model-2VZQVFTE.js} +6 -6
  35. package/{model-provider-HYLOR2WF.js → model-provider-XALJ5BZB.js} +6 -6
  36. package/{org-FKZQ7WF6.js → org-JIAZYZUL.js} +5 -5
  37. package/package.json +1 -1
  38. package/{people-search-444TQMDB.js → people-search-LZ2BRXA6.js} +5 -5
  39. package/{phone-OI2MXOHO.js → phone-MXUV3YD3.js} +5 -5
  40. package/{preference-MQYZJ7R3.js → preference-LONJZKPE.js} +5 -5
  41. package/{resource-RVZZU2ZM.js → resource-26IQ2JCS.js} +5 -5
  42. package/{scrape-MLGY4WK2.js → scrape-H2ZA5AJD.js} +5 -5
  43. package/{search-PPAN6ZHY.js → search-R62IJFT4.js} +6 -6
  44. package/{secret-HIYUWKY4.js → secret-PHZZWEE3.js} +5 -5
  45. package/{slack-QDR4X4V7.js → slack-DQJUJIWY.js} +174 -47
  46. package/slack-DQJUJIWY.js.map +1 -0
  47. package/{teams-K6YHGEVC.js → teams-B5NDIX3U.js} +5 -5
  48. package/{telegram-LHBCOVZP.js → telegram-R67CYOON.js} +5 -5
  49. package/{upgrade-KM4H4ARY.js → upgrade-FJKXJO6L.js} +4 -4
  50. package/{variable-ULJ4EFHR.js → variable-GNCE5TUG.js} +5 -5
  51. package/{video-P26LRUFN.js → video-UDPAFI36.js} +4 -4
  52. package/{weather-DMUJWZDC.js → weather-O6L5SALA.js} +5 -5
  53. package/{web-ESXMLMEC.js → web-6I5S773Q.js} +5 -5
  54. package/{web-search-QCZNJGMG.js → web-search-GQAKFVCC.js} +5 -5
  55. package/{whoami-4NVG5FI7.js → whoami-MEJV5DZB.js} +7 -7
  56. package/{workflow-G7DL7SCF.js → workflow-PEVNMY2N.js} +5 -5
  57. package/zero.js +42 -42
  58. package/chunk-2USAOUQI.js.map +0 -1
  59. package/chunk-K3F4FDYI.js.map +0 -1
  60. package/chunk-OJM5IFC3.js.map +0 -1
  61. package/chunk-ZSP7ISNV.js.map +0 -1
  62. package/feishu-HUX5DNAS.js +0 -119
  63. package/feishu-HUX5DNAS.js.map +0 -1
  64. package/slack-QDR4X4V7.js.map +0 -1
  65. /package/{agent-3IQFM2KY.js.map → agent-DJY6SYVC.js.map} +0 -0
  66. /package/{banking-EYUWBTLB.js.map → banking-SV5ZIH44.js.map} +0 -0
  67. /package/{chat-S7Z2SOGU.js.map → chat-G2KQYYK5.js.map} +0 -0
  68. /package/{chunk-KVNHL3NQ.js.map → chunk-AWLNHCAC.js.map} +0 -0
  69. /package/{chunk-THDGMML6.js.map → chunk-BKSVVARX.js.map} +0 -0
  70. /package/{chunk-5CVPQC2F.js.map → chunk-CUAL7MH6.js.map} +0 -0
  71. /package/{chunk-CGLTWZX7.js.map → chunk-E2DKMMGY.js.map} +0 -0
  72. /package/{chunk-H46N52S6.js.map → chunk-IX2GN2TI.js.map} +0 -0
  73. /package/{chunk-WIO4VCT5.js.map → chunk-RGHA7C2O.js.map} +0 -0
  74. /package/{chunk-QHG7ITIT.js.map → chunk-TRFIH4R5.js.map} +0 -0
  75. /package/{computer-use-ZI4I63OA.js.map → computer-use-FUBM53XG.js.map} +0 -0
  76. /package/{connector-JEISK7OP.js.map → connector-3GCLB6HW.js.map} +0 -0
  77. /package/{credit-DZLGKM5H.js.map → credit-SXRYMKSD.js.map} +0 -0
  78. /package/{developer-support-GKND4K5Y.js.map → developer-support-LQHWOQLY.js.map} +0 -0
  79. /package/{doctor-IDEBPM3X.js.map → doctor-RVC32BKE.js.map} +0 -0
  80. /package/{finance-QRFJGKEW.js.map → finance-HP4WFZUY.js.map} +0 -0
  81. /package/{generate-SDDS6YWC.js.map → generate-PTBOIM6B.js.map} +0 -0
  82. /package/{github-6KEMKHRG.js.map → github-62XSFEWF.js.map} +0 -0
  83. /package/{goal-5ER7N3Z3.js.map → goal-VRWB2AS3.js.map} +0 -0
  84. /package/{host-JYOXNY2B.js.map → host-OKISPSSS.js.map} +0 -0
  85. /package/{logs-7AGKFCY3.js.map → logs-53CMUU4J.js.map} +0 -0
  86. /package/{mail-LJKDHK2A.js.map → mail-E6R5V6F6.js.map} +0 -0
  87. /package/{maps-HRMZ7QBC.js.map → maps-B7F3CODU.js.map} +0 -0
  88. /package/{model-RXY3MPL4.js.map → model-2VZQVFTE.js.map} +0 -0
  89. /package/{model-provider-HYLOR2WF.js.map → model-provider-XALJ5BZB.js.map} +0 -0
  90. /package/{org-FKZQ7WF6.js.map → org-JIAZYZUL.js.map} +0 -0
  91. /package/{people-search-444TQMDB.js.map → people-search-LZ2BRXA6.js.map} +0 -0
  92. /package/{phone-OI2MXOHO.js.map → phone-MXUV3YD3.js.map} +0 -0
  93. /package/{preference-MQYZJ7R3.js.map → preference-LONJZKPE.js.map} +0 -0
  94. /package/{resource-RVZZU2ZM.js.map → resource-26IQ2JCS.js.map} +0 -0
  95. /package/{scrape-MLGY4WK2.js.map → scrape-H2ZA5AJD.js.map} +0 -0
  96. /package/{search-PPAN6ZHY.js.map → search-R62IJFT4.js.map} +0 -0
  97. /package/{secret-HIYUWKY4.js.map → secret-PHZZWEE3.js.map} +0 -0
  98. /package/{teams-K6YHGEVC.js.map → teams-B5NDIX3U.js.map} +0 -0
  99. /package/{telegram-LHBCOVZP.js.map → telegram-R67CYOON.js.map} +0 -0
  100. /package/{upgrade-KM4H4ARY.js.map → upgrade-FJKXJO6L.js.map} +0 -0
  101. /package/{variable-ULJ4EFHR.js.map → variable-GNCE5TUG.js.map} +0 -0
  102. /package/{video-P26LRUFN.js.map → video-UDPAFI36.js.map} +0 -0
  103. /package/{weather-DMUJWZDC.js.map → weather-O6L5SALA.js.map} +0 -0
  104. /package/{web-ESXMLMEC.js.map → web-6I5S773Q.js.map} +0 -0
  105. /package/{web-search-QCZNJGMG.js.map → web-search-GQAKFVCC.js.map} +0 -0
  106. /package/{whoami-4NVG5FI7.js.map → whoami-MEJV5DZB.js.map} +0 -0
  107. /package/{workflow-G7DL7SCF.js.map → workflow-PEVNMY2N.js.map} +0 -0
@@ -3,7 +3,7 @@ import { createRequire as __createRequire } from "node:module";
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  getApiUrl
6
- } from "./chunk-CGLTWZX7.js";
6
+ } from "./chunk-E2DKMMGY.js";
7
7
  import {
8
8
  init_esm_shims
9
9
  } from "./chunk-3VVCUQPB.js";
@@ -42,4 +42,4 @@ export {
42
42
  toPlatformUrl,
43
43
  getPlatformOrigin
44
44
  };
45
- //# sourceMappingURL=chunk-WIO4VCT5.js.map
45
+ //# sourceMappingURL=chunk-RGHA7C2O.js.map
@@ -3,7 +3,7 @@ import { createRequire as __createRequire } from "node:module";
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  UNKNOWN_PERMISSION_GRANT
6
- } from "./chunk-ZSP7ISNV.js";
6
+ } from "./chunk-QL2BWE6J.js";
7
7
  import {
8
8
  init_esm_shims
9
9
  } from "./chunk-3VVCUQPB.js";
@@ -130,4 +130,4 @@ export {
130
130
  resolveFirewallMetadataPolicies,
131
131
  permissionGrantsToFirewallPolicies
132
132
  };
133
- //# sourceMappingURL=chunk-QHG7ITIT.js.map
133
+ //# sourceMappingURL=chunk-TRFIH4R5.js.map
@@ -12,13 +12,13 @@ import {
12
12
  fetchComputerUseScreenshot,
13
13
  getComputerUseCommand,
14
14
  listComputerUseHosts
15
- } from "./chunk-ZSP7ISNV.js";
16
- import "./chunk-2USAOUQI.js";
15
+ } from "./chunk-QL2BWE6J.js";
16
+ import "./chunk-BSDS7GCS.js";
17
17
  import {
18
18
  ApiRequestError,
19
19
  withErrorHandler
20
- } from "./chunk-CGLTWZX7.js";
21
- import "./chunk-K3F4FDYI.js";
20
+ } from "./chunk-E2DKMMGY.js";
21
+ import "./chunk-DK3C2ME6.js";
22
22
  import {
23
23
  Command
24
24
  } from "./chunk-LD4ZVU4O.js";
@@ -970,4 +970,4 @@ export {
970
970
  formatComputerUseResultForConsole,
971
971
  zeroComputerUseCommand
972
972
  };
973
- //# sourceMappingURL=computer-use-ZI4I63OA.js.map
973
+ //# sourceMappingURL=computer-use-FUBM53XG.js.map
@@ -3,14 +3,14 @@ import { createRequire as __createRequire } from "node:module";
3
3
  const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  findFirewallMetadataPermission
6
- } from "./chunk-QHG7ITIT.js";
6
+ } from "./chunk-TRFIH4R5.js";
7
7
  import {
8
8
  availableConnectorRefs,
9
9
  findConnectorStatusItem,
10
10
  resolveAgentContext,
11
11
  resolveManualGrantAuthMethod,
12
12
  searchPublicConnectorCatalog
13
- } from "./chunk-H46N52S6.js";
13
+ } from "./chunk-IX2GN2TI.js";
14
14
  import {
15
15
  UNKNOWN_PERMISSION_GRANT,
16
16
  connectZeroConnectorManualGrant,
@@ -25,20 +25,20 @@ import {
25
25
  getZeroCustomConnector,
26
26
  listZeroConnectorCatalogStatus,
27
27
  listZeroCustomConnectors
28
- } from "./chunk-ZSP7ISNV.js";
29
- import "./chunk-2USAOUQI.js";
28
+ } from "./chunk-QL2BWE6J.js";
29
+ import "./chunk-BSDS7GCS.js";
30
30
  import {
31
31
  getPlatformOrigin,
32
32
  toPlatformUrl
33
- } from "./chunk-WIO4VCT5.js";
33
+ } from "./chunk-RGHA7C2O.js";
34
34
  import "./chunk-SB7EZ2ZO.js";
35
35
  import {
36
36
  ApiRequestError,
37
37
  getApiUrl,
38
38
  source_default,
39
39
  withErrorHandler
40
- } from "./chunk-CGLTWZX7.js";
41
- import "./chunk-K3F4FDYI.js";
40
+ } from "./chunk-E2DKMMGY.js";
41
+ import "./chunk-DK3C2ME6.js";
42
42
  import {
43
43
  Command,
44
44
  Option
@@ -1557,4 +1557,4 @@ var zeroConnectorCommand = new Command().name("connector").description("Manage a
1557
1557
  export {
1558
1558
  zeroConnectorCommand
1559
1559
  };
1560
- //# sourceMappingURL=connector-JEISK7OP.js.map
1560
+ //# sourceMappingURL=connector-3GCLB6HW.js.map
@@ -5,27 +5,27 @@ import {
5
5
  currentPlanAllowsVideo,
6
6
  currentPlanCanBuyCredits,
7
7
  currentTokenCanReadBilling
8
- } from "./chunk-5CVPQC2F.js";
8
+ } from "./chunk-CUAL7MH6.js";
9
9
  import {
10
10
  createZeroCreditCheckout,
11
11
  getZeroBillingStatus,
12
12
  getZeroOrgMembers
13
- } from "./chunk-ZSP7ISNV.js";
14
- import "./chunk-2USAOUQI.js";
13
+ } from "./chunk-QL2BWE6J.js";
14
+ import "./chunk-BSDS7GCS.js";
15
15
  import {
16
16
  planUpgradeUrl
17
17
  } from "./chunk-W75R7EZF.js";
18
18
  import {
19
19
  getPlatformOrigin
20
- } from "./chunk-WIO4VCT5.js";
20
+ } from "./chunk-RGHA7C2O.js";
21
21
  import "./chunk-SB7EZ2ZO.js";
22
22
  import {
23
23
  source_default,
24
24
  withErrorHandler
25
- } from "./chunk-CGLTWZX7.js";
25
+ } from "./chunk-E2DKMMGY.js";
26
26
  import {
27
27
  decodeZeroTokenPayload
28
- } from "./chunk-K3F4FDYI.js";
28
+ } from "./chunk-DK3C2ME6.js";
29
29
  import {
30
30
  Command,
31
31
  Option
@@ -163,4 +163,4 @@ var zeroCreditCommand = new Command().name("credit").description("View credit ba
163
163
  export {
164
164
  zeroCreditCommand
165
165
  };
166
- //# sourceMappingURL=credit-DZLGKM5H.js.map
166
+ //# sourceMappingURL=credit-SXRYMKSD.js.map
@@ -4,13 +4,13 @@ const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  requestDeveloperSupportConsent,
6
6
  submitDeveloperSupport
7
- } from "./chunk-ZSP7ISNV.js";
8
- import "./chunk-2USAOUQI.js";
7
+ } from "./chunk-QL2BWE6J.js";
8
+ import "./chunk-BSDS7GCS.js";
9
9
  import "./chunk-SB7EZ2ZO.js";
10
10
  import {
11
11
  withErrorHandler
12
- } from "./chunk-CGLTWZX7.js";
13
- import "./chunk-K3F4FDYI.js";
12
+ } from "./chunk-E2DKMMGY.js";
13
+ import "./chunk-DK3C2ME6.js";
14
14
  import {
15
15
  Command
16
16
  } from "./chunk-LD4ZVU4O.js";
@@ -61,4 +61,4 @@ Notes:
61
61
  export {
62
62
  zeroDeveloperSupportCommand
63
63
  };
64
- //# sourceMappingURL=developer-support-GKND4K5Y.js.map
64
+ //# sourceMappingURL=developer-support-LQHWOQLY.js.map
@@ -4,25 +4,25 @@ const require = __createRequire(import.meta.url);
4
4
  import {
5
5
  currentPlanAllowsVideo,
6
6
  currentPlanCanBuyCredits
7
- } from "./chunk-5CVPQC2F.js";
7
+ } from "./chunk-CUAL7MH6.js";
8
8
  import {
9
9
  getZeroBillingStatus,
10
10
  getZeroOrg,
11
11
  getZeroOrgMembers
12
- } from "./chunk-ZSP7ISNV.js";
13
- import "./chunk-2USAOUQI.js";
12
+ } from "./chunk-QL2BWE6J.js";
13
+ import "./chunk-BSDS7GCS.js";
14
14
  import {
15
15
  planUpgradeUrl
16
16
  } from "./chunk-W75R7EZF.js";
17
17
  import {
18
18
  getPlatformOrigin
19
- } from "./chunk-WIO4VCT5.js";
19
+ } from "./chunk-RGHA7C2O.js";
20
20
  import "./chunk-SB7EZ2ZO.js";
21
21
  import {
22
22
  source_default,
23
23
  withErrorHandler
24
- } from "./chunk-CGLTWZX7.js";
25
- import "./chunk-K3F4FDYI.js";
24
+ } from "./chunk-E2DKMMGY.js";
25
+ import "./chunk-DK3C2ME6.js";
26
26
  import {
27
27
  Command
28
28
  } from "./chunk-LD4ZVU4O.js";
@@ -122,4 +122,4 @@ Notes:
122
122
  export {
123
123
  zeroDoctorCommand
124
124
  };
125
- //# sourceMappingURL=doctor-IDEBPM3X.js.map
125
+ //# sourceMappingURL=doctor-RVC32BKE.js.map
@@ -0,0 +1,277 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire as __createRequire } from "node:module";
3
+ const require = __createRequire(import.meta.url);
4
+ import {
5
+ FEISHU_FILE_UPLOAD_MAX_BYTES,
6
+ completeFeishuFileUpload,
7
+ downloadFeishuFile,
8
+ initFeishuFileUpload,
9
+ sendFeishuMessage
10
+ } from "./chunk-QL2BWE6J.js";
11
+ import "./chunk-BSDS7GCS.js";
12
+ import "./chunk-SB7EZ2ZO.js";
13
+ import {
14
+ source_default,
15
+ withErrorHandler
16
+ } from "./chunk-E2DKMMGY.js";
17
+ import "./chunk-DK3C2ME6.js";
18
+ import {
19
+ Command
20
+ } from "./chunk-LD4ZVU4O.js";
21
+ import {
22
+ init_esm_shims
23
+ } from "./chunk-3VVCUQPB.js";
24
+
25
+ // src/commands/zero/feishu/index.ts
26
+ init_esm_shims();
27
+
28
+ // src/commands/zero/feishu/download-file.ts
29
+ init_esm_shims();
30
+ import { tmpdir } from "os";
31
+ import { basename, join } from "path";
32
+ function defaultOutPath(fileKey) {
33
+ return join(tmpdir(), `feishu-${basename(fileKey).slice(0, 80)}`);
34
+ }
35
+ function parseResourceType(value) {
36
+ if (value !== "file" && value !== "image") {
37
+ throw new Error("--type must be either file or image");
38
+ }
39
+ return value;
40
+ }
41
+ var downloadFileCommand = new Command().name("download-file").description("Download a file from a Feishu message").argument("<message-id>", "Message ID from a [Feishu file] block").argument("<file-key>", "File key from a [Feishu file] block").requiredOption(
42
+ "--type <type>",
43
+ "Resource type from the block: file or image"
44
+ ).option("-i, --installation <id>", "Feishu installation ID").option("-o, --out <path>", "Output path (default: /tmp/feishu-<file-key>)").addHelpText(
45
+ "after",
46
+ `
47
+ Examples:
48
+ Download a file: zero feishu download-file om_xxx file_xxx --type file
49
+ Download an image: zero feishu download-file om_xxx img_xxx --type image -o /tmp/image.png
50
+ Select an app: zero feishu download-file om_xxx file_xxx --type file -i <installation-id>
51
+
52
+ Output:
53
+ Prints a JSON object to stdout on success:
54
+ {"path":"/tmp/feishu-file_xxx","mimetype":"application/pdf","size":12345}
55
+
56
+ Notes:
57
+ - Use the message ID, file key, and type exactly as shown in a [Feishu file] block
58
+ - Specify --installation when the organization has multiple Feishu bots
59
+ - Streams the file bytes directly to disk`
60
+ ).action(
61
+ withErrorHandler(
62
+ async (messageId, fileKey, options) => {
63
+ const outPath = options.out ?? defaultOutPath(fileKey);
64
+ const result = await downloadFeishuFile(
65
+ messageId,
66
+ fileKey,
67
+ parseResourceType(options.type),
68
+ options.installation,
69
+ outPath
70
+ );
71
+ console.log(JSON.stringify(result));
72
+ }
73
+ )
74
+ );
75
+
76
+ // src/commands/zero/feishu/message/index.ts
77
+ init_esm_shims();
78
+
79
+ // src/commands/zero/feishu/message/send.ts
80
+ init_esm_shims();
81
+ import { readFileSync } from "fs";
82
+ function isRecord(value) {
83
+ return Boolean(value) && typeof value === "object" && !Array.isArray(value);
84
+ }
85
+ function parseCard(input) {
86
+ if (!input) {
87
+ return void 0;
88
+ }
89
+ let parsed;
90
+ try {
91
+ parsed = JSON.parse(input);
92
+ } catch {
93
+ throw new Error("Invalid JSON for --card flag", {
94
+ cause: new Error("Provide a valid Feishu card JSON object")
95
+ });
96
+ }
97
+ if (!isRecord(parsed)) {
98
+ throw new Error("Invalid JSON for --card", {
99
+ cause: new Error("Provide a Feishu card JSON object")
100
+ });
101
+ }
102
+ return parsed;
103
+ }
104
+ var sendCommand = new Command().name("send").description("Send a message to a Feishu chat or user").option("-i, --installation <id>", "Feishu installation ID").option("-c, --chat <id>", "Feishu chat ID").option("-u, --user <open-id>", 'Feishu user open ID (use "me" for yourself)').option("-r, --reply <message-id>", "Message ID to reply to").option("--thread", "Reply in a Feishu thread").option("-t, --text <message>", "Message text").option("--card <json>", "Feishu interactive card JSON").addHelpText(
105
+ "after",
106
+ `
107
+ Examples:
108
+ Chat message: zero feishu message send -c oc_xxx -t "Hello!"
109
+ Direct message: zero feishu message send -u ou_xxx -t "Hello!"
110
+ DM yourself: zero feishu message send -u me -t "Hello!"
111
+ Thread reply: zero feishu message send -r om_xxx --thread -t "Reply"
112
+ Interactive card: zero feishu message send -c oc_xxx --card '{"schema":"2.0","body":{"elements":[]}}'
113
+ Select a custom app: zero feishu message send -i <installation-id> -c oc_xxx -t "Hello!"
114
+
115
+ Notes:
116
+ - Exactly one of --chat, --user, or --reply is required
117
+ - Exactly one of --text or --card is required
118
+ - --installation is required when the organization has multiple Feishu bots`
119
+ ).action(
120
+ withErrorHandler(async (options) => {
121
+ const targets = [options.chat, options.user, options.reply].filter(
122
+ Boolean
123
+ );
124
+ if (targets.length !== 1) {
125
+ throw new Error(
126
+ "Exactly one of --chat, --user, or --reply must be provided"
127
+ );
128
+ }
129
+ if (options.thread && !options.reply) {
130
+ throw new Error("--thread requires --reply");
131
+ }
132
+ let text = options.text;
133
+ if (!text && !options.card && !process.stdin.isTTY) {
134
+ try {
135
+ text = readFileSync("/dev/stdin", "utf8").trim();
136
+ } catch {
137
+ }
138
+ }
139
+ const card = parseCard(options.card);
140
+ if (Boolean(text) === Boolean(card)) {
141
+ throw new Error("Exactly one of --text or --card must be provided");
142
+ }
143
+ const result = await sendFeishuMessage({
144
+ installationId: options.installation,
145
+ chat: options.chat,
146
+ user: options.user,
147
+ replyToMessageId: options.reply,
148
+ replyInThread: options.thread,
149
+ text,
150
+ card
151
+ });
152
+ console.log(source_default.green(`\u2713 Message sent (message: ${result.messageId})`));
153
+ })
154
+ );
155
+
156
+ // src/commands/zero/feishu/message/index.ts
157
+ var zeroFeishuMessageCommand = new Command().name("message").description("Send Feishu messages").addCommand(sendCommand);
158
+
159
+ // src/commands/zero/feishu/upload-file.ts
160
+ init_esm_shims();
161
+ import { readFileSync as readFileSync2, statSync } from "fs";
162
+ import { basename as basename2, extname } from "path";
163
+ var MIME_BY_EXTENSION = {
164
+ ".csv": "text/csv",
165
+ ".gif": "image/gif",
166
+ ".jpeg": "image/jpeg",
167
+ ".jpg": "image/jpeg",
168
+ ".json": "application/json",
169
+ ".md": "text/markdown",
170
+ ".mov": "video/quicktime",
171
+ ".mp4": "video/mp4",
172
+ ".pdf": "application/pdf",
173
+ ".png": "image/png",
174
+ ".svg": "image/svg+xml",
175
+ ".txt": "text/plain",
176
+ ".webm": "video/webm",
177
+ ".webp": "image/webp"
178
+ };
179
+ function inferContentType(localPath) {
180
+ return MIME_BY_EXTENSION[extname(localPath).toLowerCase()] ?? "application/octet-stream";
181
+ }
182
+ var uploadFileCommand = new Command().name("upload-file").description("Upload a local file to Feishu as an organization bot").requiredOption("-f, --file <path>", "Local file path to upload").option("-i, --installation <id>", "Feishu installation ID").option("-c, --chat <id>", "Feishu chat ID").option("-u, --user <open-id>", 'Feishu user open ID (use "me" for yourself)').option("-r, --reply <message-id>", "Message ID to reply to").option("--thread", "Reply in a Feishu thread").option("--content-type <mime>", "Override inferred content type").addHelpText(
183
+ "after",
184
+ `
185
+ Examples:
186
+ Upload to a chat: zero feishu upload-file -f /tmp/report.pdf -c oc_xxx
187
+ Send a DM: zero feishu upload-file -f /tmp/report.pdf -u ou_xxx
188
+ Reply with a file: zero feishu upload-file -f /tmp/report.pdf -r om_xxx --thread
189
+ Select a custom app: zero feishu upload-file -f /tmp/report.pdf -i <installation-id> -c oc_xxx
190
+
191
+ Output:
192
+ Prints a JSON object to stdout on success:
193
+ {"messageId":"om_xxx","chatId":"oc_xxx","fileKey":"file_xxx","filename":"report.pdf","mimetype":"application/pdf","size":12345,"url":"https://..."}
194
+
195
+ Notes:
196
+ - Exactly one of --chat, --user, or --reply is required
197
+ - Feishu accepts non-empty files up to 30 MB
198
+ - Specify --installation when the organization has multiple Feishu bots`
199
+ ).action(
200
+ withErrorHandler(async (options) => {
201
+ const targets = [options.chat, options.user, options.reply].filter(
202
+ Boolean
203
+ );
204
+ if (targets.length !== 1) {
205
+ throw new Error(
206
+ "Exactly one of --chat, --user, or --reply must be provided"
207
+ );
208
+ }
209
+ if (options.thread && !options.reply) {
210
+ throw new Error("--thread requires --reply");
211
+ }
212
+ let fileSize;
213
+ try {
214
+ const stat = statSync(options.file);
215
+ if (!stat.isFile()) {
216
+ throw new Error(`Not a regular file: ${options.file}`);
217
+ }
218
+ fileSize = stat.size;
219
+ } catch (error) {
220
+ if (error instanceof Error && error.message.startsWith("Not ")) {
221
+ throw error;
222
+ }
223
+ throw new Error(`File not found: ${options.file}`);
224
+ }
225
+ if (fileSize === 0) {
226
+ throw new Error("File is empty");
227
+ }
228
+ if (fileSize > FEISHU_FILE_UPLOAD_MAX_BYTES) {
229
+ throw new Error(
230
+ `File exceeds Feishu's ${FEISHU_FILE_UPLOAD_MAX_BYTES}-byte limit`
231
+ );
232
+ }
233
+ const filename = basename2(options.file);
234
+ const contentType = options.contentType ?? inferContentType(options.file);
235
+ const prepared = await initFeishuFileUpload({
236
+ filename,
237
+ contentType,
238
+ length: fileSize
239
+ });
240
+ const uploadResponse = await fetch(prepared.uploadUrl, {
241
+ method: "PUT",
242
+ headers: { "Content-Type": prepared.contentType },
243
+ body: new Uint8Array(readFileSync2(options.file))
244
+ });
245
+ if (!uploadResponse.ok) {
246
+ throw new Error(
247
+ `File upload failed: ${uploadResponse.status} ${uploadResponse.statusText}`
248
+ );
249
+ }
250
+ const result = await completeFeishuFileUpload({
251
+ uploadId: prepared.uploadId,
252
+ installationId: options.installation,
253
+ chat: options.chat,
254
+ user: options.user,
255
+ replyToMessageId: options.reply,
256
+ replyInThread: options.thread,
257
+ contentType: prepared.contentType
258
+ });
259
+ console.log(JSON.stringify(result));
260
+ })
261
+ );
262
+
263
+ // src/commands/zero/feishu/index.ts
264
+ var zeroFeishuCommand = new Command().name("feishu").description("Send messages and transfer files through Feishu").addCommand(zeroFeishuMessageCommand).addCommand(downloadFileCommand).addCommand(uploadFileCommand).addHelpText(
265
+ "after",
266
+ `
267
+ Examples:
268
+ Send to a chat: zero feishu message send -c <chat-id> -t "Hello!"
269
+ Send a DM: zero feishu message send -u <open-id> -t "Hello!"
270
+ Reply in a thread: zero feishu message send -r <message-id> --thread -t "Reply"
271
+ Upload a file: zero feishu upload-file -f /tmp/report.pdf -c <chat-id>
272
+ Download a file: zero feishu download-file <message-id> <file-key> --type file`
273
+ );
274
+ export {
275
+ zeroFeishuCommand
276
+ };
277
+ //# sourceMappingURL=feishu-62E2QMM5.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/commands/zero/feishu/index.ts","../src/commands/zero/feishu/download-file.ts","../src/commands/zero/feishu/message/index.ts","../src/commands/zero/feishu/message/send.ts","../src/commands/zero/feishu/upload-file.ts"],"sourcesContent":["import { Command } from \"commander\";\n\nimport { downloadFileCommand } from \"./download-file\";\nimport { zeroFeishuMessageCommand } from \"./message\";\nimport { uploadFileCommand } from \"./upload-file\";\n\nexport const zeroFeishuCommand = new Command()\n .name(\"feishu\")\n .description(\"Send messages and transfer files through Feishu\")\n .addCommand(zeroFeishuMessageCommand)\n .addCommand(downloadFileCommand)\n .addCommand(uploadFileCommand)\n .addHelpText(\n \"after\",\n `\nExamples:\n Send to a chat: zero feishu message send -c <chat-id> -t \"Hello!\"\n Send a DM: zero feishu message send -u <open-id> -t \"Hello!\"\n Reply in a thread: zero feishu message send -r <message-id> --thread -t \"Reply\"\n Upload a file: zero feishu upload-file -f /tmp/report.pdf -c <chat-id>\n Download a file: zero feishu download-file <message-id> <file-key> --type file`,\n );\n","import { tmpdir } from \"node:os\";\nimport { basename, join } from \"node:path\";\n\nimport { Command } from \"commander\";\nimport type { FeishuResourceType } from \"@vm0/api-contracts/contracts/integrations\";\n\nimport { downloadFeishuFile } from \"../../../lib/api\";\nimport { withErrorHandler } from \"../../../lib/command\";\n\nfunction defaultOutPath(fileKey: string): string {\n return join(tmpdir(), `feishu-${basename(fileKey).slice(0, 80)}`);\n}\n\nfunction parseResourceType(value: string): FeishuResourceType {\n if (value !== \"file\" && value !== \"image\") {\n throw new Error(\"--type must be either file or image\");\n }\n return value;\n}\n\nexport const downloadFileCommand = new Command()\n .name(\"download-file\")\n .description(\"Download a file from a Feishu message\")\n .argument(\"<message-id>\", \"Message ID from a [Feishu file] block\")\n .argument(\"<file-key>\", \"File key from a [Feishu file] block\")\n .requiredOption(\n \"--type <type>\",\n \"Resource type from the block: file or image\",\n )\n .option(\"-i, --installation <id>\", \"Feishu installation ID\")\n .option(\"-o, --out <path>\", \"Output path (default: /tmp/feishu-<file-key>)\")\n .addHelpText(\n \"after\",\n `\nExamples:\n Download a file: zero feishu download-file om_xxx file_xxx --type file\n Download an image: zero feishu download-file om_xxx img_xxx --type image -o /tmp/image.png\n Select an app: zero feishu download-file om_xxx file_xxx --type file -i <installation-id>\n\nOutput:\n Prints a JSON object to stdout on success:\n {\"path\":\"/tmp/feishu-file_xxx\",\"mimetype\":\"application/pdf\",\"size\":12345}\n\nNotes:\n - Use the message ID, file key, and type exactly as shown in a [Feishu file] block\n - Specify --installation when the organization has multiple Feishu bots\n - Streams the file bytes directly to disk`,\n )\n .action(\n withErrorHandler(\n async (\n messageId: string,\n fileKey: string,\n options: {\n readonly type: string;\n readonly installation?: string;\n readonly out?: string;\n },\n ) => {\n const outPath = options.out ?? defaultOutPath(fileKey);\n const result = await downloadFeishuFile(\n messageId,\n fileKey,\n parseResourceType(options.type),\n options.installation,\n outPath,\n );\n console.log(JSON.stringify(result));\n },\n ),\n );\n","import { Command } from \"commander\";\n\nimport { sendCommand } from \"./send\";\n\nexport const zeroFeishuMessageCommand = new Command()\n .name(\"message\")\n .description(\"Send Feishu messages\")\n .addCommand(sendCommand);\n","import { readFileSync } from \"node:fs\";\n\nimport chalk from \"chalk\";\nimport { Command } from \"commander\";\n\nimport { sendFeishuMessage } from \"../../../../lib/api\";\nimport { withErrorHandler } from \"../../../../lib/command\";\n\ninterface SendFeishuOptions {\n readonly installation?: string;\n readonly chat?: string;\n readonly user?: string;\n readonly reply?: string;\n readonly thread?: boolean;\n readonly text?: string;\n readonly card?: string;\n}\n\nfunction isRecord(value: unknown): value is Record<string, unknown> {\n return Boolean(value) && typeof value === \"object\" && !Array.isArray(value);\n}\n\nfunction parseCard(\n input: string | undefined,\n): Record<string, unknown> | undefined {\n if (!input) {\n return undefined;\n }\n let parsed: unknown;\n try {\n parsed = JSON.parse(input);\n } catch {\n throw new Error(\"Invalid JSON for --card flag\", {\n cause: new Error(\"Provide a valid Feishu card JSON object\"),\n });\n }\n if (!isRecord(parsed)) {\n throw new Error(\"Invalid JSON for --card\", {\n cause: new Error(\"Provide a Feishu card JSON object\"),\n });\n }\n return parsed;\n}\n\nexport const sendCommand = new Command()\n .name(\"send\")\n .description(\"Send a message to a Feishu chat or user\")\n .option(\"-i, --installation <id>\", \"Feishu installation ID\")\n .option(\"-c, --chat <id>\", \"Feishu chat ID\")\n .option(\"-u, --user <open-id>\", 'Feishu user open ID (use \"me\" for yourself)')\n .option(\"-r, --reply <message-id>\", \"Message ID to reply to\")\n .option(\"--thread\", \"Reply in a Feishu thread\")\n .option(\"-t, --text <message>\", \"Message text\")\n .option(\"--card <json>\", \"Feishu interactive card JSON\")\n .addHelpText(\n \"after\",\n `\nExamples:\n Chat message: zero feishu message send -c oc_xxx -t \"Hello!\"\n Direct message: zero feishu message send -u ou_xxx -t \"Hello!\"\n DM yourself: zero feishu message send -u me -t \"Hello!\"\n Thread reply: zero feishu message send -r om_xxx --thread -t \"Reply\"\n Interactive card: zero feishu message send -c oc_xxx --card '{\"schema\":\"2.0\",\"body\":{\"elements\":[]}}'\n Select a custom app: zero feishu message send -i <installation-id> -c oc_xxx -t \"Hello!\"\n\nNotes:\n - Exactly one of --chat, --user, or --reply is required\n - Exactly one of --text or --card is required\n - --installation is required when the organization has multiple Feishu bots`,\n )\n .action(\n withErrorHandler(async (options: SendFeishuOptions) => {\n const targets = [options.chat, options.user, options.reply].filter(\n Boolean,\n );\n if (targets.length !== 1) {\n throw new Error(\n \"Exactly one of --chat, --user, or --reply must be provided\",\n );\n }\n if (options.thread && !options.reply) {\n throw new Error(\"--thread requires --reply\");\n }\n\n let text = options.text;\n if (!text && !options.card && !process.stdin.isTTY) {\n try {\n text = readFileSync(\"/dev/stdin\", \"utf8\").trim();\n } catch {\n // stdin is not readable; fall through to normal input validation.\n }\n }\n const card = parseCard(options.card);\n if (Boolean(text) === Boolean(card)) {\n throw new Error(\"Exactly one of --text or --card must be provided\");\n }\n\n const result = await sendFeishuMessage({\n installationId: options.installation,\n chat: options.chat,\n user: options.user,\n replyToMessageId: options.reply,\n replyInThread: options.thread,\n text,\n card,\n });\n console.log(chalk.green(`✓ Message sent (message: ${result.messageId})`));\n }),\n );\n","import { readFileSync, statSync } from \"node:fs\";\nimport { basename, extname } from \"node:path\";\n\nimport { Command } from \"commander\";\nimport { FEISHU_FILE_UPLOAD_MAX_BYTES } from \"@vm0/api-contracts/contracts/integrations\";\n\nimport {\n completeFeishuFileUpload,\n initFeishuFileUpload,\n} from \"../../../lib/api\";\nimport { withErrorHandler } from \"../../../lib/command\";\n\nconst MIME_BY_EXTENSION: Readonly<Record<string, string>> = {\n \".csv\": \"text/csv\",\n \".gif\": \"image/gif\",\n \".jpeg\": \"image/jpeg\",\n \".jpg\": \"image/jpeg\",\n \".json\": \"application/json\",\n \".md\": \"text/markdown\",\n \".mov\": \"video/quicktime\",\n \".mp4\": \"video/mp4\",\n \".pdf\": \"application/pdf\",\n \".png\": \"image/png\",\n \".svg\": \"image/svg+xml\",\n \".txt\": \"text/plain\",\n \".webm\": \"video/webm\",\n \".webp\": \"image/webp\",\n};\n\ninterface UploadFeishuOptions {\n readonly file: string;\n readonly installation?: string;\n readonly chat?: string;\n readonly user?: string;\n readonly reply?: string;\n readonly thread?: boolean;\n readonly contentType?: string;\n}\n\nfunction inferContentType(localPath: string): string {\n return (\n MIME_BY_EXTENSION[extname(localPath).toLowerCase()] ??\n \"application/octet-stream\"\n );\n}\n\nexport const uploadFileCommand = new Command()\n .name(\"upload-file\")\n .description(\"Upload a local file to Feishu as an organization bot\")\n .requiredOption(\"-f, --file <path>\", \"Local file path to upload\")\n .option(\"-i, --installation <id>\", \"Feishu installation ID\")\n .option(\"-c, --chat <id>\", \"Feishu chat ID\")\n .option(\"-u, --user <open-id>\", 'Feishu user open ID (use \"me\" for yourself)')\n .option(\"-r, --reply <message-id>\", \"Message ID to reply to\")\n .option(\"--thread\", \"Reply in a Feishu thread\")\n .option(\"--content-type <mime>\", \"Override inferred content type\")\n .addHelpText(\n \"after\",\n `\nExamples:\n Upload to a chat: zero feishu upload-file -f /tmp/report.pdf -c oc_xxx\n Send a DM: zero feishu upload-file -f /tmp/report.pdf -u ou_xxx\n Reply with a file: zero feishu upload-file -f /tmp/report.pdf -r om_xxx --thread\n Select a custom app: zero feishu upload-file -f /tmp/report.pdf -i <installation-id> -c oc_xxx\n\nOutput:\n Prints a JSON object to stdout on success:\n {\"messageId\":\"om_xxx\",\"chatId\":\"oc_xxx\",\"fileKey\":\"file_xxx\",\"filename\":\"report.pdf\",\"mimetype\":\"application/pdf\",\"size\":12345,\"url\":\"https://...\"}\n\nNotes:\n - Exactly one of --chat, --user, or --reply is required\n - Feishu accepts non-empty files up to 30 MB\n - Specify --installation when the organization has multiple Feishu bots`,\n )\n .action(\n withErrorHandler(async (options: UploadFeishuOptions) => {\n const targets = [options.chat, options.user, options.reply].filter(\n Boolean,\n );\n if (targets.length !== 1) {\n throw new Error(\n \"Exactly one of --chat, --user, or --reply must be provided\",\n );\n }\n if (options.thread && !options.reply) {\n throw new Error(\"--thread requires --reply\");\n }\n\n let fileSize: number;\n try {\n const stat = statSync(options.file);\n if (!stat.isFile()) {\n throw new Error(`Not a regular file: ${options.file}`);\n }\n fileSize = stat.size;\n } catch (error) {\n if (error instanceof Error && error.message.startsWith(\"Not \")) {\n throw error;\n }\n throw new Error(`File not found: ${options.file}`);\n }\n if (fileSize === 0) {\n throw new Error(\"File is empty\");\n }\n if (fileSize > FEISHU_FILE_UPLOAD_MAX_BYTES) {\n throw new Error(\n `File exceeds Feishu's ${FEISHU_FILE_UPLOAD_MAX_BYTES}-byte limit`,\n );\n }\n\n const filename = basename(options.file);\n const contentType = options.contentType ?? inferContentType(options.file);\n const prepared = await initFeishuFileUpload({\n filename,\n contentType,\n length: fileSize,\n });\n const uploadResponse = await fetch(prepared.uploadUrl, {\n method: \"PUT\",\n headers: { \"Content-Type\": prepared.contentType },\n body: new Uint8Array(readFileSync(options.file)),\n });\n if (!uploadResponse.ok) {\n throw new Error(\n `File upload failed: ${uploadResponse.status} ${uploadResponse.statusText}`,\n );\n }\n\n const result = await completeFeishuFileUpload({\n uploadId: prepared.uploadId,\n installationId: options.installation,\n chat: options.chat,\n user: options.user,\n replyToMessageId: options.reply,\n replyInThread: options.thread,\n contentType: prepared.contentType,\n });\n console.log(JSON.stringify(result));\n }),\n );\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;;ACAA;AAAA,SAAS,cAAc;AACvB,SAAS,UAAU,YAAY;AAQ/B,SAAS,eAAe,SAAyB;AAC/C,SAAO,KAAK,OAAO,GAAG,UAAU,SAAS,OAAO,EAAE,MAAM,GAAG,EAAE,CAAC,EAAE;AAClE;AAEA,SAAS,kBAAkB,OAAmC;AAC5D,MAAI,UAAU,UAAU,UAAU,SAAS;AACzC,UAAM,IAAI,MAAM,qCAAqC;AAAA,EACvD;AACA,SAAO;AACT;AAEO,IAAM,sBAAsB,IAAI,QAAQ,EAC5C,KAAK,eAAe,EACpB,YAAY,uCAAuC,EACnD,SAAS,gBAAgB,uCAAuC,EAChE,SAAS,cAAc,qCAAqC,EAC5D;AAAA,EACC;AAAA,EACA;AACF,EACC,OAAO,2BAA2B,wBAAwB,EAC1D,OAAO,oBAAoB,+CAA+C,EAC1E;AAAA,EACC;AAAA,EACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAcF,EACC;AAAA,EACC;AAAA,IACE,OACE,WACA,SACA,YAKG;AACH,YAAM,UAAU,QAA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I,WAAW,8BAA8B;AAC3C,YAAM,IAAI;AAAA,QACR,yBAAyB,4BAA4B;AAAA,MACvD;AAAA,IACF;AAEA,UAAM,WAAWC,UAAS,QAAQ,IAAI;AACtC,UAAM,cAAc,QAAQ,eAAe,iBAAiB,QAAQ,IAAI;AACxE,UAAM,WAAW,MAAM,qBAAqB;AAAA,MAC1C;AAAA,MACA;AAAA,MACA,QAAQ;AAAA,IACV,CAAC;AACD,UAAM,iBAAiB,MAAM,MAAM,SAAS,WAAW;AAAA,MACrD,QAAQ;AAAA,MACR,SAAS,EAAE,gBAAgB,SAAS,YAAY;AAAA,MAChD,MAAM,IAAI,WAAWC,cAAa,QAAQ,IAAI,CAAC;AAAA,IACjD,CAAC;AACD,QAAI,CAAC,eAAe,IAAI;AACtB,YAAM,IAAI;AAAA,QACR,uBAAuB,eAAe,MAAM,IAAI,eAAe,UAAU;AAAA,MAC3E;AAAA,IACF;AAEA,UAAM,SAAS,MAAM,yBAAyB;AAAA,MAC5C,UAAU,SAAS;AAAA,MACnB,gBAAgB,QAAQ;AAAA,MACxB,MAAM,QAAQ;AAAA,MACd,MAAM,QAAQ;AAAA,MACd,kBAAkB,QAAQ;AAAA,MAC1B,eAAe,QAAQ;AAAA,MACvB,aAAa,SAAS;AAAA,IACxB,CAAC;AACD,YAAQ,IAAI,KAAK,UAAU,MAAM,CAAC;AAAA,EACpC,CAAC;AACH;;;AJrIK,IAAM,oBAAoB,IAAI,QAAQ,EAC1C,KAAK,QAAQ,EACb,YAAY,iDAAiD,EAC7D,WAAW,wBAAwB,EACnC,WAAW,mBAAmB,EAC9B,WAAW,iBAAiB,EAC5B;AAAA,EACC;AAAA,EACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOF;","names":["readFileSync","basename","basename","readFileSync"]}
@@ -14,14 +14,14 @@ import {
14
14
  zeroFinanceQuoteRequestSchema,
15
15
  zeroFinanceRangeSchema,
16
16
  zeroFinanceSearchRequestSchema
17
- } from "./chunk-ZSP7ISNV.js";
18
- import "./chunk-2USAOUQI.js";
17
+ } from "./chunk-QL2BWE6J.js";
18
+ import "./chunk-BSDS7GCS.js";
19
19
  import "./chunk-SB7EZ2ZO.js";
20
20
  import {
21
21
  source_default,
22
22
  withErrorHandler
23
- } from "./chunk-CGLTWZX7.js";
24
- import "./chunk-K3F4FDYI.js";
23
+ } from "./chunk-E2DKMMGY.js";
24
+ import "./chunk-DK3C2ME6.js";
25
25
  import {
26
26
  Command,
27
27
  InvalidArgumentError,
@@ -125,4 +125,4 @@ Notes:
125
125
  export {
126
126
  zeroFinanceCommand
127
127
  };
128
- //# sourceMappingURL=finance-QRFJGKEW.js.map
128
+ //# sourceMappingURL=finance-HP4WFZUY.js.map
@@ -21,31 +21,31 @@ import {
21
21
  import {
22
22
  currentPlanAllowsVideo,
23
23
  currentTokenCanReadBilling
24
- } from "./chunk-5CVPQC2F.js";
24
+ } from "./chunk-CUAL7MH6.js";
25
25
  import {
26
26
  getZeroAgentUserConnectors,
27
27
  getZeroBillingStatus,
28
28
  listZeroConnectorCatalog,
29
29
  listZeroConnectorCatalogStatus
30
- } from "./chunk-ZSP7ISNV.js";
30
+ } from "./chunk-QL2BWE6J.js";
31
31
  import {
32
32
  generateWebImage,
33
33
  generateWebVideo,
34
34
  generateWebVoice
35
- } from "./chunk-2USAOUQI.js";
35
+ } from "./chunk-BSDS7GCS.js";
36
36
  import {
37
37
  planUpgradeUrl
38
38
  } from "./chunk-W75R7EZF.js";
39
39
  import {
40
40
  getPlatformOrigin
41
- } from "./chunk-WIO4VCT5.js";
41
+ } from "./chunk-RGHA7C2O.js";
42
42
  import "./chunk-SB7EZ2ZO.js";
43
43
  import {
44
44
  ApiRequestError,
45
45
  source_default,
46
46
  withErrorHandler
47
- } from "./chunk-CGLTWZX7.js";
48
- import "./chunk-K3F4FDYI.js";
47
+ } from "./chunk-E2DKMMGY.js";
48
+ import "./chunk-DK3C2ME6.js";
49
49
  import {
50
50
  Command,
51
51
  InvalidArgumentError,
@@ -2751,4 +2751,4 @@ var generateCommand = new Command().name("generate").description(
2751
2751
  export {
2752
2752
  generateCommand
2753
2753
  };
2754
- //# sourceMappingURL=generate-SDDS6YWC.js.map
2754
+ //# sourceMappingURL=generate-PTBOIM6B.js.map
@@ -5,13 +5,13 @@ import {
5
5
  completeGithubFileUpload,
6
6
  downloadGithubFile,
7
7
  initGithubFileUpload
8
- } from "./chunk-ZSP7ISNV.js";
9
- import "./chunk-2USAOUQI.js";
8
+ } from "./chunk-QL2BWE6J.js";
9
+ import "./chunk-BSDS7GCS.js";
10
10
  import "./chunk-SB7EZ2ZO.js";
11
11
  import {
12
12
  withErrorHandler
13
- } from "./chunk-CGLTWZX7.js";
14
- import "./chunk-K3F4FDYI.js";
13
+ } from "./chunk-E2DKMMGY.js";
14
+ import "./chunk-DK3C2ME6.js";
15
15
  import {
16
16
  Command
17
17
  } from "./chunk-LD4ZVU4O.js";
@@ -201,4 +201,4 @@ Examples:
201
201
  export {
202
202
  zeroGithubCommand
203
203
  };
204
- //# sourceMappingURL=github-6KEMKHRG.js.map
204
+ //# sourceMappingURL=github-62XSFEWF.js.map
@@ -10,13 +10,13 @@ import {
10
10
  getGoal,
11
11
  pauseGoal,
12
12
  resumeGoal
13
- } from "./chunk-ZSP7ISNV.js";
14
- import "./chunk-2USAOUQI.js";
13
+ } from "./chunk-QL2BWE6J.js";
14
+ import "./chunk-BSDS7GCS.js";
15
15
  import "./chunk-SB7EZ2ZO.js";
16
16
  import {
17
17
  withErrorHandler
18
- } from "./chunk-CGLTWZX7.js";
19
- import "./chunk-K3F4FDYI.js";
18
+ } from "./chunk-E2DKMMGY.js";
19
+ import "./chunk-DK3C2ME6.js";
20
20
  import {
21
21
  Command
22
22
  } from "./chunk-LD4ZVU4O.js";
@@ -78,4 +78,4 @@ var zeroGoalCommand = new Command().name("goal").description("Manage the current
78
78
  export {
79
79
  zeroGoalCommand
80
80
  };
81
- //# sourceMappingURL=goal-5ER7N3Z3.js.map
81
+ //# sourceMappingURL=goal-VRWB2AS3.js.map