@vm0/cli 9.236.0 → 9.237.1
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/{agent-H37ZBBFD.js → agent-G5NJDTZD.js} +5 -5
- package/{banking-IRMYJKNC.js → banking-RE4Y55OB.js} +3 -3
- package/{chat-NZ6TRVR5.js → chat-TRC4V4LW.js} +4 -4
- package/{chunk-73CTMK6P.js → chunk-4KHAQF4M.js} +2 -2
- package/{chunk-VM5QYVD6.js → chunk-AJUYZVZU.js} +2 -2
- package/{chunk-MGWKM7UC.js → chunk-DNWL4DAH.js} +2 -2
- package/{chunk-76G34YAK.js → chunk-FAIVSEFV.js} +2 -2
- package/{chunk-COXWIO7D.js → chunk-G55J25QR.js} +218 -12
- package/chunk-G55J25QR.js.map +1 -0
- package/{chunk-C62RB4M2.js → chunk-LAUWX3TW.js} +4 -4
- package/{chunk-64IW3URY.js → chunk-RNGEJBP2.js} +3 -3
- package/{chunk-26HAGVMF.js → chunk-SSQSKO3U.js} +2 -2
- package/{chunk-RQQ7SG5F.js → chunk-UFRPDBLC.js} +19 -4
- package/{chunk-RQQ7SG5F.js.map → chunk-UFRPDBLC.js.map} +1 -1
- package/{chunk-W4AAAM2I.js → chunk-ZJOHVGBX.js} +2 -2
- package/{chunk-RTJRFBZ4.js → chunk-ZWYDJ3AZ.js} +2 -2
- package/{computer-use-PHPLG6PO.js → computer-use-GESXXHFG.js} +3 -3
- package/{connector-37AVV3HQ.js → connector-SDQMMKIT.js} +4 -4
- package/{credit-IOSI7BHB.js → credit-JTKH4UMZ.js} +4 -4
- package/{developer-support-CVZDCWUJ.js → developer-support-2JW3QPDC.js} +3 -3
- package/{doctor-2NROVNEM.js → doctor-VPBYKX77.js} +7 -7
- package/{generate-NA2R3CE4.js → generate-F7ZPK6IV.js} +4 -4
- package/{github-U7ICR34Q.js → github-GDPM257C.js} +3 -3
- package/{goal-LVH3SPUN.js → goal-M2AYUQJ4.js} +3 -3
- package/{host-NFZIDNFL.js → host-OJR3FPYM.js} +3 -3
- package/index.js +14 -14
- package/{logs-EANNRUOI.js → logs-H5JYXHA6.js} +7 -7
- package/{maps-CWNOZN4X.js → maps-PLCIA2DA.js} +3 -3
- package/{memory-2W5HCDIM.js → memory-EJSR4TVG.js} +3 -3
- package/{model-7QO2KBZU.js → model-5YKXB5ND.js} +4 -4
- package/{model-provider-HFNCG657.js → model-provider-4EUN45KQ.js} +4 -4
- package/{org-TTJVCI6O.js → org-NY3ZQYMJ.js} +3 -3
- package/package.json +1 -1
- package/{phone-R6ZBFTQQ.js → phone-LJFIA4YV.js} +3 -3
- package/{preference-JACH7UCD.js → preference-H4WF5NXY.js} +3 -3
- package/{relationship-D4RXZL2F.js → relationship-2OHALC26.js} +3 -3
- package/{resource-53GNP4BE.js → resource-2DLQU6OU.js} +3 -3
- package/{search-CSNF5OZC.js → search-BDC7KHXU.js} +7 -7
- package/{secret-M5GRCTGE.js → secret-DYZ2K6QX.js} +4 -4
- package/{slack-QBSJ5CLK.js → slack-DRX6JAGE.js} +3 -3
- package/teams-K2XTVCGT.js +284 -0
- package/teams-K2XTVCGT.js.map +1 -0
- package/{telegram-2P2ZZYU4.js → telegram-XNU3XVPW.js} +3 -3
- package/{variable-JM7W3UQJ.js → variable-J5FV4HHC.js} +3 -3
- package/{video-HONK7KHI.js → video-HSB2R7TK.js} +2 -2
- package/{web-3NQFBVFX.js → web-MRZE6CNW.js} +3 -3
- package/{whoami-WYOS2RAK.js → whoami-5SM2Z5BX.js} +5 -5
- package/{workflow-AYPDFQOY.js → workflow-6ZJZKTJ5.js} +3 -3
- package/zero.js +44 -33
- package/zero.js.map +1 -1
- package/chunk-COXWIO7D.js.map +0 -1
- /package/{agent-H37ZBBFD.js.map → agent-G5NJDTZD.js.map} +0 -0
- /package/{banking-IRMYJKNC.js.map → banking-RE4Y55OB.js.map} +0 -0
- /package/{chat-NZ6TRVR5.js.map → chat-TRC4V4LW.js.map} +0 -0
- /package/{chunk-73CTMK6P.js.map → chunk-4KHAQF4M.js.map} +0 -0
- /package/{chunk-VM5QYVD6.js.map → chunk-AJUYZVZU.js.map} +0 -0
- /package/{chunk-MGWKM7UC.js.map → chunk-DNWL4DAH.js.map} +0 -0
- /package/{chunk-76G34YAK.js.map → chunk-FAIVSEFV.js.map} +0 -0
- /package/{chunk-C62RB4M2.js.map → chunk-LAUWX3TW.js.map} +0 -0
- /package/{chunk-64IW3URY.js.map → chunk-RNGEJBP2.js.map} +0 -0
- /package/{chunk-26HAGVMF.js.map → chunk-SSQSKO3U.js.map} +0 -0
- /package/{chunk-W4AAAM2I.js.map → chunk-ZJOHVGBX.js.map} +0 -0
- /package/{chunk-RTJRFBZ4.js.map → chunk-ZWYDJ3AZ.js.map} +0 -0
- /package/{computer-use-PHPLG6PO.js.map → computer-use-GESXXHFG.js.map} +0 -0
- /package/{connector-37AVV3HQ.js.map → connector-SDQMMKIT.js.map} +0 -0
- /package/{credit-IOSI7BHB.js.map → credit-JTKH4UMZ.js.map} +0 -0
- /package/{developer-support-CVZDCWUJ.js.map → developer-support-2JW3QPDC.js.map} +0 -0
- /package/{doctor-2NROVNEM.js.map → doctor-VPBYKX77.js.map} +0 -0
- /package/{generate-NA2R3CE4.js.map → generate-F7ZPK6IV.js.map} +0 -0
- /package/{github-U7ICR34Q.js.map → github-GDPM257C.js.map} +0 -0
- /package/{goal-LVH3SPUN.js.map → goal-M2AYUQJ4.js.map} +0 -0
- /package/{host-NFZIDNFL.js.map → host-OJR3FPYM.js.map} +0 -0
- /package/{logs-EANNRUOI.js.map → logs-H5JYXHA6.js.map} +0 -0
- /package/{maps-CWNOZN4X.js.map → maps-PLCIA2DA.js.map} +0 -0
- /package/{memory-2W5HCDIM.js.map → memory-EJSR4TVG.js.map} +0 -0
- /package/{model-7QO2KBZU.js.map → model-5YKXB5ND.js.map} +0 -0
- /package/{model-provider-HFNCG657.js.map → model-provider-4EUN45KQ.js.map} +0 -0
- /package/{org-TTJVCI6O.js.map → org-NY3ZQYMJ.js.map} +0 -0
- /package/{phone-R6ZBFTQQ.js.map → phone-LJFIA4YV.js.map} +0 -0
- /package/{preference-JACH7UCD.js.map → preference-H4WF5NXY.js.map} +0 -0
- /package/{relationship-D4RXZL2F.js.map → relationship-2OHALC26.js.map} +0 -0
- /package/{resource-53GNP4BE.js.map → resource-2DLQU6OU.js.map} +0 -0
- /package/{search-CSNF5OZC.js.map → search-BDC7KHXU.js.map} +0 -0
- /package/{secret-M5GRCTGE.js.map → secret-DYZ2K6QX.js.map} +0 -0
- /package/{slack-QBSJ5CLK.js.map → slack-DRX6JAGE.js.map} +0 -0
- /package/{telegram-2P2ZZYU4.js.map → telegram-XNU3XVPW.js.map} +0 -0
- /package/{variable-JM7W3UQJ.js.map → variable-J5FV4HHC.js.map} +0 -0
- /package/{video-HONK7KHI.js.map → video-HSB2R7TK.js.map} +0 -0
- /package/{web-3NQFBVFX.js.map → web-MRZE6CNW.js.map} +0 -0
- /package/{whoami-WYOS2RAK.js.map → whoami-5SM2Z5BX.js.map} +0 -0
- /package/{workflow-AYPDFQOY.js.map → workflow-6ZJZKTJ5.js.map} +0 -0
|
@@ -4,10 +4,10 @@ const require = __createRequire(import.meta.url);
|
|
|
4
4
|
import {
|
|
5
5
|
loadConnectorPermissionInfos,
|
|
6
6
|
policyIcon
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-ZJOHVGBX.js";
|
|
8
8
|
import {
|
|
9
9
|
permissionGrantsToFirewallPolicies
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-AJUYZVZU.js";
|
|
11
11
|
import {
|
|
12
12
|
isInteractive,
|
|
13
13
|
promptConfirm
|
|
@@ -24,10 +24,10 @@ import {
|
|
|
24
24
|
listZeroUserPermissionGrants,
|
|
25
25
|
updateZeroAgent,
|
|
26
26
|
updateZeroAgentInstructions
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-G55J25QR.js";
|
|
28
28
|
import {
|
|
29
29
|
withErrorHandler
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-DNWL4DAH.js";
|
|
31
31
|
import {
|
|
32
32
|
source_default
|
|
33
33
|
} from "./chunk-JUTUEPIR.js";
|
|
@@ -595,4 +595,4 @@ Notes:
|
|
|
595
595
|
export {
|
|
596
596
|
zeroAgentCommand
|
|
597
597
|
};
|
|
598
|
-
//# sourceMappingURL=agent-
|
|
598
|
+
//# sourceMappingURL=agent-G5NJDTZD.js.map
|
|
@@ -4,10 +4,10 @@ const require = __createRequire(import.meta.url);
|
|
|
4
4
|
import "./chunk-LTDQISD7.js";
|
|
5
5
|
import {
|
|
6
6
|
callZeroBanking
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-G55J25QR.js";
|
|
8
8
|
import {
|
|
9
9
|
withErrorHandler
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-DNWL4DAH.js";
|
|
11
11
|
import {
|
|
12
12
|
source_default
|
|
13
13
|
} from "./chunk-JUTUEPIR.js";
|
|
@@ -115,4 +115,4 @@ Notes:
|
|
|
115
115
|
export {
|
|
116
116
|
zeroBankingCommand
|
|
117
117
|
};
|
|
118
|
-
//# sourceMappingURL=banking-
|
|
118
|
+
//# sourceMappingURL=banking-RE4Y55OB.js.map
|
|
@@ -3,17 +3,17 @@ import { createRequire as __createRequire } from "node:module";
|
|
|
3
3
|
const require = __createRequire(import.meta.url);
|
|
4
4
|
import {
|
|
5
5
|
formatModelProviderRoute
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-SSQSKO3U.js";
|
|
7
7
|
import "./chunk-LTDQISD7.js";
|
|
8
8
|
import {
|
|
9
9
|
getZeroChatThread,
|
|
10
10
|
listZeroModelPolicies,
|
|
11
11
|
renameZeroChatThread,
|
|
12
12
|
updateZeroChatThreadModelSelection
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-G55J25QR.js";
|
|
14
14
|
import {
|
|
15
15
|
withErrorHandler
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-DNWL4DAH.js";
|
|
17
17
|
import {
|
|
18
18
|
source_default
|
|
19
19
|
} from "./chunk-JUTUEPIR.js";
|
|
@@ -244,4 +244,4 @@ Examples:
|
|
|
244
244
|
export {
|
|
245
245
|
zeroChatCommand
|
|
246
246
|
};
|
|
247
|
-
//# sourceMappingURL=chat-
|
|
247
|
+
//# sourceMappingURL=chat-TRC4V4LW.js.map
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
CONNECTOR_TYPES,
|
|
6
6
|
CONNECTOR_TYPE_KEYS,
|
|
7
7
|
connectorAuthMethodIdSchema
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-G55J25QR.js";
|
|
9
9
|
import {
|
|
10
10
|
init_esm_shims
|
|
11
11
|
} from "./chunk-DIRAZ3YX.js";
|
|
@@ -121,4 +121,4 @@ export {
|
|
|
121
121
|
getConnectorStoredSecretDisplayInfo,
|
|
122
122
|
getDiagnosticConnectorTypeForRuntimeEnvName
|
|
123
123
|
};
|
|
124
|
-
//# sourceMappingURL=chunk-
|
|
124
|
+
//# sourceMappingURL=chunk-4KHAQF4M.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-
|
|
6
|
+
} from "./chunk-G55J25QR.js";
|
|
7
7
|
import {
|
|
8
8
|
init_esm_shims
|
|
9
9
|
} from "./chunk-DIRAZ3YX.js";
|
|
@@ -1251,4 +1251,4 @@ export {
|
|
|
1251
1251
|
getFirewallPermissionSummary,
|
|
1252
1252
|
loadFirewallPermissionMetadata
|
|
1253
1253
|
};
|
|
1254
|
-
//# sourceMappingURL=chunk-
|
|
1254
|
+
//# sourceMappingURL=chunk-AJUYZVZU.js.map
|
|
@@ -14959,7 +14959,7 @@ function createCliClientHeaderInjector(options) {
|
|
|
14959
14959
|
};
|
|
14960
14960
|
}
|
|
14961
14961
|
var addDefaultCliClientHeaders = createCliClientHeaderInjector({
|
|
14962
|
-
clientVersion: "9.
|
|
14962
|
+
clientVersion: "9.237.1"
|
|
14963
14963
|
});
|
|
14964
14964
|
function addCliClientHeaders(headers) {
|
|
14965
14965
|
addDefaultCliClientHeaders(headers);
|
|
@@ -15833,4 +15833,4 @@ export {
|
|
|
15833
15833
|
generateWebVideo,
|
|
15834
15834
|
transcribeAudio
|
|
15835
15835
|
};
|
|
15836
|
-
//# sourceMappingURL=chunk-
|
|
15836
|
+
//# sourceMappingURL=chunk-DNWL4DAH.js.map
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
splitPathSegments,
|
|
11
11
|
validateAuthBaseUrl,
|
|
12
12
|
validateBaseUrl
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-G55J25QR.js";
|
|
14
14
|
import {
|
|
15
15
|
init_esm_shims
|
|
16
16
|
} from "./chunk-DIRAZ3YX.js";
|
|
@@ -1175,4 +1175,4 @@ export {
|
|
|
1175
1175
|
matchFirewallBaseUrl,
|
|
1176
1176
|
matchFirewallRequestDecision
|
|
1177
1177
|
};
|
|
1178
|
-
//# sourceMappingURL=chunk-
|
|
1178
|
+
//# sourceMappingURL=chunk-FAIVSEFV.js.map
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
headersWithCliClientHeaders,
|
|
15
15
|
initClient,
|
|
16
16
|
initContract
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-DNWL4DAH.js";
|
|
18
18
|
import {
|
|
19
19
|
init_esm_shims
|
|
20
20
|
} from "./chunk-DIRAZ3YX.js";
|
|
@@ -22381,6 +22381,11 @@ var secretConnectorMetadataMapSchema = external_exports.record(
|
|
|
22381
22381
|
var storedExecutionContextSchema = external_exports.object({
|
|
22382
22382
|
storageManifest: storageManifestSchema.nullable(),
|
|
22383
22383
|
environment: external_exports.record(external_exports.string(), external_exports.string()).nullable(),
|
|
22384
|
+
// API-only references used to reconstruct runner masking values from the
|
|
22385
|
+
// stored environment. Missing means legacy/stripped data, null means no
|
|
22386
|
+
// persistent secret map, and array order/repetition follows secret-map values.
|
|
22387
|
+
// This field must not be included in the runner-facing ExecutionContext.
|
|
22388
|
+
secretValueEnvironmentKeys: external_exports.array(external_exports.string()).nullable().optional(),
|
|
22384
22389
|
// Connector-owned runtime vars used by proxy/firewall template resolution.
|
|
22385
22390
|
// User-provided run vars stay in agent_runs.vars and are merged at claim time.
|
|
22386
22391
|
vars: external_exports.record(external_exports.string(), external_exports.string()).nullable().optional(),
|
|
@@ -26988,6 +26993,65 @@ var integrationsTelegramMessageContract = c34.router({
|
|
|
26988
26993
|
summary: "Send a Telegram message via org bot token"
|
|
26989
26994
|
}
|
|
26990
26995
|
});
|
|
26996
|
+
var teamsAdaptiveCardSchema = external_exports.object({
|
|
26997
|
+
type: external_exports.literal("AdaptiveCard"),
|
|
26998
|
+
version: external_exports.string().min(1),
|
|
26999
|
+
body: external_exports.array(external_exports.record(external_exports.string(), external_exports.unknown())).optional(),
|
|
27000
|
+
actions: external_exports.array(external_exports.record(external_exports.string(), external_exports.unknown())).optional()
|
|
27001
|
+
}).passthrough();
|
|
27002
|
+
var sendTeamsMessageBodySchema = external_exports.object({
|
|
27003
|
+
conversationId: external_exports.string().min(1, "Conversation ID is required").optional(),
|
|
27004
|
+
user: external_exports.string().min(1, "Teams user ID is required").optional(),
|
|
27005
|
+
text: external_exports.string().min(1, "Message text is required").optional(),
|
|
27006
|
+
activityId: external_exports.string().min(1, "Activity ID is required").optional(),
|
|
27007
|
+
card: teamsAdaptiveCardSchema.optional()
|
|
27008
|
+
}).refine(
|
|
27009
|
+
(body) => {
|
|
27010
|
+
return Boolean(body.conversationId) !== Boolean(body.user);
|
|
27011
|
+
},
|
|
27012
|
+
{
|
|
27013
|
+
message: "Exactly one of conversationId or user is required",
|
|
27014
|
+
path: ["conversationId"]
|
|
27015
|
+
}
|
|
27016
|
+
).refine(
|
|
27017
|
+
(body) => {
|
|
27018
|
+
return Boolean(body.text) || Boolean(body.card);
|
|
27019
|
+
},
|
|
27020
|
+
{
|
|
27021
|
+
message: "Message text or card is required",
|
|
27022
|
+
path: ["text"]
|
|
27023
|
+
}
|
|
27024
|
+
).refine(
|
|
27025
|
+
(body) => {
|
|
27026
|
+
return !(body.user && body.activityId);
|
|
27027
|
+
},
|
|
27028
|
+
{
|
|
27029
|
+
message: "activityId can only be used with conversationId",
|
|
27030
|
+
path: ["activityId"]
|
|
27031
|
+
}
|
|
27032
|
+
);
|
|
27033
|
+
var sendTeamsMessageResponseSchema = external_exports.object({
|
|
27034
|
+
ok: external_exports.literal(true),
|
|
27035
|
+
activityId: external_exports.string().optional(),
|
|
27036
|
+
conversationId: external_exports.string()
|
|
27037
|
+
});
|
|
27038
|
+
var integrationsTeamsMessageContract = c34.router({
|
|
27039
|
+
sendMessage: {
|
|
27040
|
+
method: "POST",
|
|
27041
|
+
path: "/api/zero/integrations/teams/message",
|
|
27042
|
+
headers: authHeadersSchema,
|
|
27043
|
+
body: sendTeamsMessageBodySchema,
|
|
27044
|
+
responses: {
|
|
27045
|
+
200: sendTeamsMessageResponseSchema,
|
|
27046
|
+
400: apiErrorSchema,
|
|
27047
|
+
401: apiErrorSchema,
|
|
27048
|
+
403: apiErrorSchema,
|
|
27049
|
+
404: apiErrorSchema,
|
|
27050
|
+
502: apiErrorSchema
|
|
27051
|
+
},
|
|
27052
|
+
summary: "Send a Microsoft Teams message via org bot"
|
|
27053
|
+
}
|
|
27054
|
+
});
|
|
26991
27055
|
var sendPhoneMessageBodySchema = external_exports.object({
|
|
26992
27056
|
agentphoneAgentId: external_exports.string().min(1, "AgentPhone agent ID is required").optional(),
|
|
26993
27057
|
toNumber: external_exports.string().min(1, "Phone number is required"),
|
|
@@ -27126,6 +27190,34 @@ var integrationsTelegramUploadInitContract = c34.router({
|
|
|
27126
27190
|
summary: "Get a pre-signed upload URL for Telegram file delivery"
|
|
27127
27191
|
}
|
|
27128
27192
|
});
|
|
27193
|
+
var teamsUploadInitBodySchema = external_exports.object({
|
|
27194
|
+
filename: external_exports.string().min(1, "Filename is required").max(255),
|
|
27195
|
+
contentType: external_exports.string().min(1, "Content type is required").max(200),
|
|
27196
|
+
length: external_exports.number().int().positive("File length must be a positive integer")
|
|
27197
|
+
});
|
|
27198
|
+
var teamsUploadInitResponseSchema = external_exports.object({
|
|
27199
|
+
uploadId: external_exports.string().uuid(),
|
|
27200
|
+
uploadUrl: external_exports.string(),
|
|
27201
|
+
fileUrl: external_exports.string(),
|
|
27202
|
+
filename: external_exports.string(),
|
|
27203
|
+
contentType: external_exports.string(),
|
|
27204
|
+
size: external_exports.number().int().nonnegative()
|
|
27205
|
+
});
|
|
27206
|
+
var integrationsTeamsUploadInitContract = c34.router({
|
|
27207
|
+
init: {
|
|
27208
|
+
method: "POST",
|
|
27209
|
+
path: "/api/zero/integrations/teams/upload-file/init",
|
|
27210
|
+
headers: authHeadersSchema,
|
|
27211
|
+
body: teamsUploadInitBodySchema,
|
|
27212
|
+
responses: {
|
|
27213
|
+
200: teamsUploadInitResponseSchema,
|
|
27214
|
+
400: apiErrorSchema,
|
|
27215
|
+
401: apiErrorSchema,
|
|
27216
|
+
403: apiErrorSchema
|
|
27217
|
+
},
|
|
27218
|
+
summary: "Get a pre-signed upload URL for Microsoft Teams file delivery"
|
|
27219
|
+
}
|
|
27220
|
+
});
|
|
27129
27221
|
var telegramUploadCompleteBodySchema = external_exports.object({
|
|
27130
27222
|
uploadId: external_exports.string().uuid("Upload ID must be a UUID"),
|
|
27131
27223
|
botId: external_exports.string().min(1, "Bot ID is required"),
|
|
@@ -27160,6 +27252,38 @@ var integrationsTelegramUploadCompleteContract = c34.router({
|
|
|
27160
27252
|
summary: "Finalize Telegram file upload and send it to a chat"
|
|
27161
27253
|
}
|
|
27162
27254
|
});
|
|
27255
|
+
var teamsUploadCompleteBodySchema = external_exports.object({
|
|
27256
|
+
uploadId: external_exports.string().uuid("Upload ID must be a UUID"),
|
|
27257
|
+
conversationId: external_exports.string().min(1, "Conversation ID is required"),
|
|
27258
|
+
activityId: external_exports.string().min(1, "Activity ID is required").optional(),
|
|
27259
|
+
contentType: external_exports.string().min(1).max(200).optional(),
|
|
27260
|
+
text: external_exports.string().max(4e3).optional()
|
|
27261
|
+
});
|
|
27262
|
+
var teamsUploadCompleteResponseSchema = external_exports.object({
|
|
27263
|
+
activityId: external_exports.string().optional(),
|
|
27264
|
+
conversationId: external_exports.string(),
|
|
27265
|
+
filename: external_exports.string(),
|
|
27266
|
+
mimetype: external_exports.string(),
|
|
27267
|
+
size: external_exports.number().int().nonnegative(),
|
|
27268
|
+
url: external_exports.string()
|
|
27269
|
+
});
|
|
27270
|
+
var integrationsTeamsUploadCompleteContract = c34.router({
|
|
27271
|
+
complete: {
|
|
27272
|
+
method: "POST",
|
|
27273
|
+
path: "/api/zero/integrations/teams/upload-file/complete",
|
|
27274
|
+
headers: authHeadersSchema,
|
|
27275
|
+
body: teamsUploadCompleteBodySchema,
|
|
27276
|
+
responses: {
|
|
27277
|
+
200: teamsUploadCompleteResponseSchema,
|
|
27278
|
+
400: apiErrorSchema,
|
|
27279
|
+
401: apiErrorSchema,
|
|
27280
|
+
403: apiErrorSchema,
|
|
27281
|
+
404: apiErrorSchema,
|
|
27282
|
+
502: apiErrorSchema
|
|
27283
|
+
},
|
|
27284
|
+
summary: "Finalize Microsoft Teams file upload and send it to a conversation"
|
|
27285
|
+
}
|
|
27286
|
+
});
|
|
27163
27287
|
var githubUploadInitBodySchema = external_exports.object({
|
|
27164
27288
|
filename: external_exports.string().min(1, "Filename is required").max(255),
|
|
27165
27289
|
contentType: external_exports.string().min(1, "Content type is required").max(200),
|
|
@@ -27476,11 +27600,89 @@ async function downloadTelegramFile(fileId, botId, outPath) {
|
|
|
27476
27600
|
return { path: outPath, mimetype, size };
|
|
27477
27601
|
}
|
|
27478
27602
|
|
|
27479
|
-
// src/lib/api/domains/integrations-
|
|
27603
|
+
// src/lib/api/domains/integrations-teams.ts
|
|
27480
27604
|
init_esm_shims();
|
|
27481
27605
|
import { createWriteStream as createWriteStream3 } from "fs";
|
|
27482
27606
|
import { Readable as Readable3 } from "stream";
|
|
27483
27607
|
import { pipeline as pipeline3 } from "stream/promises";
|
|
27608
|
+
async function sendTeamsMessage(body) {
|
|
27609
|
+
const config = await getClientConfig();
|
|
27610
|
+
const client = initClient(integrationsTeamsMessageContract, config);
|
|
27611
|
+
const result = await client.sendMessage({ body, headers: {} });
|
|
27612
|
+
if (result.status === 200) {
|
|
27613
|
+
return result.body;
|
|
27614
|
+
}
|
|
27615
|
+
handleError(result, "Failed to send Microsoft Teams message");
|
|
27616
|
+
}
|
|
27617
|
+
async function initTeamsFileUpload(body) {
|
|
27618
|
+
const config = await getClientConfig();
|
|
27619
|
+
const client = initClient(integrationsTeamsUploadInitContract, config);
|
|
27620
|
+
const result = await client.init({ body, headers: {} });
|
|
27621
|
+
if (result.status === 200) {
|
|
27622
|
+
return result.body;
|
|
27623
|
+
}
|
|
27624
|
+
handleError(result, "Failed to initialize Microsoft Teams file upload");
|
|
27625
|
+
}
|
|
27626
|
+
async function completeTeamsFileUpload(body) {
|
|
27627
|
+
const config = await getClientConfig();
|
|
27628
|
+
const client = initClient(integrationsTeamsUploadCompleteContract, config);
|
|
27629
|
+
const result = await client.complete({ body, headers: {} });
|
|
27630
|
+
if (result.status === 200) {
|
|
27631
|
+
return result.body;
|
|
27632
|
+
}
|
|
27633
|
+
handleError(result, "Failed to complete Microsoft Teams file upload");
|
|
27634
|
+
}
|
|
27635
|
+
async function downloadTeamsFile(fileId, outPath) {
|
|
27636
|
+
const baseUrl = await getBaseUrl();
|
|
27637
|
+
const token = await getActiveToken();
|
|
27638
|
+
if (!token) {
|
|
27639
|
+
throw new ApiRequestError("Not authenticated", "UNAUTHORIZED", 401);
|
|
27640
|
+
}
|
|
27641
|
+
const url = new URL("/api/zero/integrations/teams/download-file", baseUrl);
|
|
27642
|
+
url.searchParams.set("file_id", fileId);
|
|
27643
|
+
const headers = {
|
|
27644
|
+
Authorization: `Bearer ${token}`
|
|
27645
|
+
};
|
|
27646
|
+
const bypassSecret = process.env.VERCEL_AUTOMATION_BYPASS_SECRET;
|
|
27647
|
+
if (bypassSecret) {
|
|
27648
|
+
headers["x-vercel-protection-bypass"] = bypassSecret;
|
|
27649
|
+
}
|
|
27650
|
+
const response = await fetch(url, {
|
|
27651
|
+
headers: headersWithCliClientHeaders(headers)
|
|
27652
|
+
});
|
|
27653
|
+
if (!response.ok) {
|
|
27654
|
+
let message = `Failed to download Microsoft Teams file (HTTP ${response.status})`;
|
|
27655
|
+
let code = "UNKNOWN";
|
|
27656
|
+
try {
|
|
27657
|
+
const body = await response.json();
|
|
27658
|
+
if (body.error?.message) message = body.error.message;
|
|
27659
|
+
if (body.error?.code) code = body.error.code;
|
|
27660
|
+
} catch {
|
|
27661
|
+
}
|
|
27662
|
+
throw new ApiRequestError(message, code, response.status);
|
|
27663
|
+
}
|
|
27664
|
+
if (!response.body) {
|
|
27665
|
+
throw new ApiRequestError(
|
|
27666
|
+
"Microsoft Teams download response has no body",
|
|
27667
|
+
"EMPTY_BODY",
|
|
27668
|
+
502
|
|
27669
|
+
);
|
|
27670
|
+
}
|
|
27671
|
+
const mimetype = response.headers.get("x-file-mimetype") ?? response.headers.get("content-type") ?? "application/octet-stream";
|
|
27672
|
+
await pipeline3(
|
|
27673
|
+
Readable3.fromWeb(response.body),
|
|
27674
|
+
createWriteStream3(outPath)
|
|
27675
|
+
);
|
|
27676
|
+
const contentLengthHeader = response.headers.get("content-length");
|
|
27677
|
+
const size = contentLengthHeader ? Number(contentLengthHeader) : 0;
|
|
27678
|
+
return { path: outPath, mimetype, size };
|
|
27679
|
+
}
|
|
27680
|
+
|
|
27681
|
+
// src/lib/api/domains/integrations-github.ts
|
|
27682
|
+
init_esm_shims();
|
|
27683
|
+
import { createWriteStream as createWriteStream4 } from "fs";
|
|
27684
|
+
import { Readable as Readable4 } from "stream";
|
|
27685
|
+
import { pipeline as pipeline4 } from "stream/promises";
|
|
27484
27686
|
async function initGithubFileUpload(body) {
|
|
27485
27687
|
const config = await getClientConfig();
|
|
27486
27688
|
const client = initClient(integrationsGithubUploadInitContract, config);
|
|
@@ -27539,9 +27741,9 @@ async function downloadGithubFile(fileUrl, outPath, filename) {
|
|
|
27539
27741
|
);
|
|
27540
27742
|
}
|
|
27541
27743
|
const mimetype = response.headers.get("x-file-mimetype") ?? response.headers.get("content-type") ?? "application/octet-stream";
|
|
27542
|
-
await
|
|
27543
|
-
|
|
27544
|
-
|
|
27744
|
+
await pipeline4(
|
|
27745
|
+
Readable4.fromWeb(response.body),
|
|
27746
|
+
createWriteStream4(outPath)
|
|
27545
27747
|
);
|
|
27546
27748
|
const contentLengthHeader = response.headers.get("content-length");
|
|
27547
27749
|
const size = contentLengthHeader ? Number(contentLengthHeader) : 0;
|
|
@@ -27550,9 +27752,9 @@ async function downloadGithubFile(fileUrl, outPath, filename) {
|
|
|
27550
27752
|
|
|
27551
27753
|
// src/lib/api/domains/integrations-phone.ts
|
|
27552
27754
|
init_esm_shims();
|
|
27553
|
-
import { createWriteStream as
|
|
27554
|
-
import { Readable as
|
|
27555
|
-
import { pipeline as
|
|
27755
|
+
import { createWriteStream as createWriteStream5 } from "fs";
|
|
27756
|
+
import { Readable as Readable5 } from "stream";
|
|
27757
|
+
import { pipeline as pipeline5 } from "stream/promises";
|
|
27556
27758
|
async function sendPhoneMessage(body) {
|
|
27557
27759
|
const config = await getClientConfig();
|
|
27558
27760
|
const client = initClient(integrationsPhoneMessageContract, config);
|
|
@@ -27617,9 +27819,9 @@ async function downloadPhoneFile(fileId, outPath) {
|
|
|
27617
27819
|
);
|
|
27618
27820
|
}
|
|
27619
27821
|
const mimetype = response.headers.get("x-file-mimetype") ?? response.headers.get("content-type") ?? "application/octet-stream";
|
|
27620
|
-
await
|
|
27621
|
-
|
|
27622
|
-
|
|
27822
|
+
await pipeline5(
|
|
27823
|
+
Readable5.fromWeb(response.body),
|
|
27824
|
+
createWriteStream5(outPath)
|
|
27623
27825
|
);
|
|
27624
27826
|
const contentLengthHeader = response.headers.get("content-length");
|
|
27625
27827
|
const size = contentLengthHeader ? Number(contentLengthHeader) : 0;
|
|
@@ -29376,6 +29578,10 @@ export {
|
|
|
29376
29578
|
initTelegramFileUpload,
|
|
29377
29579
|
completeTelegramFileUpload,
|
|
29378
29580
|
downloadTelegramFile,
|
|
29581
|
+
sendTeamsMessage,
|
|
29582
|
+
initTeamsFileUpload,
|
|
29583
|
+
completeTeamsFileUpload,
|
|
29584
|
+
downloadTeamsFile,
|
|
29379
29585
|
initGithubFileUpload,
|
|
29380
29586
|
completeGithubFileUpload,
|
|
29381
29587
|
downloadGithubFile,
|
|
@@ -29428,4 +29634,4 @@ export {
|
|
|
29428
29634
|
completeHostedSite,
|
|
29429
29635
|
getHostedSiteFiles
|
|
29430
29636
|
};
|
|
29431
|
-
//# sourceMappingURL=chunk-
|
|
29637
|
+
//# sourceMappingURL=chunk-G55J25QR.js.map
|