@vm0/cli 9.254.2 → 9.256.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-NSQIRPVB.js → agent-EVQN2LPX.js} +7 -7
- package/{banking-IQ7MX2B4.js → banking-YA4UBYKV.js} +5 -5
- package/browser-K37YB6WN.js +186 -0
- package/browser-K37YB6WN.js.map +1 -0
- package/{chat-SC5PGHDZ.js → chat-UFNIPVLN.js} +6 -6
- package/{chunk-F6JKPYD2.js → chunk-AAZBHQPP.js} +2 -2
- package/{chunk-X6PT2M2I.js → chunk-CIALZM7O.js} +2 -2
- package/{chunk-UUKFGXX5.js → chunk-GF22PXYF.js} +2 -2
- package/{chunk-4MPNBXFO.js → chunk-ITSKDZFI.js} +2 -2
- package/{chunk-SXD7ESWU.js → chunk-KLSQEQC4.js} +82 -151
- package/chunk-KLSQEQC4.js.map +1 -0
- package/{chunk-TV6RSLOX.js → chunk-M4F24YFV.js} +3 -3
- package/{chunk-OTH23BP4.js → chunk-OQSXOSCD.js} +84 -2
- package/chunk-OQSXOSCD.js.map +1 -0
- package/{chunk-BSFDG7MC.js → chunk-P2FBG2BA.js} +2 -2
- package/{chunk-7OBI7V4O.js → chunk-SLUCBVKQ.js} +589 -512
- package/chunk-SLUCBVKQ.js.map +1 -0
- package/{chunk-MNHYBPQB.js → chunk-VQ3ILWFQ.js} +4 -4
- package/{chunk-D4OTAABD.js → chunk-X5FAOKYK.js} +7 -3
- package/chunk-X5FAOKYK.js.map +1 -0
- package/{computer-use-C7D4GLBU.js → computer-use-C6VLY2LY.js} +5 -5
- package/{connector-FW3TFVAJ.js → connector-SJF25IFP.js} +15 -83
- package/connector-SJF25IFP.js.map +1 -0
- package/{credit-YDQVARRO.js → credit-LYZ2HJ6F.js} +7 -7
- package/{developer-support-NPRGXXF2.js → developer-support-3ISSXZCF.js} +5 -5
- package/{doctor-D7DAFSV3.js → doctor-ISR6CR7B.js} +7 -7
- package/{feishu-UDSN4AVE.js → feishu-3MULYZGN.js} +5 -5
- package/{finance-O7WTSZ7W.js → finance-7BH57FKM.js} +5 -5
- package/{generate-ERHBA3S5.js → generate-5RN37TB2.js} +7 -7
- package/{github-LFJ6JXXJ.js → github-V6IISTKM.js} +5 -5
- package/{goal-GFUDKA42.js → goal-VHURZA6I.js} +5 -5
- package/{host-4NPMKE4M.js → host-FPYIZNEY.js} +5 -5
- package/{logs-IAMPNPZU.js → logs-SOU4VJKD.js} +6 -6
- package/{mail-KZJLXDSP.js → mail-CYM7COJU.js} +67 -17
- package/mail-CYM7COJU.js.map +1 -0
- package/{maps-QC6LW3XN.js → maps-M743J55Y.js} +5 -5
- package/{model-ZCBZUROI.js → model-UP6QUEBW.js} +6 -6
- package/{model-provider-KHT4TJAD.js → model-provider-OFR5IFKC.js} +6 -6
- package/{org-PGERW5HL.js → org-TMYRDS6T.js} +5 -5
- package/package.json +1 -1
- package/{people-search-KOWVJQ7J.js → people-search-PGGRVJE2.js} +5 -5
- package/{phone-UDZRVU4K.js → phone-XDSMT3L2.js} +5 -5
- package/{preference-CW4D6H22.js → preference-HJZXDNPF.js} +5 -5
- package/{resource-UTBKHQYI.js → resource-EPIY47XQ.js} +5 -5
- package/{scrape-HSJGZHJP.js → scrape-RARAUZOC.js} +5 -5
- package/{search-E3XYG3EQ.js → search-DXXHHWDZ.js} +6 -6
- package/{secret-FHYLUY5C.js → secret-AGFBP5RY.js} +5 -5
- package/{slack-KNNFCXQL.js → slack-K2QEL2LI.js} +5 -5
- package/{teams-SE2UBCFO.js → teams-KIJXDVOL.js} +5 -5
- package/{telegram-MBCYOZOW.js → telegram-S5K3IMKH.js} +5 -5
- package/{upgrade-HCODAAIE.js → upgrade-6I5DNVPS.js} +4 -4
- package/{variable-VK42DTQ3.js → variable-IRTOV55E.js} +5 -5
- package/{video-5HT4OTPO.js → video-3ZDBT2PC.js} +4 -4
- package/{weather-JYVT7MJV.js → weather-4TPUCJLD.js} +5 -5
- package/{web-4ZYLQGTN.js → web-ZK5I2YXJ.js} +5 -5
- package/{web-search-BUSZ7LN5.js → web-search-OI6ACM3G.js} +5 -5
- package/{whoami-DD32L4F2.js → whoami-FJGFKNBS.js} +7 -7
- package/{workflow-SW7Q4HHX.js → workflow-4ODQQIVH.js} +5 -5
- package/zero.js +54 -44
- package/zero.js.map +1 -1
- package/chunk-7OBI7V4O.js.map +0 -1
- package/chunk-D4OTAABD.js.map +0 -1
- package/chunk-OTH23BP4.js.map +0 -1
- package/chunk-SXD7ESWU.js.map +0 -1
- package/connector-FW3TFVAJ.js.map +0 -1
- package/mail-KZJLXDSP.js.map +0 -1
- /package/{agent-NSQIRPVB.js.map → agent-EVQN2LPX.js.map} +0 -0
- /package/{banking-IQ7MX2B4.js.map → banking-YA4UBYKV.js.map} +0 -0
- /package/{chat-SC5PGHDZ.js.map → chat-UFNIPVLN.js.map} +0 -0
- /package/{chunk-F6JKPYD2.js.map → chunk-AAZBHQPP.js.map} +0 -0
- /package/{chunk-X6PT2M2I.js.map → chunk-CIALZM7O.js.map} +0 -0
- /package/{chunk-UUKFGXX5.js.map → chunk-GF22PXYF.js.map} +0 -0
- /package/{chunk-4MPNBXFO.js.map → chunk-ITSKDZFI.js.map} +0 -0
- /package/{chunk-TV6RSLOX.js.map → chunk-M4F24YFV.js.map} +0 -0
- /package/{chunk-BSFDG7MC.js.map → chunk-P2FBG2BA.js.map} +0 -0
- /package/{chunk-MNHYBPQB.js.map → chunk-VQ3ILWFQ.js.map} +0 -0
- /package/{computer-use-C7D4GLBU.js.map → computer-use-C6VLY2LY.js.map} +0 -0
- /package/{credit-YDQVARRO.js.map → credit-LYZ2HJ6F.js.map} +0 -0
- /package/{developer-support-NPRGXXF2.js.map → developer-support-3ISSXZCF.js.map} +0 -0
- /package/{doctor-D7DAFSV3.js.map → doctor-ISR6CR7B.js.map} +0 -0
- /package/{feishu-UDSN4AVE.js.map → feishu-3MULYZGN.js.map} +0 -0
- /package/{finance-O7WTSZ7W.js.map → finance-7BH57FKM.js.map} +0 -0
- /package/{generate-ERHBA3S5.js.map → generate-5RN37TB2.js.map} +0 -0
- /package/{github-LFJ6JXXJ.js.map → github-V6IISTKM.js.map} +0 -0
- /package/{goal-GFUDKA42.js.map → goal-VHURZA6I.js.map} +0 -0
- /package/{host-4NPMKE4M.js.map → host-FPYIZNEY.js.map} +0 -0
- /package/{logs-IAMPNPZU.js.map → logs-SOU4VJKD.js.map} +0 -0
- /package/{maps-QC6LW3XN.js.map → maps-M743J55Y.js.map} +0 -0
- /package/{model-ZCBZUROI.js.map → model-UP6QUEBW.js.map} +0 -0
- /package/{model-provider-KHT4TJAD.js.map → model-provider-OFR5IFKC.js.map} +0 -0
- /package/{org-PGERW5HL.js.map → org-TMYRDS6T.js.map} +0 -0
- /package/{people-search-KOWVJQ7J.js.map → people-search-PGGRVJE2.js.map} +0 -0
- /package/{phone-UDZRVU4K.js.map → phone-XDSMT3L2.js.map} +0 -0
- /package/{preference-CW4D6H22.js.map → preference-HJZXDNPF.js.map} +0 -0
- /package/{resource-UTBKHQYI.js.map → resource-EPIY47XQ.js.map} +0 -0
- /package/{scrape-HSJGZHJP.js.map → scrape-RARAUZOC.js.map} +0 -0
- /package/{search-E3XYG3EQ.js.map → search-DXXHHWDZ.js.map} +0 -0
- /package/{secret-FHYLUY5C.js.map → secret-AGFBP5RY.js.map} +0 -0
- /package/{slack-KNNFCXQL.js.map → slack-K2QEL2LI.js.map} +0 -0
- /package/{teams-SE2UBCFO.js.map → teams-KIJXDVOL.js.map} +0 -0
- /package/{telegram-MBCYOZOW.js.map → telegram-S5K3IMKH.js.map} +0 -0
- /package/{upgrade-HCODAAIE.js.map → upgrade-6I5DNVPS.js.map} +0 -0
- /package/{variable-VK42DTQ3.js.map → variable-IRTOV55E.js.map} +0 -0
- /package/{video-5HT4OTPO.js.map → video-3ZDBT2PC.js.map} +0 -0
- /package/{weather-JYVT7MJV.js.map → weather-4TPUCJLD.js.map} +0 -0
- /package/{web-4ZYLQGTN.js.map → web-ZK5I2YXJ.js.map} +0 -0
- /package/{web-search-BUSZ7LN5.js.map → web-search-OI6ACM3G.js.map} +0 -0
- /package/{whoami-DD32L4F2.js.map → whoami-FJGFKNBS.js.map} +0 -0
- /package/{workflow-SW7Q4HHX.js.map → workflow-4ODQQIVH.js.map} +0 -0
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
updateOrgModelPoliciesRequestSchema,
|
|
22
22
|
upsertModelProviderRequestSchema,
|
|
23
23
|
upsertModelProviderResponseSchema
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-M4F24YFV.js";
|
|
25
25
|
import {
|
|
26
26
|
__commonJS,
|
|
27
27
|
__esm,
|
|
@@ -682,8 +682,8 @@ var registryResourceDownloadContract = c.router({
|
|
|
682
682
|
// src/lib/api/domains/registry-resources.ts
|
|
683
683
|
async function getRegistryResourceDownload(query) {
|
|
684
684
|
const config = await getClientConfig();
|
|
685
|
-
const
|
|
686
|
-
const result = await
|
|
685
|
+
const client2 = initClient(registryResourceDownloadContract, config);
|
|
686
|
+
const result = await client2.download({ query });
|
|
687
687
|
if (result.status === 200) {
|
|
688
688
|
return result.body;
|
|
689
689
|
}
|
|
@@ -756,8 +756,8 @@ var zeroUserPreferencesContract = c2.router({
|
|
|
756
756
|
// src/lib/api/domains/zero-user-preferences.ts
|
|
757
757
|
async function getZeroUserPreferences() {
|
|
758
758
|
const config = await getClientConfig();
|
|
759
|
-
const
|
|
760
|
-
const result = await
|
|
759
|
+
const client2 = initClient(zeroUserPreferencesContract, config);
|
|
760
|
+
const result = await client2.get({ headers: {} });
|
|
761
761
|
if (result.status === 200) {
|
|
762
762
|
return result.body;
|
|
763
763
|
}
|
|
@@ -765,8 +765,8 @@ async function getZeroUserPreferences() {
|
|
|
765
765
|
}
|
|
766
766
|
async function updateZeroUserPreferences(body) {
|
|
767
767
|
const config = await getClientConfig();
|
|
768
|
-
const
|
|
769
|
-
const result = await
|
|
768
|
+
const client2 = initClient(zeroUserPreferencesContract, config);
|
|
769
|
+
const result = await client2.update({ body });
|
|
770
770
|
if (result.status === 200) {
|
|
771
771
|
return result.body;
|
|
772
772
|
}
|
|
@@ -839,7 +839,6 @@ var orgMessageResponseSchema = external_exports.object({
|
|
|
839
839
|
});
|
|
840
840
|
|
|
841
841
|
// ../../packages/api-contracts/src/contracts/orgs.ts
|
|
842
|
-
var c3 = initContract();
|
|
843
842
|
var orgTierSchema = external_exports.enum([
|
|
844
843
|
"free",
|
|
845
844
|
"limited-free-1",
|
|
@@ -868,38 +867,10 @@ var updateOrgRequestSchema = external_exports.object({
|
|
|
868
867
|
name: external_exports.string().min(1).max(128).optional(),
|
|
869
868
|
force: external_exports.boolean().optional().default(false)
|
|
870
869
|
});
|
|
871
|
-
var orgDefaultAgentContract = c3.router({
|
|
872
|
-
/**
|
|
873
|
-
* PUT /api/zero/default-agent
|
|
874
|
-
* Set or unset the default agent for an org.
|
|
875
|
-
* Only org admins can perform this action.
|
|
876
|
-
* The agent must belong to the same org.
|
|
877
|
-
*/
|
|
878
|
-
setDefaultAgent: {
|
|
879
|
-
method: "PUT",
|
|
880
|
-
path: "/api/zero/default-agent",
|
|
881
|
-
headers: authHeadersSchema,
|
|
882
|
-
query: external_exports.object({}),
|
|
883
|
-
body: external_exports.object({
|
|
884
|
-
agentId: external_exports.uuid().nullable()
|
|
885
|
-
}),
|
|
886
|
-
responses: {
|
|
887
|
-
200: external_exports.object({
|
|
888
|
-
agentId: external_exports.uuid().nullable()
|
|
889
|
-
}),
|
|
890
|
-
400: apiErrorSchema,
|
|
891
|
-
401: apiErrorSchema,
|
|
892
|
-
403: apiErrorSchema,
|
|
893
|
-
404: apiErrorSchema,
|
|
894
|
-
409: apiErrorSchema
|
|
895
|
-
},
|
|
896
|
-
summary: "Set or unset the default agent for an org"
|
|
897
|
-
}
|
|
898
|
-
});
|
|
899
870
|
|
|
900
871
|
// ../../packages/api-contracts/src/contracts/zero-org.ts
|
|
901
|
-
var
|
|
902
|
-
var zeroOrgContract =
|
|
872
|
+
var c3 = initContract();
|
|
873
|
+
var zeroOrgContract = c3.router({
|
|
903
874
|
get: {
|
|
904
875
|
method: "GET",
|
|
905
876
|
path: "/api/zero/org",
|
|
@@ -929,7 +900,7 @@ var zeroOrgContract = c4.router({
|
|
|
929
900
|
summary: "Update org slug (zero proxy)"
|
|
930
901
|
}
|
|
931
902
|
});
|
|
932
|
-
var zeroOrgLeaveContract =
|
|
903
|
+
var zeroOrgLeaveContract = c3.router({
|
|
933
904
|
leave: {
|
|
934
905
|
method: "POST",
|
|
935
906
|
path: "/api/zero/org/leave",
|
|
@@ -945,7 +916,7 @@ var zeroOrgLeaveContract = c4.router({
|
|
|
945
916
|
summary: "Leave the current org (zero proxy)"
|
|
946
917
|
}
|
|
947
918
|
});
|
|
948
|
-
var zeroOrgDeleteContract =
|
|
919
|
+
var zeroOrgDeleteContract = c3.router({
|
|
949
920
|
delete: {
|
|
950
921
|
method: "POST",
|
|
951
922
|
path: "/api/zero/org/delete",
|
|
@@ -978,8 +949,8 @@ var orgListResponseSchema = external_exports.object({
|
|
|
978
949
|
});
|
|
979
950
|
|
|
980
951
|
// ../../packages/api-contracts/src/contracts/zero-org-list.ts
|
|
981
|
-
var
|
|
982
|
-
var zeroOrgListContract =
|
|
952
|
+
var c4 = initContract();
|
|
953
|
+
var zeroOrgListContract = c4.router({
|
|
983
954
|
list: {
|
|
984
955
|
method: "GET",
|
|
985
956
|
path: "/api/zero/org/list",
|
|
@@ -995,8 +966,8 @@ var zeroOrgListContract = c5.router({
|
|
|
995
966
|
|
|
996
967
|
// ../../packages/api-contracts/src/contracts/zero-org-members.ts
|
|
997
968
|
init_esm_shims();
|
|
998
|
-
var
|
|
999
|
-
var zeroOrgMembersContract =
|
|
969
|
+
var c5 = initContract();
|
|
970
|
+
var zeroOrgMembersContract = c5.router({
|
|
1000
971
|
members: {
|
|
1001
972
|
method: "GET",
|
|
1002
973
|
path: "/api/zero/org/members",
|
|
@@ -1042,7 +1013,7 @@ var zeroOrgMembersContract = c6.router({
|
|
|
1042
1013
|
summary: "Remove a member from the org (zero proxy)"
|
|
1043
1014
|
}
|
|
1044
1015
|
});
|
|
1045
|
-
var zeroOrgInviteContract =
|
|
1016
|
+
var zeroOrgInviteContract = c5.router({
|
|
1046
1017
|
invite: {
|
|
1047
1018
|
method: "POST",
|
|
1048
1019
|
path: "/api/zero/org/invite",
|
|
@@ -1072,7 +1043,7 @@ var zeroOrgInviteContract = c6.router({
|
|
|
1072
1043
|
summary: "Revoke a pending invitation (zero proxy)"
|
|
1073
1044
|
}
|
|
1074
1045
|
});
|
|
1075
|
-
var zeroOrgMembershipRequestsContract =
|
|
1046
|
+
var zeroOrgMembershipRequestsContract = c5.router({
|
|
1076
1047
|
accept: {
|
|
1077
1048
|
method: "POST",
|
|
1078
1049
|
path: "/api/zero/org/membership-requests",
|
|
@@ -1106,8 +1077,8 @@ var zeroOrgMembershipRequestsContract = c6.router({
|
|
|
1106
1077
|
// src/lib/api/domains/zero-orgs.ts
|
|
1107
1078
|
async function getZeroOrg() {
|
|
1108
1079
|
const config = await getClientConfig();
|
|
1109
|
-
const
|
|
1110
|
-
const result = await
|
|
1080
|
+
const client2 = initClient(zeroOrgContract, config);
|
|
1081
|
+
const result = await client2.get({ headers: {} });
|
|
1111
1082
|
if (result.status === 200) {
|
|
1112
1083
|
return result.body;
|
|
1113
1084
|
}
|
|
@@ -1115,8 +1086,8 @@ async function getZeroOrg() {
|
|
|
1115
1086
|
}
|
|
1116
1087
|
async function updateZeroOrg(body) {
|
|
1117
1088
|
const config = await getClientConfig();
|
|
1118
|
-
const
|
|
1119
|
-
const result = await
|
|
1089
|
+
const client2 = initClient(zeroOrgContract, config);
|
|
1090
|
+
const result = await client2.update({ body });
|
|
1120
1091
|
if (result.status === 200) {
|
|
1121
1092
|
return result.body;
|
|
1122
1093
|
}
|
|
@@ -1124,8 +1095,8 @@ async function updateZeroOrg(body) {
|
|
|
1124
1095
|
}
|
|
1125
1096
|
async function listZeroOrgs() {
|
|
1126
1097
|
const config = await getClientConfig();
|
|
1127
|
-
const
|
|
1128
|
-
const result = await
|
|
1098
|
+
const client2 = initClient(zeroOrgListContract, config);
|
|
1099
|
+
const result = await client2.list({ headers: {} });
|
|
1129
1100
|
if (result.status === 200) {
|
|
1130
1101
|
return result.body;
|
|
1131
1102
|
}
|
|
@@ -1133,8 +1104,8 @@ async function listZeroOrgs() {
|
|
|
1133
1104
|
}
|
|
1134
1105
|
async function getZeroOrgMembers() {
|
|
1135
1106
|
const config = await getClientConfig();
|
|
1136
|
-
const
|
|
1137
|
-
const result = await
|
|
1107
|
+
const client2 = initClient(zeroOrgMembersContract, config);
|
|
1108
|
+
const result = await client2.members({ headers: {} });
|
|
1138
1109
|
if (result.status === 200) {
|
|
1139
1110
|
return result.body;
|
|
1140
1111
|
}
|
|
@@ -1142,8 +1113,8 @@ async function getZeroOrgMembers() {
|
|
|
1142
1113
|
}
|
|
1143
1114
|
async function inviteZeroOrgMember(email, role = "member") {
|
|
1144
1115
|
const config = await getClientConfig();
|
|
1145
|
-
const
|
|
1146
|
-
const result = await
|
|
1116
|
+
const client2 = initClient(zeroOrgInviteContract, config);
|
|
1117
|
+
const result = await client2.invite({
|
|
1147
1118
|
body: { email, role }
|
|
1148
1119
|
});
|
|
1149
1120
|
if (result.status === 200) {
|
|
@@ -1153,8 +1124,8 @@ async function inviteZeroOrgMember(email, role = "member") {
|
|
|
1153
1124
|
}
|
|
1154
1125
|
async function removeZeroOrgMember(email) {
|
|
1155
1126
|
const config = await getClientConfig();
|
|
1156
|
-
const
|
|
1157
|
-
const result = await
|
|
1127
|
+
const client2 = initClient(zeroOrgMembersContract, config);
|
|
1128
|
+
const result = await client2.removeMember({
|
|
1158
1129
|
body: { email }
|
|
1159
1130
|
});
|
|
1160
1131
|
if (result.status === 200) {
|
|
@@ -1164,8 +1135,8 @@ async function removeZeroOrgMember(email) {
|
|
|
1164
1135
|
}
|
|
1165
1136
|
async function leaveZeroOrg() {
|
|
1166
1137
|
const config = await getClientConfig();
|
|
1167
|
-
const
|
|
1168
|
-
const result = await
|
|
1138
|
+
const client2 = initClient(zeroOrgLeaveContract, config);
|
|
1139
|
+
const result = await client2.leave({
|
|
1169
1140
|
body: {}
|
|
1170
1141
|
});
|
|
1171
1142
|
if (result.status === 200) {
|
|
@@ -1175,8 +1146,8 @@ async function leaveZeroOrg() {
|
|
|
1175
1146
|
}
|
|
1176
1147
|
async function deleteZeroOrg(slug) {
|
|
1177
1148
|
const config = await getClientConfig();
|
|
1178
|
-
const
|
|
1179
|
-
const result = await
|
|
1149
|
+
const client2 = initClient(zeroOrgDeleteContract, config);
|
|
1150
|
+
const result = await client2.delete({
|
|
1180
1151
|
body: { slug }
|
|
1181
1152
|
});
|
|
1182
1153
|
if (result.status === 200) {
|
|
@@ -1193,7 +1164,7 @@ init_esm_shims();
|
|
|
1193
1164
|
|
|
1194
1165
|
// ../../packages/api-contracts/src/contracts/zero-attribution.ts
|
|
1195
1166
|
init_esm_shims();
|
|
1196
|
-
var
|
|
1167
|
+
var c6 = initContract();
|
|
1197
1168
|
var SOURCE_TYPES = [
|
|
1198
1169
|
"paid",
|
|
1199
1170
|
"organic_search",
|
|
@@ -1229,7 +1200,7 @@ var recordSignupAttributionRequestSchema = external_exports.object({
|
|
|
1229
1200
|
var recordSignupAttributionResponseSchema = external_exports.object({
|
|
1230
1201
|
recorded: external_exports.boolean()
|
|
1231
1202
|
});
|
|
1232
|
-
var zeroAttributionContract =
|
|
1203
|
+
var zeroAttributionContract = c6.router({
|
|
1233
1204
|
recordSignup: {
|
|
1234
1205
|
method: "POST",
|
|
1235
1206
|
path: "/api/zero/attribution/signup",
|
|
@@ -1246,7 +1217,7 @@ var zeroAttributionContract = c7.router({
|
|
|
1246
1217
|
});
|
|
1247
1218
|
|
|
1248
1219
|
// ../../packages/api-contracts/src/contracts/zero-billing.ts
|
|
1249
|
-
var
|
|
1220
|
+
var c7 = initContract();
|
|
1250
1221
|
var autoRechargeSchema = external_exports.object({
|
|
1251
1222
|
enabled: external_exports.boolean(),
|
|
1252
1223
|
threshold: external_exports.number().nullable(),
|
|
@@ -1416,7 +1387,7 @@ var redeemRequestSchema = external_exports.object({
|
|
|
1416
1387
|
var redeemCodeRequestSchema = external_exports.object({
|
|
1417
1388
|
code: external_exports.string().trim().min(1)
|
|
1418
1389
|
});
|
|
1419
|
-
var zeroBillingStatusContract =
|
|
1390
|
+
var zeroBillingStatusContract = c7.router({
|
|
1420
1391
|
get: {
|
|
1421
1392
|
method: "GET",
|
|
1422
1393
|
path: "/api/zero/billing/status",
|
|
@@ -1430,7 +1401,7 @@ var zeroBillingStatusContract = c8.router({
|
|
|
1430
1401
|
summary: "Get billing status for current org"
|
|
1431
1402
|
}
|
|
1432
1403
|
});
|
|
1433
|
-
var zeroBillingCheckoutContract =
|
|
1404
|
+
var zeroBillingCheckoutContract = c7.router({
|
|
1434
1405
|
create: {
|
|
1435
1406
|
method: "POST",
|
|
1436
1407
|
path: "/api/zero/billing/checkout",
|
|
@@ -1462,7 +1433,7 @@ var zeroBillingCheckoutContract = c8.router({
|
|
|
1462
1433
|
summary: "Complete Stripe checkout session"
|
|
1463
1434
|
}
|
|
1464
1435
|
});
|
|
1465
|
-
var zeroBillingConcurrencyCheckoutContract =
|
|
1436
|
+
var zeroBillingConcurrencyCheckoutContract = c7.router({
|
|
1466
1437
|
create: {
|
|
1467
1438
|
method: "POST",
|
|
1468
1439
|
path: "/api/zero/billing/concurrency-checkout",
|
|
@@ -1479,7 +1450,7 @@ var zeroBillingConcurrencyCheckoutContract = c8.router({
|
|
|
1479
1450
|
summary: "Create Stripe checkout session for concurrency add-on"
|
|
1480
1451
|
}
|
|
1481
1452
|
});
|
|
1482
|
-
var zeroBillingConcurrencySubscriptionContract =
|
|
1453
|
+
var zeroBillingConcurrencySubscriptionContract = c7.router({
|
|
1483
1454
|
cancel: {
|
|
1484
1455
|
method: "POST",
|
|
1485
1456
|
path: "/api/zero/billing/concurrency-subscriptions/:subscriptionId/cancel",
|
|
@@ -1517,7 +1488,7 @@ var zeroBillingConcurrencySubscriptionContract = c8.router({
|
|
|
1517
1488
|
summary: "Restore a concurrency add-on subscription"
|
|
1518
1489
|
}
|
|
1519
1490
|
});
|
|
1520
|
-
var zeroBillingCreditCheckoutContract =
|
|
1491
|
+
var zeroBillingCreditCheckoutContract = c7.router({
|
|
1521
1492
|
create: {
|
|
1522
1493
|
method: "POST",
|
|
1523
1494
|
path: "/api/zero/billing/credit-checkout",
|
|
@@ -1534,7 +1505,7 @@ var zeroBillingCreditCheckoutContract = c8.router({
|
|
|
1534
1505
|
summary: "Create Stripe checkout session for credits"
|
|
1535
1506
|
}
|
|
1536
1507
|
});
|
|
1537
|
-
var zeroBillingPortalContract =
|
|
1508
|
+
var zeroBillingPortalContract = c7.router({
|
|
1538
1509
|
create: {
|
|
1539
1510
|
method: "POST",
|
|
1540
1511
|
path: "/api/zero/billing/portal",
|
|
@@ -1551,7 +1522,7 @@ var zeroBillingPortalContract = c8.router({
|
|
|
1551
1522
|
summary: "Create Stripe billing portal session"
|
|
1552
1523
|
}
|
|
1553
1524
|
});
|
|
1554
|
-
var zeroBillingAutoRechargeContract =
|
|
1525
|
+
var zeroBillingAutoRechargeContract = c7.router({
|
|
1555
1526
|
get: {
|
|
1556
1527
|
method: "GET",
|
|
1557
1528
|
path: "/api/zero/billing/auto-recharge",
|
|
@@ -1589,7 +1560,7 @@ var invoiceSchema = external_exports.object({
|
|
|
1589
1560
|
var billingInvoicesResponseSchema = external_exports.object({
|
|
1590
1561
|
invoices: external_exports.array(invoiceSchema)
|
|
1591
1562
|
});
|
|
1592
|
-
var zeroBillingInvoicesContract =
|
|
1563
|
+
var zeroBillingInvoicesContract = c7.router({
|
|
1593
1564
|
get: {
|
|
1594
1565
|
method: "GET",
|
|
1595
1566
|
path: "/api/zero/billing/invoices",
|
|
@@ -1629,7 +1600,7 @@ var restoreResponseSchema = external_exports.discriminatedUnion("status", [
|
|
|
1629
1600
|
checkoutUrl: external_exports.string().url()
|
|
1630
1601
|
})
|
|
1631
1602
|
]);
|
|
1632
|
-
var zeroBillingDowngradeContract =
|
|
1603
|
+
var zeroBillingDowngradeContract = c7.router({
|
|
1633
1604
|
create: {
|
|
1634
1605
|
method: "POST",
|
|
1635
1606
|
path: "/api/zero/billing/downgrade",
|
|
@@ -1647,7 +1618,7 @@ var zeroBillingDowngradeContract = c8.router({
|
|
|
1647
1618
|
summary: "Downgrade subscription to a lower tier"
|
|
1648
1619
|
}
|
|
1649
1620
|
});
|
|
1650
|
-
var zeroBillingRestoreContract =
|
|
1621
|
+
var zeroBillingRestoreContract = c7.router({
|
|
1651
1622
|
create: {
|
|
1652
1623
|
method: "POST",
|
|
1653
1624
|
path: "/api/zero/billing/restore",
|
|
@@ -1664,7 +1635,7 @@ var zeroBillingRestoreContract = c8.router({
|
|
|
1664
1635
|
summary: "Restore a subscription scheduled for cancellation"
|
|
1665
1636
|
}
|
|
1666
1637
|
});
|
|
1667
|
-
var zeroBillingRedeemContract =
|
|
1638
|
+
var zeroBillingRedeemContract = c7.router({
|
|
1668
1639
|
create: {
|
|
1669
1640
|
method: "POST",
|
|
1670
1641
|
path: "/api/zero/billing/redeem/:campaign",
|
|
@@ -1682,7 +1653,7 @@ var zeroBillingRedeemContract = c8.router({
|
|
|
1682
1653
|
summary: "Redeem a one-time campaign"
|
|
1683
1654
|
}
|
|
1684
1655
|
});
|
|
1685
|
-
var zeroBillingRedeemCodeContract =
|
|
1656
|
+
var zeroBillingRedeemCodeContract = c7.router({
|
|
1686
1657
|
create: {
|
|
1687
1658
|
method: "POST",
|
|
1688
1659
|
path: "/api/zero/billing/redeem-code",
|
|
@@ -1703,8 +1674,8 @@ var zeroBillingRedeemCodeContract = c8.router({
|
|
|
1703
1674
|
// src/lib/api/domains/zero-billing.ts
|
|
1704
1675
|
async function getZeroBillingStatus() {
|
|
1705
1676
|
const config = await getClientConfig();
|
|
1706
|
-
const
|
|
1707
|
-
const result = await
|
|
1677
|
+
const client2 = initClient(zeroBillingStatusContract, config);
|
|
1678
|
+
const result = await client2.get({ headers: {} });
|
|
1708
1679
|
if (result.status === 200) {
|
|
1709
1680
|
return result.body;
|
|
1710
1681
|
}
|
|
@@ -1712,8 +1683,8 @@ async function getZeroBillingStatus() {
|
|
|
1712
1683
|
}
|
|
1713
1684
|
async function createZeroCreditCheckout(body) {
|
|
1714
1685
|
const config = await getClientConfig();
|
|
1715
|
-
const
|
|
1716
|
-
const result = await
|
|
1686
|
+
const client2 = initClient(zeroBillingCreditCheckoutContract, config);
|
|
1687
|
+
const result = await client2.create({ body });
|
|
1717
1688
|
if (result.status === 200) {
|
|
1718
1689
|
return result.body;
|
|
1719
1690
|
}
|
|
@@ -1725,8 +1696,8 @@ init_esm_shims();
|
|
|
1725
1696
|
|
|
1726
1697
|
// ../../packages/api-contracts/src/contracts/zero-model-policies.ts
|
|
1727
1698
|
init_esm_shims();
|
|
1728
|
-
var
|
|
1729
|
-
var zeroModelPoliciesMainContract =
|
|
1699
|
+
var c8 = initContract();
|
|
1700
|
+
var zeroModelPoliciesMainContract = c8.router({
|
|
1730
1701
|
list: {
|
|
1731
1702
|
method: "GET",
|
|
1732
1703
|
path: "/api/zero/model-policies",
|
|
@@ -1761,8 +1732,8 @@ var zeroModelPoliciesMainContract = c9.router({
|
|
|
1761
1732
|
// src/lib/api/domains/zero-model-policies.ts
|
|
1762
1733
|
async function listZeroModelPolicies() {
|
|
1763
1734
|
const config = await getClientConfig();
|
|
1764
|
-
const
|
|
1765
|
-
const result = await
|
|
1735
|
+
const client2 = initClient(zeroModelPoliciesMainContract, config);
|
|
1736
|
+
const result = await client2.list({ headers: {} });
|
|
1766
1737
|
if (result.status === 200) {
|
|
1767
1738
|
return result.body;
|
|
1768
1739
|
}
|
|
@@ -1771,7 +1742,7 @@ async function listZeroModelPolicies() {
|
|
|
1771
1742
|
|
|
1772
1743
|
// ../../packages/api-contracts/src/contracts/zero-host.ts
|
|
1773
1744
|
init_esm_shims();
|
|
1774
|
-
var
|
|
1745
|
+
var c9 = initContract();
|
|
1775
1746
|
var ORG_SLUG_HASH_LENGTH = 8;
|
|
1776
1747
|
var RANDOM_SLUG_SUFFIX_LENGTH = 8;
|
|
1777
1748
|
var PUBLIC_SLUG_SEPARATOR_LENGTH = 2;
|
|
@@ -1920,7 +1891,7 @@ var hostedSiteDeploymentsResponseSchema = external_exports.object({
|
|
|
1920
1891
|
activeDeploymentVersion: external_exports.number().int().positive().nullable(),
|
|
1921
1892
|
deployments: external_exports.array(hostedSiteDeploymentSummarySchema)
|
|
1922
1893
|
});
|
|
1923
|
-
var zeroHostContract =
|
|
1894
|
+
var zeroHostContract = c9.router({
|
|
1924
1895
|
prepare: {
|
|
1925
1896
|
method: "POST",
|
|
1926
1897
|
path: "/api/zero/host/deployments/prepare",
|
|
@@ -2402,7 +2373,7 @@ var listQuerySchema = external_exports.object({
|
|
|
2402
2373
|
cursor: external_exports.string().optional(),
|
|
2403
2374
|
limit: external_exports.coerce.number().int().min(1).max(100).default(20)
|
|
2404
2375
|
});
|
|
2405
|
-
var
|
|
2376
|
+
var c10 = initContract();
|
|
2406
2377
|
var logStatusSchema = external_exports.enum([
|
|
2407
2378
|
"queued",
|
|
2408
2379
|
"pending",
|
|
@@ -2475,7 +2446,7 @@ var logDetailSchema = external_exports.object({
|
|
|
2475
2446
|
completedAt: external_exports.string().nullable(),
|
|
2476
2447
|
artifact: artifactSchema
|
|
2477
2448
|
});
|
|
2478
|
-
var logsListContract =
|
|
2449
|
+
var logsListContract = c10.router({
|
|
2479
2450
|
list: {
|
|
2480
2451
|
method: "GET",
|
|
2481
2452
|
path: "/api/zero/logs",
|
|
@@ -2497,7 +2468,7 @@ var logsListContract = c11.router({
|
|
|
2497
2468
|
summary: "List agent run logs with pagination"
|
|
2498
2469
|
}
|
|
2499
2470
|
});
|
|
2500
|
-
var logsByIdContract =
|
|
2471
|
+
var logsByIdContract = c10.router({
|
|
2501
2472
|
getById: {
|
|
2502
2473
|
method: "GET",
|
|
2503
2474
|
path: "/api/zero/logs/:id",
|
|
@@ -2516,7 +2487,7 @@ var logsByIdContract = c11.router({
|
|
|
2516
2487
|
});
|
|
2517
2488
|
|
|
2518
2489
|
// ../../packages/api-contracts/src/contracts/runs.ts
|
|
2519
|
-
var
|
|
2490
|
+
var c11 = initContract();
|
|
2520
2491
|
var directRunModelProviderTypeSchema = modelProviderTypeSchema.refine(
|
|
2521
2492
|
(type) => {
|
|
2522
2493
|
return type !== "vm0";
|
|
@@ -2680,7 +2651,7 @@ var runListItemSchema = external_exports.object({
|
|
|
2680
2651
|
var runsListResponseSchema = external_exports.object({
|
|
2681
2652
|
runs: external_exports.array(runListItemSchema)
|
|
2682
2653
|
});
|
|
2683
|
-
var runsMainContract =
|
|
2654
|
+
var runsMainContract = c11.router({
|
|
2684
2655
|
/**
|
|
2685
2656
|
* GET /api/agent/runs
|
|
2686
2657
|
* List agent runs (pending and running by default)
|
|
@@ -2731,7 +2702,7 @@ var runsMainContract = c12.router({
|
|
|
2731
2702
|
summary: "Create and execute agent run"
|
|
2732
2703
|
}
|
|
2733
2704
|
});
|
|
2734
|
-
var runsByIdContract =
|
|
2705
|
+
var runsByIdContract = c11.router({
|
|
2735
2706
|
/**
|
|
2736
2707
|
* GET /api/agent/runs/:id
|
|
2737
2708
|
* Get agent run status and results
|
|
@@ -2757,7 +2728,7 @@ var cancelRunResponseSchema = external_exports.object({
|
|
|
2757
2728
|
status: external_exports.literal("cancelled"),
|
|
2758
2729
|
message: external_exports.string()
|
|
2759
2730
|
});
|
|
2760
|
-
var runsCancelContract =
|
|
2731
|
+
var runsCancelContract = c11.router({
|
|
2761
2732
|
/**
|
|
2762
2733
|
* POST /api/agent/runs/:id/cancel
|
|
2763
2734
|
* Cancel a pending or running run
|
|
@@ -2780,7 +2751,7 @@ var runsCancelContract = c12.router({
|
|
|
2780
2751
|
summary: "Cancel a pending or running run"
|
|
2781
2752
|
}
|
|
2782
2753
|
});
|
|
2783
|
-
var runEventsContract =
|
|
2754
|
+
var runEventsContract = c11.router({
|
|
2784
2755
|
/**
|
|
2785
2756
|
* GET /api/agent/runs/:id/events
|
|
2786
2757
|
* Poll for agent run events with pagination
|
|
@@ -3066,7 +3037,7 @@ var networkLogsResponseSchema = external_exports.object({
|
|
|
3066
3037
|
hasMore: external_exports.boolean(),
|
|
3067
3038
|
nextCursor: external_exports.string().nullable().optional()
|
|
3068
3039
|
});
|
|
3069
|
-
var runSystemLogContract =
|
|
3040
|
+
var runSystemLogContract = c11.router({
|
|
3070
3041
|
/**
|
|
3071
3042
|
* GET /api/agent/runs/:id/telemetry/system-log
|
|
3072
3043
|
* Get system log with pagination
|
|
@@ -3088,7 +3059,7 @@ var runSystemLogContract = c12.router({
|
|
|
3088
3059
|
summary: "Get system log with pagination"
|
|
3089
3060
|
}
|
|
3090
3061
|
});
|
|
3091
|
-
var runMetricsContract =
|
|
3062
|
+
var runMetricsContract = c11.router({
|
|
3092
3063
|
/**
|
|
3093
3064
|
* GET /api/agent/runs/:id/telemetry/metrics
|
|
3094
3065
|
* Get metrics with pagination
|
|
@@ -3163,27 +3134,10 @@ var queueResponseSchema = external_exports.object({
|
|
|
3163
3134
|
runningTasks: external_exports.array(runningTaskSchema),
|
|
3164
3135
|
estimatedTimePerRun: external_exports.number().nullable()
|
|
3165
3136
|
});
|
|
3166
|
-
var runsQueueContract = c12.router({
|
|
3167
|
-
/**
|
|
3168
|
-
* GET /api/agent/runs/queue
|
|
3169
|
-
* Get org run queue status including concurrency context and queued entries
|
|
3170
|
-
*/
|
|
3171
|
-
getQueue: {
|
|
3172
|
-
method: "GET",
|
|
3173
|
-
path: "/api/agent/runs/queue",
|
|
3174
|
-
headers: authHeadersSchema,
|
|
3175
|
-
responses: {
|
|
3176
|
-
200: queueResponseSchema,
|
|
3177
|
-
401: apiErrorSchema,
|
|
3178
|
-
403: apiErrorSchema
|
|
3179
|
-
},
|
|
3180
|
-
summary: "Get org run queue status"
|
|
3181
|
-
}
|
|
3182
|
-
});
|
|
3183
3137
|
|
|
3184
3138
|
// ../../packages/api-contracts/src/contracts/zero-goals.ts
|
|
3185
3139
|
init_esm_shims();
|
|
3186
|
-
var
|
|
3140
|
+
var c12 = initContract();
|
|
3187
3141
|
var zeroGoalStatusSchema = external_exports.enum([
|
|
3188
3142
|
"active",
|
|
3189
3143
|
"paused",
|
|
@@ -3216,7 +3170,7 @@ var zeroGoalResponseSchema = external_exports.object({
|
|
|
3216
3170
|
var chatThreadGoalParamsSchema = external_exports.object({
|
|
3217
3171
|
threadId: external_exports.string().min(1)
|
|
3218
3172
|
});
|
|
3219
|
-
var zeroGoalsContract =
|
|
3173
|
+
var zeroGoalsContract = c12.router({
|
|
3220
3174
|
create: {
|
|
3221
3175
|
method: "POST",
|
|
3222
3176
|
path: "/api/zero/goal",
|
|
@@ -3277,7 +3231,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3277
3231
|
method: "POST",
|
|
3278
3232
|
path: "/api/zero/goal/complete",
|
|
3279
3233
|
headers: authHeadersSchema,
|
|
3280
|
-
body:
|
|
3234
|
+
body: c12.noBody(),
|
|
3281
3235
|
responses: {
|
|
3282
3236
|
200: zeroGoalResponseSchema,
|
|
3283
3237
|
401: apiErrorSchema,
|
|
@@ -3291,7 +3245,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3291
3245
|
method: "POST",
|
|
3292
3246
|
path: "/api/zero/goal/block",
|
|
3293
3247
|
headers: authHeadersSchema,
|
|
3294
|
-
body:
|
|
3248
|
+
body: c12.noBody(),
|
|
3295
3249
|
responses: {
|
|
3296
3250
|
200: zeroGoalResponseSchema,
|
|
3297
3251
|
401: apiErrorSchema,
|
|
@@ -3305,7 +3259,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3305
3259
|
method: "POST",
|
|
3306
3260
|
path: "/api/zero/goal/pause",
|
|
3307
3261
|
headers: authHeadersSchema,
|
|
3308
|
-
body:
|
|
3262
|
+
body: c12.noBody(),
|
|
3309
3263
|
responses: {
|
|
3310
3264
|
200: zeroGoalResponseSchema,
|
|
3311
3265
|
401: apiErrorSchema,
|
|
@@ -3320,7 +3274,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3320
3274
|
path: "/api/zero/chat-threads/:threadId/goal/pause",
|
|
3321
3275
|
headers: authHeadersSchema,
|
|
3322
3276
|
pathParams: chatThreadGoalParamsSchema,
|
|
3323
|
-
body:
|
|
3277
|
+
body: c12.noBody(),
|
|
3324
3278
|
responses: {
|
|
3325
3279
|
200: zeroGoalResponseSchema,
|
|
3326
3280
|
401: apiErrorSchema,
|
|
@@ -3334,7 +3288,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3334
3288
|
method: "POST",
|
|
3335
3289
|
path: "/api/zero/goal/resume",
|
|
3336
3290
|
headers: authHeadersSchema,
|
|
3337
|
-
body:
|
|
3291
|
+
body: c12.noBody(),
|
|
3338
3292
|
responses: {
|
|
3339
3293
|
200: zeroGoalResponseSchema,
|
|
3340
3294
|
401: apiErrorSchema,
|
|
@@ -3348,7 +3302,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3348
3302
|
method: "DELETE",
|
|
3349
3303
|
path: "/api/zero/goal",
|
|
3350
3304
|
headers: authHeadersSchema,
|
|
3351
|
-
body:
|
|
3305
|
+
body: c12.noBody(),
|
|
3352
3306
|
responses: {
|
|
3353
3307
|
200: external_exports.object({ cleared: external_exports.literal(true) }),
|
|
3354
3308
|
401: apiErrorSchema,
|
|
@@ -3360,7 +3314,7 @@ var zeroGoalsContract = c13.router({
|
|
|
3360
3314
|
});
|
|
3361
3315
|
|
|
3362
3316
|
// ../../packages/api-contracts/src/contracts/chat-threads.ts
|
|
3363
|
-
var
|
|
3317
|
+
var c13 = initContract();
|
|
3364
3318
|
var attachFileSchema = external_exports.object({
|
|
3365
3319
|
id: external_exports.string(),
|
|
3366
3320
|
filename: external_exports.string(),
|
|
@@ -3817,7 +3771,7 @@ var chatMessageNormalSendBodySchema = external_exports.preprocess(
|
|
|
3817
3771
|
interruptsRunId: external_exports.undefined().optional()
|
|
3818
3772
|
})
|
|
3819
3773
|
);
|
|
3820
|
-
var chatThreadsContract =
|
|
3774
|
+
var chatThreadsContract = c13.router({
|
|
3821
3775
|
snapshot: {
|
|
3822
3776
|
method: "GET",
|
|
3823
3777
|
path: "/api/zero/chat-threads/snapshot",
|
|
@@ -3932,7 +3886,7 @@ var chatThreadThreadIdPathParamsSchema = external_exports.object({
|
|
|
3932
3886
|
var chatThreadMessagePathParamsSchema = chatThreadThreadIdPathParamsSchema.extend({
|
|
3933
3887
|
messageId: external_exports.string().uuid()
|
|
3934
3888
|
});
|
|
3935
|
-
var chatThreadByIdContract =
|
|
3889
|
+
var chatThreadByIdContract = c13.router({
|
|
3936
3890
|
get: {
|
|
3937
3891
|
method: "GET",
|
|
3938
3892
|
path: "/api/zero/chat-threads/:id",
|
|
@@ -3957,7 +3911,7 @@ var chatThreadByIdContract = c14.router({
|
|
|
3957
3911
|
draftAttachments: external_exports.array(persistedAttachmentSchema).nullable().optional()
|
|
3958
3912
|
}),
|
|
3959
3913
|
responses: {
|
|
3960
|
-
204:
|
|
3914
|
+
204: c13.noBody(),
|
|
3961
3915
|
400: apiErrorSchema,
|
|
3962
3916
|
401: apiErrorSchema,
|
|
3963
3917
|
404: apiErrorSchema
|
|
@@ -3971,17 +3925,17 @@ var chatThreadByIdContract = c14.router({
|
|
|
3971
3925
|
pathParams: chatThreadIdPathParamsSchema,
|
|
3972
3926
|
query: external_exports.object({ eventId: chatThreadEventIdSchema.optional() }).optional(),
|
|
3973
3927
|
responses: {
|
|
3974
|
-
204:
|
|
3928
|
+
204: c13.noBody(),
|
|
3975
3929
|
400: apiErrorSchema,
|
|
3976
3930
|
401: apiErrorSchema,
|
|
3977
3931
|
402: apiErrorSchema,
|
|
3978
3932
|
404: apiErrorSchema
|
|
3979
3933
|
},
|
|
3980
3934
|
summary: "Delete a chat thread",
|
|
3981
|
-
body:
|
|
3935
|
+
body: c13.noBody()
|
|
3982
3936
|
}
|
|
3983
3937
|
});
|
|
3984
|
-
var chatThreadDraftContract =
|
|
3938
|
+
var chatThreadDraftContract = c13.router({
|
|
3985
3939
|
get: {
|
|
3986
3940
|
method: "GET",
|
|
3987
3941
|
path: "/api/zero/chat-threads/:id/draft",
|
|
@@ -3996,13 +3950,13 @@ var chatThreadDraftContract = c14.router({
|
|
|
3996
3950
|
summary: "Get chat thread draft content and attachments"
|
|
3997
3951
|
}
|
|
3998
3952
|
});
|
|
3999
|
-
var chatThreadMarkReadContract =
|
|
3953
|
+
var chatThreadMarkReadContract = c13.router({
|
|
4000
3954
|
markRead: {
|
|
4001
3955
|
method: "POST",
|
|
4002
3956
|
path: "/api/zero/chat-threads/:id/mark-read",
|
|
4003
3957
|
headers: authHeadersSchema,
|
|
4004
3958
|
pathParams: chatThreadIdPathParamsSchema,
|
|
4005
|
-
body:
|
|
3959
|
+
body: c13.noBody(),
|
|
4006
3960
|
responses: {
|
|
4007
3961
|
200: external_exports.object({
|
|
4008
3962
|
lastReadAt: external_exports.string().nullable(),
|
|
@@ -4020,7 +3974,7 @@ var chatThreadMarkReadContract = c14.router({
|
|
|
4020
3974
|
summary: "Mark a chat thread as read up to the latest run-finish marker"
|
|
4021
3975
|
}
|
|
4022
3976
|
});
|
|
4023
|
-
var chatThreadMarkAgentReadContract =
|
|
3977
|
+
var chatThreadMarkAgentReadContract = c13.router({
|
|
4024
3978
|
markAgentRead: {
|
|
4025
3979
|
method: "POST",
|
|
4026
3980
|
path: "/api/zero/chat-thread-unreads/mark-read",
|
|
@@ -4029,7 +3983,7 @@ var chatThreadMarkAgentReadContract = c14.router({
|
|
|
4029
3983
|
agentId: external_exports.string().min(1)
|
|
4030
3984
|
}),
|
|
4031
3985
|
responses: {
|
|
4032
|
-
204:
|
|
3986
|
+
204: c13.noBody(),
|
|
4033
3987
|
400: apiErrorSchema,
|
|
4034
3988
|
401: apiErrorSchema,
|
|
4035
3989
|
403: apiErrorSchema
|
|
@@ -4037,16 +3991,16 @@ var chatThreadMarkAgentReadContract = c14.router({
|
|
|
4037
3991
|
summary: "Mark all unread chat threads under an agent as read"
|
|
4038
3992
|
}
|
|
4039
3993
|
});
|
|
4040
|
-
var chatThreadPinContract =
|
|
3994
|
+
var chatThreadPinContract = c13.router({
|
|
4041
3995
|
pin: {
|
|
4042
3996
|
method: "POST",
|
|
4043
3997
|
path: "/api/zero/chat-threads/:id/pin",
|
|
4044
3998
|
headers: authHeadersSchema,
|
|
4045
3999
|
pathParams: chatThreadIdPathParamsSchema,
|
|
4046
4000
|
query: external_exports.object({ eventId: chatThreadEventIdSchema.optional() }).optional(),
|
|
4047
|
-
body:
|
|
4001
|
+
body: c13.noBody(),
|
|
4048
4002
|
responses: {
|
|
4049
|
-
204:
|
|
4003
|
+
204: c13.noBody(),
|
|
4050
4004
|
400: apiErrorSchema,
|
|
4051
4005
|
401: apiErrorSchema,
|
|
4052
4006
|
404: apiErrorSchema
|
|
@@ -4054,16 +4008,16 @@ var chatThreadPinContract = c14.router({
|
|
|
4054
4008
|
summary: "Pin a chat thread to the top of the sidebar"
|
|
4055
4009
|
}
|
|
4056
4010
|
});
|
|
4057
|
-
var chatThreadUnpinContract =
|
|
4011
|
+
var chatThreadUnpinContract = c13.router({
|
|
4058
4012
|
unpin: {
|
|
4059
4013
|
method: "POST",
|
|
4060
4014
|
path: "/api/zero/chat-threads/:id/unpin",
|
|
4061
4015
|
headers: authHeadersSchema,
|
|
4062
4016
|
pathParams: chatThreadIdPathParamsSchema,
|
|
4063
4017
|
query: external_exports.object({ eventId: chatThreadEventIdSchema.optional() }).optional(),
|
|
4064
|
-
body:
|
|
4018
|
+
body: c13.noBody(),
|
|
4065
4019
|
responses: {
|
|
4066
|
-
204:
|
|
4020
|
+
204: c13.noBody(),
|
|
4067
4021
|
400: apiErrorSchema,
|
|
4068
4022
|
401: apiErrorSchema,
|
|
4069
4023
|
404: apiErrorSchema
|
|
@@ -4071,7 +4025,7 @@ var chatThreadUnpinContract = c14.router({
|
|
|
4071
4025
|
summary: "Remove the pin from a chat thread"
|
|
4072
4026
|
}
|
|
4073
4027
|
});
|
|
4074
|
-
var chatThreadRenameContract =
|
|
4028
|
+
var chatThreadRenameContract = c13.router({
|
|
4075
4029
|
rename: {
|
|
4076
4030
|
method: "POST",
|
|
4077
4031
|
path: "/api/zero/chat-threads/:id/rename",
|
|
@@ -4082,7 +4036,7 @@ var chatThreadRenameContract = c14.router({
|
|
|
4082
4036
|
eventId: chatThreadEventIdSchema.optional()
|
|
4083
4037
|
}),
|
|
4084
4038
|
responses: {
|
|
4085
|
-
204:
|
|
4039
|
+
204: c13.noBody(),
|
|
4086
4040
|
400: apiErrorSchema,
|
|
4087
4041
|
401: apiErrorSchema,
|
|
4088
4042
|
403: apiErrorSchema,
|
|
@@ -4091,7 +4045,7 @@ var chatThreadRenameContract = c14.router({
|
|
|
4091
4045
|
summary: "Rename a chat thread (suppresses automated title generation)"
|
|
4092
4046
|
}
|
|
4093
4047
|
});
|
|
4094
|
-
var chatThreadMetadataContract =
|
|
4048
|
+
var chatThreadMetadataContract = c13.router({
|
|
4095
4049
|
get: {
|
|
4096
4050
|
method: "GET",
|
|
4097
4051
|
path: "/api/zero/chat-threads/:id/metadata",
|
|
@@ -4107,7 +4061,7 @@ var chatThreadMetadataContract = c14.router({
|
|
|
4107
4061
|
summary: "Get chat thread metadata"
|
|
4108
4062
|
}
|
|
4109
4063
|
});
|
|
4110
|
-
var chatThreadModelSelectionContract =
|
|
4064
|
+
var chatThreadModelSelectionContract = c13.router({
|
|
4111
4065
|
update: {
|
|
4112
4066
|
method: "POST",
|
|
4113
4067
|
path: "/api/zero/chat-threads/:id/model-selection",
|
|
@@ -4115,7 +4069,7 @@ var chatThreadModelSelectionContract = c14.router({
|
|
|
4115
4069
|
pathParams: chatThreadIdPathParamsSchema,
|
|
4116
4070
|
body: chatThreadModelSelectionUpdateBodySchema,
|
|
4117
4071
|
responses: {
|
|
4118
|
-
204:
|
|
4072
|
+
204: c13.noBody(),
|
|
4119
4073
|
400: apiErrorSchema,
|
|
4120
4074
|
401: apiErrorSchema,
|
|
4121
4075
|
402: apiErrorSchema,
|
|
@@ -4125,7 +4079,7 @@ var chatThreadModelSelectionContract = c14.router({
|
|
|
4125
4079
|
summary: "Update a chat thread model selection"
|
|
4126
4080
|
}
|
|
4127
4081
|
});
|
|
4128
|
-
var chatThreadComputerUseHostContract =
|
|
4082
|
+
var chatThreadComputerUseHostContract = c13.router({
|
|
4129
4083
|
update: {
|
|
4130
4084
|
method: "POST",
|
|
4131
4085
|
path: "/api/zero/chat-threads/:id/computer-use-host",
|
|
@@ -4136,7 +4090,7 @@ var chatThreadComputerUseHostContract = c14.router({
|
|
|
4136
4090
|
eventId: chatThreadEventIdSchema.optional()
|
|
4137
4091
|
}),
|
|
4138
4092
|
responses: {
|
|
4139
|
-
204:
|
|
4093
|
+
204: c13.noBody(),
|
|
4140
4094
|
400: apiErrorSchema,
|
|
4141
4095
|
401: apiErrorSchema,
|
|
4142
4096
|
403: apiErrorSchema,
|
|
@@ -4145,7 +4099,7 @@ var chatThreadComputerUseHostContract = c14.router({
|
|
|
4145
4099
|
summary: "Update a chat thread Computer Use host binding"
|
|
4146
4100
|
}
|
|
4147
4101
|
});
|
|
4148
|
-
var chatMessagesContract =
|
|
4102
|
+
var chatMessagesContract = c13.router({
|
|
4149
4103
|
send: {
|
|
4150
4104
|
method: "POST",
|
|
4151
4105
|
path: "/api/zero/chat/messages",
|
|
@@ -4230,7 +4184,7 @@ var chatSearchResponseSchema = external_exports.object({
|
|
|
4230
4184
|
results: external_exports.array(chatSearchResultSchema),
|
|
4231
4185
|
hasMore: external_exports.boolean()
|
|
4232
4186
|
});
|
|
4233
|
-
var chatSearchContract =
|
|
4187
|
+
var chatSearchContract = c13.router({
|
|
4234
4188
|
search: {
|
|
4235
4189
|
method: "GET",
|
|
4236
4190
|
path: "/api/zero/chat/search",
|
|
@@ -4252,7 +4206,7 @@ var chatSearchContract = c14.router({
|
|
|
4252
4206
|
summary: "Search chat messages within caller's org (zero proxy)"
|
|
4253
4207
|
}
|
|
4254
4208
|
});
|
|
4255
|
-
var chatThreadMessagesContract =
|
|
4209
|
+
var chatThreadMessagesContract = c13.router({
|
|
4256
4210
|
list: {
|
|
4257
4211
|
method: "GET",
|
|
4258
4212
|
path: "/api/zero/chat-threads/:threadId/messages",
|
|
@@ -4294,7 +4248,7 @@ var chatThreadMessagesContract = c14.router({
|
|
|
4294
4248
|
summary: "Get a chat message by id for a thread"
|
|
4295
4249
|
}
|
|
4296
4250
|
});
|
|
4297
|
-
var chatThreadArtifactsContract =
|
|
4251
|
+
var chatThreadArtifactsContract = c13.router({
|
|
4298
4252
|
list: {
|
|
4299
4253
|
method: "GET",
|
|
4300
4254
|
path: "/api/zero/chat-threads/:threadId/artifacts",
|
|
@@ -4348,7 +4302,7 @@ var chatThreadArtifactsContract = c14.router({
|
|
|
4348
4302
|
pathParams: chatThreadThreadIdPathParamsSchema,
|
|
4349
4303
|
query: htmlArtifactEditSnapshotQuerySchema,
|
|
4350
4304
|
responses: {
|
|
4351
|
-
204:
|
|
4305
|
+
204: c13.noBody(),
|
|
4352
4306
|
400: apiErrorSchema,
|
|
4353
4307
|
401: apiErrorSchema,
|
|
4354
4308
|
404: apiErrorSchema
|
|
@@ -4384,7 +4338,7 @@ var chatThreadArtifactsContract = c14.router({
|
|
|
4384
4338
|
headers: authHeadersSchema,
|
|
4385
4339
|
pathParams: chatThreadThreadIdPathParamsSchema,
|
|
4386
4340
|
contentType: "multipart/form-data",
|
|
4387
|
-
body:
|
|
4341
|
+
body: c13.type(),
|
|
4388
4342
|
responses: {
|
|
4389
4343
|
200: external_exports.object({
|
|
4390
4344
|
id: external_exports.string(),
|
|
@@ -4400,7 +4354,7 @@ var chatThreadArtifactsContract = c14.router({
|
|
|
4400
4354
|
summary: "Upload a presentation artifact to the user's Google Drive as a native Google Slides deck"
|
|
4401
4355
|
}
|
|
4402
4356
|
});
|
|
4403
|
-
var artifactsContract =
|
|
4357
|
+
var artifactsContract = c13.router({
|
|
4404
4358
|
list: {
|
|
4405
4359
|
method: "GET",
|
|
4406
4360
|
path: "/api/zero/artifacts",
|
|
@@ -4430,7 +4384,7 @@ var artifactsContract = c14.router({
|
|
|
4430
4384
|
headers: authHeadersSchema,
|
|
4431
4385
|
body: artifactFavoriteBodySchema,
|
|
4432
4386
|
responses: {
|
|
4433
|
-
204:
|
|
4387
|
+
204: c13.noBody(),
|
|
4434
4388
|
400: apiErrorSchema,
|
|
4435
4389
|
401: apiErrorSchema,
|
|
4436
4390
|
403: apiErrorSchema,
|
|
@@ -4444,7 +4398,7 @@ var artifactsContract = c14.router({
|
|
|
4444
4398
|
headers: authHeadersSchema,
|
|
4445
4399
|
body: artifactFavoriteBodySchema,
|
|
4446
4400
|
responses: {
|
|
4447
|
-
204:
|
|
4401
|
+
204: c13.noBody(),
|
|
4448
4402
|
400: apiErrorSchema,
|
|
4449
4403
|
401: apiErrorSchema,
|
|
4450
4404
|
403: apiErrorSchema,
|
|
@@ -4473,7 +4427,7 @@ var artifactsContract = c14.router({
|
|
|
4473
4427
|
body: imageArtifactEditSnapshotUpsertSchema,
|
|
4474
4428
|
responses: {
|
|
4475
4429
|
200: imageArtifactEditSnapshotSchema,
|
|
4476
|
-
204:
|
|
4430
|
+
204: c13.noBody(),
|
|
4477
4431
|
400: apiErrorSchema,
|
|
4478
4432
|
401: apiErrorSchema,
|
|
4479
4433
|
403: apiErrorSchema,
|
|
@@ -4487,7 +4441,7 @@ var artifactsContract = c14.router({
|
|
|
4487
4441
|
headers: authHeadersSchema,
|
|
4488
4442
|
query: imageArtifactEditSnapshotQuerySchema,
|
|
4489
4443
|
responses: {
|
|
4490
|
-
204:
|
|
4444
|
+
204: c13.noBody(),
|
|
4491
4445
|
400: apiErrorSchema,
|
|
4492
4446
|
401: apiErrorSchema,
|
|
4493
4447
|
403: apiErrorSchema,
|
|
@@ -4498,7 +4452,7 @@ var artifactsContract = c14.router({
|
|
|
4498
4452
|
});
|
|
4499
4453
|
|
|
4500
4454
|
// ../../packages/api-contracts/src/contracts/zero-agents.ts
|
|
4501
|
-
var
|
|
4455
|
+
var c14 = initContract();
|
|
4502
4456
|
var zeroAgentVisibilitySchema = external_exports.enum(["public", "private"]);
|
|
4503
4457
|
var zeroAgentResponseSchema = external_exports.object({
|
|
4504
4458
|
agentId: external_exports.string(),
|
|
@@ -4543,7 +4497,7 @@ var zeroAgentDraftRequestSchema = external_exports.object({
|
|
|
4543
4497
|
draftStructuredPrompt: userMessageDocumentSchema.nullable().optional(),
|
|
4544
4498
|
draftAttachments: external_exports.array(persistedAttachmentSchema).nullable().optional()
|
|
4545
4499
|
});
|
|
4546
|
-
var zeroAgentsMainContract =
|
|
4500
|
+
var zeroAgentsMainContract = c14.router({
|
|
4547
4501
|
create: {
|
|
4548
4502
|
method: "POST",
|
|
4549
4503
|
path: "/api/zero/agents",
|
|
@@ -4571,7 +4525,7 @@ var zeroAgentsMainContract = c15.router({
|
|
|
4571
4525
|
summary: "List zero agents"
|
|
4572
4526
|
}
|
|
4573
4527
|
});
|
|
4574
|
-
var zeroAgentsByIdContract =
|
|
4528
|
+
var zeroAgentsByIdContract = c14.router({
|
|
4575
4529
|
get: {
|
|
4576
4530
|
method: "GET",
|
|
4577
4531
|
path: "/api/zero/agents/:id",
|
|
@@ -4624,9 +4578,9 @@ var zeroAgentsByIdContract = c15.router({
|
|
|
4624
4578
|
path: "/api/zero/agents/:id",
|
|
4625
4579
|
headers: authHeadersSchema,
|
|
4626
4580
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
4627
|
-
body:
|
|
4581
|
+
body: c14.noBody(),
|
|
4628
4582
|
responses: {
|
|
4629
|
-
204:
|
|
4583
|
+
204: c14.noBody(),
|
|
4630
4584
|
400: apiErrorSchema,
|
|
4631
4585
|
401: apiErrorSchema,
|
|
4632
4586
|
403: apiErrorSchema,
|
|
@@ -4636,7 +4590,7 @@ var zeroAgentsByIdContract = c15.router({
|
|
|
4636
4590
|
summary: "Delete zero agent by id"
|
|
4637
4591
|
}
|
|
4638
4592
|
});
|
|
4639
|
-
var zeroAgentInstructionsContract =
|
|
4593
|
+
var zeroAgentInstructionsContract = c14.router({
|
|
4640
4594
|
get: {
|
|
4641
4595
|
method: "GET",
|
|
4642
4596
|
path: "/api/zero/agents/:id/instructions",
|
|
@@ -4668,7 +4622,7 @@ var zeroAgentInstructionsContract = c15.router({
|
|
|
4668
4622
|
summary: "Update zero agent instructions"
|
|
4669
4623
|
}
|
|
4670
4624
|
});
|
|
4671
|
-
var zeroAgentDraftContract =
|
|
4625
|
+
var zeroAgentDraftContract = c14.router({
|
|
4672
4626
|
get: {
|
|
4673
4627
|
method: "GET",
|
|
4674
4628
|
path: "/api/zero/agents/:id/draft",
|
|
@@ -4690,7 +4644,7 @@ var zeroAgentDraftContract = c15.router({
|
|
|
4690
4644
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
4691
4645
|
body: zeroAgentDraftRequestSchema,
|
|
4692
4646
|
responses: {
|
|
4693
|
-
204:
|
|
4647
|
+
204: c14.noBody(),
|
|
4694
4648
|
400: apiErrorSchema,
|
|
4695
4649
|
401: apiErrorSchema,
|
|
4696
4650
|
403: apiErrorSchema,
|
|
@@ -4712,7 +4666,7 @@ var connectorRefSchema = external_exports.string().min(1).max(CONNECTOR_REF_MAX_
|
|
|
4712
4666
|
var connectorAuthMethodIdSchema = external_exports.string().min(1).max(CONNECTOR_AUTH_METHOD_ID_MAX_LENGTH).regex(connectorIdentityPattern);
|
|
4713
4667
|
|
|
4714
4668
|
// ../../packages/api-contracts/src/contracts/zero-user-permission-grants.ts
|
|
4715
|
-
var
|
|
4669
|
+
var c15 = initContract();
|
|
4716
4670
|
var agentIdSchema = external_exports.string().uuid();
|
|
4717
4671
|
var permissionSchema = external_exports.string().min(1).max(128);
|
|
4718
4672
|
var userPermissionGrantActionSchema = external_exports.enum(["allow", "deny"]);
|
|
@@ -4759,7 +4713,7 @@ var applyUserPermissionGrantsRequestSchema = userPermissionGrantScopeSchema.and(
|
|
|
4759
4713
|
grants: external_exports.array(applyUserPermissionGrantSchema)
|
|
4760
4714
|
})
|
|
4761
4715
|
);
|
|
4762
|
-
var zeroUserPermissionGrantsContract =
|
|
4716
|
+
var zeroUserPermissionGrantsContract = c15.router({
|
|
4763
4717
|
list: {
|
|
4764
4718
|
method: "GET",
|
|
4765
4719
|
path: "/api/zero/user-permission-grants",
|
|
@@ -4793,7 +4747,7 @@ var zeroUserPermissionGrantsContract = c16.router({
|
|
|
4793
4747
|
|
|
4794
4748
|
// ../../packages/api-contracts/src/contracts/user-connectors.ts
|
|
4795
4749
|
init_esm_shims();
|
|
4796
|
-
var
|
|
4750
|
+
var c16 = initContract();
|
|
4797
4751
|
var userConnectorEnabledTypesSchema = external_exports.object({
|
|
4798
4752
|
enabledTypes: external_exports.array(connectorRefSchema)
|
|
4799
4753
|
});
|
|
@@ -4802,7 +4756,7 @@ var userConnectorUpdateSchema = userConnectorEnabledTypesSchema.extend(
|
|
|
4802
4756
|
operation: external_exports.enum(["replace", "add", "remove"]).optional()
|
|
4803
4757
|
}
|
|
4804
4758
|
);
|
|
4805
|
-
var zeroUserConnectorsContract =
|
|
4759
|
+
var zeroUserConnectorsContract = c16.router({
|
|
4806
4760
|
get: {
|
|
4807
4761
|
method: "GET",
|
|
4808
4762
|
path: "/api/zero/agents/:id/user-connectors",
|
|
@@ -4835,14 +4789,14 @@ var zeroUserConnectorsContract = c17.router({
|
|
|
4835
4789
|
|
|
4836
4790
|
// ../../packages/api-contracts/src/contracts/zero-agent-custom-connectors.ts
|
|
4837
4791
|
init_esm_shims();
|
|
4838
|
-
var
|
|
4792
|
+
var c17 = initContract();
|
|
4839
4793
|
var agentCustomConnectorEnabledIdsSchema = external_exports.object({
|
|
4840
4794
|
enabledIds: external_exports.array(external_exports.string().uuid())
|
|
4841
4795
|
});
|
|
4842
4796
|
var agentCustomConnectorUpdateSchema = agentCustomConnectorEnabledIdsSchema.extend({
|
|
4843
4797
|
operation: external_exports.enum(["replace", "add", "remove"]).optional()
|
|
4844
4798
|
});
|
|
4845
|
-
var zeroAgentCustomConnectorsContract =
|
|
4799
|
+
var zeroAgentCustomConnectorsContract = c17.router({
|
|
4846
4800
|
get: {
|
|
4847
4801
|
method: "GET",
|
|
4848
4802
|
path: "/api/zero/agents/:id/custom-connectors",
|
|
@@ -4876,50 +4830,50 @@ var zeroAgentCustomConnectorsContract = c18.router({
|
|
|
4876
4830
|
// src/lib/api/domains/zero-agents.ts
|
|
4877
4831
|
async function createZeroAgent(body) {
|
|
4878
4832
|
const config = await getClientConfig();
|
|
4879
|
-
const
|
|
4880
|
-
const result = await
|
|
4833
|
+
const client2 = initClient(zeroAgentsMainContract, config);
|
|
4834
|
+
const result = await client2.create({ body });
|
|
4881
4835
|
if (result.status === 201) return result.body;
|
|
4882
4836
|
handleError(result, "Failed to create zero agent");
|
|
4883
4837
|
}
|
|
4884
4838
|
async function listZeroAgents() {
|
|
4885
4839
|
const config = await getClientConfig();
|
|
4886
|
-
const
|
|
4887
|
-
const result = await
|
|
4840
|
+
const client2 = initClient(zeroAgentsMainContract, config);
|
|
4841
|
+
const result = await client2.list({ headers: {} });
|
|
4888
4842
|
if (result.status === 200) return result.body;
|
|
4889
4843
|
handleError(result, "Failed to list zero agents");
|
|
4890
4844
|
}
|
|
4891
4845
|
async function getZeroAgent(id) {
|
|
4892
4846
|
const config = await getClientConfig();
|
|
4893
|
-
const
|
|
4894
|
-
const result = await
|
|
4847
|
+
const client2 = initClient(zeroAgentsByIdContract, config);
|
|
4848
|
+
const result = await client2.get({ params: { id } });
|
|
4895
4849
|
if (result.status === 200) return result.body;
|
|
4896
4850
|
handleError(result, `Zero agent "${id}" not found`);
|
|
4897
4851
|
}
|
|
4898
4852
|
async function updateZeroAgent(id, body) {
|
|
4899
4853
|
const config = await getClientConfig();
|
|
4900
|
-
const
|
|
4901
|
-
const result = await
|
|
4854
|
+
const client2 = initClient(zeroAgentsByIdContract, config);
|
|
4855
|
+
const result = await client2.update({ params: { id }, body });
|
|
4902
4856
|
if (result.status === 200) return result.body;
|
|
4903
4857
|
handleError(result, `Failed to update zero agent "${id}"`);
|
|
4904
4858
|
}
|
|
4905
4859
|
async function deleteZeroAgent(id) {
|
|
4906
4860
|
const config = await getClientConfig();
|
|
4907
|
-
const
|
|
4908
|
-
const result = await
|
|
4861
|
+
const client2 = initClient(zeroAgentsByIdContract, config);
|
|
4862
|
+
const result = await client2.delete({ params: { id } });
|
|
4909
4863
|
if (result.status === 204) return;
|
|
4910
4864
|
handleError(result, `Zero agent "${id}" not found`);
|
|
4911
4865
|
}
|
|
4912
4866
|
async function getZeroAgentInstructions(id) {
|
|
4913
4867
|
const config = await getClientConfig();
|
|
4914
|
-
const
|
|
4915
|
-
const result = await
|
|
4868
|
+
const client2 = initClient(zeroAgentInstructionsContract, config);
|
|
4869
|
+
const result = await client2.get({ params: { id } });
|
|
4916
4870
|
if (result.status === 200) return result.body;
|
|
4917
4871
|
handleError(result, `Failed to get instructions for zero agent "${id}"`);
|
|
4918
4872
|
}
|
|
4919
4873
|
async function getZeroAgentUserConnectors(id) {
|
|
4920
4874
|
const config = await getClientConfig();
|
|
4921
|
-
const
|
|
4922
|
-
const result = await
|
|
4875
|
+
const client2 = initClient(zeroUserConnectorsContract, config);
|
|
4876
|
+
const result = await client2.get({ params: { id } });
|
|
4923
4877
|
if (result.status === 200) return result.body.enabledTypes;
|
|
4924
4878
|
handleError(
|
|
4925
4879
|
result,
|
|
@@ -4928,8 +4882,8 @@ async function getZeroAgentUserConnectors(id) {
|
|
|
4928
4882
|
}
|
|
4929
4883
|
async function getZeroAgentCustomConnectors(id) {
|
|
4930
4884
|
const config = await getClientConfig();
|
|
4931
|
-
const
|
|
4932
|
-
const result = await
|
|
4885
|
+
const client2 = initClient(zeroAgentCustomConnectorsContract, config);
|
|
4886
|
+
const result = await client2.get({ params: { id } });
|
|
4933
4887
|
if (result.status === 200) return result.body.enabledIds;
|
|
4934
4888
|
handleError(
|
|
4935
4889
|
result,
|
|
@@ -4938,8 +4892,8 @@ async function getZeroAgentCustomConnectors(id) {
|
|
|
4938
4892
|
}
|
|
4939
4893
|
async function listZeroUserPermissionGrants(agentId) {
|
|
4940
4894
|
const config = await getClientConfig();
|
|
4941
|
-
const
|
|
4942
|
-
const result = await
|
|
4895
|
+
const client2 = initClient(zeroUserPermissionGrantsContract, config);
|
|
4896
|
+
const result = await client2.list({ query: { agentId } });
|
|
4943
4897
|
if (result.status === 200) return result.body;
|
|
4944
4898
|
handleError(
|
|
4945
4899
|
result,
|
|
@@ -4948,8 +4902,8 @@ async function listZeroUserPermissionGrants(agentId) {
|
|
|
4948
4902
|
}
|
|
4949
4903
|
async function updateZeroAgentInstructions(id, content) {
|
|
4950
4904
|
const config = await getClientConfig();
|
|
4951
|
-
const
|
|
4952
|
-
const result = await
|
|
4905
|
+
const client2 = initClient(zeroAgentInstructionsContract, config);
|
|
4906
|
+
const result = await client2.update({
|
|
4953
4907
|
params: { id },
|
|
4954
4908
|
body: { content }
|
|
4955
4909
|
});
|
|
@@ -4961,57 +4915,57 @@ async function updateZeroAgentInstructions(id, content) {
|
|
|
4961
4915
|
init_esm_shims();
|
|
4962
4916
|
async function createGoal(body) {
|
|
4963
4917
|
const config = await getClientConfig();
|
|
4964
|
-
const
|
|
4965
|
-
const result = await
|
|
4918
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4919
|
+
const result = await client2.create({ body });
|
|
4966
4920
|
if (result.status === 201) return result.body;
|
|
4967
4921
|
handleError(result, "Failed to create goal");
|
|
4968
4922
|
}
|
|
4969
4923
|
async function editGoal(body) {
|
|
4970
4924
|
const config = await getClientConfig();
|
|
4971
|
-
const
|
|
4972
|
-
const result = await
|
|
4925
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4926
|
+
const result = await client2.edit({ body });
|
|
4973
4927
|
if (result.status === 200) return result.body;
|
|
4974
4928
|
handleError(result, "Failed to edit goal");
|
|
4975
4929
|
}
|
|
4976
4930
|
async function getGoal() {
|
|
4977
4931
|
const config = await getClientConfig();
|
|
4978
|
-
const
|
|
4979
|
-
const result = await
|
|
4932
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4933
|
+
const result = await client2.get({ headers: {} });
|
|
4980
4934
|
if (result.status === 200) return result.body;
|
|
4981
4935
|
handleError(result, "Goal not found");
|
|
4982
4936
|
}
|
|
4983
4937
|
async function completeGoal() {
|
|
4984
4938
|
const config = await getClientConfig();
|
|
4985
|
-
const
|
|
4986
|
-
const result = await
|
|
4939
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4940
|
+
const result = await client2.complete({});
|
|
4987
4941
|
if (result.status === 200) return result.body;
|
|
4988
4942
|
handleError(result, "Failed to complete goal");
|
|
4989
4943
|
}
|
|
4990
4944
|
async function blockGoal() {
|
|
4991
4945
|
const config = await getClientConfig();
|
|
4992
|
-
const
|
|
4993
|
-
const result = await
|
|
4946
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4947
|
+
const result = await client2.block({});
|
|
4994
4948
|
if (result.status === 200) return result.body;
|
|
4995
4949
|
handleError(result, "Failed to block goal");
|
|
4996
4950
|
}
|
|
4997
4951
|
async function pauseGoal() {
|
|
4998
4952
|
const config = await getClientConfig();
|
|
4999
|
-
const
|
|
5000
|
-
const result = await
|
|
4953
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4954
|
+
const result = await client2.pause({});
|
|
5001
4955
|
if (result.status === 200) return result.body;
|
|
5002
4956
|
handleError(result, "Failed to pause goal");
|
|
5003
4957
|
}
|
|
5004
4958
|
async function resumeGoal() {
|
|
5005
4959
|
const config = await getClientConfig();
|
|
5006
|
-
const
|
|
5007
|
-
const result = await
|
|
4960
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4961
|
+
const result = await client2.resume({});
|
|
5008
4962
|
if (result.status === 200) return result.body;
|
|
5009
4963
|
handleError(result, "Failed to resume goal");
|
|
5010
4964
|
}
|
|
5011
4965
|
async function clearGoal() {
|
|
5012
4966
|
const config = await getClientConfig();
|
|
5013
|
-
const
|
|
5014
|
-
const result = await
|
|
4967
|
+
const client2 = initClient(zeroGoalsContract, config);
|
|
4968
|
+
const result = await client2.clear({});
|
|
5015
4969
|
if (result.status === 200) return result.body;
|
|
5016
4970
|
handleError(result, "Failed to clear goal");
|
|
5017
4971
|
}
|
|
@@ -5143,8 +5097,8 @@ var connectorExternalCodeSessionCompleteResponseSchema = external_exports.object
|
|
|
5143
5097
|
});
|
|
5144
5098
|
|
|
5145
5099
|
// ../../packages/api-contracts/src/contracts/zero-connectors.ts
|
|
5146
|
-
var
|
|
5147
|
-
var zeroConnectorsMainContract =
|
|
5100
|
+
var c18 = initContract();
|
|
5101
|
+
var zeroConnectorsMainContract = c18.router({
|
|
5148
5102
|
list: {
|
|
5149
5103
|
method: "GET",
|
|
5150
5104
|
path: "/api/zero/connectors",
|
|
@@ -5158,7 +5112,7 @@ var zeroConnectorsMainContract = c19.router({
|
|
|
5158
5112
|
summary: "List all connectors (zero proxy)"
|
|
5159
5113
|
}
|
|
5160
5114
|
});
|
|
5161
|
-
var zeroConnectorsByTypeContract =
|
|
5115
|
+
var zeroConnectorsByTypeContract = c18.router({
|
|
5162
5116
|
get: {
|
|
5163
5117
|
method: "GET",
|
|
5164
5118
|
path: "/api/zero/connectors/:type",
|
|
@@ -5178,14 +5132,14 @@ var zeroConnectorsByTypeContract = c19.router({
|
|
|
5178
5132
|
headers: authHeadersSchema,
|
|
5179
5133
|
pathParams: external_exports.object({ type: connectorRefSchema }),
|
|
5180
5134
|
responses: {
|
|
5181
|
-
204:
|
|
5135
|
+
204: c18.noBody(),
|
|
5182
5136
|
401: apiErrorSchema,
|
|
5183
5137
|
404: apiErrorSchema
|
|
5184
5138
|
},
|
|
5185
5139
|
summary: "Disconnect a connector (zero proxy)"
|
|
5186
5140
|
}
|
|
5187
5141
|
});
|
|
5188
|
-
var zeroConnectorScopeDiffContract =
|
|
5142
|
+
var zeroConnectorScopeDiffContract = c18.router({
|
|
5189
5143
|
getScopeDiff: {
|
|
5190
5144
|
method: "GET",
|
|
5191
5145
|
path: "/api/zero/connectors/:type/scope-diff",
|
|
@@ -5200,7 +5154,7 @@ var zeroConnectorScopeDiffContract = c19.router({
|
|
|
5200
5154
|
summary: "Get scope diff for a connector"
|
|
5201
5155
|
}
|
|
5202
5156
|
});
|
|
5203
|
-
var zeroConnectorOauthStartContract =
|
|
5157
|
+
var zeroConnectorOauthStartContract = c18.router({
|
|
5204
5158
|
start: {
|
|
5205
5159
|
method: "POST",
|
|
5206
5160
|
path: "/api/zero/connectors/:type/oauth/start",
|
|
@@ -5222,21 +5176,21 @@ var zeroConnectorOauthStartContract = c19.router({
|
|
|
5222
5176
|
summary: "Create connector OAuth authorization URL"
|
|
5223
5177
|
}
|
|
5224
5178
|
});
|
|
5225
|
-
var zeroConnectorOauthContinueContract =
|
|
5179
|
+
var zeroConnectorOauthContinueContract = c18.router({
|
|
5226
5180
|
continue: {
|
|
5227
5181
|
method: "GET",
|
|
5228
5182
|
path: "/api/zero/connectors/:type/oauth/continue",
|
|
5229
5183
|
pathParams: external_exports.object({ type: connectorRefSchema }),
|
|
5230
5184
|
query: external_exports.object({ state: external_exports.string().regex(/^[0-9a-f]{64}$/) }),
|
|
5231
5185
|
responses: {
|
|
5232
|
-
307:
|
|
5186
|
+
307: c18.noBody(),
|
|
5233
5187
|
400: apiErrorSchema,
|
|
5234
5188
|
404: apiErrorSchema
|
|
5235
5189
|
},
|
|
5236
5190
|
summary: "Continue connector OAuth in the browser"
|
|
5237
5191
|
}
|
|
5238
5192
|
});
|
|
5239
|
-
var zeroConnectorOpenIdStartContract =
|
|
5193
|
+
var zeroConnectorOpenIdStartContract = c18.router({
|
|
5240
5194
|
start: {
|
|
5241
5195
|
method: "POST",
|
|
5242
5196
|
path: "/api/zero/connectors/:type/openid/start",
|
|
@@ -5257,7 +5211,7 @@ var zeroConnectorOpenIdStartContract = c19.router({
|
|
|
5257
5211
|
summary: "Create connector OpenID handoff and authorization URL"
|
|
5258
5212
|
}
|
|
5259
5213
|
});
|
|
5260
|
-
var zeroConnectorManualGrantContract =
|
|
5214
|
+
var zeroConnectorManualGrantContract = c18.router({
|
|
5261
5215
|
connect: {
|
|
5262
5216
|
method: "POST",
|
|
5263
5217
|
path: "/api/zero/connectors/:type/manual-grant",
|
|
@@ -5280,7 +5234,7 @@ var zeroConnectorManualGrantContract = c19.router({
|
|
|
5280
5234
|
summary: "Connect a connector with a manual grant"
|
|
5281
5235
|
}
|
|
5282
5236
|
});
|
|
5283
|
-
var zeroConnectorNoAuthGrantContract =
|
|
5237
|
+
var zeroConnectorNoAuthGrantContract = c18.router({
|
|
5284
5238
|
connect: {
|
|
5285
5239
|
method: "POST",
|
|
5286
5240
|
path: "/api/zero/connectors/:type/no-auth",
|
|
@@ -5302,7 +5256,7 @@ var zeroConnectorNoAuthGrantContract = c19.router({
|
|
|
5302
5256
|
summary: "Enable a connector with a no-auth grant"
|
|
5303
5257
|
}
|
|
5304
5258
|
});
|
|
5305
|
-
var zeroConnectorOauthDeviceAuthSessionContract =
|
|
5259
|
+
var zeroConnectorOauthDeviceAuthSessionContract = c18.router({
|
|
5306
5260
|
create: {
|
|
5307
5261
|
method: "POST",
|
|
5308
5262
|
path: "/api/zero/connectors/:type/oauth/device/sessions",
|
|
@@ -5343,7 +5297,7 @@ var zeroConnectorOauthDeviceAuthSessionContract = c19.router({
|
|
|
5343
5297
|
summary: "Poll connector OAuth device authorization session"
|
|
5344
5298
|
}
|
|
5345
5299
|
});
|
|
5346
|
-
var zeroConnectorExternalCodeSessionContract =
|
|
5300
|
+
var zeroConnectorExternalCodeSessionContract = c18.router({
|
|
5347
5301
|
create: {
|
|
5348
5302
|
method: "POST",
|
|
5349
5303
|
path: "/api/zero/connectors/:type/external-code/sessions",
|
|
@@ -5392,7 +5346,7 @@ var connectorSearchItemSchema = external_exports.object({
|
|
|
5392
5346
|
var connectorSearchResponseSchema = external_exports.object({
|
|
5393
5347
|
connectors: external_exports.array(connectorSearchItemSchema)
|
|
5394
5348
|
});
|
|
5395
|
-
var zeroConnectorsSearchContract =
|
|
5349
|
+
var zeroConnectorsSearchContract = c18.router({
|
|
5396
5350
|
search: {
|
|
5397
5351
|
method: "GET",
|
|
5398
5352
|
path: "/api/zero/connectors/search",
|
|
@@ -5463,15 +5417,22 @@ var connectorCatalogDiagnosticsSchema = external_exports.object({
|
|
|
5463
5417
|
lastAttempt: external_exports.object({
|
|
5464
5418
|
at: external_exports.string().datetime(),
|
|
5465
5419
|
outcome: external_exports.enum(["accepted", "unchanged", "rejected"]),
|
|
5466
|
-
failureCode: connectorCatalogSyncFailureCodeSchema.nullable()
|
|
5420
|
+
failureCode: connectorCatalogSyncFailureCodeSchema.nullable(),
|
|
5421
|
+
reusedCachedRejection: external_exports.boolean().nullable().optional()
|
|
5467
5422
|
}).nullable(),
|
|
5468
5423
|
lastSuccessAt: external_exports.string().datetime().nullable(),
|
|
5424
|
+
rejectedCandidate: external_exports.object({
|
|
5425
|
+
catalogVersion: external_exports.string().nullable(),
|
|
5426
|
+
catalogDigest: external_exports.string().regex(/^sha256:[a-f0-9]{64}$/u).nullable(),
|
|
5427
|
+
failureCode: connectorCatalogSyncFailureCodeSchema,
|
|
5428
|
+
backendVersion: external_exports.string().regex(/^(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)\.(0|[1-9][0-9]*)$/u).nullable()
|
|
5429
|
+
}).nullable().optional(),
|
|
5469
5430
|
filtering: connectorCatalogFilteringStatusSchema,
|
|
5470
5431
|
credentialStorage: connectorCredentialStorageReadinessSchema
|
|
5471
5432
|
});
|
|
5472
5433
|
|
|
5473
5434
|
// ../../packages/api-contracts/src/contracts/zero-connector-catalog.ts
|
|
5474
|
-
var
|
|
5435
|
+
var c19 = initContract();
|
|
5475
5436
|
var publicConnectorCatalogAuthMethodSummarySchema = external_exports.object({
|
|
5476
5437
|
id: connectorAuthMethodIdSchema,
|
|
5477
5438
|
label: external_exports.string(),
|
|
@@ -5611,7 +5572,7 @@ var publicConnectorCatalogPermissionDetailResponseSchema = external_exports.obje
|
|
|
5611
5572
|
var connectorCatalogPathParamsSchema = external_exports.object({
|
|
5612
5573
|
connectorRef: connectorRefSchema
|
|
5613
5574
|
});
|
|
5614
|
-
var zeroConnectorCatalogContract =
|
|
5575
|
+
var zeroConnectorCatalogContract = c19.router({
|
|
5615
5576
|
list: {
|
|
5616
5577
|
method: "GET",
|
|
5617
5578
|
path: "/api/zero/connector-catalog",
|
|
@@ -5682,7 +5643,7 @@ var zeroConnectorCatalogContract = c20.router({
|
|
|
5682
5643
|
|
|
5683
5644
|
// ../../packages/api-contracts/src/contracts/zero-connector-check.ts
|
|
5684
5645
|
init_esm_shims();
|
|
5685
|
-
var
|
|
5646
|
+
var c20 = initContract();
|
|
5686
5647
|
var boundedNameSchema = external_exports.string().min(1).max(255);
|
|
5687
5648
|
var connectorCheckUrlRequestSchema = external_exports.object({
|
|
5688
5649
|
mode: external_exports.literal("url"),
|
|
@@ -5828,7 +5789,7 @@ var connectorCheckDiagnosticResultSchema = external_exports.union([
|
|
|
5828
5789
|
connectorCheckUnresolvedDynamicBaseSchema,
|
|
5829
5790
|
connectorCheckRunContextUnavailableSchema
|
|
5830
5791
|
]);
|
|
5831
|
-
var zeroConnectorCheckContract =
|
|
5792
|
+
var zeroConnectorCheckContract = c20.router({
|
|
5832
5793
|
check: {
|
|
5833
5794
|
method: "POST",
|
|
5834
5795
|
path: "/api/zero/connectors/diagnostics/check",
|
|
@@ -5848,7 +5809,7 @@ var zeroConnectorCheckContract = c21.router({
|
|
|
5848
5809
|
|
|
5849
5810
|
// ../../packages/api-contracts/src/contracts/zero-custom-connectors.ts
|
|
5850
5811
|
init_esm_shims();
|
|
5851
|
-
var
|
|
5812
|
+
var c21 = initContract();
|
|
5852
5813
|
var customConnectorFieldKindSchema = external_exports.enum(["secret", "variable"]);
|
|
5853
5814
|
var customConnectorFieldSchema = external_exports.object({
|
|
5854
5815
|
key: external_exports.string().min(1).max(64),
|
|
@@ -5934,7 +5895,7 @@ var saveCustomConnectorProposalResponseSchema = external_exports.object({
|
|
|
5934
5895
|
connector: customConnectorResponseSchema,
|
|
5935
5896
|
authorizedAgentId: external_exports.string().uuid().optional()
|
|
5936
5897
|
});
|
|
5937
|
-
var zeroCustomConnectorsContract =
|
|
5898
|
+
var zeroCustomConnectorsContract = c21.router({
|
|
5938
5899
|
list: {
|
|
5939
5900
|
method: "GET",
|
|
5940
5901
|
path: "/api/zero/custom-connectors",
|
|
@@ -5961,7 +5922,7 @@ var zeroCustomConnectorsContract = c22.router({
|
|
|
5961
5922
|
summary: "Create an org custom connector"
|
|
5962
5923
|
}
|
|
5963
5924
|
});
|
|
5964
|
-
var zeroCustomConnectorByIdContract =
|
|
5925
|
+
var zeroCustomConnectorByIdContract = c21.router({
|
|
5965
5926
|
get: {
|
|
5966
5927
|
method: "GET",
|
|
5967
5928
|
path: "/api/zero/custom-connectors/:id",
|
|
@@ -5982,7 +5943,7 @@ var zeroCustomConnectorByIdContract = c22.router({
|
|
|
5982
5943
|
headers: authHeadersSchema,
|
|
5983
5944
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
5984
5945
|
responses: {
|
|
5985
|
-
204:
|
|
5946
|
+
204: c21.noBody(),
|
|
5986
5947
|
401: apiErrorSchema,
|
|
5987
5948
|
403: apiErrorSchema,
|
|
5988
5949
|
404: apiErrorSchema,
|
|
@@ -6007,7 +5968,7 @@ var zeroCustomConnectorByIdContract = c22.router({
|
|
|
6007
5968
|
summary: "Rename an org custom connector"
|
|
6008
5969
|
}
|
|
6009
5970
|
});
|
|
6010
|
-
var zeroCustomConnectorSecretContract =
|
|
5971
|
+
var zeroCustomConnectorSecretContract = c21.router({
|
|
6011
5972
|
set: {
|
|
6012
5973
|
method: "PUT",
|
|
6013
5974
|
path: "/api/zero/custom-connectors/:id/secret",
|
|
@@ -6015,7 +5976,7 @@ var zeroCustomConnectorSecretContract = c22.router({
|
|
|
6015
5976
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
6016
5977
|
body: setCustomConnectorSecretBodySchema,
|
|
6017
5978
|
responses: {
|
|
6018
|
-
204:
|
|
5979
|
+
204: c21.noBody(),
|
|
6019
5980
|
400: apiErrorSchema,
|
|
6020
5981
|
401: apiErrorSchema,
|
|
6021
5982
|
404: apiErrorSchema,
|
|
@@ -6029,7 +5990,7 @@ var zeroCustomConnectorSecretContract = c22.router({
|
|
|
6029
5990
|
headers: authHeadersSchema,
|
|
6030
5991
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
6031
5992
|
responses: {
|
|
6032
|
-
204:
|
|
5993
|
+
204: c21.noBody(),
|
|
6033
5994
|
401: apiErrorSchema,
|
|
6034
5995
|
404: apiErrorSchema,
|
|
6035
5996
|
500: apiErrorSchema
|
|
@@ -6037,7 +5998,7 @@ var zeroCustomConnectorSecretContract = c22.router({
|
|
|
6037
5998
|
summary: "Clear the calling user's secret for a custom connector"
|
|
6038
5999
|
}
|
|
6039
6000
|
});
|
|
6040
|
-
var zeroCustomConnectorProposalContract =
|
|
6001
|
+
var zeroCustomConnectorProposalContract = c21.router({
|
|
6041
6002
|
save: {
|
|
6042
6003
|
method: "POST",
|
|
6043
6004
|
path: "/api/zero/custom-connectors/proposals/save",
|
|
@@ -6058,8 +6019,8 @@ var zeroCustomConnectorProposalContract = c22.router({
|
|
|
6058
6019
|
// src/lib/api/domains/zero-connectors.ts
|
|
6059
6020
|
async function listZeroConnectors() {
|
|
6060
6021
|
const config = await getClientConfig();
|
|
6061
|
-
const
|
|
6062
|
-
const result = await
|
|
6022
|
+
const client2 = initClient(zeroConnectorsMainContract, config);
|
|
6023
|
+
const result = await client2.list({ headers: {} });
|
|
6063
6024
|
if (result.status === 200) {
|
|
6064
6025
|
return result.body;
|
|
6065
6026
|
}
|
|
@@ -6067,8 +6028,8 @@ async function listZeroConnectors() {
|
|
|
6067
6028
|
}
|
|
6068
6029
|
async function listZeroConnectorCatalog() {
|
|
6069
6030
|
const config = await getClientConfig();
|
|
6070
|
-
const
|
|
6071
|
-
const result = await
|
|
6031
|
+
const client2 = initClient(zeroConnectorCatalogContract, config);
|
|
6032
|
+
const result = await client2.list({ headers: {} });
|
|
6072
6033
|
if (result.status === 200) {
|
|
6073
6034
|
return result.body;
|
|
6074
6035
|
}
|
|
@@ -6076,8 +6037,8 @@ async function listZeroConnectorCatalog() {
|
|
|
6076
6037
|
}
|
|
6077
6038
|
async function listZeroConnectorCatalogStatus() {
|
|
6078
6039
|
const config = await getClientConfig();
|
|
6079
|
-
const
|
|
6080
|
-
const result = await
|
|
6040
|
+
const client2 = initClient(zeroConnectorCatalogContract, config);
|
|
6041
|
+
const result = await client2.status({ headers: {} });
|
|
6081
6042
|
if (result.status === 200) {
|
|
6082
6043
|
return result.body;
|
|
6083
6044
|
}
|
|
@@ -6085,8 +6046,8 @@ async function listZeroConnectorCatalogStatus() {
|
|
|
6085
6046
|
}
|
|
6086
6047
|
async function getZeroConnectorCatalogPermissions(connectorRef) {
|
|
6087
6048
|
const config = await getClientConfig();
|
|
6088
|
-
const
|
|
6089
|
-
const result = await
|
|
6049
|
+
const client2 = initClient(zeroConnectorCatalogContract, config);
|
|
6050
|
+
const result = await client2.permissions({
|
|
6090
6051
|
params: { connectorRef }
|
|
6091
6052
|
});
|
|
6092
6053
|
if (result.status === 200) {
|
|
@@ -6107,11 +6068,11 @@ async function getZeroConnectorCatalogPermissions(connectorRef) {
|
|
|
6107
6068
|
}
|
|
6108
6069
|
async function diagnoseZeroConnectorCheck(request) {
|
|
6109
6070
|
const config = await getClientConfig();
|
|
6110
|
-
const
|
|
6071
|
+
const client2 = initClient(zeroConnectorCheckContract, {
|
|
6111
6072
|
...config,
|
|
6112
6073
|
validateResponse: true
|
|
6113
6074
|
});
|
|
6114
|
-
const result = await
|
|
6075
|
+
const result = await client2.check({ body: request });
|
|
6115
6076
|
if (result.status === 200) {
|
|
6116
6077
|
return result.body;
|
|
6117
6078
|
}
|
|
@@ -6119,8 +6080,8 @@ async function diagnoseZeroConnectorCheck(request) {
|
|
|
6119
6080
|
}
|
|
6120
6081
|
async function getZeroConnector(type) {
|
|
6121
6082
|
const config = await getClientConfig();
|
|
6122
|
-
const
|
|
6123
|
-
const result = await
|
|
6083
|
+
const client2 = initClient(zeroConnectorsByTypeContract, config);
|
|
6084
|
+
const result = await client2.get({
|
|
6124
6085
|
params: { type }
|
|
6125
6086
|
});
|
|
6126
6087
|
if (result.status === 200) {
|
|
@@ -6133,8 +6094,8 @@ async function getZeroConnector(type) {
|
|
|
6133
6094
|
}
|
|
6134
6095
|
async function connectZeroConnectorManualGrant(type, authMethod, values) {
|
|
6135
6096
|
const config = await getClientConfig();
|
|
6136
|
-
const
|
|
6137
|
-
const result = await
|
|
6097
|
+
const client2 = initClient(zeroConnectorManualGrantContract, config);
|
|
6098
|
+
const result = await client2.connect({
|
|
6138
6099
|
params: { type },
|
|
6139
6100
|
body: { authMethod, values }
|
|
6140
6101
|
});
|
|
@@ -6145,8 +6106,8 @@ async function connectZeroConnectorManualGrant(type, authMethod, values) {
|
|
|
6145
6106
|
}
|
|
6146
6107
|
async function listZeroCustomConnectors() {
|
|
6147
6108
|
const config = await getClientConfig();
|
|
6148
|
-
const
|
|
6149
|
-
const result = await
|
|
6109
|
+
const client2 = initClient(zeroCustomConnectorsContract, config);
|
|
6110
|
+
const result = await client2.list({ headers: {} });
|
|
6150
6111
|
if (result.status === 200) {
|
|
6151
6112
|
return result.body.connectors;
|
|
6152
6113
|
}
|
|
@@ -6154,8 +6115,8 @@ async function listZeroCustomConnectors() {
|
|
|
6154
6115
|
}
|
|
6155
6116
|
async function getZeroCustomConnector(id) {
|
|
6156
6117
|
const config = await getClientConfig();
|
|
6157
|
-
const
|
|
6158
|
-
const result = await
|
|
6118
|
+
const client2 = initClient(zeroCustomConnectorByIdContract, config);
|
|
6119
|
+
const result = await client2.get({ params: { id }, headers: {} });
|
|
6159
6120
|
if (result.status === 200) {
|
|
6160
6121
|
return result.body;
|
|
6161
6122
|
}
|
|
@@ -6176,7 +6137,7 @@ init_esm_shims();
|
|
|
6176
6137
|
|
|
6177
6138
|
// ../../packages/api-contracts/src/contracts/runners.ts
|
|
6178
6139
|
init_esm_shims();
|
|
6179
|
-
var
|
|
6140
|
+
var c22 = initContract();
|
|
6180
6141
|
var MIN_EPOCH_MS_TIMESTAMP = 1e12;
|
|
6181
6142
|
var apiStartTimeSchema = external_exports.number().int().min(MIN_EPOCH_MS_TIMESTAMP);
|
|
6182
6143
|
var CANONICAL_GUEST_HOME_DIR = "/home/user";
|
|
@@ -6300,7 +6261,7 @@ var heldSessionStateSchema = external_exports.object({
|
|
|
6300
6261
|
})
|
|
6301
6262
|
).max(8).optional()
|
|
6302
6263
|
});
|
|
6303
|
-
var runnersPollContract =
|
|
6264
|
+
var runnersPollContract = c22.router({
|
|
6304
6265
|
poll: {
|
|
6305
6266
|
method: "POST",
|
|
6306
6267
|
path: "/api/runners/poll",
|
|
@@ -6623,7 +6584,7 @@ var executionContextSchema = external_exports.object({
|
|
|
6623
6584
|
// API-owned Codex provider/runtime metadata forwarded through the runner.
|
|
6624
6585
|
codexRuntimeConfig: modelProviderCodexRuntimeConfigSchema.nullable().optional()
|
|
6625
6586
|
});
|
|
6626
|
-
var runnersJobClaimContract =
|
|
6587
|
+
var runnersJobClaimContract = c22.router({
|
|
6627
6588
|
claim: {
|
|
6628
6589
|
method: "POST",
|
|
6629
6590
|
path: "/api/runners/jobs/:id/claim",
|
|
@@ -6647,7 +6608,7 @@ var runnersJobClaimContract = c23.router({
|
|
|
6647
6608
|
summary: "Claim a pending job for execution"
|
|
6648
6609
|
}
|
|
6649
6610
|
});
|
|
6650
|
-
var runnersNetworkPolicyRefreshContract =
|
|
6611
|
+
var runnersNetworkPolicyRefreshContract = c22.router({
|
|
6651
6612
|
refresh: {
|
|
6652
6613
|
method: "POST",
|
|
6653
6614
|
path: "/api/runners/runs/:runId/network-policy-refresh",
|
|
@@ -6677,7 +6638,7 @@ var runnersNetworkPolicyRefreshContract = c23.router({
|
|
|
6677
6638
|
summary: "Refresh active run network policies"
|
|
6678
6639
|
}
|
|
6679
6640
|
});
|
|
6680
|
-
var runnersBuiltinFirewallsResolveContract =
|
|
6641
|
+
var runnersBuiltinFirewallsResolveContract = c22.router({
|
|
6681
6642
|
resolve: {
|
|
6682
6643
|
method: "POST",
|
|
6683
6644
|
path: "/api/runners/builtin-firewalls/resolve",
|
|
@@ -6723,7 +6684,7 @@ var heartbeatBodySchema = external_exports.object({
|
|
|
6723
6684
|
message: "heldSessionStates may contain at most 1024 workspace caches"
|
|
6724
6685
|
});
|
|
6725
6686
|
});
|
|
6726
|
-
var runnersHeartbeatContract =
|
|
6687
|
+
var runnersHeartbeatContract = c22.router({
|
|
6727
6688
|
heartbeat: {
|
|
6728
6689
|
method: "POST",
|
|
6729
6690
|
path: "/api/runners/heartbeat",
|
|
@@ -6741,7 +6702,7 @@ var runnersHeartbeatContract = c23.router({
|
|
|
6741
6702
|
|
|
6742
6703
|
// ../../packages/api-contracts/src/contracts/storages.ts
|
|
6743
6704
|
init_esm_shims();
|
|
6744
|
-
var
|
|
6705
|
+
var c23 = initContract();
|
|
6745
6706
|
var storageTypeSchema = external_exports.enum(["volume", "artifact"]);
|
|
6746
6707
|
var versionQuerySchema = external_exports.string().regex(/^[a-f0-9]{8,64}$/i, "Version must be 8-64 hex characters").optional();
|
|
6747
6708
|
var uploadStorageResponseSchema = external_exports.object({
|
|
@@ -6752,7 +6713,7 @@ var uploadStorageResponseSchema = external_exports.object({
|
|
|
6752
6713
|
type: storageTypeSchema,
|
|
6753
6714
|
deduplicated: external_exports.boolean()
|
|
6754
6715
|
});
|
|
6755
|
-
var storagesContract =
|
|
6716
|
+
var storagesContract = c23.router({
|
|
6756
6717
|
/**
|
|
6757
6718
|
* POST /api/storages
|
|
6758
6719
|
* Upload a storage (tar.gz file)
|
|
@@ -6769,7 +6730,7 @@ var storagesContract = c24.router({
|
|
|
6769
6730
|
path: "/api/storages",
|
|
6770
6731
|
headers: authHeadersSchema,
|
|
6771
6732
|
contentType: "multipart/form-data",
|
|
6772
|
-
body:
|
|
6733
|
+
body: c23.type(),
|
|
6773
6734
|
responses: {
|
|
6774
6735
|
200: uploadStorageResponseSchema,
|
|
6775
6736
|
400: apiErrorSchema,
|
|
@@ -6798,9 +6759,9 @@ var storagesContract = c24.router({
|
|
|
6798
6759
|
}),
|
|
6799
6760
|
responses: {
|
|
6800
6761
|
// Binary response - actual handling done at route level
|
|
6801
|
-
200:
|
|
6762
|
+
200: c23.otherResponse({
|
|
6802
6763
|
contentType: "application/gzip",
|
|
6803
|
-
body:
|
|
6764
|
+
body: c23.type()
|
|
6804
6765
|
}),
|
|
6805
6766
|
400: apiErrorSchema,
|
|
6806
6767
|
401: apiErrorSchema,
|
|
@@ -6825,7 +6786,7 @@ var presignedUploadSchema = external_exports.object({
|
|
|
6825
6786
|
key: external_exports.string(),
|
|
6826
6787
|
presignedUrl: external_exports.url()
|
|
6827
6788
|
});
|
|
6828
|
-
var storagesPrepareContract =
|
|
6789
|
+
var storagesPrepareContract = c23.router({
|
|
6829
6790
|
prepare: {
|
|
6830
6791
|
method: "POST",
|
|
6831
6792
|
path: "/api/storages/prepare",
|
|
@@ -6860,7 +6821,7 @@ var storagesPrepareContract = c24.router({
|
|
|
6860
6821
|
summary: "Prepare for direct S3 upload"
|
|
6861
6822
|
}
|
|
6862
6823
|
});
|
|
6863
|
-
var storagesCommitContract =
|
|
6824
|
+
var storagesCommitContract = c23.router({
|
|
6864
6825
|
commit: {
|
|
6865
6826
|
method: "POST",
|
|
6866
6827
|
path: "/api/storages/commit",
|
|
@@ -6894,7 +6855,7 @@ var storagesCommitContract = c24.router({
|
|
|
6894
6855
|
summary: "Commit uploaded storage"
|
|
6895
6856
|
}
|
|
6896
6857
|
});
|
|
6897
|
-
var storagesDownloadContract =
|
|
6858
|
+
var storagesDownloadContract = c23.router({
|
|
6898
6859
|
download: {
|
|
6899
6860
|
method: "GET",
|
|
6900
6861
|
path: "/api/storages/download",
|
|
@@ -6930,7 +6891,7 @@ var storagesDownloadContract = c24.router({
|
|
|
6930
6891
|
summary: "Get presigned download URL"
|
|
6931
6892
|
}
|
|
6932
6893
|
});
|
|
6933
|
-
var storagesListContract =
|
|
6894
|
+
var storagesListContract = c23.router({
|
|
6934
6895
|
list: {
|
|
6935
6896
|
method: "GET",
|
|
6936
6897
|
path: "/api/storages/list",
|
|
@@ -6958,7 +6919,7 @@ var storagesListContract = c24.router({
|
|
|
6958
6919
|
});
|
|
6959
6920
|
|
|
6960
6921
|
// ../../packages/api-contracts/src/contracts/webhooks.ts
|
|
6961
|
-
var
|
|
6922
|
+
var c24 = initContract();
|
|
6962
6923
|
var sha256HexSchema = external_exports.string().regex(
|
|
6963
6924
|
/^[a-f0-9]{64}$/,
|
|
6964
6925
|
"hash must be a lowercase 64-character SHA-256 hex string"
|
|
@@ -6968,11 +6929,11 @@ var thirdPartyWebhookOkSchema = external_exports.union([
|
|
|
6968
6929
|
external_exports.string(),
|
|
6969
6930
|
external_exports.object({ message: external_exports.literal("pong") })
|
|
6970
6931
|
]);
|
|
6971
|
-
var webhookClerkContract =
|
|
6932
|
+
var webhookClerkContract = c24.router({
|
|
6972
6933
|
post: {
|
|
6973
6934
|
method: "POST",
|
|
6974
6935
|
path: "/api/webhooks/clerk",
|
|
6975
|
-
body:
|
|
6936
|
+
body: c24.type(),
|
|
6976
6937
|
responses: {
|
|
6977
6938
|
200: thirdPartyWebhookOkSchema,
|
|
6978
6939
|
401: thirdPartyWebhookErrorSchema
|
|
@@ -6980,11 +6941,11 @@ var webhookClerkContract = c25.router({
|
|
|
6980
6941
|
summary: "Handle Clerk organization and user webhooks"
|
|
6981
6942
|
}
|
|
6982
6943
|
});
|
|
6983
|
-
var webhookGithubContract =
|
|
6944
|
+
var webhookGithubContract = c24.router({
|
|
6984
6945
|
post: {
|
|
6985
6946
|
method: "POST",
|
|
6986
6947
|
path: "/api/webhooks/github",
|
|
6987
|
-
body:
|
|
6948
|
+
body: c24.type(),
|
|
6988
6949
|
responses: {
|
|
6989
6950
|
200: thirdPartyWebhookOkSchema,
|
|
6990
6951
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -6994,11 +6955,11 @@ var webhookGithubContract = c25.router({
|
|
|
6994
6955
|
summary: "Handle GitHub App webhooks"
|
|
6995
6956
|
}
|
|
6996
6957
|
});
|
|
6997
|
-
var webhookStripeContract =
|
|
6958
|
+
var webhookStripeContract = c24.router({
|
|
6998
6959
|
post: {
|
|
6999
6960
|
method: "POST",
|
|
7000
6961
|
path: "/api/webhooks/stripe",
|
|
7001
|
-
body:
|
|
6962
|
+
body: c24.type(),
|
|
7002
6963
|
responses: {
|
|
7003
6964
|
200: thirdPartyWebhookOkSchema,
|
|
7004
6965
|
401: thirdPartyWebhookErrorSchema,
|
|
@@ -7037,11 +6998,11 @@ var workflowAutomationWebhookResponseSchema = external_exports.object({
|
|
|
7037
6998
|
duplicate: external_exports.boolean(),
|
|
7038
6999
|
runId: external_exports.string().uuid().optional()
|
|
7039
7000
|
});
|
|
7040
|
-
var webhookGmailContract =
|
|
7001
|
+
var webhookGmailContract = c24.router({
|
|
7041
7002
|
post: {
|
|
7042
7003
|
method: "POST",
|
|
7043
7004
|
path: "/api/webhooks/gmail",
|
|
7044
|
-
body:
|
|
7005
|
+
body: c24.type(),
|
|
7045
7006
|
responses: {
|
|
7046
7007
|
200: gmailWebhookResponseSchema,
|
|
7047
7008
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7052,11 +7013,11 @@ var webhookGmailContract = c25.router({
|
|
|
7052
7013
|
summary: "Handle Gmail Pub/Sub push notifications"
|
|
7053
7014
|
}
|
|
7054
7015
|
});
|
|
7055
|
-
var webhookGoogleCalendarContract =
|
|
7016
|
+
var webhookGoogleCalendarContract = c24.router({
|
|
7056
7017
|
post: {
|
|
7057
7018
|
method: "POST",
|
|
7058
7019
|
path: "/api/webhooks/google-calendar",
|
|
7059
|
-
body:
|
|
7020
|
+
body: c24.type(),
|
|
7060
7021
|
responses: {
|
|
7061
7022
|
200: googleCalendarWebhookResponseSchema,
|
|
7062
7023
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7067,11 +7028,11 @@ var webhookGoogleCalendarContract = c25.router({
|
|
|
7067
7028
|
summary: "Handle Google Calendar push notifications"
|
|
7068
7029
|
}
|
|
7069
7030
|
});
|
|
7070
|
-
var webhookGoogleWorkspaceEventsContract =
|
|
7031
|
+
var webhookGoogleWorkspaceEventsContract = c24.router({
|
|
7071
7032
|
post: {
|
|
7072
7033
|
method: "POST",
|
|
7073
7034
|
path: "/api/webhooks/google-workspace-events",
|
|
7074
|
-
body:
|
|
7035
|
+
body: c24.type(),
|
|
7075
7036
|
responses: {
|
|
7076
7037
|
200: googleWorkspaceEventsWebhookResponseSchema,
|
|
7077
7038
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7082,11 +7043,11 @@ var webhookGoogleWorkspaceEventsContract = c25.router({
|
|
|
7082
7043
|
summary: "Handle Google Workspace Events Pub/Sub push notifications"
|
|
7083
7044
|
}
|
|
7084
7045
|
});
|
|
7085
|
-
var webhookNotionContract =
|
|
7046
|
+
var webhookNotionContract = c24.router({
|
|
7086
7047
|
post: {
|
|
7087
7048
|
method: "POST",
|
|
7088
7049
|
path: "/api/webhooks/notion",
|
|
7089
|
-
body:
|
|
7050
|
+
body: c24.type(),
|
|
7090
7051
|
responses: {
|
|
7091
7052
|
200: notionWebhookResponseSchema,
|
|
7092
7053
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7101,7 +7062,7 @@ var workflowAutomationWebhookPostRoute = {
|
|
|
7101
7062
|
pathParams: external_exports.object({
|
|
7102
7063
|
token: external_exports.string().min(1)
|
|
7103
7064
|
}),
|
|
7104
|
-
body:
|
|
7065
|
+
body: c24.type(),
|
|
7105
7066
|
responses: {
|
|
7106
7067
|
200: workflowAutomationWebhookResponseSchema,
|
|
7107
7068
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7112,14 +7073,14 @@ var workflowAutomationWebhookPostRoute = {
|
|
|
7112
7073
|
500: thirdPartyWebhookErrorSchema
|
|
7113
7074
|
}
|
|
7114
7075
|
};
|
|
7115
|
-
var webhookWorkflowAutomationContract =
|
|
7076
|
+
var webhookWorkflowAutomationContract = c24.router({
|
|
7116
7077
|
post: {
|
|
7117
7078
|
...workflowAutomationWebhookPostRoute,
|
|
7118
7079
|
path: "/api/webhooks/workflow-automations/:token",
|
|
7119
7080
|
summary: "Handle inbound workflow automation webhooks"
|
|
7120
7081
|
}
|
|
7121
7082
|
});
|
|
7122
|
-
var webhookBuiltInGenerationFalContract =
|
|
7083
|
+
var webhookBuiltInGenerationFalContract = c24.router({
|
|
7123
7084
|
post: {
|
|
7124
7085
|
method: "POST",
|
|
7125
7086
|
path: "/api/webhooks/built-in-generations/fal/:generationId",
|
|
@@ -7130,7 +7091,7 @@ var webhookBuiltInGenerationFalContract = c25.router({
|
|
|
7130
7091
|
token: external_exports.string().min(1),
|
|
7131
7092
|
visualKey: external_exports.string().min(1).optional()
|
|
7132
7093
|
}),
|
|
7133
|
-
body:
|
|
7094
|
+
body: c24.type(),
|
|
7134
7095
|
responses: {
|
|
7135
7096
|
200: thirdPartyWebhookOkSchema,
|
|
7136
7097
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7140,7 +7101,7 @@ var webhookBuiltInGenerationFalContract = c25.router({
|
|
|
7140
7101
|
summary: "Handle fal built-in generation webhooks"
|
|
7141
7102
|
}
|
|
7142
7103
|
});
|
|
7143
|
-
var webhookBuiltInGenerationBytePlusContract =
|
|
7104
|
+
var webhookBuiltInGenerationBytePlusContract = c24.router({
|
|
7144
7105
|
post: {
|
|
7145
7106
|
method: "POST",
|
|
7146
7107
|
path: "/api/webhooks/built-in-generations/byteplus/:generationId",
|
|
@@ -7151,7 +7112,7 @@ var webhookBuiltInGenerationBytePlusContract = c25.router({
|
|
|
7151
7112
|
token: external_exports.string().min(1),
|
|
7152
7113
|
visualKey: external_exports.string().min(1).optional()
|
|
7153
7114
|
}),
|
|
7154
|
-
body:
|
|
7115
|
+
body: c24.type(),
|
|
7155
7116
|
responses: {
|
|
7156
7117
|
200: thirdPartyWebhookOkSchema,
|
|
7157
7118
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7211,7 +7172,7 @@ var firewallAuthResponseSchema = external_exports.object({
|
|
|
7211
7172
|
refreshedConnectors: external_exports.array(external_exports.string()),
|
|
7212
7173
|
refreshedSecrets: external_exports.array(external_exports.string())
|
|
7213
7174
|
});
|
|
7214
|
-
var webhookFirewallAuthContract =
|
|
7175
|
+
var webhookFirewallAuthContract = c24.router({
|
|
7215
7176
|
/**
|
|
7216
7177
|
* POST /api/webhooks/agent/firewall/auth
|
|
7217
7178
|
* Resolve firewall auth templates and refresh access tokens on demand.
|
|
@@ -7253,7 +7214,7 @@ var webhookFirewallAuthContract = c25.router({
|
|
|
7253
7214
|
summary: "Resolve firewall auth templates"
|
|
7254
7215
|
}
|
|
7255
7216
|
});
|
|
7256
|
-
var webhookEventsContract =
|
|
7217
|
+
var webhookEventsContract = c24.router({
|
|
7257
7218
|
/**
|
|
7258
7219
|
* POST /api/webhooks/agent/events
|
|
7259
7220
|
* Receive agent events from sandbox
|
|
@@ -7280,7 +7241,7 @@ var webhookEventsContract = c25.router({
|
|
|
7280
7241
|
summary: "Receive agent events from sandbox"
|
|
7281
7242
|
}
|
|
7282
7243
|
});
|
|
7283
|
-
var webhookCompleteContract =
|
|
7244
|
+
var webhookCompleteContract = c24.router({
|
|
7284
7245
|
/**
|
|
7285
7246
|
* POST /api/webhooks/agent/complete
|
|
7286
7247
|
* Handle agent run completion (success or failure)
|
|
@@ -7317,7 +7278,7 @@ var webhookCompleteContract = c25.router({
|
|
|
7317
7278
|
summary: "Handle agent run completion"
|
|
7318
7279
|
}
|
|
7319
7280
|
});
|
|
7320
|
-
var webhookCheckpointsContract =
|
|
7281
|
+
var webhookCheckpointsContract = c24.router({
|
|
7321
7282
|
/**
|
|
7322
7283
|
* POST /api/webhooks/agent/checkpoints
|
|
7323
7284
|
* Create a recoverable checkpoint for an agent run.
|
|
@@ -7352,7 +7313,7 @@ var webhookCheckpointsContract = c25.router({
|
|
|
7352
7313
|
summary: "Create checkpoint for agent run"
|
|
7353
7314
|
}
|
|
7354
7315
|
});
|
|
7355
|
-
var webhookCheckpointsPrepareHistoryContract =
|
|
7316
|
+
var webhookCheckpointsPrepareHistoryContract = c24.router({
|
|
7356
7317
|
prepare: {
|
|
7357
7318
|
method: "POST",
|
|
7358
7319
|
path: "/api/webhooks/agent/checkpoints/prepare-history",
|
|
@@ -7378,7 +7339,7 @@ var webhookCheckpointsPrepareHistoryContract = c25.router({
|
|
|
7378
7339
|
summary: "Get presigned URL for uploading session history to S3"
|
|
7379
7340
|
}
|
|
7380
7341
|
});
|
|
7381
|
-
var webhookHeartbeatContract =
|
|
7342
|
+
var webhookHeartbeatContract = c24.router({
|
|
7382
7343
|
/**
|
|
7383
7344
|
* POST /api/webhooks/agent/heartbeat
|
|
7384
7345
|
* Receive heartbeat signals from sandbox
|
|
@@ -7402,7 +7363,7 @@ var webhookHeartbeatContract = c25.router({
|
|
|
7402
7363
|
summary: "Receive heartbeat from sandbox"
|
|
7403
7364
|
}
|
|
7404
7365
|
});
|
|
7405
|
-
var webhookStoragesContract =
|
|
7366
|
+
var webhookStoragesContract = c24.router({
|
|
7406
7367
|
/**
|
|
7407
7368
|
* POST /api/webhooks/agent/storages
|
|
7408
7369
|
* Create a new version of a storage from sandbox
|
|
@@ -7418,7 +7379,7 @@ var webhookStoragesContract = c25.router({
|
|
|
7418
7379
|
path: "/api/webhooks/agent/storages",
|
|
7419
7380
|
headers: authHeadersSchema,
|
|
7420
7381
|
contentType: "multipart/form-data",
|
|
7421
|
-
body:
|
|
7382
|
+
body: c24.type(),
|
|
7422
7383
|
responses: {
|
|
7423
7384
|
200: external_exports.object({
|
|
7424
7385
|
versionId: external_exports.string(),
|
|
@@ -7434,7 +7395,7 @@ var webhookStoragesContract = c25.router({
|
|
|
7434
7395
|
summary: "Upload storage version from sandbox"
|
|
7435
7396
|
}
|
|
7436
7397
|
});
|
|
7437
|
-
var webhookStoragesIncrementalContract =
|
|
7398
|
+
var webhookStoragesIncrementalContract = c24.router({
|
|
7438
7399
|
/**
|
|
7439
7400
|
* POST /api/webhooks/agent/storages/incremental
|
|
7440
7401
|
* Create a new version using incremental upload
|
|
@@ -7452,7 +7413,7 @@ var webhookStoragesIncrementalContract = c25.router({
|
|
|
7452
7413
|
path: "/api/webhooks/agent/storages/incremental",
|
|
7453
7414
|
headers: authHeadersSchema,
|
|
7454
7415
|
contentType: "multipart/form-data",
|
|
7455
|
-
body:
|
|
7416
|
+
body: c24.type(),
|
|
7456
7417
|
responses: {
|
|
7457
7418
|
200: external_exports.object({
|
|
7458
7419
|
versionId: external_exports.string(),
|
|
@@ -7537,7 +7498,7 @@ var sandboxOperationSchema = external_exports.object({
|
|
|
7537
7498
|
session_history_transfer_encoding_state: sessionHistoryTransferEncodingStateSchema.optional(),
|
|
7538
7499
|
session_history_download_source: sandboxOperationDownloadSourceSchema
|
|
7539
7500
|
});
|
|
7540
|
-
var webhookTelemetryContract =
|
|
7501
|
+
var webhookTelemetryContract = c24.router({
|
|
7541
7502
|
/**
|
|
7542
7503
|
* POST /api/webhooks/agent/telemetry
|
|
7543
7504
|
* Receive telemetry data (system log, metrics, network logs, and sandbox operations) from sandbox
|
|
@@ -7566,7 +7527,7 @@ var webhookTelemetryContract = c25.router({
|
|
|
7566
7527
|
summary: "Receive telemetry data from sandbox"
|
|
7567
7528
|
}
|
|
7568
7529
|
});
|
|
7569
|
-
var webhookStoragesPrepareContract =
|
|
7530
|
+
var webhookStoragesPrepareContract = c24.router({
|
|
7570
7531
|
prepare: {
|
|
7571
7532
|
method: "POST",
|
|
7572
7533
|
path: "/api/webhooks/agent/storages/prepare",
|
|
@@ -7600,7 +7561,7 @@ var webhookStoragesPrepareContract = c25.router({
|
|
|
7600
7561
|
summary: "Prepare for direct S3 upload from sandbox"
|
|
7601
7562
|
}
|
|
7602
7563
|
});
|
|
7603
|
-
var webhookStoragesCommitContract =
|
|
7564
|
+
var webhookStoragesCommitContract = c24.router({
|
|
7604
7565
|
commit: {
|
|
7605
7566
|
method: "POST",
|
|
7606
7567
|
path: "/api/webhooks/agent/storages/commit",
|
|
@@ -7643,7 +7604,7 @@ var webhookUsageEventItemSchema = external_exports.object({
|
|
|
7643
7604
|
quantity: external_exports.number().int().min(0),
|
|
7644
7605
|
grossCredits: external_exports.number().int().min(0).optional()
|
|
7645
7606
|
}).strict();
|
|
7646
|
-
var webhookUsageEventContract =
|
|
7607
|
+
var webhookUsageEventContract = c24.router({
|
|
7647
7608
|
send: {
|
|
7648
7609
|
method: "POST",
|
|
7649
7610
|
path: "/api/webhooks/agent/usage-event",
|
|
@@ -7664,7 +7625,7 @@ var webhookUsageEventContract = c25.router({
|
|
|
7664
7625
|
summary: "Receive billing usage event data from sandbox"
|
|
7665
7626
|
}
|
|
7666
7627
|
});
|
|
7667
|
-
var
|
|
7628
|
+
var webhookModelUsageObservationItemSchema = external_exports.object({
|
|
7668
7629
|
idempotencyKey: external_exports.uuid(),
|
|
7669
7630
|
model: external_exports.string().min(1).max(255),
|
|
7670
7631
|
inputTokens: external_exports.number().int().min(0).max(Number.MAX_SAFE_INTEGER),
|
|
@@ -7677,9 +7638,9 @@ var webhookModelUsageObservationV2ItemSchema = external_exports.object({
|
|
|
7677
7638
|
},
|
|
7678
7639
|
{ message: "At least one token counter must be positive" }
|
|
7679
7640
|
);
|
|
7680
|
-
var
|
|
7641
|
+
var webhookModelUsageObservationBodySchema = external_exports.object({
|
|
7681
7642
|
runId: external_exports.string().min(1, "runId is required"),
|
|
7682
|
-
events: external_exports.array(
|
|
7643
|
+
events: external_exports.array(webhookModelUsageObservationItemSchema).min(1).max(100)
|
|
7683
7644
|
}).strict().superRefine((body, ctx) => {
|
|
7684
7645
|
const idempotencyKeys = /* @__PURE__ */ new Set();
|
|
7685
7646
|
body.events.forEach((event, index) => {
|
|
@@ -7693,30 +7654,12 @@ var webhookModelUsageObservationV2BodySchema = external_exports.object({
|
|
|
7693
7654
|
idempotencyKeys.add(event.idempotencyKey);
|
|
7694
7655
|
});
|
|
7695
7656
|
});
|
|
7696
|
-
var webhookModelUsageObservationContract =
|
|
7657
|
+
var webhookModelUsageObservationContract = c24.router({
|
|
7697
7658
|
send: {
|
|
7698
7659
|
method: "POST",
|
|
7699
7660
|
path: "/api/webhooks/agent/model-usage-observation",
|
|
7700
7661
|
headers: authHeadersSchema,
|
|
7701
|
-
body:
|
|
7702
|
-
responses: {
|
|
7703
|
-
200: external_exports.object({
|
|
7704
|
-
success: external_exports.boolean()
|
|
7705
|
-
}),
|
|
7706
|
-
400: apiErrorSchema,
|
|
7707
|
-
401: apiErrorSchema,
|
|
7708
|
-
404: apiErrorSchema,
|
|
7709
|
-
500: apiErrorSchema
|
|
7710
|
-
},
|
|
7711
|
-
summary: "Receive compact model usage observation data from sandbox"
|
|
7712
|
-
}
|
|
7713
|
-
});
|
|
7714
|
-
var webhookModelUsageObservationV2Contract = c25.router({
|
|
7715
|
-
send: {
|
|
7716
|
-
method: "POST",
|
|
7717
|
-
path: "/api/webhooks/agent/model-usage-observation-v2",
|
|
7718
|
-
headers: authHeadersSchema,
|
|
7719
|
-
body: webhookModelUsageObservationV2BodySchema,
|
|
7662
|
+
body: webhookModelUsageObservationBodySchema,
|
|
7720
7663
|
responses: {
|
|
7721
7664
|
200: external_exports.object({
|
|
7722
7665
|
success: external_exports.boolean()
|
|
@@ -7746,7 +7689,7 @@ var zeroRunRequestSchema = unifiedRunRequestSchema.omit({
|
|
|
7746
7689
|
agentId: external_exports.string().optional(),
|
|
7747
7690
|
modelProvider: external_exports.string().optional()
|
|
7748
7691
|
});
|
|
7749
|
-
var
|
|
7692
|
+
var c25 = initContract();
|
|
7750
7693
|
var zeroLogPaginationQuerySchema = createLogPaginationQuerySchema({
|
|
7751
7694
|
cursorKind: "sequence"
|
|
7752
7695
|
});
|
|
@@ -7756,7 +7699,7 @@ var zeroNetworkLogPaginationQuerySchema = createLogPaginationQuerySchema({
|
|
|
7756
7699
|
defaultLimit: 500,
|
|
7757
7700
|
defaultOrder: "asc"
|
|
7758
7701
|
});
|
|
7759
|
-
var zeroRunsMainContract =
|
|
7702
|
+
var zeroRunsMainContract = c25.router({
|
|
7760
7703
|
create: {
|
|
7761
7704
|
method: "POST",
|
|
7762
7705
|
path: "/api/zero/runs",
|
|
@@ -7775,7 +7718,7 @@ var zeroRunsMainContract = c26.router({
|
|
|
7775
7718
|
summary: "Create and execute agent run (zero proxy)"
|
|
7776
7719
|
}
|
|
7777
7720
|
});
|
|
7778
|
-
var zeroRunsByIdContract =
|
|
7721
|
+
var zeroRunsByIdContract = c25.router({
|
|
7779
7722
|
getById: {
|
|
7780
7723
|
method: "GET",
|
|
7781
7724
|
path: "/api/zero/runs/:id",
|
|
@@ -7793,7 +7736,7 @@ var zeroRunsByIdContract = c26.router({
|
|
|
7793
7736
|
summary: "Get agent run by ID (zero proxy)"
|
|
7794
7737
|
}
|
|
7795
7738
|
});
|
|
7796
|
-
var zeroRunsCancelContract =
|
|
7739
|
+
var zeroRunsCancelContract = c25.router({
|
|
7797
7740
|
cancel: {
|
|
7798
7741
|
method: "POST",
|
|
7799
7742
|
path: "/api/zero/runs/:id/cancel",
|
|
@@ -7812,7 +7755,7 @@ var zeroRunsCancelContract = c26.router({
|
|
|
7812
7755
|
summary: "Cancel a pending or running run (zero proxy)"
|
|
7813
7756
|
}
|
|
7814
7757
|
});
|
|
7815
|
-
var zeroRunsQueueContract =
|
|
7758
|
+
var zeroRunsQueueContract = c25.router({
|
|
7816
7759
|
getQueue: {
|
|
7817
7760
|
method: "GET",
|
|
7818
7761
|
path: "/api/zero/runs/queue",
|
|
@@ -7825,7 +7768,7 @@ var zeroRunsQueueContract = c26.router({
|
|
|
7825
7768
|
summary: "Get org run queue status (zero proxy)"
|
|
7826
7769
|
}
|
|
7827
7770
|
});
|
|
7828
|
-
var zeroRunAgentEventsContract =
|
|
7771
|
+
var zeroRunAgentEventsContract = c25.router({
|
|
7829
7772
|
getAgentEvents: {
|
|
7830
7773
|
method: "GET",
|
|
7831
7774
|
path: "/api/zero/runs/:id/telemetry/agent",
|
|
@@ -7889,7 +7832,7 @@ var runContextResponseSchema = external_exports.object({
|
|
|
7889
7832
|
artifact: runContextArtifactSchema.nullable(),
|
|
7890
7833
|
featureFlags: external_exports.record(external_exports.string(), external_exports.boolean()).nullable()
|
|
7891
7834
|
});
|
|
7892
|
-
var zeroRunContextContract =
|
|
7835
|
+
var zeroRunContextContract = c25.router({
|
|
7893
7836
|
getContext: {
|
|
7894
7837
|
method: "GET",
|
|
7895
7838
|
path: "/api/zero/runs/:id/context",
|
|
@@ -7907,7 +7850,7 @@ var zeroRunContextContract = c26.router({
|
|
|
7907
7850
|
summary: "Get run execution context snapshot for debugging"
|
|
7908
7851
|
}
|
|
7909
7852
|
});
|
|
7910
|
-
var zeroRunNetworkLogsContract =
|
|
7853
|
+
var zeroRunNetworkLogsContract = c25.router({
|
|
7911
7854
|
getNetworkLogs: {
|
|
7912
7855
|
method: "GET",
|
|
7913
7856
|
path: "/api/zero/runs/:id/network",
|
|
@@ -7929,7 +7872,7 @@ var zeroRunNetworkLogsContract = c26.router({
|
|
|
7929
7872
|
var runRunnerResponseSchema = external_exports.object({
|
|
7930
7873
|
sandboxReuseResult: sandboxReuseResultSchema.nullable()
|
|
7931
7874
|
});
|
|
7932
|
-
var zeroRunRunnerContract =
|
|
7875
|
+
var zeroRunRunnerContract = c25.router({
|
|
7933
7876
|
getRunner: {
|
|
7934
7877
|
method: "GET",
|
|
7935
7878
|
path: "/api/zero/runs/:id/runner",
|
|
@@ -7947,7 +7890,7 @@ var zeroRunRunnerContract = c26.router({
|
|
|
7947
7890
|
summary: "Get runner-level metadata for a run"
|
|
7948
7891
|
}
|
|
7949
7892
|
});
|
|
7950
|
-
var zeroLogsSearchContract =
|
|
7893
|
+
var zeroLogsSearchContract = c25.router({
|
|
7951
7894
|
searchLogs: {
|
|
7952
7895
|
method: "GET",
|
|
7953
7896
|
path: "/api/zero/logs/search",
|
|
@@ -7966,8 +7909,8 @@ var zeroLogsSearchContract = c26.router({
|
|
|
7966
7909
|
// src/lib/api/domains/zero-runs.ts
|
|
7967
7910
|
async function getZeroRunAgentEvents(id, options) {
|
|
7968
7911
|
const config = await getClientConfig();
|
|
7969
|
-
const
|
|
7970
|
-
const result = await
|
|
7912
|
+
const client2 = initClient(zeroRunAgentEventsContract, config);
|
|
7913
|
+
const result = await client2.getAgentEvents({
|
|
7971
7914
|
params: { id },
|
|
7972
7915
|
query: {
|
|
7973
7916
|
since: options?.since,
|
|
@@ -7985,8 +7928,8 @@ async function getZeroRunAgentEvents(id, options) {
|
|
|
7985
7928
|
init_esm_shims();
|
|
7986
7929
|
async function searchZeroChat(options) {
|
|
7987
7930
|
const config = await getClientConfig();
|
|
7988
|
-
const
|
|
7989
|
-
const result = await
|
|
7931
|
+
const client2 = initClient(chatSearchContract, config);
|
|
7932
|
+
const result = await client2.search({
|
|
7990
7933
|
query: {
|
|
7991
7934
|
keyword: options.keyword,
|
|
7992
7935
|
agentId: options.agentId,
|
|
@@ -8001,8 +7944,8 @@ async function searchZeroChat(options) {
|
|
|
8001
7944
|
}
|
|
8002
7945
|
async function getZeroChatThreadSnapshot() {
|
|
8003
7946
|
const config = await getClientConfig();
|
|
8004
|
-
const
|
|
8005
|
-
const result = await
|
|
7947
|
+
const client2 = initClient(chatThreadsContract, config);
|
|
7948
|
+
const result = await client2.snapshot();
|
|
8006
7949
|
if (result.status === 200) {
|
|
8007
7950
|
return result.body;
|
|
8008
7951
|
}
|
|
@@ -8010,8 +7953,8 @@ async function getZeroChatThreadSnapshot() {
|
|
|
8010
7953
|
}
|
|
8011
7954
|
async function listZeroChatThreadEvents(options) {
|
|
8012
7955
|
const config = await getClientConfig();
|
|
8013
|
-
const
|
|
8014
|
-
const result = await
|
|
7956
|
+
const client2 = initClient(chatThreadsContract, config);
|
|
7957
|
+
const result = await client2.events({
|
|
8015
7958
|
query: options.sinceEventId ? { sinceEventId: options.sinceEventId } : {}
|
|
8016
7959
|
});
|
|
8017
7960
|
if (result.status === 200) {
|
|
@@ -8028,8 +7971,8 @@ async function listZeroChatThreadEvents(options) {
|
|
|
8028
7971
|
}
|
|
8029
7972
|
async function renameZeroChatThread(options) {
|
|
8030
7973
|
const config = await getClientConfig();
|
|
8031
|
-
const
|
|
8032
|
-
const result = await
|
|
7974
|
+
const client2 = initClient(chatThreadRenameContract, config);
|
|
7975
|
+
const result = await client2.rename({
|
|
8033
7976
|
params: { id: options.threadId },
|
|
8034
7977
|
body: { title: options.title }
|
|
8035
7978
|
});
|
|
@@ -8040,8 +7983,8 @@ async function renameZeroChatThread(options) {
|
|
|
8040
7983
|
}
|
|
8041
7984
|
async function getZeroChatThread(options) {
|
|
8042
7985
|
const config = await getClientConfig();
|
|
8043
|
-
const
|
|
8044
|
-
const result = await
|
|
7986
|
+
const client2 = initClient(chatThreadMetadataContract, config);
|
|
7987
|
+
const result = await client2.get({
|
|
8045
7988
|
params: { id: options.threadId }
|
|
8046
7989
|
});
|
|
8047
7990
|
if (result.status === 200) {
|
|
@@ -8051,8 +7994,8 @@ async function getZeroChatThread(options) {
|
|
|
8051
7994
|
}
|
|
8052
7995
|
async function updateZeroChatThreadModelSelection(options) {
|
|
8053
7996
|
const config = await getClientConfig();
|
|
8054
|
-
const
|
|
8055
|
-
const result = await
|
|
7997
|
+
const client2 = initClient(chatThreadModelSelectionContract, config);
|
|
7998
|
+
const result = await client2.update({
|
|
8056
7999
|
params: { id: options.threadId },
|
|
8057
8000
|
body: { model: options.model }
|
|
8058
8001
|
});
|
|
@@ -8070,7 +8013,7 @@ init_esm_shims();
|
|
|
8070
8013
|
|
|
8071
8014
|
// ../../packages/api-contracts/src/contracts/zero-developer-support.ts
|
|
8072
8015
|
init_esm_shims();
|
|
8073
|
-
var
|
|
8016
|
+
var c26 = initContract();
|
|
8074
8017
|
var developerSupportBodySchema = external_exports.object({
|
|
8075
8018
|
title: external_exports.string().min(1, "Title is required"),
|
|
8076
8019
|
description: external_exports.string().min(1, "Description is required"),
|
|
@@ -8082,7 +8025,7 @@ var consentCodeResponseSchema = external_exports.object({
|
|
|
8082
8025
|
var submitResponseSchema = external_exports.object({
|
|
8083
8026
|
reference: external_exports.string()
|
|
8084
8027
|
});
|
|
8085
|
-
var zeroDeveloperSupportContract =
|
|
8028
|
+
var zeroDeveloperSupportContract = c26.router({
|
|
8086
8029
|
submit: {
|
|
8087
8030
|
method: "POST",
|
|
8088
8031
|
path: "/api/zero/developer-support",
|
|
@@ -8101,15 +8044,15 @@ var zeroDeveloperSupportContract = c27.router({
|
|
|
8101
8044
|
// src/lib/api/domains/zero-developer-support.ts
|
|
8102
8045
|
async function requestDeveloperSupportConsent(body) {
|
|
8103
8046
|
const config = await getClientConfig();
|
|
8104
|
-
const
|
|
8105
|
-
const result = await
|
|
8047
|
+
const client2 = initClient(zeroDeveloperSupportContract, config);
|
|
8048
|
+
const result = await client2.submit({ body, headers: {} });
|
|
8106
8049
|
if (result.status === 200) return result.body;
|
|
8107
8050
|
handleError(result, "Failed to request developer support consent");
|
|
8108
8051
|
}
|
|
8109
8052
|
async function submitDeveloperSupport(body) {
|
|
8110
8053
|
const config = await getClientConfig();
|
|
8111
|
-
const
|
|
8112
|
-
const result = await
|
|
8054
|
+
const client2 = initClient(zeroDeveloperSupportContract, config);
|
|
8055
|
+
const result = await client2.submit({ body, headers: {} });
|
|
8113
8056
|
if (result.status === 200) return result.body;
|
|
8114
8057
|
handleError(result, "Failed to submit developer support request");
|
|
8115
8058
|
}
|
|
@@ -8278,7 +8221,7 @@ init_esm_shims();
|
|
|
8278
8221
|
|
|
8279
8222
|
// ../../packages/api-contracts/src/contracts/zero-computer-use.ts
|
|
8280
8223
|
init_esm_shims();
|
|
8281
|
-
var
|
|
8224
|
+
var c27 = initContract();
|
|
8282
8225
|
var computerUseHostStatusSchema = external_exports.enum(["online", "offline"]);
|
|
8283
8226
|
var computerUseReadCommandKindSchema = external_exports.enum([
|
|
8284
8227
|
"apps.list",
|
|
@@ -8337,9 +8280,6 @@ var hostNameSchema = external_exports.string().trim().min(1).max(253);
|
|
|
8337
8280
|
var hostInstallationIdSchema = external_exports.string().trim().uuid();
|
|
8338
8281
|
var hostVersionSchema = external_exports.string().trim().min(1).max(64);
|
|
8339
8282
|
var hostOsVersionSchema = external_exports.string().trim().min(1).max(128);
|
|
8340
|
-
var hostIdPathParamsSchema = external_exports.object({
|
|
8341
|
-
hostId: external_exports.string().min(1)
|
|
8342
|
-
});
|
|
8343
8283
|
var authorizationRequestTokenPathParamsSchema = external_exports.object({
|
|
8344
8284
|
requestToken: external_exports.string().min(1)
|
|
8345
8285
|
});
|
|
@@ -8562,9 +8502,6 @@ var computerUseHostStopResponseSchema = external_exports.object({
|
|
|
8562
8502
|
var computerUseHostListResponseSchema = external_exports.object({
|
|
8563
8503
|
hosts: external_exports.array(computerUseHostSchema)
|
|
8564
8504
|
});
|
|
8565
|
-
var computerUseHostDeleteResponseSchema = external_exports.object({
|
|
8566
|
-
ok: external_exports.literal(true)
|
|
8567
|
-
});
|
|
8568
8505
|
var computerUseAuthorizationSourceSchema = external_exports.enum([
|
|
8569
8506
|
"chat",
|
|
8570
8507
|
"slack",
|
|
@@ -8653,7 +8590,7 @@ var computerUseAuditEventSchema = external_exports.object({
|
|
|
8653
8590
|
var computerUseAuditEventListResponseSchema = external_exports.object({
|
|
8654
8591
|
auditEvents: external_exports.array(computerUseAuditEventSchema)
|
|
8655
8592
|
});
|
|
8656
|
-
var zeroComputerUseHostsContract =
|
|
8593
|
+
var zeroComputerUseHostsContract = c27.router({
|
|
8657
8594
|
start: {
|
|
8658
8595
|
method: "POST",
|
|
8659
8596
|
path: "/api/zero/computer-use/hosts/start",
|
|
@@ -8677,22 +8614,9 @@ var zeroComputerUseHostsContract = c28.router({
|
|
|
8677
8614
|
403: apiErrorSchema
|
|
8678
8615
|
},
|
|
8679
8616
|
summary: "List linked desktop computer-use hosts"
|
|
8680
|
-
},
|
|
8681
|
-
delete: {
|
|
8682
|
-
method: "DELETE",
|
|
8683
|
-
path: "/api/zero/computer-use/hosts/:hostId",
|
|
8684
|
-
headers: authHeadersSchema,
|
|
8685
|
-
pathParams: hostIdPathParamsSchema,
|
|
8686
|
-
responses: {
|
|
8687
|
-
200: computerUseHostDeleteResponseSchema,
|
|
8688
|
-
401: apiErrorSchema,
|
|
8689
|
-
403: apiErrorSchema,
|
|
8690
|
-
404: apiErrorSchema
|
|
8691
|
-
},
|
|
8692
|
-
summary: "Delete a desktop computer-use host"
|
|
8693
8617
|
}
|
|
8694
8618
|
});
|
|
8695
|
-
var zeroComputerUseHeartbeatContract =
|
|
8619
|
+
var zeroComputerUseHeartbeatContract = c27.router({
|
|
8696
8620
|
heartbeat: {
|
|
8697
8621
|
method: "POST",
|
|
8698
8622
|
path: "/api/zero/computer-use/heartbeat",
|
|
@@ -8717,7 +8641,7 @@ var zeroComputerUseHeartbeatContract = c28.router({
|
|
|
8717
8641
|
summary: "Stop a desktop computer-use host"
|
|
8718
8642
|
}
|
|
8719
8643
|
});
|
|
8720
|
-
var zeroComputerUseAuthorizationRequestsContract =
|
|
8644
|
+
var zeroComputerUseAuthorizationRequestsContract = c27.router({
|
|
8721
8645
|
create: {
|
|
8722
8646
|
method: "POST",
|
|
8723
8647
|
path: "/api/zero/computer-use/authorization-requests",
|
|
@@ -8764,7 +8688,7 @@ var zeroComputerUseAuthorizationRequestsContract = c28.router({
|
|
|
8764
8688
|
summary: "Bind a Computer Use host for a delegated authorization request"
|
|
8765
8689
|
}
|
|
8766
8690
|
});
|
|
8767
|
-
var zeroComputerUseCommandContract =
|
|
8691
|
+
var zeroComputerUseCommandContract = c27.router({
|
|
8768
8692
|
create: {
|
|
8769
8693
|
method: "POST",
|
|
8770
8694
|
path: "/api/zero/computer-use/commands",
|
|
@@ -8799,7 +8723,7 @@ var zeroComputerUseCommandContract = c28.router({
|
|
|
8799
8723
|
headers: authHeadersSchema,
|
|
8800
8724
|
pathParams: commandIdPathParamsSchema,
|
|
8801
8725
|
responses: {
|
|
8802
|
-
200:
|
|
8726
|
+
200: c27.type(),
|
|
8803
8727
|
401: apiErrorSchema,
|
|
8804
8728
|
403: apiErrorSchema,
|
|
8805
8729
|
404: apiErrorSchema
|
|
@@ -8812,7 +8736,7 @@ var zeroComputerUseCommandContract = c28.router({
|
|
|
8812
8736
|
headers: authHeadersSchema,
|
|
8813
8737
|
pathParams: commandIdPathParamsSchema,
|
|
8814
8738
|
responses: {
|
|
8815
|
-
200:
|
|
8739
|
+
200: c27.type(),
|
|
8816
8740
|
401: apiErrorSchema,
|
|
8817
8741
|
403: apiErrorSchema,
|
|
8818
8742
|
404: apiErrorSchema
|
|
@@ -8820,7 +8744,7 @@ var zeroComputerUseCommandContract = c28.router({
|
|
|
8820
8744
|
summary: "Download offloaded desktop computer-use plugin content"
|
|
8821
8745
|
}
|
|
8822
8746
|
});
|
|
8823
|
-
var zeroComputerUseWriteCommandContract =
|
|
8747
|
+
var zeroComputerUseWriteCommandContract = c27.router({
|
|
8824
8748
|
create: {
|
|
8825
8749
|
method: "POST",
|
|
8826
8750
|
path: "/api/zero/computer-use/write-commands",
|
|
@@ -8837,7 +8761,7 @@ var zeroComputerUseWriteCommandContract = c28.router({
|
|
|
8837
8761
|
summary: "Create a desktop computer-use write command"
|
|
8838
8762
|
}
|
|
8839
8763
|
});
|
|
8840
|
-
var zeroComputerUsePluginCommandContract =
|
|
8764
|
+
var zeroComputerUsePluginCommandContract = c27.router({
|
|
8841
8765
|
create: {
|
|
8842
8766
|
method: "POST",
|
|
8843
8767
|
path: "/api/zero/computer-use/plugin-commands",
|
|
@@ -8854,7 +8778,7 @@ var zeroComputerUsePluginCommandContract = c28.router({
|
|
|
8854
8778
|
summary: "Create a desktop computer-use plugin command"
|
|
8855
8779
|
}
|
|
8856
8780
|
});
|
|
8857
|
-
var zeroComputerUseHostCommandsContract =
|
|
8781
|
+
var zeroComputerUseHostCommandsContract = c27.router({
|
|
8858
8782
|
next: {
|
|
8859
8783
|
method: "POST",
|
|
8860
8784
|
path: "/api/zero/computer-use/host/commands/next",
|
|
@@ -8882,7 +8806,7 @@ var zeroComputerUseHostCommandsContract = c28.router({
|
|
|
8882
8806
|
summary: "Complete a desktop computer-use command"
|
|
8883
8807
|
}
|
|
8884
8808
|
});
|
|
8885
|
-
var zeroComputerUseAuditEventsContract =
|
|
8809
|
+
var zeroComputerUseAuditEventsContract = c27.router({
|
|
8886
8810
|
list: {
|
|
8887
8811
|
method: "GET",
|
|
8888
8812
|
path: "/api/zero/computer-use/audit-events",
|
|
@@ -8963,8 +8887,8 @@ function commandBody(params) {
|
|
|
8963
8887
|
}
|
|
8964
8888
|
async function createComputerUseReadCommand(params) {
|
|
8965
8889
|
const config = await getComputerUseClientConfig();
|
|
8966
|
-
const
|
|
8967
|
-
const result = await
|
|
8890
|
+
const client2 = initClient(zeroComputerUseCommandContract, config);
|
|
8891
|
+
const result = await client2.create({ body: commandBody(params) });
|
|
8968
8892
|
if (result.status === 200) {
|
|
8969
8893
|
return result.body;
|
|
8970
8894
|
}
|
|
@@ -8972,8 +8896,8 @@ async function createComputerUseReadCommand(params) {
|
|
|
8972
8896
|
}
|
|
8973
8897
|
async function createComputerUseWriteCommand(params) {
|
|
8974
8898
|
const config = await getComputerUseClientConfig();
|
|
8975
|
-
const
|
|
8976
|
-
const result = await
|
|
8899
|
+
const client2 = initClient(zeroComputerUseWriteCommandContract, config);
|
|
8900
|
+
const result = await client2.create({ body: commandBody(params) });
|
|
8977
8901
|
if (result.status === 200) {
|
|
8978
8902
|
return result.body;
|
|
8979
8903
|
}
|
|
@@ -8981,8 +8905,8 @@ async function createComputerUseWriteCommand(params) {
|
|
|
8981
8905
|
}
|
|
8982
8906
|
async function createComputerUsePluginCommand(params) {
|
|
8983
8907
|
const config = await getComputerUseClientConfig();
|
|
8984
|
-
const
|
|
8985
|
-
const result = await
|
|
8908
|
+
const client2 = initClient(zeroComputerUsePluginCommandContract, config);
|
|
8909
|
+
const result = await client2.create({ body: params });
|
|
8986
8910
|
if (result.status === 200) {
|
|
8987
8911
|
return result.body;
|
|
8988
8912
|
}
|
|
@@ -8990,8 +8914,8 @@ async function createComputerUsePluginCommand(params) {
|
|
|
8990
8914
|
}
|
|
8991
8915
|
async function listComputerUseHosts() {
|
|
8992
8916
|
const config = await getComputerUseClientConfig();
|
|
8993
|
-
const
|
|
8994
|
-
const result = await
|
|
8917
|
+
const client2 = initClient(zeroComputerUseHostsContract, config);
|
|
8918
|
+
const result = await client2.list({});
|
|
8995
8919
|
if (result.status === 200) {
|
|
8996
8920
|
return result.body.hosts;
|
|
8997
8921
|
}
|
|
@@ -8999,8 +8923,8 @@ async function listComputerUseHosts() {
|
|
|
8999
8923
|
}
|
|
9000
8924
|
async function getComputerUseCommand(commandId) {
|
|
9001
8925
|
const config = await getComputerUseClientConfig();
|
|
9002
|
-
const
|
|
9003
|
-
const result = await
|
|
8926
|
+
const client2 = initClient(zeroComputerUseCommandContract, config);
|
|
8927
|
+
const result = await client2.get({ params: { commandId } });
|
|
9004
8928
|
if (result.status === 200) {
|
|
9005
8929
|
return result.body;
|
|
9006
8930
|
}
|
|
@@ -9008,11 +8932,11 @@ async function getComputerUseCommand(commandId) {
|
|
|
9008
8932
|
}
|
|
9009
8933
|
async function createComputerUseAuthorizationRequest() {
|
|
9010
8934
|
const config = await getComputerUseClientConfig();
|
|
9011
|
-
const
|
|
8935
|
+
const client2 = initClient(
|
|
9012
8936
|
zeroComputerUseAuthorizationRequestsContract,
|
|
9013
8937
|
config
|
|
9014
8938
|
);
|
|
9015
|
-
const result = await
|
|
8939
|
+
const result = await client2.create({ body: {} });
|
|
9016
8940
|
if (result.status === 200) {
|
|
9017
8941
|
return result.body;
|
|
9018
8942
|
}
|
|
@@ -9059,6 +8983,151 @@ async function fetchComputerUsePluginContent(commandId) {
|
|
|
9059
8983
|
return { buffer: Buffer.from(arrayBuffer), mimeType, fileName };
|
|
9060
8984
|
}
|
|
9061
8985
|
|
|
8986
|
+
// ../../packages/api-contracts/src/contracts/zero-browser.ts
|
|
8987
|
+
init_esm_shims();
|
|
8988
|
+
var c28 = initContract();
|
|
8989
|
+
var ZERO_BROWSER_DEFAULT_TIMEOUT_MINUTES = 30;
|
|
8990
|
+
var ZERO_BROWSER_MAX_TIMEOUT_MINUTES = 240;
|
|
8991
|
+
var ZERO_BROWSER_DEFAULT_MAX_CREDITS = 500;
|
|
8992
|
+
var ZERO_BROWSER_MAX_CREDITS = 1e5;
|
|
8993
|
+
var zeroBrowserStatusSchema = external_exports.enum([
|
|
8994
|
+
"creating",
|
|
8995
|
+
"active",
|
|
8996
|
+
"resuming",
|
|
8997
|
+
"stopping",
|
|
8998
|
+
"suspended",
|
|
8999
|
+
"error"
|
|
9000
|
+
]);
|
|
9001
|
+
var zeroBrowserSuspensionReasonSchema = external_exports.enum([
|
|
9002
|
+
"run_end",
|
|
9003
|
+
"timeout",
|
|
9004
|
+
"budget",
|
|
9005
|
+
"provider",
|
|
9006
|
+
"reconcile"
|
|
9007
|
+
]);
|
|
9008
|
+
var zeroBrowserSessionSchema = external_exports.object({
|
|
9009
|
+
id: external_exports.uuid(),
|
|
9010
|
+
name: external_exports.string().min(1).max(64),
|
|
9011
|
+
status: zeroBrowserStatusSchema,
|
|
9012
|
+
viewerUrl: external_exports.url(),
|
|
9013
|
+
liveUrl: external_exports.url().nullable(),
|
|
9014
|
+
proxyCountryCode: external_exports.string().length(2).nullable(),
|
|
9015
|
+
timeoutMinutes: external_exports.number().int().positive(),
|
|
9016
|
+
maxCredits: external_exports.number().int().positive(),
|
|
9017
|
+
grossCredits: external_exports.number().int().nonnegative(),
|
|
9018
|
+
creditsCharged: external_exports.number().int().nonnegative(),
|
|
9019
|
+
suspendedAt: external_exports.iso.datetime().nullable(),
|
|
9020
|
+
suspensionReason: zeroBrowserSuspensionReasonSchema.nullable(),
|
|
9021
|
+
createdAt: external_exports.iso.datetime(),
|
|
9022
|
+
updatedAt: external_exports.iso.datetime()
|
|
9023
|
+
});
|
|
9024
|
+
var zeroBrowserCreateRequestSchema = external_exports.object({
|
|
9025
|
+
name: external_exports.string().trim().min(1).max(64).default("browser"),
|
|
9026
|
+
proxyCountryCode: external_exports.string().trim().length(2).transform((value) => {
|
|
9027
|
+
return value.toLowerCase();
|
|
9028
|
+
}).nullable().default(null),
|
|
9029
|
+
timeoutMinutes: external_exports.number().int().min(1).max(ZERO_BROWSER_MAX_TIMEOUT_MINUTES).default(ZERO_BROWSER_DEFAULT_TIMEOUT_MINUTES),
|
|
9030
|
+
maxCredits: external_exports.number().int().min(1).max(ZERO_BROWSER_MAX_CREDITS).default(ZERO_BROWSER_DEFAULT_MAX_CREDITS)
|
|
9031
|
+
});
|
|
9032
|
+
var browserIdParamsSchema = external_exports.object({
|
|
9033
|
+
browserId: external_exports.uuid()
|
|
9034
|
+
});
|
|
9035
|
+
var browserGetQuerySchema = external_exports.object({
|
|
9036
|
+
chatThreadId: external_exports.uuid().optional()
|
|
9037
|
+
});
|
|
9038
|
+
var browserResponseSchema = external_exports.object({
|
|
9039
|
+
browser: zeroBrowserSessionSchema
|
|
9040
|
+
});
|
|
9041
|
+
var browserConnectionResponseSchema = browserResponseSchema.extend({
|
|
9042
|
+
cdpUrl: external_exports.url()
|
|
9043
|
+
});
|
|
9044
|
+
var commonErrorResponses = {
|
|
9045
|
+
400: apiErrorSchema,
|
|
9046
|
+
401: apiErrorSchema,
|
|
9047
|
+
402: apiErrorSchema,
|
|
9048
|
+
403: apiErrorSchema,
|
|
9049
|
+
404: apiErrorSchema,
|
|
9050
|
+
409: apiErrorSchema,
|
|
9051
|
+
502: apiErrorSchema,
|
|
9052
|
+
503: apiErrorSchema
|
|
9053
|
+
};
|
|
9054
|
+
var zeroBrowserContract = c28.router({
|
|
9055
|
+
create: {
|
|
9056
|
+
method: "POST",
|
|
9057
|
+
path: "/api/zero/browsers",
|
|
9058
|
+
headers: authHeadersSchema,
|
|
9059
|
+
body: zeroBrowserCreateRequestSchema,
|
|
9060
|
+
responses: {
|
|
9061
|
+
201: browserConnectionResponseSchema,
|
|
9062
|
+
...commonErrorResponses
|
|
9063
|
+
},
|
|
9064
|
+
summary: "Create a new managed browser for the current chat thread using the user's shared profile"
|
|
9065
|
+
},
|
|
9066
|
+
resume: {
|
|
9067
|
+
method: "POST",
|
|
9068
|
+
path: "/api/zero/browsers/resume",
|
|
9069
|
+
headers: authHeadersSchema,
|
|
9070
|
+
body: external_exports.object({}),
|
|
9071
|
+
responses: {
|
|
9072
|
+
200: browserConnectionResponseSchema,
|
|
9073
|
+
...commonErrorResponses
|
|
9074
|
+
},
|
|
9075
|
+
summary: "Resume the current chat thread's managed browser"
|
|
9076
|
+
},
|
|
9077
|
+
current: {
|
|
9078
|
+
method: "GET",
|
|
9079
|
+
path: "/api/zero/browsers/current",
|
|
9080
|
+
headers: authHeadersSchema,
|
|
9081
|
+
responses: {
|
|
9082
|
+
200: browserResponseSchema,
|
|
9083
|
+
...commonErrorResponses
|
|
9084
|
+
},
|
|
9085
|
+
summary: "Get the current chat thread's managed browser"
|
|
9086
|
+
},
|
|
9087
|
+
get: {
|
|
9088
|
+
method: "GET",
|
|
9089
|
+
path: "/api/zero/browsers/:browserId",
|
|
9090
|
+
headers: authHeadersSchema,
|
|
9091
|
+
pathParams: browserIdParamsSchema,
|
|
9092
|
+
query: browserGetQuerySchema,
|
|
9093
|
+
responses: {
|
|
9094
|
+
200: browserResponseSchema,
|
|
9095
|
+
...commonErrorResponses
|
|
9096
|
+
},
|
|
9097
|
+
summary: "Get a managed browser by universal-link ID"
|
|
9098
|
+
}
|
|
9099
|
+
});
|
|
9100
|
+
|
|
9101
|
+
// src/lib/api/domains/zero-browser.ts
|
|
9102
|
+
init_esm_shims();
|
|
9103
|
+
async function client() {
|
|
9104
|
+
return initClient(zeroBrowserContract, await getClientConfig());
|
|
9105
|
+
}
|
|
9106
|
+
async function createZeroBrowser(body) {
|
|
9107
|
+
const result = await (await client()).create({ headers: {}, body });
|
|
9108
|
+
if (result.status === 201) {
|
|
9109
|
+
return result.body;
|
|
9110
|
+
}
|
|
9111
|
+
handleError(result, "Failed to create a new managed browser");
|
|
9112
|
+
}
|
|
9113
|
+
async function resumeZeroBrowser() {
|
|
9114
|
+
const result = await (await client()).resume({
|
|
9115
|
+
headers: {},
|
|
9116
|
+
body: {}
|
|
9117
|
+
});
|
|
9118
|
+
if (result.status === 200) {
|
|
9119
|
+
return result.body;
|
|
9120
|
+
}
|
|
9121
|
+
handleError(result, "Failed to resume the managed browser");
|
|
9122
|
+
}
|
|
9123
|
+
async function getCurrentZeroBrowser() {
|
|
9124
|
+
const result = await (await client()).current({ headers: {} });
|
|
9125
|
+
if (result.status === 200) {
|
|
9126
|
+
return result.body.browser;
|
|
9127
|
+
}
|
|
9128
|
+
handleError(result, "Failed to get the current managed browser");
|
|
9129
|
+
}
|
|
9130
|
+
|
|
9062
9131
|
// src/lib/api/domains/zero-maps.ts
|
|
9063
9132
|
init_esm_shims();
|
|
9064
9133
|
function authenticatedJsonHeaders(token) {
|
|
@@ -9270,8 +9339,8 @@ var zeroScrapeContract = c29.router({
|
|
|
9270
9339
|
init_esm_shims();
|
|
9271
9340
|
async function callZeroScrape(body) {
|
|
9272
9341
|
const config = await getClientConfig();
|
|
9273
|
-
const
|
|
9274
|
-
const result = await
|
|
9342
|
+
const client2 = initClient(zeroScrapeContract, config);
|
|
9343
|
+
const result = await client2.scrape({ headers: {}, body });
|
|
9275
9344
|
if (result.status === 200) {
|
|
9276
9345
|
return result.body;
|
|
9277
9346
|
}
|
|
@@ -9341,8 +9410,8 @@ var zeroPeopleSearchContract = c30.router({
|
|
|
9341
9410
|
init_esm_shims();
|
|
9342
9411
|
async function callZeroPeopleSearch(body) {
|
|
9343
9412
|
const config = await getClientConfig();
|
|
9344
|
-
const
|
|
9345
|
-
const result = await
|
|
9413
|
+
const client2 = initClient(zeroPeopleSearchContract, config);
|
|
9414
|
+
const result = await client2.search({ headers: {}, body });
|
|
9346
9415
|
if (result.status === 200) {
|
|
9347
9416
|
return result.body;
|
|
9348
9417
|
}
|
|
@@ -9433,8 +9502,8 @@ var zeroWebSearchContract = c31.router({
|
|
|
9433
9502
|
init_esm_shims();
|
|
9434
9503
|
async function callZeroWebSearch(body) {
|
|
9435
9504
|
const config = await getClientConfig();
|
|
9436
|
-
const
|
|
9437
|
-
const result = await
|
|
9505
|
+
const client2 = initClient(zeroWebSearchContract, config);
|
|
9506
|
+
const result = await client2.search({ headers: {}, body });
|
|
9438
9507
|
if (result.status === 200) {
|
|
9439
9508
|
return result.body;
|
|
9440
9509
|
}
|
|
@@ -9549,8 +9618,8 @@ var zeroFinanceContract = c32.router({
|
|
|
9549
9618
|
init_esm_shims();
|
|
9550
9619
|
async function callZeroFinanceSearch(body) {
|
|
9551
9620
|
const config = await getClientConfig();
|
|
9552
|
-
const
|
|
9553
|
-
const result = await
|
|
9621
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9622
|
+
const result = await client2.search({ headers: {}, body });
|
|
9554
9623
|
if (result.status === 200) {
|
|
9555
9624
|
return result.body;
|
|
9556
9625
|
}
|
|
@@ -9558,8 +9627,8 @@ async function callZeroFinanceSearch(body) {
|
|
|
9558
9627
|
}
|
|
9559
9628
|
async function callZeroFinanceProfile(body) {
|
|
9560
9629
|
const config = await getClientConfig();
|
|
9561
|
-
const
|
|
9562
|
-
const result = await
|
|
9630
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9631
|
+
const result = await client2.profile({ headers: {}, body });
|
|
9563
9632
|
if (result.status === 200) {
|
|
9564
9633
|
return result.body;
|
|
9565
9634
|
}
|
|
@@ -9567,8 +9636,8 @@ async function callZeroFinanceProfile(body) {
|
|
|
9567
9636
|
}
|
|
9568
9637
|
async function callZeroFinanceQuote(body) {
|
|
9569
9638
|
const config = await getClientConfig();
|
|
9570
|
-
const
|
|
9571
|
-
const result = await
|
|
9639
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9640
|
+
const result = await client2.quote({ headers: {}, body });
|
|
9572
9641
|
if (result.status === 200) {
|
|
9573
9642
|
return result.body;
|
|
9574
9643
|
}
|
|
@@ -9576,8 +9645,8 @@ async function callZeroFinanceQuote(body) {
|
|
|
9576
9645
|
}
|
|
9577
9646
|
async function callZeroFinanceChart(body) {
|
|
9578
9647
|
const config = await getClientConfig();
|
|
9579
|
-
const
|
|
9580
|
-
const result = await
|
|
9648
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9649
|
+
const result = await client2.chart({ headers: {}, body });
|
|
9581
9650
|
if (result.status === 200) {
|
|
9582
9651
|
return result.body;
|
|
9583
9652
|
}
|
|
@@ -9797,8 +9866,8 @@ var zeroVariablesByNameContract = c33.router({
|
|
|
9797
9866
|
// src/lib/api/domains/zero-secrets.ts
|
|
9798
9867
|
async function listZeroSecrets() {
|
|
9799
9868
|
const config = await getClientConfig();
|
|
9800
|
-
const
|
|
9801
|
-
const result = await
|
|
9869
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9870
|
+
const result = await client2.list({ headers: {} });
|
|
9802
9871
|
if (result.status === 200) {
|
|
9803
9872
|
return result.body;
|
|
9804
9873
|
}
|
|
@@ -9806,8 +9875,8 @@ async function listZeroSecrets() {
|
|
|
9806
9875
|
}
|
|
9807
9876
|
async function setZeroSecret(body) {
|
|
9808
9877
|
const config = await getClientConfig();
|
|
9809
|
-
const
|
|
9810
|
-
const result = await
|
|
9878
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9879
|
+
const result = await client2.set({ body });
|
|
9811
9880
|
if (result.status === 200 || result.status === 201) {
|
|
9812
9881
|
return result.body;
|
|
9813
9882
|
}
|
|
@@ -9815,8 +9884,8 @@ async function setZeroSecret(body) {
|
|
|
9815
9884
|
}
|
|
9816
9885
|
async function deleteZeroSecret(name) {
|
|
9817
9886
|
const config = await getClientConfig();
|
|
9818
|
-
const
|
|
9819
|
-
const result = await
|
|
9887
|
+
const client2 = initClient(zeroSecretsByNameContract, config);
|
|
9888
|
+
const result = await client2.delete({
|
|
9820
9889
|
params: { name }
|
|
9821
9890
|
});
|
|
9822
9891
|
if (result.status === 204) {
|
|
@@ -9829,8 +9898,8 @@ async function deleteZeroSecret(name) {
|
|
|
9829
9898
|
init_esm_shims();
|
|
9830
9899
|
async function listZeroVariables() {
|
|
9831
9900
|
const config = await getClientConfig();
|
|
9832
|
-
const
|
|
9833
|
-
const result = await
|
|
9901
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9902
|
+
const result = await client2.list({ headers: {} });
|
|
9834
9903
|
if (result.status === 200) {
|
|
9835
9904
|
return result.body;
|
|
9836
9905
|
}
|
|
@@ -9838,8 +9907,8 @@ async function listZeroVariables() {
|
|
|
9838
9907
|
}
|
|
9839
9908
|
async function setZeroVariable(body) {
|
|
9840
9909
|
const config = await getClientConfig();
|
|
9841
|
-
const
|
|
9842
|
-
const result = await
|
|
9910
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9911
|
+
const result = await client2.set({ body });
|
|
9843
9912
|
if (result.status === 200 || result.status === 201) {
|
|
9844
9913
|
return result.body;
|
|
9845
9914
|
}
|
|
@@ -9847,8 +9916,8 @@ async function setZeroVariable(body) {
|
|
|
9847
9916
|
}
|
|
9848
9917
|
async function deleteZeroVariable(name) {
|
|
9849
9918
|
const config = await getClientConfig();
|
|
9850
|
-
const
|
|
9851
|
-
const result = await
|
|
9919
|
+
const client2 = initClient(zeroVariablesByNameContract, config);
|
|
9920
|
+
const result = await client2.delete({
|
|
9852
9921
|
params: { name }
|
|
9853
9922
|
});
|
|
9854
9923
|
if (result.status === 204) {
|
|
@@ -9861,8 +9930,8 @@ async function deleteZeroVariable(name) {
|
|
|
9861
9930
|
init_esm_shims();
|
|
9862
9931
|
async function listZeroOrgSecrets() {
|
|
9863
9932
|
const config = await getClientConfig();
|
|
9864
|
-
const
|
|
9865
|
-
const result = await
|
|
9933
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9934
|
+
const result = await client2.list({ headers: {} });
|
|
9866
9935
|
if (result.status === 200) {
|
|
9867
9936
|
return result.body;
|
|
9868
9937
|
}
|
|
@@ -9870,8 +9939,8 @@ async function listZeroOrgSecrets() {
|
|
|
9870
9939
|
}
|
|
9871
9940
|
async function setZeroOrgSecret(body) {
|
|
9872
9941
|
const config = await getClientConfig();
|
|
9873
|
-
const
|
|
9874
|
-
const result = await
|
|
9942
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9943
|
+
const result = await client2.set({ body });
|
|
9875
9944
|
if (result.status === 200 || result.status === 201) {
|
|
9876
9945
|
return result.body;
|
|
9877
9946
|
}
|
|
@@ -9879,8 +9948,8 @@ async function setZeroOrgSecret(body) {
|
|
|
9879
9948
|
}
|
|
9880
9949
|
async function deleteZeroOrgSecret(name) {
|
|
9881
9950
|
const config = await getClientConfig();
|
|
9882
|
-
const
|
|
9883
|
-
const result = await
|
|
9951
|
+
const client2 = initClient(zeroSecretsByNameContract, config);
|
|
9952
|
+
const result = await client2.delete({
|
|
9884
9953
|
params: { name }
|
|
9885
9954
|
});
|
|
9886
9955
|
if (result.status === 204) {
|
|
@@ -9893,8 +9962,8 @@ async function deleteZeroOrgSecret(name) {
|
|
|
9893
9962
|
init_esm_shims();
|
|
9894
9963
|
async function listZeroOrgVariables() {
|
|
9895
9964
|
const config = await getClientConfig();
|
|
9896
|
-
const
|
|
9897
|
-
const result = await
|
|
9965
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9966
|
+
const result = await client2.list({ headers: {} });
|
|
9898
9967
|
if (result.status === 200) {
|
|
9899
9968
|
return result.body;
|
|
9900
9969
|
}
|
|
@@ -9902,8 +9971,8 @@ async function listZeroOrgVariables() {
|
|
|
9902
9971
|
}
|
|
9903
9972
|
async function setZeroOrgVariable(body) {
|
|
9904
9973
|
const config = await getClientConfig();
|
|
9905
|
-
const
|
|
9906
|
-
const result = await
|
|
9974
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9975
|
+
const result = await client2.set({ body });
|
|
9907
9976
|
if (result.status === 200 || result.status === 201) {
|
|
9908
9977
|
return result.body;
|
|
9909
9978
|
}
|
|
@@ -9911,8 +9980,8 @@ async function setZeroOrgVariable(body) {
|
|
|
9911
9980
|
}
|
|
9912
9981
|
async function deleteZeroOrgVariable(name) {
|
|
9913
9982
|
const config = await getClientConfig();
|
|
9914
|
-
const
|
|
9915
|
-
const result = await
|
|
9983
|
+
const client2 = initClient(zeroVariablesByNameContract, config);
|
|
9984
|
+
const result = await client2.delete({
|
|
9916
9985
|
params: { name }
|
|
9917
9986
|
});
|
|
9918
9987
|
if (result.status === 204) {
|
|
@@ -9979,8 +10048,8 @@ var zeroModelProvidersByTypeContract = c34.router({
|
|
|
9979
10048
|
// src/lib/api/domains/zero-org-model-providers.ts
|
|
9980
10049
|
async function listZeroOrgModelProviders() {
|
|
9981
10050
|
const config = await getClientConfig();
|
|
9982
|
-
const
|
|
9983
|
-
const result = await
|
|
10051
|
+
const client2 = initClient(zeroModelProvidersMainContract, config);
|
|
10052
|
+
const result = await client2.list({ headers: {} });
|
|
9984
10053
|
if (result.status === 200) {
|
|
9985
10054
|
return result.body;
|
|
9986
10055
|
}
|
|
@@ -9988,8 +10057,8 @@ async function listZeroOrgModelProviders() {
|
|
|
9988
10057
|
}
|
|
9989
10058
|
async function upsertZeroOrgModelProvider(body) {
|
|
9990
10059
|
const config = await getClientConfig();
|
|
9991
|
-
const
|
|
9992
|
-
const result = await
|
|
10060
|
+
const client2 = initClient(zeroModelProvidersMainContract, config);
|
|
10061
|
+
const result = await client2.upsert({ body });
|
|
9993
10062
|
if (result.status === 200 || result.status === 201) {
|
|
9994
10063
|
return result.body;
|
|
9995
10064
|
}
|
|
@@ -9997,8 +10066,8 @@ async function upsertZeroOrgModelProvider(body) {
|
|
|
9997
10066
|
}
|
|
9998
10067
|
async function deleteZeroOrgModelProvider(type) {
|
|
9999
10068
|
const config = await getClientConfig();
|
|
10000
|
-
const
|
|
10001
|
-
const result = await
|
|
10069
|
+
const client2 = initClient(zeroModelProvidersByTypeContract, config);
|
|
10070
|
+
const result = await client2.delete({
|
|
10002
10071
|
params: { type }
|
|
10003
10072
|
});
|
|
10004
10073
|
if (result.status === 204) {
|
|
@@ -11218,43 +11287,43 @@ var zeroWorkflowAutomationsContract = c35.router({
|
|
|
11218
11287
|
// src/lib/api/domains/zero-workflows.ts
|
|
11219
11288
|
async function listWorkflows(query) {
|
|
11220
11289
|
const config = await getClientConfig();
|
|
11221
|
-
const
|
|
11222
|
-
const result = await
|
|
11290
|
+
const client2 = initClient(zeroWorkflowsCollectionContract, config);
|
|
11291
|
+
const result = await client2.list({ query });
|
|
11223
11292
|
if (result.status === 200) return result.body;
|
|
11224
11293
|
handleError(result, "Failed to list workflows");
|
|
11225
11294
|
}
|
|
11226
11295
|
async function createWorkflow(body) {
|
|
11227
11296
|
const config = await getClientConfig();
|
|
11228
|
-
const
|
|
11229
|
-
const result = await
|
|
11297
|
+
const client2 = initClient(zeroWorkflowsCollectionContract, config);
|
|
11298
|
+
const result = await client2.create({ body });
|
|
11230
11299
|
if (result.status === 201) return result.body;
|
|
11231
11300
|
handleError(result, `Failed to create workflow "${body.name}"`);
|
|
11232
11301
|
}
|
|
11233
11302
|
async function getWorkflow(workflowId) {
|
|
11234
11303
|
const config = await getClientConfig();
|
|
11235
|
-
const
|
|
11236
|
-
const result = await
|
|
11304
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11305
|
+
const result = await client2.get({ params: { workflowId } });
|
|
11237
11306
|
if (result.status === 200) return result.body;
|
|
11238
11307
|
handleError(result, `Workflow "${workflowId}" not found`);
|
|
11239
11308
|
}
|
|
11240
11309
|
async function updateWorkflow(workflowId, body) {
|
|
11241
11310
|
const config = await getClientConfig();
|
|
11242
|
-
const
|
|
11243
|
-
const result = await
|
|
11311
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11312
|
+
const result = await client2.update({ params: { workflowId }, body });
|
|
11244
11313
|
if (result.status === 200) return result.body;
|
|
11245
11314
|
handleError(result, `Failed to update workflow "${workflowId}"`);
|
|
11246
11315
|
}
|
|
11247
11316
|
async function deleteWorkflow(workflowId) {
|
|
11248
11317
|
const config = await getClientConfig();
|
|
11249
|
-
const
|
|
11250
|
-
const result = await
|
|
11318
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11319
|
+
const result = await client2.delete({ params: { workflowId } });
|
|
11251
11320
|
if (result.status === 204) return;
|
|
11252
11321
|
handleError(result, `Workflow "${workflowId}" not found`);
|
|
11253
11322
|
}
|
|
11254
11323
|
async function copyWorkflow(workflowId, toAgentId) {
|
|
11255
11324
|
const config = await getClientConfig();
|
|
11256
|
-
const
|
|
11257
|
-
const result = await
|
|
11325
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11326
|
+
const result = await client2.copy({
|
|
11258
11327
|
params: { workflowId },
|
|
11259
11328
|
body: { toAgentId }
|
|
11260
11329
|
});
|
|
@@ -11263,8 +11332,8 @@ async function copyWorkflow(workflowId, toAgentId) {
|
|
|
11263
11332
|
}
|
|
11264
11333
|
async function listWorkflowAutomations(workflowId) {
|
|
11265
11334
|
const config = await getClientConfig();
|
|
11266
|
-
const
|
|
11267
|
-
const result = await
|
|
11335
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11336
|
+
const result = await client2.list({ params: { workflowId } });
|
|
11268
11337
|
if (result.status === 200) return result.body;
|
|
11269
11338
|
handleError(
|
|
11270
11339
|
result,
|
|
@@ -11273,43 +11342,43 @@ async function listWorkflowAutomations(workflowId) {
|
|
|
11273
11342
|
}
|
|
11274
11343
|
async function createWorkflowAutomation(workflowId, body) {
|
|
11275
11344
|
const config = await getClientConfig();
|
|
11276
|
-
const
|
|
11277
|
-
const result = await
|
|
11345
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11346
|
+
const result = await client2.create({ params: { workflowId }, body });
|
|
11278
11347
|
if (result.status === 201) return result.body;
|
|
11279
11348
|
handleError(result, `Failed to add automation to workflow "${workflowId}"`);
|
|
11280
11349
|
}
|
|
11281
11350
|
async function getWorkflowAutomation(id) {
|
|
11282
11351
|
const config = await getClientConfig();
|
|
11283
|
-
const
|
|
11284
|
-
const result = await
|
|
11352
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11353
|
+
const result = await client2.get({ params: { id } });
|
|
11285
11354
|
if (result.status === 200) return result.body;
|
|
11286
11355
|
handleError(result, `Workflow automation "${id}" not found`);
|
|
11287
11356
|
}
|
|
11288
11357
|
async function updateWorkflowAutomation(id, body) {
|
|
11289
11358
|
const config = await getClientConfig();
|
|
11290
|
-
const
|
|
11291
|
-
const result = await
|
|
11359
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11360
|
+
const result = await client2.update({ params: { id }, body });
|
|
11292
11361
|
if (result.status === 200) return result.body;
|
|
11293
11362
|
handleError(result, `Failed to update workflow automation "${id}"`);
|
|
11294
11363
|
}
|
|
11295
11364
|
async function deleteWorkflowAutomation(id) {
|
|
11296
11365
|
const config = await getClientConfig();
|
|
11297
|
-
const
|
|
11298
|
-
const result = await
|
|
11366
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11367
|
+
const result = await client2.delete({ params: { id } });
|
|
11299
11368
|
if (result.status === 204) return;
|
|
11300
11369
|
handleError(result, `Workflow automation "${id}" not found`);
|
|
11301
11370
|
}
|
|
11302
11371
|
async function enableWorkflowAutomation(id) {
|
|
11303
11372
|
const config = await getClientConfig();
|
|
11304
|
-
const
|
|
11305
|
-
const result = await
|
|
11373
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11374
|
+
const result = await client2.enable({ params: { id } });
|
|
11306
11375
|
if (result.status === 200) return result.body;
|
|
11307
11376
|
handleError(result, `Failed to enable workflow automation "${id}"`);
|
|
11308
11377
|
}
|
|
11309
11378
|
async function disableWorkflowAutomation(id) {
|
|
11310
11379
|
const config = await getClientConfig();
|
|
11311
|
-
const
|
|
11312
|
-
const result = await
|
|
11380
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11381
|
+
const result = await client2.disable({ params: { id } });
|
|
11313
11382
|
if (result.status === 200) return result.body;
|
|
11314
11383
|
handleError(result, `Failed to disable workflow automation "${id}"`);
|
|
11315
11384
|
}
|
|
@@ -11463,8 +11532,8 @@ var zeroMailContract = c36.router({
|
|
|
11463
11532
|
// src/lib/api/domains/zero-mail.ts
|
|
11464
11533
|
async function linkZeroMailDraft(args) {
|
|
11465
11534
|
const config = await getClientConfig();
|
|
11466
|
-
const
|
|
11467
|
-
const result = await
|
|
11535
|
+
const client2 = initClient(zeroMailContract, config);
|
|
11536
|
+
const result = await client2.linkDraft({
|
|
11468
11537
|
body: {
|
|
11469
11538
|
threadId: args.threadId,
|
|
11470
11539
|
agentId: args.agentId,
|
|
@@ -12231,8 +12300,8 @@ var integrationsSlackUploadCompleteContract = c37.router({
|
|
|
12231
12300
|
// src/lib/api/domains/integrations-slack.ts
|
|
12232
12301
|
async function sendSlackMessage(body) {
|
|
12233
12302
|
const config = await getClientConfig();
|
|
12234
|
-
const
|
|
12235
|
-
const result = await
|
|
12303
|
+
const client2 = initClient(integrationsSlackMessageContract, config);
|
|
12304
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12236
12305
|
if (result.status === 200) {
|
|
12237
12306
|
return result.body;
|
|
12238
12307
|
}
|
|
@@ -12240,8 +12309,8 @@ async function sendSlackMessage(body) {
|
|
|
12240
12309
|
}
|
|
12241
12310
|
async function initSlackFileUpload(body) {
|
|
12242
12311
|
const config = await getClientConfig();
|
|
12243
|
-
const
|
|
12244
|
-
const result = await
|
|
12312
|
+
const client2 = initClient(integrationsSlackUploadInitContract, config);
|
|
12313
|
+
const result = await client2.init({ body, headers: {} });
|
|
12245
12314
|
if (result.status === 200) {
|
|
12246
12315
|
return result.body;
|
|
12247
12316
|
}
|
|
@@ -12249,8 +12318,8 @@ async function initSlackFileUpload(body) {
|
|
|
12249
12318
|
}
|
|
12250
12319
|
async function completeSlackFileUpload(body) {
|
|
12251
12320
|
const config = await getClientConfig();
|
|
12252
|
-
const
|
|
12253
|
-
const result = await
|
|
12321
|
+
const client2 = initClient(integrationsSlackUploadCompleteContract, config);
|
|
12322
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12254
12323
|
if (result.status === 200) {
|
|
12255
12324
|
return result.body;
|
|
12256
12325
|
}
|
|
@@ -12258,8 +12327,8 @@ async function completeSlackFileUpload(body) {
|
|
|
12258
12327
|
}
|
|
12259
12328
|
async function materializeSlackFileUpload(body) {
|
|
12260
12329
|
const config = await getClientConfig();
|
|
12261
|
-
const
|
|
12262
|
-
const result = await
|
|
12330
|
+
const client2 = initClient(integrationsSlackUploadMaterializeContract, config);
|
|
12331
|
+
const result = await client2.materialize({ body, headers: {} });
|
|
12263
12332
|
if (result.status === 200) {
|
|
12264
12333
|
return result.body;
|
|
12265
12334
|
}
|
|
@@ -12318,8 +12387,8 @@ import { Readable as Readable2 } from "stream";
|
|
|
12318
12387
|
import { pipeline as pipeline2 } from "stream/promises";
|
|
12319
12388
|
async function listTelegramBots() {
|
|
12320
12389
|
const config = await getClientConfig();
|
|
12321
|
-
const
|
|
12322
|
-
const result = await
|
|
12390
|
+
const client2 = initClient(integrationsTelegramBotListContract, config);
|
|
12391
|
+
const result = await client2.listBots({ headers: {} });
|
|
12323
12392
|
if (result.status === 200) {
|
|
12324
12393
|
return result.body;
|
|
12325
12394
|
}
|
|
@@ -12327,8 +12396,8 @@ async function listTelegramBots() {
|
|
|
12327
12396
|
}
|
|
12328
12397
|
async function sendTelegramMessage(body) {
|
|
12329
12398
|
const config = await getClientConfig();
|
|
12330
|
-
const
|
|
12331
|
-
const result = await
|
|
12399
|
+
const client2 = initClient(integrationsTelegramMessageContract, config);
|
|
12400
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12332
12401
|
if (result.status === 200) {
|
|
12333
12402
|
return result.body;
|
|
12334
12403
|
}
|
|
@@ -12336,8 +12405,8 @@ async function sendTelegramMessage(body) {
|
|
|
12336
12405
|
}
|
|
12337
12406
|
async function initTelegramFileUpload(body) {
|
|
12338
12407
|
const config = await getClientConfig();
|
|
12339
|
-
const
|
|
12340
|
-
const result = await
|
|
12408
|
+
const client2 = initClient(integrationsTelegramUploadInitContract, config);
|
|
12409
|
+
const result = await client2.init({ body, headers: {} });
|
|
12341
12410
|
if (result.status === 200) {
|
|
12342
12411
|
return result.body;
|
|
12343
12412
|
}
|
|
@@ -12345,8 +12414,8 @@ async function initTelegramFileUpload(body) {
|
|
|
12345
12414
|
}
|
|
12346
12415
|
async function completeTelegramFileUpload(body) {
|
|
12347
12416
|
const config = await getClientConfig();
|
|
12348
|
-
const
|
|
12349
|
-
const result = await
|
|
12417
|
+
const client2 = initClient(integrationsTelegramUploadCompleteContract, config);
|
|
12418
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12350
12419
|
if (result.status === 200) {
|
|
12351
12420
|
return result.body;
|
|
12352
12421
|
}
|
|
@@ -12406,8 +12475,8 @@ import { Readable as Readable3 } from "stream";
|
|
|
12406
12475
|
import { pipeline as pipeline3 } from "stream/promises";
|
|
12407
12476
|
async function sendTeamsMessage(body) {
|
|
12408
12477
|
const config = await getClientConfig();
|
|
12409
|
-
const
|
|
12410
|
-
const result = await
|
|
12478
|
+
const client2 = initClient(integrationsTeamsMessageContract, config);
|
|
12479
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12411
12480
|
if (result.status === 200) {
|
|
12412
12481
|
return result.body;
|
|
12413
12482
|
}
|
|
@@ -12415,8 +12484,8 @@ async function sendTeamsMessage(body) {
|
|
|
12415
12484
|
}
|
|
12416
12485
|
async function initTeamsFileUpload(body) {
|
|
12417
12486
|
const config = await getClientConfig();
|
|
12418
|
-
const
|
|
12419
|
-
const result = await
|
|
12487
|
+
const client2 = initClient(integrationsTeamsUploadInitContract, config);
|
|
12488
|
+
const result = await client2.init({ body, headers: {} });
|
|
12420
12489
|
if (result.status === 200) {
|
|
12421
12490
|
return result.body;
|
|
12422
12491
|
}
|
|
@@ -12424,8 +12493,8 @@ async function initTeamsFileUpload(body) {
|
|
|
12424
12493
|
}
|
|
12425
12494
|
async function completeTeamsFileUpload(body) {
|
|
12426
12495
|
const config = await getClientConfig();
|
|
12427
|
-
const
|
|
12428
|
-
const result = await
|
|
12496
|
+
const client2 = initClient(integrationsTeamsUploadCompleteContract, config);
|
|
12497
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12429
12498
|
if (result.status === 200) {
|
|
12430
12499
|
return result.body;
|
|
12431
12500
|
}
|
|
@@ -12484,8 +12553,8 @@ import { Readable as Readable4 } from "stream";
|
|
|
12484
12553
|
import { pipeline as pipeline4 } from "stream/promises";
|
|
12485
12554
|
async function sendFeishuMessage(body) {
|
|
12486
12555
|
const config = await getClientConfig();
|
|
12487
|
-
const
|
|
12488
|
-
const result = await
|
|
12556
|
+
const client2 = initClient(integrationsFeishuMessageContract, config);
|
|
12557
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12489
12558
|
if (result.status === 200) {
|
|
12490
12559
|
return result.body;
|
|
12491
12560
|
}
|
|
@@ -12493,8 +12562,8 @@ async function sendFeishuMessage(body) {
|
|
|
12493
12562
|
}
|
|
12494
12563
|
async function initFeishuFileUpload(body) {
|
|
12495
12564
|
const config = await getClientConfig();
|
|
12496
|
-
const
|
|
12497
|
-
const result = await
|
|
12565
|
+
const client2 = initClient(integrationsFeishuUploadInitContract, config);
|
|
12566
|
+
const result = await client2.init({ body, headers: {} });
|
|
12498
12567
|
if (result.status === 200) {
|
|
12499
12568
|
return result.body;
|
|
12500
12569
|
}
|
|
@@ -12502,8 +12571,8 @@ async function initFeishuFileUpload(body) {
|
|
|
12502
12571
|
}
|
|
12503
12572
|
async function completeFeishuFileUpload(body) {
|
|
12504
12573
|
const config = await getClientConfig();
|
|
12505
|
-
const
|
|
12506
|
-
const result = await
|
|
12574
|
+
const client2 = initClient(integrationsFeishuUploadCompleteContract, config);
|
|
12575
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12507
12576
|
if (result.status === 200) {
|
|
12508
12577
|
return result.body;
|
|
12509
12578
|
}
|
|
@@ -12571,8 +12640,8 @@ import { Readable as Readable5 } from "stream";
|
|
|
12571
12640
|
import { pipeline as pipeline5 } from "stream/promises";
|
|
12572
12641
|
async function initGithubFileUpload(body) {
|
|
12573
12642
|
const config = await getClientConfig();
|
|
12574
|
-
const
|
|
12575
|
-
const result = await
|
|
12643
|
+
const client2 = initClient(integrationsGithubUploadInitContract, config);
|
|
12644
|
+
const result = await client2.init({ body, headers: {} });
|
|
12576
12645
|
if (result.status === 200) {
|
|
12577
12646
|
return result.body;
|
|
12578
12647
|
}
|
|
@@ -12580,8 +12649,8 @@ async function initGithubFileUpload(body) {
|
|
|
12580
12649
|
}
|
|
12581
12650
|
async function completeGithubFileUpload(body) {
|
|
12582
12651
|
const config = await getClientConfig();
|
|
12583
|
-
const
|
|
12584
|
-
const result = await
|
|
12652
|
+
const client2 = initClient(integrationsGithubUploadCompleteContract, config);
|
|
12653
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12585
12654
|
if (result.status === 200) {
|
|
12586
12655
|
return result.body;
|
|
12587
12656
|
}
|
|
@@ -12643,8 +12712,8 @@ import { Readable as Readable6 } from "stream";
|
|
|
12643
12712
|
import { pipeline as pipeline6 } from "stream/promises";
|
|
12644
12713
|
async function sendPhoneMessage(body) {
|
|
12645
12714
|
const config = await getClientConfig();
|
|
12646
|
-
const
|
|
12647
|
-
const result = await
|
|
12715
|
+
const client2 = initClient(integrationsPhoneMessageContract, config);
|
|
12716
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12648
12717
|
if (result.status === 200) {
|
|
12649
12718
|
return result.body;
|
|
12650
12719
|
}
|
|
@@ -12652,8 +12721,8 @@ async function sendPhoneMessage(body) {
|
|
|
12652
12721
|
}
|
|
12653
12722
|
async function initPhoneFileUpload(body) {
|
|
12654
12723
|
const config = await getClientConfig();
|
|
12655
|
-
const
|
|
12656
|
-
const result = await
|
|
12724
|
+
const client2 = initClient(integrationsPhoneUploadInitContract, config);
|
|
12725
|
+
const result = await client2.init({ body, headers: {} });
|
|
12657
12726
|
if (result.status === 200) {
|
|
12658
12727
|
return result.body;
|
|
12659
12728
|
}
|
|
@@ -12661,8 +12730,8 @@ async function initPhoneFileUpload(body) {
|
|
|
12661
12730
|
}
|
|
12662
12731
|
async function completePhoneFileUpload(body) {
|
|
12663
12732
|
const config = await getClientConfig();
|
|
12664
|
-
const
|
|
12665
|
-
const result = await
|
|
12733
|
+
const client2 = initClient(integrationsPhoneUploadCompleteContract, config);
|
|
12734
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12666
12735
|
if (result.status === 200) {
|
|
12667
12736
|
return result.body;
|
|
12668
12737
|
}
|
|
@@ -12718,8 +12787,8 @@ async function downloadPhoneFile(fileId, outPath) {
|
|
|
12718
12787
|
init_esm_shims();
|
|
12719
12788
|
async function listZeroLogs(options) {
|
|
12720
12789
|
const config = await getClientConfig();
|
|
12721
|
-
const
|
|
12722
|
-
const result = await
|
|
12790
|
+
const client2 = initClient(logsListContract, config);
|
|
12791
|
+
const result = await client2.list({
|
|
12723
12792
|
query: {
|
|
12724
12793
|
agentId: options?.agentId,
|
|
12725
12794
|
status: options?.status,
|
|
@@ -12733,8 +12802,8 @@ async function listZeroLogs(options) {
|
|
|
12733
12802
|
}
|
|
12734
12803
|
async function searchZeroLogs(options) {
|
|
12735
12804
|
const config = await getClientConfig();
|
|
12736
|
-
const
|
|
12737
|
-
const result = await
|
|
12805
|
+
const client2 = initClient(zeroLogsSearchContract, config);
|
|
12806
|
+
const result = await client2.searchLogs({
|
|
12738
12807
|
query: {
|
|
12739
12808
|
keyword: options.keyword,
|
|
12740
12809
|
agentId: options.agentId,
|
|
@@ -12998,6 +13067,14 @@ export {
|
|
|
12998
13067
|
createComputerUseAuthorizationRequest,
|
|
12999
13068
|
fetchComputerUseScreenshot,
|
|
13000
13069
|
fetchComputerUsePluginContent,
|
|
13070
|
+
ZERO_BROWSER_DEFAULT_TIMEOUT_MINUTES,
|
|
13071
|
+
ZERO_BROWSER_MAX_TIMEOUT_MINUTES,
|
|
13072
|
+
ZERO_BROWSER_DEFAULT_MAX_CREDITS,
|
|
13073
|
+
ZERO_BROWSER_MAX_CREDITS,
|
|
13074
|
+
zeroBrowserCreateRequestSchema,
|
|
13075
|
+
createZeroBrowser,
|
|
13076
|
+
resumeZeroBrowser,
|
|
13077
|
+
getCurrentZeroBrowser,
|
|
13001
13078
|
callZeroMaps,
|
|
13002
13079
|
callZeroWeather,
|
|
13003
13080
|
zeroScrapeFormatSchema,
|
|
@@ -13032,4 +13109,4 @@ export {
|
|
|
13032
13109
|
getHostedSiteFiles,
|
|
13033
13110
|
getHostedSiteDeployments
|
|
13034
13111
|
};
|
|
13035
|
-
//# sourceMappingURL=chunk-
|
|
13112
|
+
//# sourceMappingURL=chunk-SLUCBVKQ.js.map
|