@vm0/cli 9.254.1 → 9.255.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{agent-CDMQ3BO4.js → agent-YXVPOZDT.js} +7 -7
- package/{banking-M5CIVLRH.js → banking-K734DGW4.js} +5 -5
- package/browser-GMLGBTV7.js +186 -0
- package/browser-GMLGBTV7.js.map +1 -0
- package/{chat-TRK5KDSP.js → chat-I2URW23Z.js} +6 -6
- package/{chunk-BL37FBZF.js → chunk-24QJ7H5R.js} +2 -2
- package/{chunk-7NYMO54N.js → chunk-45FQJCB2.js} +2 -2
- package/{chunk-JLEBJUMI.js → chunk-7PFY5Y77.js} +84 -219
- package/chunk-7PFY5Y77.js.map +1 -0
- package/{chunk-UUKFGXX5.js → chunk-BKR7J5QP.js} +2 -2
- package/{chunk-BXVXXD3E.js → chunk-BYD553JQ.js} +4 -4
- package/{chunk-5QLT6M5N.js → chunk-DQB537B5.js} +3 -3
- package/{chunk-D4OTAABD.js → chunk-H4LRAOOF.js} +6 -1
- package/chunk-H4LRAOOF.js.map +1 -0
- package/{chunk-R23NULE7.js → chunk-MDKQRZ7S.js} +656 -495
- package/chunk-MDKQRZ7S.js.map +1 -0
- package/{chunk-TBBXBBFT.js → chunk-RKXDWJW5.js} +2 -2
- package/{chunk-JXYKIW37.js → chunk-UKQRMBLJ.js} +2 -2
- package/{chunk-XBX4JTXR.js → chunk-ZLP3TODB.js} +84 -2
- package/chunk-ZLP3TODB.js.map +1 -0
- package/{computer-use-K7ULCJNC.js → computer-use-OVYDVFLM.js} +5 -5
- package/{connector-JFE4GTW4.js → connector-ZJ4GNXOR.js} +15 -83
- package/connector-ZJ4GNXOR.js.map +1 -0
- package/{credit-QVY2XIPE.js → credit-5F56FMHI.js} +7 -7
- package/{developer-support-EJOQWXKB.js → developer-support-DMN7JGPX.js} +5 -5
- package/{doctor-7YEA3BYV.js → doctor-Y724BLON.js} +7 -7
- package/{feishu-KCN4UME3.js → feishu-T5ZIWV53.js} +5 -5
- package/{finance-TOKK5DCK.js → finance-4ZRCXMFS.js} +5 -5
- package/{generate-6E23MDCE.js → generate-JFRB6NBZ.js} +7 -7
- package/{github-LJMT5D7D.js → github-ZXWGL5Q6.js} +5 -5
- package/{goal-OJ4J7OCD.js → goal-22N3CH3F.js} +5 -5
- package/{host-KX5G666N.js → host-I7S5PYUY.js} +5 -5
- package/{logs-IDABHTFA.js → logs-4HV44EMA.js} +6 -6
- package/{mail-U6JQDKN3.js → mail-U5LPAC7X.js} +67 -17
- package/mail-U5LPAC7X.js.map +1 -0
- package/{maps-Y7PIXKLP.js → maps-PF5WHYEC.js} +5 -5
- package/{model-PXWGKXUA.js → model-JMQSUUFJ.js} +6 -6
- package/{model-provider-LNVO4LHA.js → model-provider-AJCWCCNB.js} +6 -6
- package/{org-G46VCLIF.js → org-7Q3J66NB.js} +5 -5
- package/package.json +1 -1
- package/{people-search-TZBJNLYY.js → people-search-GUIJICYT.js} +5 -5
- package/{phone-KEHX5BEJ.js → phone-6U27VFNC.js} +5 -5
- package/{preference-5KLKA6DR.js → preference-BFLHPME6.js} +5 -5
- package/{resource-W2PYM3GG.js → resource-C3PAGM7Y.js} +5 -5
- package/{scrape-27OBJPNR.js → scrape-5XL47HZY.js} +5 -5
- package/{search-23XNHEE5.js → search-B2V6NTUP.js} +6 -6
- package/{secret-IRLST7ZX.js → secret-QORKNSMC.js} +5 -5
- package/{slack-U3YX4HK7.js → slack-MD6HYUDE.js} +5 -5
- package/{teams-2BPJ3VT4.js → teams-LO3PPNA2.js} +5 -5
- package/{telegram-B7JBB6M2.js → telegram-BZUBR4QS.js} +5 -5
- package/{upgrade-SFFQF2QF.js → upgrade-63B4TM4E.js} +4 -4
- package/{variable-ZZ7OX5PU.js → variable-FW7F63SB.js} +5 -5
- package/{video-PEACIVNU.js → video-RWCQZ4XP.js} +4 -4
- package/{weather-4SC7E3OZ.js → weather-ST6CIHV4.js} +5 -5
- package/{web-2O6V5RRP.js → web-GBSYVVYF.js} +5 -5
- package/{web-search-KOU476ZM.js → web-search-AZXILILB.js} +5 -5
- package/{whoami-VGNKLROW.js → whoami-UI67766P.js} +7 -7
- package/{workflow-3GXAC4BP.js → workflow-CXWRSWUP.js} +5 -5
- package/zero.js +54 -44
- package/zero.js.map +1 -1
- package/chunk-D4OTAABD.js.map +0 -1
- package/chunk-JLEBJUMI.js.map +0 -1
- package/chunk-R23NULE7.js.map +0 -1
- package/chunk-XBX4JTXR.js.map +0 -1
- package/connector-JFE4GTW4.js.map +0 -1
- package/mail-U6JQDKN3.js.map +0 -1
- /package/{agent-CDMQ3BO4.js.map → agent-YXVPOZDT.js.map} +0 -0
- /package/{banking-M5CIVLRH.js.map → banking-K734DGW4.js.map} +0 -0
- /package/{chat-TRK5KDSP.js.map → chat-I2URW23Z.js.map} +0 -0
- /package/{chunk-BL37FBZF.js.map → chunk-24QJ7H5R.js.map} +0 -0
- /package/{chunk-7NYMO54N.js.map → chunk-45FQJCB2.js.map} +0 -0
- /package/{chunk-UUKFGXX5.js.map → chunk-BKR7J5QP.js.map} +0 -0
- /package/{chunk-BXVXXD3E.js.map → chunk-BYD553JQ.js.map} +0 -0
- /package/{chunk-5QLT6M5N.js.map → chunk-DQB537B5.js.map} +0 -0
- /package/{chunk-TBBXBBFT.js.map → chunk-RKXDWJW5.js.map} +0 -0
- /package/{chunk-JXYKIW37.js.map → chunk-UKQRMBLJ.js.map} +0 -0
- /package/{computer-use-K7ULCJNC.js.map → computer-use-OVYDVFLM.js.map} +0 -0
- /package/{credit-QVY2XIPE.js.map → credit-5F56FMHI.js.map} +0 -0
- /package/{developer-support-EJOQWXKB.js.map → developer-support-DMN7JGPX.js.map} +0 -0
- /package/{doctor-7YEA3BYV.js.map → doctor-Y724BLON.js.map} +0 -0
- /package/{feishu-KCN4UME3.js.map → feishu-T5ZIWV53.js.map} +0 -0
- /package/{finance-TOKK5DCK.js.map → finance-4ZRCXMFS.js.map} +0 -0
- /package/{generate-6E23MDCE.js.map → generate-JFRB6NBZ.js.map} +0 -0
- /package/{github-LJMT5D7D.js.map → github-ZXWGL5Q6.js.map} +0 -0
- /package/{goal-OJ4J7OCD.js.map → goal-22N3CH3F.js.map} +0 -0
- /package/{host-KX5G666N.js.map → host-I7S5PYUY.js.map} +0 -0
- /package/{logs-IDABHTFA.js.map → logs-4HV44EMA.js.map} +0 -0
- /package/{maps-Y7PIXKLP.js.map → maps-PF5WHYEC.js.map} +0 -0
- /package/{model-PXWGKXUA.js.map → model-JMQSUUFJ.js.map} +0 -0
- /package/{model-provider-LNVO4LHA.js.map → model-provider-AJCWCCNB.js.map} +0 -0
- /package/{org-G46VCLIF.js.map → org-7Q3J66NB.js.map} +0 -0
- /package/{people-search-TZBJNLYY.js.map → people-search-GUIJICYT.js.map} +0 -0
- /package/{phone-KEHX5BEJ.js.map → phone-6U27VFNC.js.map} +0 -0
- /package/{preference-5KLKA6DR.js.map → preference-BFLHPME6.js.map} +0 -0
- /package/{resource-W2PYM3GG.js.map → resource-C3PAGM7Y.js.map} +0 -0
- /package/{scrape-27OBJPNR.js.map → scrape-5XL47HZY.js.map} +0 -0
- /package/{search-23XNHEE5.js.map → search-B2V6NTUP.js.map} +0 -0
- /package/{secret-IRLST7ZX.js.map → secret-QORKNSMC.js.map} +0 -0
- /package/{slack-U3YX4HK7.js.map → slack-MD6HYUDE.js.map} +0 -0
- /package/{teams-2BPJ3VT4.js.map → teams-LO3PPNA2.js.map} +0 -0
- /package/{telegram-B7JBB6M2.js.map → telegram-BZUBR4QS.js.map} +0 -0
- /package/{upgrade-SFFQF2QF.js.map → upgrade-63B4TM4E.js.map} +0 -0
- /package/{variable-ZZ7OX5PU.js.map → variable-FW7F63SB.js.map} +0 -0
- /package/{video-PEACIVNU.js.map → video-RWCQZ4XP.js.map} +0 -0
- /package/{weather-4SC7E3OZ.js.map → weather-ST6CIHV4.js.map} +0 -0
- /package/{web-2O6V5RRP.js.map → web-GBSYVVYF.js.map} +0 -0
- /package/{web-search-KOU476ZM.js.map → web-search-AZXILILB.js.map} +0 -0
- /package/{whoami-VGNKLROW.js.map → whoami-UI67766P.js.map} +0 -0
- /package/{workflow-3GXAC4BP.js.map → workflow-CXWRSWUP.js.map} +0 -0
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
updateOrgModelPoliciesRequestSchema,
|
|
22
22
|
upsertModelProviderRequestSchema,
|
|
23
23
|
upsertModelProviderResponseSchema
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-DQB537B5.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",
|
|
@@ -5410,7 +5364,68 @@ var zeroConnectorsSearchContract = c19.router({
|
|
|
5410
5364
|
|
|
5411
5365
|
// ../../packages/api-contracts/src/contracts/zero-connector-catalog.ts
|
|
5412
5366
|
init_esm_shims();
|
|
5413
|
-
|
|
5367
|
+
|
|
5368
|
+
// ../../packages/api-contracts/src/contracts/connector-catalog-diagnostics.ts
|
|
5369
|
+
init_esm_shims();
|
|
5370
|
+
var connectorCatalogSyncFailureCodeSchema = external_exports.enum([
|
|
5371
|
+
"source-unavailable",
|
|
5372
|
+
"object-too-large",
|
|
5373
|
+
"invalid-json",
|
|
5374
|
+
"invalid-pointer",
|
|
5375
|
+
"invalid-reference",
|
|
5376
|
+
"digest-mismatch",
|
|
5377
|
+
"unsupported-schema",
|
|
5378
|
+
"invalid-artifact",
|
|
5379
|
+
"public-leakage",
|
|
5380
|
+
"relationship-mismatch",
|
|
5381
|
+
"invalid-compression"
|
|
5382
|
+
]);
|
|
5383
|
+
var connectorCatalogCompatibilityReasonSchema = external_exports.enum([
|
|
5384
|
+
"missing-grant-provider",
|
|
5385
|
+
"missing-access-provider",
|
|
5386
|
+
"missing-revoke-provider",
|
|
5387
|
+
"provider-contract-mismatch",
|
|
5388
|
+
"missing-platform-configuration"
|
|
5389
|
+
]);
|
|
5390
|
+
var connectorCatalogFilteredAuthMethodSchema = external_exports.object({
|
|
5391
|
+
connectorRef: connectorRefSchema,
|
|
5392
|
+
authMethodId: connectorAuthMethodIdSchema,
|
|
5393
|
+
reasons: external_exports.array(connectorCatalogCompatibilityReasonSchema).min(1)
|
|
5394
|
+
});
|
|
5395
|
+
var connectorCatalogFilteredAuthMethodsSchema = external_exports.array(
|
|
5396
|
+
connectorCatalogFilteredAuthMethodSchema
|
|
5397
|
+
);
|
|
5398
|
+
var connectorCatalogFilteringStatusSchema = external_exports.object({
|
|
5399
|
+
capabilityDigest: external_exports.string().regex(/^sha256:[a-f0-9]{64}$/u),
|
|
5400
|
+
evaluatedAt: external_exports.string().datetime().nullable(),
|
|
5401
|
+
stale: external_exports.boolean(),
|
|
5402
|
+
filteredAuthMethods: connectorCatalogFilteredAuthMethodsSchema
|
|
5403
|
+
});
|
|
5404
|
+
var connectorCredentialStorageReadinessSchema = external_exports.object({
|
|
5405
|
+
missingConnectorVersions: external_exports.number().int().nonnegative(),
|
|
5406
|
+
unownedConnectorSecrets: external_exports.number().int().nonnegative(),
|
|
5407
|
+
unownedConnectorVariables: external_exports.number().int().nonnegative(),
|
|
5408
|
+
unresolvedBridgeCredentials: external_exports.number().int().nonnegative()
|
|
5409
|
+
});
|
|
5410
|
+
var connectorCatalogDiagnosticsSchema = external_exports.object({
|
|
5411
|
+
state: external_exports.enum(["never-synced", "current", "stale"]),
|
|
5412
|
+
active: external_exports.object({
|
|
5413
|
+
catalogVersion: external_exports.string(),
|
|
5414
|
+
catalogDigest: external_exports.string(),
|
|
5415
|
+
activatedAt: external_exports.string().datetime()
|
|
5416
|
+
}).nullable(),
|
|
5417
|
+
lastAttempt: external_exports.object({
|
|
5418
|
+
at: external_exports.string().datetime(),
|
|
5419
|
+
outcome: external_exports.enum(["accepted", "unchanged", "rejected"]),
|
|
5420
|
+
failureCode: connectorCatalogSyncFailureCodeSchema.nullable()
|
|
5421
|
+
}).nullable(),
|
|
5422
|
+
lastSuccessAt: external_exports.string().datetime().nullable(),
|
|
5423
|
+
filtering: connectorCatalogFilteringStatusSchema,
|
|
5424
|
+
credentialStorage: connectorCredentialStorageReadinessSchema
|
|
5425
|
+
});
|
|
5426
|
+
|
|
5427
|
+
// ../../packages/api-contracts/src/contracts/zero-connector-catalog.ts
|
|
5428
|
+
var c19 = initContract();
|
|
5414
5429
|
var publicConnectorCatalogAuthMethodSummarySchema = external_exports.object({
|
|
5415
5430
|
id: connectorAuthMethodIdSchema,
|
|
5416
5431
|
label: external_exports.string(),
|
|
@@ -5550,7 +5565,7 @@ var publicConnectorCatalogPermissionDetailResponseSchema = external_exports.obje
|
|
|
5550
5565
|
var connectorCatalogPathParamsSchema = external_exports.object({
|
|
5551
5566
|
connectorRef: connectorRefSchema
|
|
5552
5567
|
});
|
|
5553
|
-
var zeroConnectorCatalogContract =
|
|
5568
|
+
var zeroConnectorCatalogContract = c19.router({
|
|
5554
5569
|
list: {
|
|
5555
5570
|
method: "GET",
|
|
5556
5571
|
path: "/api/zero/connector-catalog",
|
|
@@ -5575,6 +5590,18 @@ var zeroConnectorCatalogContract = c20.router({
|
|
|
5575
5590
|
},
|
|
5576
5591
|
summary: "List public connector catalog metadata with connection status"
|
|
5577
5592
|
},
|
|
5593
|
+
diagnostics: {
|
|
5594
|
+
method: "GET",
|
|
5595
|
+
path: "/api/zero/connector-catalog/diagnostics",
|
|
5596
|
+
headers: authHeadersSchema,
|
|
5597
|
+
responses: {
|
|
5598
|
+
200: connectorCatalogDiagnosticsSchema,
|
|
5599
|
+
401: apiErrorSchema,
|
|
5600
|
+
403: apiErrorSchema,
|
|
5601
|
+
404: apiErrorSchema
|
|
5602
|
+
},
|
|
5603
|
+
summary: "Read connector catalog diagnostics"
|
|
5604
|
+
},
|
|
5578
5605
|
get: {
|
|
5579
5606
|
method: "GET",
|
|
5580
5607
|
path: "/api/zero/connector-catalog/:connectorRef",
|
|
@@ -5609,7 +5636,7 @@ var zeroConnectorCatalogContract = c20.router({
|
|
|
5609
5636
|
|
|
5610
5637
|
// ../../packages/api-contracts/src/contracts/zero-connector-check.ts
|
|
5611
5638
|
init_esm_shims();
|
|
5612
|
-
var
|
|
5639
|
+
var c20 = initContract();
|
|
5613
5640
|
var boundedNameSchema = external_exports.string().min(1).max(255);
|
|
5614
5641
|
var connectorCheckUrlRequestSchema = external_exports.object({
|
|
5615
5642
|
mode: external_exports.literal("url"),
|
|
@@ -5755,7 +5782,7 @@ var connectorCheckDiagnosticResultSchema = external_exports.union([
|
|
|
5755
5782
|
connectorCheckUnresolvedDynamicBaseSchema,
|
|
5756
5783
|
connectorCheckRunContextUnavailableSchema
|
|
5757
5784
|
]);
|
|
5758
|
-
var zeroConnectorCheckContract =
|
|
5785
|
+
var zeroConnectorCheckContract = c20.router({
|
|
5759
5786
|
check: {
|
|
5760
5787
|
method: "POST",
|
|
5761
5788
|
path: "/api/zero/connectors/diagnostics/check",
|
|
@@ -5775,7 +5802,7 @@ var zeroConnectorCheckContract = c21.router({
|
|
|
5775
5802
|
|
|
5776
5803
|
// ../../packages/api-contracts/src/contracts/zero-custom-connectors.ts
|
|
5777
5804
|
init_esm_shims();
|
|
5778
|
-
var
|
|
5805
|
+
var c21 = initContract();
|
|
5779
5806
|
var customConnectorFieldKindSchema = external_exports.enum(["secret", "variable"]);
|
|
5780
5807
|
var customConnectorFieldSchema = external_exports.object({
|
|
5781
5808
|
key: external_exports.string().min(1).max(64),
|
|
@@ -5861,7 +5888,7 @@ var saveCustomConnectorProposalResponseSchema = external_exports.object({
|
|
|
5861
5888
|
connector: customConnectorResponseSchema,
|
|
5862
5889
|
authorizedAgentId: external_exports.string().uuid().optional()
|
|
5863
5890
|
});
|
|
5864
|
-
var zeroCustomConnectorsContract =
|
|
5891
|
+
var zeroCustomConnectorsContract = c21.router({
|
|
5865
5892
|
list: {
|
|
5866
5893
|
method: "GET",
|
|
5867
5894
|
path: "/api/zero/custom-connectors",
|
|
@@ -5888,7 +5915,7 @@ var zeroCustomConnectorsContract = c22.router({
|
|
|
5888
5915
|
summary: "Create an org custom connector"
|
|
5889
5916
|
}
|
|
5890
5917
|
});
|
|
5891
|
-
var zeroCustomConnectorByIdContract =
|
|
5918
|
+
var zeroCustomConnectorByIdContract = c21.router({
|
|
5892
5919
|
get: {
|
|
5893
5920
|
method: "GET",
|
|
5894
5921
|
path: "/api/zero/custom-connectors/:id",
|
|
@@ -5909,7 +5936,7 @@ var zeroCustomConnectorByIdContract = c22.router({
|
|
|
5909
5936
|
headers: authHeadersSchema,
|
|
5910
5937
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
5911
5938
|
responses: {
|
|
5912
|
-
204:
|
|
5939
|
+
204: c21.noBody(),
|
|
5913
5940
|
401: apiErrorSchema,
|
|
5914
5941
|
403: apiErrorSchema,
|
|
5915
5942
|
404: apiErrorSchema,
|
|
@@ -5934,7 +5961,7 @@ var zeroCustomConnectorByIdContract = c22.router({
|
|
|
5934
5961
|
summary: "Rename an org custom connector"
|
|
5935
5962
|
}
|
|
5936
5963
|
});
|
|
5937
|
-
var zeroCustomConnectorSecretContract =
|
|
5964
|
+
var zeroCustomConnectorSecretContract = c21.router({
|
|
5938
5965
|
set: {
|
|
5939
5966
|
method: "PUT",
|
|
5940
5967
|
path: "/api/zero/custom-connectors/:id/secret",
|
|
@@ -5942,7 +5969,7 @@ var zeroCustomConnectorSecretContract = c22.router({
|
|
|
5942
5969
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
5943
5970
|
body: setCustomConnectorSecretBodySchema,
|
|
5944
5971
|
responses: {
|
|
5945
|
-
204:
|
|
5972
|
+
204: c21.noBody(),
|
|
5946
5973
|
400: apiErrorSchema,
|
|
5947
5974
|
401: apiErrorSchema,
|
|
5948
5975
|
404: apiErrorSchema,
|
|
@@ -5956,7 +5983,7 @@ var zeroCustomConnectorSecretContract = c22.router({
|
|
|
5956
5983
|
headers: authHeadersSchema,
|
|
5957
5984
|
pathParams: external_exports.object({ id: external_exports.string().uuid() }),
|
|
5958
5985
|
responses: {
|
|
5959
|
-
204:
|
|
5986
|
+
204: c21.noBody(),
|
|
5960
5987
|
401: apiErrorSchema,
|
|
5961
5988
|
404: apiErrorSchema,
|
|
5962
5989
|
500: apiErrorSchema
|
|
@@ -5964,7 +5991,7 @@ var zeroCustomConnectorSecretContract = c22.router({
|
|
|
5964
5991
|
summary: "Clear the calling user's secret for a custom connector"
|
|
5965
5992
|
}
|
|
5966
5993
|
});
|
|
5967
|
-
var zeroCustomConnectorProposalContract =
|
|
5994
|
+
var zeroCustomConnectorProposalContract = c21.router({
|
|
5968
5995
|
save: {
|
|
5969
5996
|
method: "POST",
|
|
5970
5997
|
path: "/api/zero/custom-connectors/proposals/save",
|
|
@@ -5985,8 +6012,8 @@ var zeroCustomConnectorProposalContract = c22.router({
|
|
|
5985
6012
|
// src/lib/api/domains/zero-connectors.ts
|
|
5986
6013
|
async function listZeroConnectors() {
|
|
5987
6014
|
const config = await getClientConfig();
|
|
5988
|
-
const
|
|
5989
|
-
const result = await
|
|
6015
|
+
const client2 = initClient(zeroConnectorsMainContract, config);
|
|
6016
|
+
const result = await client2.list({ headers: {} });
|
|
5990
6017
|
if (result.status === 200) {
|
|
5991
6018
|
return result.body;
|
|
5992
6019
|
}
|
|
@@ -5994,8 +6021,8 @@ async function listZeroConnectors() {
|
|
|
5994
6021
|
}
|
|
5995
6022
|
async function listZeroConnectorCatalog() {
|
|
5996
6023
|
const config = await getClientConfig();
|
|
5997
|
-
const
|
|
5998
|
-
const result = await
|
|
6024
|
+
const client2 = initClient(zeroConnectorCatalogContract, config);
|
|
6025
|
+
const result = await client2.list({ headers: {} });
|
|
5999
6026
|
if (result.status === 200) {
|
|
6000
6027
|
return result.body;
|
|
6001
6028
|
}
|
|
@@ -6003,8 +6030,8 @@ async function listZeroConnectorCatalog() {
|
|
|
6003
6030
|
}
|
|
6004
6031
|
async function listZeroConnectorCatalogStatus() {
|
|
6005
6032
|
const config = await getClientConfig();
|
|
6006
|
-
const
|
|
6007
|
-
const result = await
|
|
6033
|
+
const client2 = initClient(zeroConnectorCatalogContract, config);
|
|
6034
|
+
const result = await client2.status({ headers: {} });
|
|
6008
6035
|
if (result.status === 200) {
|
|
6009
6036
|
return result.body;
|
|
6010
6037
|
}
|
|
@@ -6012,8 +6039,8 @@ async function listZeroConnectorCatalogStatus() {
|
|
|
6012
6039
|
}
|
|
6013
6040
|
async function getZeroConnectorCatalogPermissions(connectorRef) {
|
|
6014
6041
|
const config = await getClientConfig();
|
|
6015
|
-
const
|
|
6016
|
-
const result = await
|
|
6042
|
+
const client2 = initClient(zeroConnectorCatalogContract, config);
|
|
6043
|
+
const result = await client2.permissions({
|
|
6017
6044
|
params: { connectorRef }
|
|
6018
6045
|
});
|
|
6019
6046
|
if (result.status === 200) {
|
|
@@ -6034,11 +6061,11 @@ async function getZeroConnectorCatalogPermissions(connectorRef) {
|
|
|
6034
6061
|
}
|
|
6035
6062
|
async function diagnoseZeroConnectorCheck(request) {
|
|
6036
6063
|
const config = await getClientConfig();
|
|
6037
|
-
const
|
|
6064
|
+
const client2 = initClient(zeroConnectorCheckContract, {
|
|
6038
6065
|
...config,
|
|
6039
6066
|
validateResponse: true
|
|
6040
6067
|
});
|
|
6041
|
-
const result = await
|
|
6068
|
+
const result = await client2.check({ body: request });
|
|
6042
6069
|
if (result.status === 200) {
|
|
6043
6070
|
return result.body;
|
|
6044
6071
|
}
|
|
@@ -6046,8 +6073,8 @@ async function diagnoseZeroConnectorCheck(request) {
|
|
|
6046
6073
|
}
|
|
6047
6074
|
async function getZeroConnector(type) {
|
|
6048
6075
|
const config = await getClientConfig();
|
|
6049
|
-
const
|
|
6050
|
-
const result = await
|
|
6076
|
+
const client2 = initClient(zeroConnectorsByTypeContract, config);
|
|
6077
|
+
const result = await client2.get({
|
|
6051
6078
|
params: { type }
|
|
6052
6079
|
});
|
|
6053
6080
|
if (result.status === 200) {
|
|
@@ -6060,8 +6087,8 @@ async function getZeroConnector(type) {
|
|
|
6060
6087
|
}
|
|
6061
6088
|
async function connectZeroConnectorManualGrant(type, authMethod, values) {
|
|
6062
6089
|
const config = await getClientConfig();
|
|
6063
|
-
const
|
|
6064
|
-
const result = await
|
|
6090
|
+
const client2 = initClient(zeroConnectorManualGrantContract, config);
|
|
6091
|
+
const result = await client2.connect({
|
|
6065
6092
|
params: { type },
|
|
6066
6093
|
body: { authMethod, values }
|
|
6067
6094
|
});
|
|
@@ -6072,8 +6099,8 @@ async function connectZeroConnectorManualGrant(type, authMethod, values) {
|
|
|
6072
6099
|
}
|
|
6073
6100
|
async function listZeroCustomConnectors() {
|
|
6074
6101
|
const config = await getClientConfig();
|
|
6075
|
-
const
|
|
6076
|
-
const result = await
|
|
6102
|
+
const client2 = initClient(zeroCustomConnectorsContract, config);
|
|
6103
|
+
const result = await client2.list({ headers: {} });
|
|
6077
6104
|
if (result.status === 200) {
|
|
6078
6105
|
return result.body.connectors;
|
|
6079
6106
|
}
|
|
@@ -6081,8 +6108,8 @@ async function listZeroCustomConnectors() {
|
|
|
6081
6108
|
}
|
|
6082
6109
|
async function getZeroCustomConnector(id) {
|
|
6083
6110
|
const config = await getClientConfig();
|
|
6084
|
-
const
|
|
6085
|
-
const result = await
|
|
6111
|
+
const client2 = initClient(zeroCustomConnectorByIdContract, config);
|
|
6112
|
+
const result = await client2.get({ params: { id }, headers: {} });
|
|
6086
6113
|
if (result.status === 200) {
|
|
6087
6114
|
return result.body;
|
|
6088
6115
|
}
|
|
@@ -6103,7 +6130,7 @@ init_esm_shims();
|
|
|
6103
6130
|
|
|
6104
6131
|
// ../../packages/api-contracts/src/contracts/runners.ts
|
|
6105
6132
|
init_esm_shims();
|
|
6106
|
-
var
|
|
6133
|
+
var c22 = initContract();
|
|
6107
6134
|
var MIN_EPOCH_MS_TIMESTAMP = 1e12;
|
|
6108
6135
|
var apiStartTimeSchema = external_exports.number().int().min(MIN_EPOCH_MS_TIMESTAMP);
|
|
6109
6136
|
var CANONICAL_GUEST_HOME_DIR = "/home/user";
|
|
@@ -6227,7 +6254,7 @@ var heldSessionStateSchema = external_exports.object({
|
|
|
6227
6254
|
})
|
|
6228
6255
|
).max(8).optional()
|
|
6229
6256
|
});
|
|
6230
|
-
var runnersPollContract =
|
|
6257
|
+
var runnersPollContract = c22.router({
|
|
6231
6258
|
poll: {
|
|
6232
6259
|
method: "POST",
|
|
6233
6260
|
path: "/api/runners/poll",
|
|
@@ -6550,7 +6577,7 @@ var executionContextSchema = external_exports.object({
|
|
|
6550
6577
|
// API-owned Codex provider/runtime metadata forwarded through the runner.
|
|
6551
6578
|
codexRuntimeConfig: modelProviderCodexRuntimeConfigSchema.nullable().optional()
|
|
6552
6579
|
});
|
|
6553
|
-
var runnersJobClaimContract =
|
|
6580
|
+
var runnersJobClaimContract = c22.router({
|
|
6554
6581
|
claim: {
|
|
6555
6582
|
method: "POST",
|
|
6556
6583
|
path: "/api/runners/jobs/:id/claim",
|
|
@@ -6574,7 +6601,7 @@ var runnersJobClaimContract = c23.router({
|
|
|
6574
6601
|
summary: "Claim a pending job for execution"
|
|
6575
6602
|
}
|
|
6576
6603
|
});
|
|
6577
|
-
var runnersNetworkPolicyRefreshContract =
|
|
6604
|
+
var runnersNetworkPolicyRefreshContract = c22.router({
|
|
6578
6605
|
refresh: {
|
|
6579
6606
|
method: "POST",
|
|
6580
6607
|
path: "/api/runners/runs/:runId/network-policy-refresh",
|
|
@@ -6604,7 +6631,7 @@ var runnersNetworkPolicyRefreshContract = c23.router({
|
|
|
6604
6631
|
summary: "Refresh active run network policies"
|
|
6605
6632
|
}
|
|
6606
6633
|
});
|
|
6607
|
-
var runnersBuiltinFirewallsResolveContract =
|
|
6634
|
+
var runnersBuiltinFirewallsResolveContract = c22.router({
|
|
6608
6635
|
resolve: {
|
|
6609
6636
|
method: "POST",
|
|
6610
6637
|
path: "/api/runners/builtin-firewalls/resolve",
|
|
@@ -6650,7 +6677,7 @@ var heartbeatBodySchema = external_exports.object({
|
|
|
6650
6677
|
message: "heldSessionStates may contain at most 1024 workspace caches"
|
|
6651
6678
|
});
|
|
6652
6679
|
});
|
|
6653
|
-
var runnersHeartbeatContract =
|
|
6680
|
+
var runnersHeartbeatContract = c22.router({
|
|
6654
6681
|
heartbeat: {
|
|
6655
6682
|
method: "POST",
|
|
6656
6683
|
path: "/api/runners/heartbeat",
|
|
@@ -6668,7 +6695,7 @@ var runnersHeartbeatContract = c23.router({
|
|
|
6668
6695
|
|
|
6669
6696
|
// ../../packages/api-contracts/src/contracts/storages.ts
|
|
6670
6697
|
init_esm_shims();
|
|
6671
|
-
var
|
|
6698
|
+
var c23 = initContract();
|
|
6672
6699
|
var storageTypeSchema = external_exports.enum(["volume", "artifact"]);
|
|
6673
6700
|
var versionQuerySchema = external_exports.string().regex(/^[a-f0-9]{8,64}$/i, "Version must be 8-64 hex characters").optional();
|
|
6674
6701
|
var uploadStorageResponseSchema = external_exports.object({
|
|
@@ -6679,7 +6706,7 @@ var uploadStorageResponseSchema = external_exports.object({
|
|
|
6679
6706
|
type: storageTypeSchema,
|
|
6680
6707
|
deduplicated: external_exports.boolean()
|
|
6681
6708
|
});
|
|
6682
|
-
var storagesContract =
|
|
6709
|
+
var storagesContract = c23.router({
|
|
6683
6710
|
/**
|
|
6684
6711
|
* POST /api/storages
|
|
6685
6712
|
* Upload a storage (tar.gz file)
|
|
@@ -6696,7 +6723,7 @@ var storagesContract = c24.router({
|
|
|
6696
6723
|
path: "/api/storages",
|
|
6697
6724
|
headers: authHeadersSchema,
|
|
6698
6725
|
contentType: "multipart/form-data",
|
|
6699
|
-
body:
|
|
6726
|
+
body: c23.type(),
|
|
6700
6727
|
responses: {
|
|
6701
6728
|
200: uploadStorageResponseSchema,
|
|
6702
6729
|
400: apiErrorSchema,
|
|
@@ -6725,9 +6752,9 @@ var storagesContract = c24.router({
|
|
|
6725
6752
|
}),
|
|
6726
6753
|
responses: {
|
|
6727
6754
|
// Binary response - actual handling done at route level
|
|
6728
|
-
200:
|
|
6755
|
+
200: c23.otherResponse({
|
|
6729
6756
|
contentType: "application/gzip",
|
|
6730
|
-
body:
|
|
6757
|
+
body: c23.type()
|
|
6731
6758
|
}),
|
|
6732
6759
|
400: apiErrorSchema,
|
|
6733
6760
|
401: apiErrorSchema,
|
|
@@ -6752,7 +6779,7 @@ var presignedUploadSchema = external_exports.object({
|
|
|
6752
6779
|
key: external_exports.string(),
|
|
6753
6780
|
presignedUrl: external_exports.url()
|
|
6754
6781
|
});
|
|
6755
|
-
var storagesPrepareContract =
|
|
6782
|
+
var storagesPrepareContract = c23.router({
|
|
6756
6783
|
prepare: {
|
|
6757
6784
|
method: "POST",
|
|
6758
6785
|
path: "/api/storages/prepare",
|
|
@@ -6787,7 +6814,7 @@ var storagesPrepareContract = c24.router({
|
|
|
6787
6814
|
summary: "Prepare for direct S3 upload"
|
|
6788
6815
|
}
|
|
6789
6816
|
});
|
|
6790
|
-
var storagesCommitContract =
|
|
6817
|
+
var storagesCommitContract = c23.router({
|
|
6791
6818
|
commit: {
|
|
6792
6819
|
method: "POST",
|
|
6793
6820
|
path: "/api/storages/commit",
|
|
@@ -6821,7 +6848,7 @@ var storagesCommitContract = c24.router({
|
|
|
6821
6848
|
summary: "Commit uploaded storage"
|
|
6822
6849
|
}
|
|
6823
6850
|
});
|
|
6824
|
-
var storagesDownloadContract =
|
|
6851
|
+
var storagesDownloadContract = c23.router({
|
|
6825
6852
|
download: {
|
|
6826
6853
|
method: "GET",
|
|
6827
6854
|
path: "/api/storages/download",
|
|
@@ -6857,7 +6884,7 @@ var storagesDownloadContract = c24.router({
|
|
|
6857
6884
|
summary: "Get presigned download URL"
|
|
6858
6885
|
}
|
|
6859
6886
|
});
|
|
6860
|
-
var storagesListContract =
|
|
6887
|
+
var storagesListContract = c23.router({
|
|
6861
6888
|
list: {
|
|
6862
6889
|
method: "GET",
|
|
6863
6890
|
path: "/api/storages/list",
|
|
@@ -6885,7 +6912,7 @@ var storagesListContract = c24.router({
|
|
|
6885
6912
|
});
|
|
6886
6913
|
|
|
6887
6914
|
// ../../packages/api-contracts/src/contracts/webhooks.ts
|
|
6888
|
-
var
|
|
6915
|
+
var c24 = initContract();
|
|
6889
6916
|
var sha256HexSchema = external_exports.string().regex(
|
|
6890
6917
|
/^[a-f0-9]{64}$/,
|
|
6891
6918
|
"hash must be a lowercase 64-character SHA-256 hex string"
|
|
@@ -6895,11 +6922,11 @@ var thirdPartyWebhookOkSchema = external_exports.union([
|
|
|
6895
6922
|
external_exports.string(),
|
|
6896
6923
|
external_exports.object({ message: external_exports.literal("pong") })
|
|
6897
6924
|
]);
|
|
6898
|
-
var webhookClerkContract =
|
|
6925
|
+
var webhookClerkContract = c24.router({
|
|
6899
6926
|
post: {
|
|
6900
6927
|
method: "POST",
|
|
6901
6928
|
path: "/api/webhooks/clerk",
|
|
6902
|
-
body:
|
|
6929
|
+
body: c24.type(),
|
|
6903
6930
|
responses: {
|
|
6904
6931
|
200: thirdPartyWebhookOkSchema,
|
|
6905
6932
|
401: thirdPartyWebhookErrorSchema
|
|
@@ -6907,11 +6934,11 @@ var webhookClerkContract = c25.router({
|
|
|
6907
6934
|
summary: "Handle Clerk organization and user webhooks"
|
|
6908
6935
|
}
|
|
6909
6936
|
});
|
|
6910
|
-
var webhookGithubContract =
|
|
6937
|
+
var webhookGithubContract = c24.router({
|
|
6911
6938
|
post: {
|
|
6912
6939
|
method: "POST",
|
|
6913
6940
|
path: "/api/webhooks/github",
|
|
6914
|
-
body:
|
|
6941
|
+
body: c24.type(),
|
|
6915
6942
|
responses: {
|
|
6916
6943
|
200: thirdPartyWebhookOkSchema,
|
|
6917
6944
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -6921,11 +6948,11 @@ var webhookGithubContract = c25.router({
|
|
|
6921
6948
|
summary: "Handle GitHub App webhooks"
|
|
6922
6949
|
}
|
|
6923
6950
|
});
|
|
6924
|
-
var webhookStripeContract =
|
|
6951
|
+
var webhookStripeContract = c24.router({
|
|
6925
6952
|
post: {
|
|
6926
6953
|
method: "POST",
|
|
6927
6954
|
path: "/api/webhooks/stripe",
|
|
6928
|
-
body:
|
|
6955
|
+
body: c24.type(),
|
|
6929
6956
|
responses: {
|
|
6930
6957
|
200: thirdPartyWebhookOkSchema,
|
|
6931
6958
|
401: thirdPartyWebhookErrorSchema,
|
|
@@ -6964,11 +6991,11 @@ var workflowAutomationWebhookResponseSchema = external_exports.object({
|
|
|
6964
6991
|
duplicate: external_exports.boolean(),
|
|
6965
6992
|
runId: external_exports.string().uuid().optional()
|
|
6966
6993
|
});
|
|
6967
|
-
var webhookGmailContract =
|
|
6994
|
+
var webhookGmailContract = c24.router({
|
|
6968
6995
|
post: {
|
|
6969
6996
|
method: "POST",
|
|
6970
6997
|
path: "/api/webhooks/gmail",
|
|
6971
|
-
body:
|
|
6998
|
+
body: c24.type(),
|
|
6972
6999
|
responses: {
|
|
6973
7000
|
200: gmailWebhookResponseSchema,
|
|
6974
7001
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -6979,11 +7006,11 @@ var webhookGmailContract = c25.router({
|
|
|
6979
7006
|
summary: "Handle Gmail Pub/Sub push notifications"
|
|
6980
7007
|
}
|
|
6981
7008
|
});
|
|
6982
|
-
var webhookGoogleCalendarContract =
|
|
7009
|
+
var webhookGoogleCalendarContract = c24.router({
|
|
6983
7010
|
post: {
|
|
6984
7011
|
method: "POST",
|
|
6985
7012
|
path: "/api/webhooks/google-calendar",
|
|
6986
|
-
body:
|
|
7013
|
+
body: c24.type(),
|
|
6987
7014
|
responses: {
|
|
6988
7015
|
200: googleCalendarWebhookResponseSchema,
|
|
6989
7016
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -6994,11 +7021,11 @@ var webhookGoogleCalendarContract = c25.router({
|
|
|
6994
7021
|
summary: "Handle Google Calendar push notifications"
|
|
6995
7022
|
}
|
|
6996
7023
|
});
|
|
6997
|
-
var webhookGoogleWorkspaceEventsContract =
|
|
7024
|
+
var webhookGoogleWorkspaceEventsContract = c24.router({
|
|
6998
7025
|
post: {
|
|
6999
7026
|
method: "POST",
|
|
7000
7027
|
path: "/api/webhooks/google-workspace-events",
|
|
7001
|
-
body:
|
|
7028
|
+
body: c24.type(),
|
|
7002
7029
|
responses: {
|
|
7003
7030
|
200: googleWorkspaceEventsWebhookResponseSchema,
|
|
7004
7031
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7009,11 +7036,11 @@ var webhookGoogleWorkspaceEventsContract = c25.router({
|
|
|
7009
7036
|
summary: "Handle Google Workspace Events Pub/Sub push notifications"
|
|
7010
7037
|
}
|
|
7011
7038
|
});
|
|
7012
|
-
var webhookNotionContract =
|
|
7039
|
+
var webhookNotionContract = c24.router({
|
|
7013
7040
|
post: {
|
|
7014
7041
|
method: "POST",
|
|
7015
7042
|
path: "/api/webhooks/notion",
|
|
7016
|
-
body:
|
|
7043
|
+
body: c24.type(),
|
|
7017
7044
|
responses: {
|
|
7018
7045
|
200: notionWebhookResponseSchema,
|
|
7019
7046
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7028,7 +7055,7 @@ var workflowAutomationWebhookPostRoute = {
|
|
|
7028
7055
|
pathParams: external_exports.object({
|
|
7029
7056
|
token: external_exports.string().min(1)
|
|
7030
7057
|
}),
|
|
7031
|
-
body:
|
|
7058
|
+
body: c24.type(),
|
|
7032
7059
|
responses: {
|
|
7033
7060
|
200: workflowAutomationWebhookResponseSchema,
|
|
7034
7061
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7039,14 +7066,14 @@ var workflowAutomationWebhookPostRoute = {
|
|
|
7039
7066
|
500: thirdPartyWebhookErrorSchema
|
|
7040
7067
|
}
|
|
7041
7068
|
};
|
|
7042
|
-
var webhookWorkflowAutomationContract =
|
|
7069
|
+
var webhookWorkflowAutomationContract = c24.router({
|
|
7043
7070
|
post: {
|
|
7044
7071
|
...workflowAutomationWebhookPostRoute,
|
|
7045
7072
|
path: "/api/webhooks/workflow-automations/:token",
|
|
7046
7073
|
summary: "Handle inbound workflow automation webhooks"
|
|
7047
7074
|
}
|
|
7048
7075
|
});
|
|
7049
|
-
var webhookBuiltInGenerationFalContract =
|
|
7076
|
+
var webhookBuiltInGenerationFalContract = c24.router({
|
|
7050
7077
|
post: {
|
|
7051
7078
|
method: "POST",
|
|
7052
7079
|
path: "/api/webhooks/built-in-generations/fal/:generationId",
|
|
@@ -7057,7 +7084,7 @@ var webhookBuiltInGenerationFalContract = c25.router({
|
|
|
7057
7084
|
token: external_exports.string().min(1),
|
|
7058
7085
|
visualKey: external_exports.string().min(1).optional()
|
|
7059
7086
|
}),
|
|
7060
|
-
body:
|
|
7087
|
+
body: c24.type(),
|
|
7061
7088
|
responses: {
|
|
7062
7089
|
200: thirdPartyWebhookOkSchema,
|
|
7063
7090
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7067,7 +7094,7 @@ var webhookBuiltInGenerationFalContract = c25.router({
|
|
|
7067
7094
|
summary: "Handle fal built-in generation webhooks"
|
|
7068
7095
|
}
|
|
7069
7096
|
});
|
|
7070
|
-
var webhookBuiltInGenerationBytePlusContract =
|
|
7097
|
+
var webhookBuiltInGenerationBytePlusContract = c24.router({
|
|
7071
7098
|
post: {
|
|
7072
7099
|
method: "POST",
|
|
7073
7100
|
path: "/api/webhooks/built-in-generations/byteplus/:generationId",
|
|
@@ -7078,7 +7105,7 @@ var webhookBuiltInGenerationBytePlusContract = c25.router({
|
|
|
7078
7105
|
token: external_exports.string().min(1),
|
|
7079
7106
|
visualKey: external_exports.string().min(1).optional()
|
|
7080
7107
|
}),
|
|
7081
|
-
body:
|
|
7108
|
+
body: c24.type(),
|
|
7082
7109
|
responses: {
|
|
7083
7110
|
200: thirdPartyWebhookOkSchema,
|
|
7084
7111
|
400: thirdPartyWebhookErrorSchema,
|
|
@@ -7138,7 +7165,7 @@ var firewallAuthResponseSchema = external_exports.object({
|
|
|
7138
7165
|
refreshedConnectors: external_exports.array(external_exports.string()),
|
|
7139
7166
|
refreshedSecrets: external_exports.array(external_exports.string())
|
|
7140
7167
|
});
|
|
7141
|
-
var webhookFirewallAuthContract =
|
|
7168
|
+
var webhookFirewallAuthContract = c24.router({
|
|
7142
7169
|
/**
|
|
7143
7170
|
* POST /api/webhooks/agent/firewall/auth
|
|
7144
7171
|
* Resolve firewall auth templates and refresh access tokens on demand.
|
|
@@ -7180,7 +7207,7 @@ var webhookFirewallAuthContract = c25.router({
|
|
|
7180
7207
|
summary: "Resolve firewall auth templates"
|
|
7181
7208
|
}
|
|
7182
7209
|
});
|
|
7183
|
-
var webhookEventsContract =
|
|
7210
|
+
var webhookEventsContract = c24.router({
|
|
7184
7211
|
/**
|
|
7185
7212
|
* POST /api/webhooks/agent/events
|
|
7186
7213
|
* Receive agent events from sandbox
|
|
@@ -7207,7 +7234,7 @@ var webhookEventsContract = c25.router({
|
|
|
7207
7234
|
summary: "Receive agent events from sandbox"
|
|
7208
7235
|
}
|
|
7209
7236
|
});
|
|
7210
|
-
var webhookCompleteContract =
|
|
7237
|
+
var webhookCompleteContract = c24.router({
|
|
7211
7238
|
/**
|
|
7212
7239
|
* POST /api/webhooks/agent/complete
|
|
7213
7240
|
* Handle agent run completion (success or failure)
|
|
@@ -7244,7 +7271,7 @@ var webhookCompleteContract = c25.router({
|
|
|
7244
7271
|
summary: "Handle agent run completion"
|
|
7245
7272
|
}
|
|
7246
7273
|
});
|
|
7247
|
-
var webhookCheckpointsContract =
|
|
7274
|
+
var webhookCheckpointsContract = c24.router({
|
|
7248
7275
|
/**
|
|
7249
7276
|
* POST /api/webhooks/agent/checkpoints
|
|
7250
7277
|
* Create a recoverable checkpoint for an agent run.
|
|
@@ -7279,7 +7306,7 @@ var webhookCheckpointsContract = c25.router({
|
|
|
7279
7306
|
summary: "Create checkpoint for agent run"
|
|
7280
7307
|
}
|
|
7281
7308
|
});
|
|
7282
|
-
var webhookCheckpointsPrepareHistoryContract =
|
|
7309
|
+
var webhookCheckpointsPrepareHistoryContract = c24.router({
|
|
7283
7310
|
prepare: {
|
|
7284
7311
|
method: "POST",
|
|
7285
7312
|
path: "/api/webhooks/agent/checkpoints/prepare-history",
|
|
@@ -7305,7 +7332,7 @@ var webhookCheckpointsPrepareHistoryContract = c25.router({
|
|
|
7305
7332
|
summary: "Get presigned URL for uploading session history to S3"
|
|
7306
7333
|
}
|
|
7307
7334
|
});
|
|
7308
|
-
var webhookHeartbeatContract =
|
|
7335
|
+
var webhookHeartbeatContract = c24.router({
|
|
7309
7336
|
/**
|
|
7310
7337
|
* POST /api/webhooks/agent/heartbeat
|
|
7311
7338
|
* Receive heartbeat signals from sandbox
|
|
@@ -7329,7 +7356,7 @@ var webhookHeartbeatContract = c25.router({
|
|
|
7329
7356
|
summary: "Receive heartbeat from sandbox"
|
|
7330
7357
|
}
|
|
7331
7358
|
});
|
|
7332
|
-
var webhookStoragesContract =
|
|
7359
|
+
var webhookStoragesContract = c24.router({
|
|
7333
7360
|
/**
|
|
7334
7361
|
* POST /api/webhooks/agent/storages
|
|
7335
7362
|
* Create a new version of a storage from sandbox
|
|
@@ -7345,7 +7372,7 @@ var webhookStoragesContract = c25.router({
|
|
|
7345
7372
|
path: "/api/webhooks/agent/storages",
|
|
7346
7373
|
headers: authHeadersSchema,
|
|
7347
7374
|
contentType: "multipart/form-data",
|
|
7348
|
-
body:
|
|
7375
|
+
body: c24.type(),
|
|
7349
7376
|
responses: {
|
|
7350
7377
|
200: external_exports.object({
|
|
7351
7378
|
versionId: external_exports.string(),
|
|
@@ -7361,7 +7388,7 @@ var webhookStoragesContract = c25.router({
|
|
|
7361
7388
|
summary: "Upload storage version from sandbox"
|
|
7362
7389
|
}
|
|
7363
7390
|
});
|
|
7364
|
-
var webhookStoragesIncrementalContract =
|
|
7391
|
+
var webhookStoragesIncrementalContract = c24.router({
|
|
7365
7392
|
/**
|
|
7366
7393
|
* POST /api/webhooks/agent/storages/incremental
|
|
7367
7394
|
* Create a new version using incremental upload
|
|
@@ -7379,7 +7406,7 @@ var webhookStoragesIncrementalContract = c25.router({
|
|
|
7379
7406
|
path: "/api/webhooks/agent/storages/incremental",
|
|
7380
7407
|
headers: authHeadersSchema,
|
|
7381
7408
|
contentType: "multipart/form-data",
|
|
7382
|
-
body:
|
|
7409
|
+
body: c24.type(),
|
|
7383
7410
|
responses: {
|
|
7384
7411
|
200: external_exports.object({
|
|
7385
7412
|
versionId: external_exports.string(),
|
|
@@ -7464,7 +7491,7 @@ var sandboxOperationSchema = external_exports.object({
|
|
|
7464
7491
|
session_history_transfer_encoding_state: sessionHistoryTransferEncodingStateSchema.optional(),
|
|
7465
7492
|
session_history_download_source: sandboxOperationDownloadSourceSchema
|
|
7466
7493
|
});
|
|
7467
|
-
var webhookTelemetryContract =
|
|
7494
|
+
var webhookTelemetryContract = c24.router({
|
|
7468
7495
|
/**
|
|
7469
7496
|
* POST /api/webhooks/agent/telemetry
|
|
7470
7497
|
* Receive telemetry data (system log, metrics, network logs, and sandbox operations) from sandbox
|
|
@@ -7493,7 +7520,7 @@ var webhookTelemetryContract = c25.router({
|
|
|
7493
7520
|
summary: "Receive telemetry data from sandbox"
|
|
7494
7521
|
}
|
|
7495
7522
|
});
|
|
7496
|
-
var webhookStoragesPrepareContract =
|
|
7523
|
+
var webhookStoragesPrepareContract = c24.router({
|
|
7497
7524
|
prepare: {
|
|
7498
7525
|
method: "POST",
|
|
7499
7526
|
path: "/api/webhooks/agent/storages/prepare",
|
|
@@ -7527,7 +7554,7 @@ var webhookStoragesPrepareContract = c25.router({
|
|
|
7527
7554
|
summary: "Prepare for direct S3 upload from sandbox"
|
|
7528
7555
|
}
|
|
7529
7556
|
});
|
|
7530
|
-
var webhookStoragesCommitContract =
|
|
7557
|
+
var webhookStoragesCommitContract = c24.router({
|
|
7531
7558
|
commit: {
|
|
7532
7559
|
method: "POST",
|
|
7533
7560
|
path: "/api/webhooks/agent/storages/commit",
|
|
@@ -7570,7 +7597,7 @@ var webhookUsageEventItemSchema = external_exports.object({
|
|
|
7570
7597
|
quantity: external_exports.number().int().min(0),
|
|
7571
7598
|
grossCredits: external_exports.number().int().min(0).optional()
|
|
7572
7599
|
}).strict();
|
|
7573
|
-
var webhookUsageEventContract =
|
|
7600
|
+
var webhookUsageEventContract = c24.router({
|
|
7574
7601
|
send: {
|
|
7575
7602
|
method: "POST",
|
|
7576
7603
|
path: "/api/webhooks/agent/usage-event",
|
|
@@ -7591,7 +7618,7 @@ var webhookUsageEventContract = c25.router({
|
|
|
7591
7618
|
summary: "Receive billing usage event data from sandbox"
|
|
7592
7619
|
}
|
|
7593
7620
|
});
|
|
7594
|
-
var
|
|
7621
|
+
var webhookModelUsageObservationItemSchema = external_exports.object({
|
|
7595
7622
|
idempotencyKey: external_exports.uuid(),
|
|
7596
7623
|
model: external_exports.string().min(1).max(255),
|
|
7597
7624
|
inputTokens: external_exports.number().int().min(0).max(Number.MAX_SAFE_INTEGER),
|
|
@@ -7604,9 +7631,9 @@ var webhookModelUsageObservationV2ItemSchema = external_exports.object({
|
|
|
7604
7631
|
},
|
|
7605
7632
|
{ message: "At least one token counter must be positive" }
|
|
7606
7633
|
);
|
|
7607
|
-
var
|
|
7634
|
+
var webhookModelUsageObservationBodySchema = external_exports.object({
|
|
7608
7635
|
runId: external_exports.string().min(1, "runId is required"),
|
|
7609
|
-
events: external_exports.array(
|
|
7636
|
+
events: external_exports.array(webhookModelUsageObservationItemSchema).min(1).max(100)
|
|
7610
7637
|
}).strict().superRefine((body, ctx) => {
|
|
7611
7638
|
const idempotencyKeys = /* @__PURE__ */ new Set();
|
|
7612
7639
|
body.events.forEach((event, index) => {
|
|
@@ -7620,12 +7647,12 @@ var webhookModelUsageObservationV2BodySchema = external_exports.object({
|
|
|
7620
7647
|
idempotencyKeys.add(event.idempotencyKey);
|
|
7621
7648
|
});
|
|
7622
7649
|
});
|
|
7623
|
-
var
|
|
7650
|
+
var webhookModelUsageObservationContract = c24.router({
|
|
7624
7651
|
send: {
|
|
7625
7652
|
method: "POST",
|
|
7626
|
-
path: "/api/webhooks/agent/model-usage-observation
|
|
7653
|
+
path: "/api/webhooks/agent/model-usage-observation",
|
|
7627
7654
|
headers: authHeadersSchema,
|
|
7628
|
-
body:
|
|
7655
|
+
body: webhookModelUsageObservationBodySchema,
|
|
7629
7656
|
responses: {
|
|
7630
7657
|
200: external_exports.object({
|
|
7631
7658
|
success: external_exports.boolean()
|
|
@@ -7655,7 +7682,7 @@ var zeroRunRequestSchema = unifiedRunRequestSchema.omit({
|
|
|
7655
7682
|
agentId: external_exports.string().optional(),
|
|
7656
7683
|
modelProvider: external_exports.string().optional()
|
|
7657
7684
|
});
|
|
7658
|
-
var
|
|
7685
|
+
var c25 = initContract();
|
|
7659
7686
|
var zeroLogPaginationQuerySchema = createLogPaginationQuerySchema({
|
|
7660
7687
|
cursorKind: "sequence"
|
|
7661
7688
|
});
|
|
@@ -7665,7 +7692,7 @@ var zeroNetworkLogPaginationQuerySchema = createLogPaginationQuerySchema({
|
|
|
7665
7692
|
defaultLimit: 500,
|
|
7666
7693
|
defaultOrder: "asc"
|
|
7667
7694
|
});
|
|
7668
|
-
var zeroRunsMainContract =
|
|
7695
|
+
var zeroRunsMainContract = c25.router({
|
|
7669
7696
|
create: {
|
|
7670
7697
|
method: "POST",
|
|
7671
7698
|
path: "/api/zero/runs",
|
|
@@ -7684,7 +7711,7 @@ var zeroRunsMainContract = c26.router({
|
|
|
7684
7711
|
summary: "Create and execute agent run (zero proxy)"
|
|
7685
7712
|
}
|
|
7686
7713
|
});
|
|
7687
|
-
var zeroRunsByIdContract =
|
|
7714
|
+
var zeroRunsByIdContract = c25.router({
|
|
7688
7715
|
getById: {
|
|
7689
7716
|
method: "GET",
|
|
7690
7717
|
path: "/api/zero/runs/:id",
|
|
@@ -7702,7 +7729,7 @@ var zeroRunsByIdContract = c26.router({
|
|
|
7702
7729
|
summary: "Get agent run by ID (zero proxy)"
|
|
7703
7730
|
}
|
|
7704
7731
|
});
|
|
7705
|
-
var zeroRunsCancelContract =
|
|
7732
|
+
var zeroRunsCancelContract = c25.router({
|
|
7706
7733
|
cancel: {
|
|
7707
7734
|
method: "POST",
|
|
7708
7735
|
path: "/api/zero/runs/:id/cancel",
|
|
@@ -7721,7 +7748,7 @@ var zeroRunsCancelContract = c26.router({
|
|
|
7721
7748
|
summary: "Cancel a pending or running run (zero proxy)"
|
|
7722
7749
|
}
|
|
7723
7750
|
});
|
|
7724
|
-
var zeroRunsQueueContract =
|
|
7751
|
+
var zeroRunsQueueContract = c25.router({
|
|
7725
7752
|
getQueue: {
|
|
7726
7753
|
method: "GET",
|
|
7727
7754
|
path: "/api/zero/runs/queue",
|
|
@@ -7734,7 +7761,7 @@ var zeroRunsQueueContract = c26.router({
|
|
|
7734
7761
|
summary: "Get org run queue status (zero proxy)"
|
|
7735
7762
|
}
|
|
7736
7763
|
});
|
|
7737
|
-
var zeroRunAgentEventsContract =
|
|
7764
|
+
var zeroRunAgentEventsContract = c25.router({
|
|
7738
7765
|
getAgentEvents: {
|
|
7739
7766
|
method: "GET",
|
|
7740
7767
|
path: "/api/zero/runs/:id/telemetry/agent",
|
|
@@ -7798,7 +7825,7 @@ var runContextResponseSchema = external_exports.object({
|
|
|
7798
7825
|
artifact: runContextArtifactSchema.nullable(),
|
|
7799
7826
|
featureFlags: external_exports.record(external_exports.string(), external_exports.boolean()).nullable()
|
|
7800
7827
|
});
|
|
7801
|
-
var zeroRunContextContract =
|
|
7828
|
+
var zeroRunContextContract = c25.router({
|
|
7802
7829
|
getContext: {
|
|
7803
7830
|
method: "GET",
|
|
7804
7831
|
path: "/api/zero/runs/:id/context",
|
|
@@ -7816,7 +7843,7 @@ var zeroRunContextContract = c26.router({
|
|
|
7816
7843
|
summary: "Get run execution context snapshot for debugging"
|
|
7817
7844
|
}
|
|
7818
7845
|
});
|
|
7819
|
-
var zeroRunNetworkLogsContract =
|
|
7846
|
+
var zeroRunNetworkLogsContract = c25.router({
|
|
7820
7847
|
getNetworkLogs: {
|
|
7821
7848
|
method: "GET",
|
|
7822
7849
|
path: "/api/zero/runs/:id/network",
|
|
@@ -7838,7 +7865,7 @@ var zeroRunNetworkLogsContract = c26.router({
|
|
|
7838
7865
|
var runRunnerResponseSchema = external_exports.object({
|
|
7839
7866
|
sandboxReuseResult: sandboxReuseResultSchema.nullable()
|
|
7840
7867
|
});
|
|
7841
|
-
var zeroRunRunnerContract =
|
|
7868
|
+
var zeroRunRunnerContract = c25.router({
|
|
7842
7869
|
getRunner: {
|
|
7843
7870
|
method: "GET",
|
|
7844
7871
|
path: "/api/zero/runs/:id/runner",
|
|
@@ -7856,7 +7883,7 @@ var zeroRunRunnerContract = c26.router({
|
|
|
7856
7883
|
summary: "Get runner-level metadata for a run"
|
|
7857
7884
|
}
|
|
7858
7885
|
});
|
|
7859
|
-
var zeroLogsSearchContract =
|
|
7886
|
+
var zeroLogsSearchContract = c25.router({
|
|
7860
7887
|
searchLogs: {
|
|
7861
7888
|
method: "GET",
|
|
7862
7889
|
path: "/api/zero/logs/search",
|
|
@@ -7875,8 +7902,8 @@ var zeroLogsSearchContract = c26.router({
|
|
|
7875
7902
|
// src/lib/api/domains/zero-runs.ts
|
|
7876
7903
|
async function getZeroRunAgentEvents(id, options) {
|
|
7877
7904
|
const config = await getClientConfig();
|
|
7878
|
-
const
|
|
7879
|
-
const result = await
|
|
7905
|
+
const client2 = initClient(zeroRunAgentEventsContract, config);
|
|
7906
|
+
const result = await client2.getAgentEvents({
|
|
7880
7907
|
params: { id },
|
|
7881
7908
|
query: {
|
|
7882
7909
|
since: options?.since,
|
|
@@ -7894,8 +7921,8 @@ async function getZeroRunAgentEvents(id, options) {
|
|
|
7894
7921
|
init_esm_shims();
|
|
7895
7922
|
async function searchZeroChat(options) {
|
|
7896
7923
|
const config = await getClientConfig();
|
|
7897
|
-
const
|
|
7898
|
-
const result = await
|
|
7924
|
+
const client2 = initClient(chatSearchContract, config);
|
|
7925
|
+
const result = await client2.search({
|
|
7899
7926
|
query: {
|
|
7900
7927
|
keyword: options.keyword,
|
|
7901
7928
|
agentId: options.agentId,
|
|
@@ -7910,8 +7937,8 @@ async function searchZeroChat(options) {
|
|
|
7910
7937
|
}
|
|
7911
7938
|
async function getZeroChatThreadSnapshot() {
|
|
7912
7939
|
const config = await getClientConfig();
|
|
7913
|
-
const
|
|
7914
|
-
const result = await
|
|
7940
|
+
const client2 = initClient(chatThreadsContract, config);
|
|
7941
|
+
const result = await client2.snapshot();
|
|
7915
7942
|
if (result.status === 200) {
|
|
7916
7943
|
return result.body;
|
|
7917
7944
|
}
|
|
@@ -7919,8 +7946,8 @@ async function getZeroChatThreadSnapshot() {
|
|
|
7919
7946
|
}
|
|
7920
7947
|
async function listZeroChatThreadEvents(options) {
|
|
7921
7948
|
const config = await getClientConfig();
|
|
7922
|
-
const
|
|
7923
|
-
const result = await
|
|
7949
|
+
const client2 = initClient(chatThreadsContract, config);
|
|
7950
|
+
const result = await client2.events({
|
|
7924
7951
|
query: options.sinceEventId ? { sinceEventId: options.sinceEventId } : {}
|
|
7925
7952
|
});
|
|
7926
7953
|
if (result.status === 200) {
|
|
@@ -7937,8 +7964,8 @@ async function listZeroChatThreadEvents(options) {
|
|
|
7937
7964
|
}
|
|
7938
7965
|
async function renameZeroChatThread(options) {
|
|
7939
7966
|
const config = await getClientConfig();
|
|
7940
|
-
const
|
|
7941
|
-
const result = await
|
|
7967
|
+
const client2 = initClient(chatThreadRenameContract, config);
|
|
7968
|
+
const result = await client2.rename({
|
|
7942
7969
|
params: { id: options.threadId },
|
|
7943
7970
|
body: { title: options.title }
|
|
7944
7971
|
});
|
|
@@ -7949,8 +7976,8 @@ async function renameZeroChatThread(options) {
|
|
|
7949
7976
|
}
|
|
7950
7977
|
async function getZeroChatThread(options) {
|
|
7951
7978
|
const config = await getClientConfig();
|
|
7952
|
-
const
|
|
7953
|
-
const result = await
|
|
7979
|
+
const client2 = initClient(chatThreadMetadataContract, config);
|
|
7980
|
+
const result = await client2.get({
|
|
7954
7981
|
params: { id: options.threadId }
|
|
7955
7982
|
});
|
|
7956
7983
|
if (result.status === 200) {
|
|
@@ -7960,8 +7987,8 @@ async function getZeroChatThread(options) {
|
|
|
7960
7987
|
}
|
|
7961
7988
|
async function updateZeroChatThreadModelSelection(options) {
|
|
7962
7989
|
const config = await getClientConfig();
|
|
7963
|
-
const
|
|
7964
|
-
const result = await
|
|
7990
|
+
const client2 = initClient(chatThreadModelSelectionContract, config);
|
|
7991
|
+
const result = await client2.update({
|
|
7965
7992
|
params: { id: options.threadId },
|
|
7966
7993
|
body: { model: options.model }
|
|
7967
7994
|
});
|
|
@@ -7979,7 +8006,7 @@ init_esm_shims();
|
|
|
7979
8006
|
|
|
7980
8007
|
// ../../packages/api-contracts/src/contracts/zero-developer-support.ts
|
|
7981
8008
|
init_esm_shims();
|
|
7982
|
-
var
|
|
8009
|
+
var c26 = initContract();
|
|
7983
8010
|
var developerSupportBodySchema = external_exports.object({
|
|
7984
8011
|
title: external_exports.string().min(1, "Title is required"),
|
|
7985
8012
|
description: external_exports.string().min(1, "Description is required"),
|
|
@@ -7991,7 +8018,7 @@ var consentCodeResponseSchema = external_exports.object({
|
|
|
7991
8018
|
var submitResponseSchema = external_exports.object({
|
|
7992
8019
|
reference: external_exports.string()
|
|
7993
8020
|
});
|
|
7994
|
-
var zeroDeveloperSupportContract =
|
|
8021
|
+
var zeroDeveloperSupportContract = c26.router({
|
|
7995
8022
|
submit: {
|
|
7996
8023
|
method: "POST",
|
|
7997
8024
|
path: "/api/zero/developer-support",
|
|
@@ -8010,15 +8037,15 @@ var zeroDeveloperSupportContract = c27.router({
|
|
|
8010
8037
|
// src/lib/api/domains/zero-developer-support.ts
|
|
8011
8038
|
async function requestDeveloperSupportConsent(body) {
|
|
8012
8039
|
const config = await getClientConfig();
|
|
8013
|
-
const
|
|
8014
|
-
const result = await
|
|
8040
|
+
const client2 = initClient(zeroDeveloperSupportContract, config);
|
|
8041
|
+
const result = await client2.submit({ body, headers: {} });
|
|
8015
8042
|
if (result.status === 200) return result.body;
|
|
8016
8043
|
handleError(result, "Failed to request developer support consent");
|
|
8017
8044
|
}
|
|
8018
8045
|
async function submitDeveloperSupport(body) {
|
|
8019
8046
|
const config = await getClientConfig();
|
|
8020
|
-
const
|
|
8021
|
-
const result = await
|
|
8047
|
+
const client2 = initClient(zeroDeveloperSupportContract, config);
|
|
8048
|
+
const result = await client2.submit({ body, headers: {} });
|
|
8022
8049
|
if (result.status === 200) return result.body;
|
|
8023
8050
|
handleError(result, "Failed to submit developer support request");
|
|
8024
8051
|
}
|
|
@@ -8187,7 +8214,7 @@ init_esm_shims();
|
|
|
8187
8214
|
|
|
8188
8215
|
// ../../packages/api-contracts/src/contracts/zero-computer-use.ts
|
|
8189
8216
|
init_esm_shims();
|
|
8190
|
-
var
|
|
8217
|
+
var c27 = initContract();
|
|
8191
8218
|
var computerUseHostStatusSchema = external_exports.enum(["online", "offline"]);
|
|
8192
8219
|
var computerUseReadCommandKindSchema = external_exports.enum([
|
|
8193
8220
|
"apps.list",
|
|
@@ -8246,9 +8273,6 @@ var hostNameSchema = external_exports.string().trim().min(1).max(253);
|
|
|
8246
8273
|
var hostInstallationIdSchema = external_exports.string().trim().uuid();
|
|
8247
8274
|
var hostVersionSchema = external_exports.string().trim().min(1).max(64);
|
|
8248
8275
|
var hostOsVersionSchema = external_exports.string().trim().min(1).max(128);
|
|
8249
|
-
var hostIdPathParamsSchema = external_exports.object({
|
|
8250
|
-
hostId: external_exports.string().min(1)
|
|
8251
|
-
});
|
|
8252
8276
|
var authorizationRequestTokenPathParamsSchema = external_exports.object({
|
|
8253
8277
|
requestToken: external_exports.string().min(1)
|
|
8254
8278
|
});
|
|
@@ -8471,9 +8495,6 @@ var computerUseHostStopResponseSchema = external_exports.object({
|
|
|
8471
8495
|
var computerUseHostListResponseSchema = external_exports.object({
|
|
8472
8496
|
hosts: external_exports.array(computerUseHostSchema)
|
|
8473
8497
|
});
|
|
8474
|
-
var computerUseHostDeleteResponseSchema = external_exports.object({
|
|
8475
|
-
ok: external_exports.literal(true)
|
|
8476
|
-
});
|
|
8477
8498
|
var computerUseAuthorizationSourceSchema = external_exports.enum([
|
|
8478
8499
|
"chat",
|
|
8479
8500
|
"slack",
|
|
@@ -8562,7 +8583,7 @@ var computerUseAuditEventSchema = external_exports.object({
|
|
|
8562
8583
|
var computerUseAuditEventListResponseSchema = external_exports.object({
|
|
8563
8584
|
auditEvents: external_exports.array(computerUseAuditEventSchema)
|
|
8564
8585
|
});
|
|
8565
|
-
var zeroComputerUseHostsContract =
|
|
8586
|
+
var zeroComputerUseHostsContract = c27.router({
|
|
8566
8587
|
start: {
|
|
8567
8588
|
method: "POST",
|
|
8568
8589
|
path: "/api/zero/computer-use/hosts/start",
|
|
@@ -8586,22 +8607,9 @@ var zeroComputerUseHostsContract = c28.router({
|
|
|
8586
8607
|
403: apiErrorSchema
|
|
8587
8608
|
},
|
|
8588
8609
|
summary: "List linked desktop computer-use hosts"
|
|
8589
|
-
},
|
|
8590
|
-
delete: {
|
|
8591
|
-
method: "DELETE",
|
|
8592
|
-
path: "/api/zero/computer-use/hosts/:hostId",
|
|
8593
|
-
headers: authHeadersSchema,
|
|
8594
|
-
pathParams: hostIdPathParamsSchema,
|
|
8595
|
-
responses: {
|
|
8596
|
-
200: computerUseHostDeleteResponseSchema,
|
|
8597
|
-
401: apiErrorSchema,
|
|
8598
|
-
403: apiErrorSchema,
|
|
8599
|
-
404: apiErrorSchema
|
|
8600
|
-
},
|
|
8601
|
-
summary: "Delete a desktop computer-use host"
|
|
8602
8610
|
}
|
|
8603
8611
|
});
|
|
8604
|
-
var zeroComputerUseHeartbeatContract =
|
|
8612
|
+
var zeroComputerUseHeartbeatContract = c27.router({
|
|
8605
8613
|
heartbeat: {
|
|
8606
8614
|
method: "POST",
|
|
8607
8615
|
path: "/api/zero/computer-use/heartbeat",
|
|
@@ -8626,7 +8634,7 @@ var zeroComputerUseHeartbeatContract = c28.router({
|
|
|
8626
8634
|
summary: "Stop a desktop computer-use host"
|
|
8627
8635
|
}
|
|
8628
8636
|
});
|
|
8629
|
-
var zeroComputerUseAuthorizationRequestsContract =
|
|
8637
|
+
var zeroComputerUseAuthorizationRequestsContract = c27.router({
|
|
8630
8638
|
create: {
|
|
8631
8639
|
method: "POST",
|
|
8632
8640
|
path: "/api/zero/computer-use/authorization-requests",
|
|
@@ -8673,7 +8681,7 @@ var zeroComputerUseAuthorizationRequestsContract = c28.router({
|
|
|
8673
8681
|
summary: "Bind a Computer Use host for a delegated authorization request"
|
|
8674
8682
|
}
|
|
8675
8683
|
});
|
|
8676
|
-
var zeroComputerUseCommandContract =
|
|
8684
|
+
var zeroComputerUseCommandContract = c27.router({
|
|
8677
8685
|
create: {
|
|
8678
8686
|
method: "POST",
|
|
8679
8687
|
path: "/api/zero/computer-use/commands",
|
|
@@ -8708,7 +8716,7 @@ var zeroComputerUseCommandContract = c28.router({
|
|
|
8708
8716
|
headers: authHeadersSchema,
|
|
8709
8717
|
pathParams: commandIdPathParamsSchema,
|
|
8710
8718
|
responses: {
|
|
8711
|
-
200:
|
|
8719
|
+
200: c27.type(),
|
|
8712
8720
|
401: apiErrorSchema,
|
|
8713
8721
|
403: apiErrorSchema,
|
|
8714
8722
|
404: apiErrorSchema
|
|
@@ -8721,7 +8729,7 @@ var zeroComputerUseCommandContract = c28.router({
|
|
|
8721
8729
|
headers: authHeadersSchema,
|
|
8722
8730
|
pathParams: commandIdPathParamsSchema,
|
|
8723
8731
|
responses: {
|
|
8724
|
-
200:
|
|
8732
|
+
200: c27.type(),
|
|
8725
8733
|
401: apiErrorSchema,
|
|
8726
8734
|
403: apiErrorSchema,
|
|
8727
8735
|
404: apiErrorSchema
|
|
@@ -8729,7 +8737,7 @@ var zeroComputerUseCommandContract = c28.router({
|
|
|
8729
8737
|
summary: "Download offloaded desktop computer-use plugin content"
|
|
8730
8738
|
}
|
|
8731
8739
|
});
|
|
8732
|
-
var zeroComputerUseWriteCommandContract =
|
|
8740
|
+
var zeroComputerUseWriteCommandContract = c27.router({
|
|
8733
8741
|
create: {
|
|
8734
8742
|
method: "POST",
|
|
8735
8743
|
path: "/api/zero/computer-use/write-commands",
|
|
@@ -8746,7 +8754,7 @@ var zeroComputerUseWriteCommandContract = c28.router({
|
|
|
8746
8754
|
summary: "Create a desktop computer-use write command"
|
|
8747
8755
|
}
|
|
8748
8756
|
});
|
|
8749
|
-
var zeroComputerUsePluginCommandContract =
|
|
8757
|
+
var zeroComputerUsePluginCommandContract = c27.router({
|
|
8750
8758
|
create: {
|
|
8751
8759
|
method: "POST",
|
|
8752
8760
|
path: "/api/zero/computer-use/plugin-commands",
|
|
@@ -8763,7 +8771,7 @@ var zeroComputerUsePluginCommandContract = c28.router({
|
|
|
8763
8771
|
summary: "Create a desktop computer-use plugin command"
|
|
8764
8772
|
}
|
|
8765
8773
|
});
|
|
8766
|
-
var zeroComputerUseHostCommandsContract =
|
|
8774
|
+
var zeroComputerUseHostCommandsContract = c27.router({
|
|
8767
8775
|
next: {
|
|
8768
8776
|
method: "POST",
|
|
8769
8777
|
path: "/api/zero/computer-use/host/commands/next",
|
|
@@ -8791,7 +8799,7 @@ var zeroComputerUseHostCommandsContract = c28.router({
|
|
|
8791
8799
|
summary: "Complete a desktop computer-use command"
|
|
8792
8800
|
}
|
|
8793
8801
|
});
|
|
8794
|
-
var zeroComputerUseAuditEventsContract =
|
|
8802
|
+
var zeroComputerUseAuditEventsContract = c27.router({
|
|
8795
8803
|
list: {
|
|
8796
8804
|
method: "GET",
|
|
8797
8805
|
path: "/api/zero/computer-use/audit-events",
|
|
@@ -8872,8 +8880,8 @@ function commandBody(params) {
|
|
|
8872
8880
|
}
|
|
8873
8881
|
async function createComputerUseReadCommand(params) {
|
|
8874
8882
|
const config = await getComputerUseClientConfig();
|
|
8875
|
-
const
|
|
8876
|
-
const result = await
|
|
8883
|
+
const client2 = initClient(zeroComputerUseCommandContract, config);
|
|
8884
|
+
const result = await client2.create({ body: commandBody(params) });
|
|
8877
8885
|
if (result.status === 200) {
|
|
8878
8886
|
return result.body;
|
|
8879
8887
|
}
|
|
@@ -8881,8 +8889,8 @@ async function createComputerUseReadCommand(params) {
|
|
|
8881
8889
|
}
|
|
8882
8890
|
async function createComputerUseWriteCommand(params) {
|
|
8883
8891
|
const config = await getComputerUseClientConfig();
|
|
8884
|
-
const
|
|
8885
|
-
const result = await
|
|
8892
|
+
const client2 = initClient(zeroComputerUseWriteCommandContract, config);
|
|
8893
|
+
const result = await client2.create({ body: commandBody(params) });
|
|
8886
8894
|
if (result.status === 200) {
|
|
8887
8895
|
return result.body;
|
|
8888
8896
|
}
|
|
@@ -8890,8 +8898,8 @@ async function createComputerUseWriteCommand(params) {
|
|
|
8890
8898
|
}
|
|
8891
8899
|
async function createComputerUsePluginCommand(params) {
|
|
8892
8900
|
const config = await getComputerUseClientConfig();
|
|
8893
|
-
const
|
|
8894
|
-
const result = await
|
|
8901
|
+
const client2 = initClient(zeroComputerUsePluginCommandContract, config);
|
|
8902
|
+
const result = await client2.create({ body: params });
|
|
8895
8903
|
if (result.status === 200) {
|
|
8896
8904
|
return result.body;
|
|
8897
8905
|
}
|
|
@@ -8899,8 +8907,8 @@ async function createComputerUsePluginCommand(params) {
|
|
|
8899
8907
|
}
|
|
8900
8908
|
async function listComputerUseHosts() {
|
|
8901
8909
|
const config = await getComputerUseClientConfig();
|
|
8902
|
-
const
|
|
8903
|
-
const result = await
|
|
8910
|
+
const client2 = initClient(zeroComputerUseHostsContract, config);
|
|
8911
|
+
const result = await client2.list({});
|
|
8904
8912
|
if (result.status === 200) {
|
|
8905
8913
|
return result.body.hosts;
|
|
8906
8914
|
}
|
|
@@ -8908,8 +8916,8 @@ async function listComputerUseHosts() {
|
|
|
8908
8916
|
}
|
|
8909
8917
|
async function getComputerUseCommand(commandId) {
|
|
8910
8918
|
const config = await getComputerUseClientConfig();
|
|
8911
|
-
const
|
|
8912
|
-
const result = await
|
|
8919
|
+
const client2 = initClient(zeroComputerUseCommandContract, config);
|
|
8920
|
+
const result = await client2.get({ params: { commandId } });
|
|
8913
8921
|
if (result.status === 200) {
|
|
8914
8922
|
return result.body;
|
|
8915
8923
|
}
|
|
@@ -8917,11 +8925,11 @@ async function getComputerUseCommand(commandId) {
|
|
|
8917
8925
|
}
|
|
8918
8926
|
async function createComputerUseAuthorizationRequest() {
|
|
8919
8927
|
const config = await getComputerUseClientConfig();
|
|
8920
|
-
const
|
|
8928
|
+
const client2 = initClient(
|
|
8921
8929
|
zeroComputerUseAuthorizationRequestsContract,
|
|
8922
8930
|
config
|
|
8923
8931
|
);
|
|
8924
|
-
const result = await
|
|
8932
|
+
const result = await client2.create({ body: {} });
|
|
8925
8933
|
if (result.status === 200) {
|
|
8926
8934
|
return result.body;
|
|
8927
8935
|
}
|
|
@@ -8968,6 +8976,151 @@ async function fetchComputerUsePluginContent(commandId) {
|
|
|
8968
8976
|
return { buffer: Buffer.from(arrayBuffer), mimeType, fileName };
|
|
8969
8977
|
}
|
|
8970
8978
|
|
|
8979
|
+
// ../../packages/api-contracts/src/contracts/zero-browser.ts
|
|
8980
|
+
init_esm_shims();
|
|
8981
|
+
var c28 = initContract();
|
|
8982
|
+
var ZERO_BROWSER_DEFAULT_TIMEOUT_MINUTES = 30;
|
|
8983
|
+
var ZERO_BROWSER_MAX_TIMEOUT_MINUTES = 240;
|
|
8984
|
+
var ZERO_BROWSER_DEFAULT_MAX_CREDITS = 500;
|
|
8985
|
+
var ZERO_BROWSER_MAX_CREDITS = 1e5;
|
|
8986
|
+
var zeroBrowserStatusSchema = external_exports.enum([
|
|
8987
|
+
"creating",
|
|
8988
|
+
"active",
|
|
8989
|
+
"resuming",
|
|
8990
|
+
"stopping",
|
|
8991
|
+
"suspended",
|
|
8992
|
+
"error"
|
|
8993
|
+
]);
|
|
8994
|
+
var zeroBrowserSuspensionReasonSchema = external_exports.enum([
|
|
8995
|
+
"run_end",
|
|
8996
|
+
"timeout",
|
|
8997
|
+
"budget",
|
|
8998
|
+
"provider",
|
|
8999
|
+
"reconcile"
|
|
9000
|
+
]);
|
|
9001
|
+
var zeroBrowserSessionSchema = external_exports.object({
|
|
9002
|
+
id: external_exports.uuid(),
|
|
9003
|
+
name: external_exports.string().min(1).max(64),
|
|
9004
|
+
status: zeroBrowserStatusSchema,
|
|
9005
|
+
viewerUrl: external_exports.url(),
|
|
9006
|
+
liveUrl: external_exports.url().nullable(),
|
|
9007
|
+
proxyCountryCode: external_exports.string().length(2).nullable(),
|
|
9008
|
+
timeoutMinutes: external_exports.number().int().positive(),
|
|
9009
|
+
maxCredits: external_exports.number().int().positive(),
|
|
9010
|
+
grossCredits: external_exports.number().int().nonnegative(),
|
|
9011
|
+
creditsCharged: external_exports.number().int().nonnegative(),
|
|
9012
|
+
suspendedAt: external_exports.iso.datetime().nullable(),
|
|
9013
|
+
suspensionReason: zeroBrowserSuspensionReasonSchema.nullable(),
|
|
9014
|
+
createdAt: external_exports.iso.datetime(),
|
|
9015
|
+
updatedAt: external_exports.iso.datetime()
|
|
9016
|
+
});
|
|
9017
|
+
var zeroBrowserCreateRequestSchema = external_exports.object({
|
|
9018
|
+
name: external_exports.string().trim().min(1).max(64).default("browser"),
|
|
9019
|
+
proxyCountryCode: external_exports.string().trim().length(2).transform((value) => {
|
|
9020
|
+
return value.toLowerCase();
|
|
9021
|
+
}).nullable().default(null),
|
|
9022
|
+
timeoutMinutes: external_exports.number().int().min(1).max(ZERO_BROWSER_MAX_TIMEOUT_MINUTES).default(ZERO_BROWSER_DEFAULT_TIMEOUT_MINUTES),
|
|
9023
|
+
maxCredits: external_exports.number().int().min(1).max(ZERO_BROWSER_MAX_CREDITS).default(ZERO_BROWSER_DEFAULT_MAX_CREDITS)
|
|
9024
|
+
});
|
|
9025
|
+
var browserIdParamsSchema = external_exports.object({
|
|
9026
|
+
browserId: external_exports.uuid()
|
|
9027
|
+
});
|
|
9028
|
+
var browserGetQuerySchema = external_exports.object({
|
|
9029
|
+
chatThreadId: external_exports.uuid().optional()
|
|
9030
|
+
});
|
|
9031
|
+
var browserResponseSchema = external_exports.object({
|
|
9032
|
+
browser: zeroBrowserSessionSchema
|
|
9033
|
+
});
|
|
9034
|
+
var browserConnectionResponseSchema = browserResponseSchema.extend({
|
|
9035
|
+
cdpUrl: external_exports.url()
|
|
9036
|
+
});
|
|
9037
|
+
var commonErrorResponses = {
|
|
9038
|
+
400: apiErrorSchema,
|
|
9039
|
+
401: apiErrorSchema,
|
|
9040
|
+
402: apiErrorSchema,
|
|
9041
|
+
403: apiErrorSchema,
|
|
9042
|
+
404: apiErrorSchema,
|
|
9043
|
+
409: apiErrorSchema,
|
|
9044
|
+
502: apiErrorSchema,
|
|
9045
|
+
503: apiErrorSchema
|
|
9046
|
+
};
|
|
9047
|
+
var zeroBrowserContract = c28.router({
|
|
9048
|
+
create: {
|
|
9049
|
+
method: "POST",
|
|
9050
|
+
path: "/api/zero/browsers",
|
|
9051
|
+
headers: authHeadersSchema,
|
|
9052
|
+
body: zeroBrowserCreateRequestSchema,
|
|
9053
|
+
responses: {
|
|
9054
|
+
201: browserConnectionResponseSchema,
|
|
9055
|
+
...commonErrorResponses
|
|
9056
|
+
},
|
|
9057
|
+
summary: "Create a new managed browser for the current chat thread using the user's shared profile"
|
|
9058
|
+
},
|
|
9059
|
+
resume: {
|
|
9060
|
+
method: "POST",
|
|
9061
|
+
path: "/api/zero/browsers/resume",
|
|
9062
|
+
headers: authHeadersSchema,
|
|
9063
|
+
body: external_exports.object({}),
|
|
9064
|
+
responses: {
|
|
9065
|
+
200: browserConnectionResponseSchema,
|
|
9066
|
+
...commonErrorResponses
|
|
9067
|
+
},
|
|
9068
|
+
summary: "Resume the current chat thread's managed browser"
|
|
9069
|
+
},
|
|
9070
|
+
current: {
|
|
9071
|
+
method: "GET",
|
|
9072
|
+
path: "/api/zero/browsers/current",
|
|
9073
|
+
headers: authHeadersSchema,
|
|
9074
|
+
responses: {
|
|
9075
|
+
200: browserResponseSchema,
|
|
9076
|
+
...commonErrorResponses
|
|
9077
|
+
},
|
|
9078
|
+
summary: "Get the current chat thread's managed browser"
|
|
9079
|
+
},
|
|
9080
|
+
get: {
|
|
9081
|
+
method: "GET",
|
|
9082
|
+
path: "/api/zero/browsers/:browserId",
|
|
9083
|
+
headers: authHeadersSchema,
|
|
9084
|
+
pathParams: browserIdParamsSchema,
|
|
9085
|
+
query: browserGetQuerySchema,
|
|
9086
|
+
responses: {
|
|
9087
|
+
200: browserResponseSchema,
|
|
9088
|
+
...commonErrorResponses
|
|
9089
|
+
},
|
|
9090
|
+
summary: "Get a managed browser by universal-link ID"
|
|
9091
|
+
}
|
|
9092
|
+
});
|
|
9093
|
+
|
|
9094
|
+
// src/lib/api/domains/zero-browser.ts
|
|
9095
|
+
init_esm_shims();
|
|
9096
|
+
async function client() {
|
|
9097
|
+
return initClient(zeroBrowserContract, await getClientConfig());
|
|
9098
|
+
}
|
|
9099
|
+
async function createZeroBrowser(body) {
|
|
9100
|
+
const result = await (await client()).create({ headers: {}, body });
|
|
9101
|
+
if (result.status === 201) {
|
|
9102
|
+
return result.body;
|
|
9103
|
+
}
|
|
9104
|
+
handleError(result, "Failed to create a new managed browser");
|
|
9105
|
+
}
|
|
9106
|
+
async function resumeZeroBrowser() {
|
|
9107
|
+
const result = await (await client()).resume({
|
|
9108
|
+
headers: {},
|
|
9109
|
+
body: {}
|
|
9110
|
+
});
|
|
9111
|
+
if (result.status === 200) {
|
|
9112
|
+
return result.body;
|
|
9113
|
+
}
|
|
9114
|
+
handleError(result, "Failed to resume the managed browser");
|
|
9115
|
+
}
|
|
9116
|
+
async function getCurrentZeroBrowser() {
|
|
9117
|
+
const result = await (await client()).current({ headers: {} });
|
|
9118
|
+
if (result.status === 200) {
|
|
9119
|
+
return result.body.browser;
|
|
9120
|
+
}
|
|
9121
|
+
handleError(result, "Failed to get the current managed browser");
|
|
9122
|
+
}
|
|
9123
|
+
|
|
8971
9124
|
// src/lib/api/domains/zero-maps.ts
|
|
8972
9125
|
init_esm_shims();
|
|
8973
9126
|
function authenticatedJsonHeaders(token) {
|
|
@@ -9179,8 +9332,8 @@ var zeroScrapeContract = c29.router({
|
|
|
9179
9332
|
init_esm_shims();
|
|
9180
9333
|
async function callZeroScrape(body) {
|
|
9181
9334
|
const config = await getClientConfig();
|
|
9182
|
-
const
|
|
9183
|
-
const result = await
|
|
9335
|
+
const client2 = initClient(zeroScrapeContract, config);
|
|
9336
|
+
const result = await client2.scrape({ headers: {}, body });
|
|
9184
9337
|
if (result.status === 200) {
|
|
9185
9338
|
return result.body;
|
|
9186
9339
|
}
|
|
@@ -9250,8 +9403,8 @@ var zeroPeopleSearchContract = c30.router({
|
|
|
9250
9403
|
init_esm_shims();
|
|
9251
9404
|
async function callZeroPeopleSearch(body) {
|
|
9252
9405
|
const config = await getClientConfig();
|
|
9253
|
-
const
|
|
9254
|
-
const result = await
|
|
9406
|
+
const client2 = initClient(zeroPeopleSearchContract, config);
|
|
9407
|
+
const result = await client2.search({ headers: {}, body });
|
|
9255
9408
|
if (result.status === 200) {
|
|
9256
9409
|
return result.body;
|
|
9257
9410
|
}
|
|
@@ -9342,8 +9495,8 @@ var zeroWebSearchContract = c31.router({
|
|
|
9342
9495
|
init_esm_shims();
|
|
9343
9496
|
async function callZeroWebSearch(body) {
|
|
9344
9497
|
const config = await getClientConfig();
|
|
9345
|
-
const
|
|
9346
|
-
const result = await
|
|
9498
|
+
const client2 = initClient(zeroWebSearchContract, config);
|
|
9499
|
+
const result = await client2.search({ headers: {}, body });
|
|
9347
9500
|
if (result.status === 200) {
|
|
9348
9501
|
return result.body;
|
|
9349
9502
|
}
|
|
@@ -9458,8 +9611,8 @@ var zeroFinanceContract = c32.router({
|
|
|
9458
9611
|
init_esm_shims();
|
|
9459
9612
|
async function callZeroFinanceSearch(body) {
|
|
9460
9613
|
const config = await getClientConfig();
|
|
9461
|
-
const
|
|
9462
|
-
const result = await
|
|
9614
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9615
|
+
const result = await client2.search({ headers: {}, body });
|
|
9463
9616
|
if (result.status === 200) {
|
|
9464
9617
|
return result.body;
|
|
9465
9618
|
}
|
|
@@ -9467,8 +9620,8 @@ async function callZeroFinanceSearch(body) {
|
|
|
9467
9620
|
}
|
|
9468
9621
|
async function callZeroFinanceProfile(body) {
|
|
9469
9622
|
const config = await getClientConfig();
|
|
9470
|
-
const
|
|
9471
|
-
const result = await
|
|
9623
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9624
|
+
const result = await client2.profile({ headers: {}, body });
|
|
9472
9625
|
if (result.status === 200) {
|
|
9473
9626
|
return result.body;
|
|
9474
9627
|
}
|
|
@@ -9476,8 +9629,8 @@ async function callZeroFinanceProfile(body) {
|
|
|
9476
9629
|
}
|
|
9477
9630
|
async function callZeroFinanceQuote(body) {
|
|
9478
9631
|
const config = await getClientConfig();
|
|
9479
|
-
const
|
|
9480
|
-
const result = await
|
|
9632
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9633
|
+
const result = await client2.quote({ headers: {}, body });
|
|
9481
9634
|
if (result.status === 200) {
|
|
9482
9635
|
return result.body;
|
|
9483
9636
|
}
|
|
@@ -9485,8 +9638,8 @@ async function callZeroFinanceQuote(body) {
|
|
|
9485
9638
|
}
|
|
9486
9639
|
async function callZeroFinanceChart(body) {
|
|
9487
9640
|
const config = await getClientConfig();
|
|
9488
|
-
const
|
|
9489
|
-
const result = await
|
|
9641
|
+
const client2 = initClient(zeroFinanceContract, config);
|
|
9642
|
+
const result = await client2.chart({ headers: {}, body });
|
|
9490
9643
|
if (result.status === 200) {
|
|
9491
9644
|
return result.body;
|
|
9492
9645
|
}
|
|
@@ -9706,8 +9859,8 @@ var zeroVariablesByNameContract = c33.router({
|
|
|
9706
9859
|
// src/lib/api/domains/zero-secrets.ts
|
|
9707
9860
|
async function listZeroSecrets() {
|
|
9708
9861
|
const config = await getClientConfig();
|
|
9709
|
-
const
|
|
9710
|
-
const result = await
|
|
9862
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9863
|
+
const result = await client2.list({ headers: {} });
|
|
9711
9864
|
if (result.status === 200) {
|
|
9712
9865
|
return result.body;
|
|
9713
9866
|
}
|
|
@@ -9715,8 +9868,8 @@ async function listZeroSecrets() {
|
|
|
9715
9868
|
}
|
|
9716
9869
|
async function setZeroSecret(body) {
|
|
9717
9870
|
const config = await getClientConfig();
|
|
9718
|
-
const
|
|
9719
|
-
const result = await
|
|
9871
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9872
|
+
const result = await client2.set({ body });
|
|
9720
9873
|
if (result.status === 200 || result.status === 201) {
|
|
9721
9874
|
return result.body;
|
|
9722
9875
|
}
|
|
@@ -9724,8 +9877,8 @@ async function setZeroSecret(body) {
|
|
|
9724
9877
|
}
|
|
9725
9878
|
async function deleteZeroSecret(name) {
|
|
9726
9879
|
const config = await getClientConfig();
|
|
9727
|
-
const
|
|
9728
|
-
const result = await
|
|
9880
|
+
const client2 = initClient(zeroSecretsByNameContract, config);
|
|
9881
|
+
const result = await client2.delete({
|
|
9729
9882
|
params: { name }
|
|
9730
9883
|
});
|
|
9731
9884
|
if (result.status === 204) {
|
|
@@ -9738,8 +9891,8 @@ async function deleteZeroSecret(name) {
|
|
|
9738
9891
|
init_esm_shims();
|
|
9739
9892
|
async function listZeroVariables() {
|
|
9740
9893
|
const config = await getClientConfig();
|
|
9741
|
-
const
|
|
9742
|
-
const result = await
|
|
9894
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9895
|
+
const result = await client2.list({ headers: {} });
|
|
9743
9896
|
if (result.status === 200) {
|
|
9744
9897
|
return result.body;
|
|
9745
9898
|
}
|
|
@@ -9747,8 +9900,8 @@ async function listZeroVariables() {
|
|
|
9747
9900
|
}
|
|
9748
9901
|
async function setZeroVariable(body) {
|
|
9749
9902
|
const config = await getClientConfig();
|
|
9750
|
-
const
|
|
9751
|
-
const result = await
|
|
9903
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9904
|
+
const result = await client2.set({ body });
|
|
9752
9905
|
if (result.status === 200 || result.status === 201) {
|
|
9753
9906
|
return result.body;
|
|
9754
9907
|
}
|
|
@@ -9756,8 +9909,8 @@ async function setZeroVariable(body) {
|
|
|
9756
9909
|
}
|
|
9757
9910
|
async function deleteZeroVariable(name) {
|
|
9758
9911
|
const config = await getClientConfig();
|
|
9759
|
-
const
|
|
9760
|
-
const result = await
|
|
9912
|
+
const client2 = initClient(zeroVariablesByNameContract, config);
|
|
9913
|
+
const result = await client2.delete({
|
|
9761
9914
|
params: { name }
|
|
9762
9915
|
});
|
|
9763
9916
|
if (result.status === 204) {
|
|
@@ -9770,8 +9923,8 @@ async function deleteZeroVariable(name) {
|
|
|
9770
9923
|
init_esm_shims();
|
|
9771
9924
|
async function listZeroOrgSecrets() {
|
|
9772
9925
|
const config = await getClientConfig();
|
|
9773
|
-
const
|
|
9774
|
-
const result = await
|
|
9926
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9927
|
+
const result = await client2.list({ headers: {} });
|
|
9775
9928
|
if (result.status === 200) {
|
|
9776
9929
|
return result.body;
|
|
9777
9930
|
}
|
|
@@ -9779,8 +9932,8 @@ async function listZeroOrgSecrets() {
|
|
|
9779
9932
|
}
|
|
9780
9933
|
async function setZeroOrgSecret(body) {
|
|
9781
9934
|
const config = await getClientConfig();
|
|
9782
|
-
const
|
|
9783
|
-
const result = await
|
|
9935
|
+
const client2 = initClient(zeroSecretsContract, config);
|
|
9936
|
+
const result = await client2.set({ body });
|
|
9784
9937
|
if (result.status === 200 || result.status === 201) {
|
|
9785
9938
|
return result.body;
|
|
9786
9939
|
}
|
|
@@ -9788,8 +9941,8 @@ async function setZeroOrgSecret(body) {
|
|
|
9788
9941
|
}
|
|
9789
9942
|
async function deleteZeroOrgSecret(name) {
|
|
9790
9943
|
const config = await getClientConfig();
|
|
9791
|
-
const
|
|
9792
|
-
const result = await
|
|
9944
|
+
const client2 = initClient(zeroSecretsByNameContract, config);
|
|
9945
|
+
const result = await client2.delete({
|
|
9793
9946
|
params: { name }
|
|
9794
9947
|
});
|
|
9795
9948
|
if (result.status === 204) {
|
|
@@ -9802,8 +9955,8 @@ async function deleteZeroOrgSecret(name) {
|
|
|
9802
9955
|
init_esm_shims();
|
|
9803
9956
|
async function listZeroOrgVariables() {
|
|
9804
9957
|
const config = await getClientConfig();
|
|
9805
|
-
const
|
|
9806
|
-
const result = await
|
|
9958
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9959
|
+
const result = await client2.list({ headers: {} });
|
|
9807
9960
|
if (result.status === 200) {
|
|
9808
9961
|
return result.body;
|
|
9809
9962
|
}
|
|
@@ -9811,8 +9964,8 @@ async function listZeroOrgVariables() {
|
|
|
9811
9964
|
}
|
|
9812
9965
|
async function setZeroOrgVariable(body) {
|
|
9813
9966
|
const config = await getClientConfig();
|
|
9814
|
-
const
|
|
9815
|
-
const result = await
|
|
9967
|
+
const client2 = initClient(zeroVariablesContract, config);
|
|
9968
|
+
const result = await client2.set({ body });
|
|
9816
9969
|
if (result.status === 200 || result.status === 201) {
|
|
9817
9970
|
return result.body;
|
|
9818
9971
|
}
|
|
@@ -9820,8 +9973,8 @@ async function setZeroOrgVariable(body) {
|
|
|
9820
9973
|
}
|
|
9821
9974
|
async function deleteZeroOrgVariable(name) {
|
|
9822
9975
|
const config = await getClientConfig();
|
|
9823
|
-
const
|
|
9824
|
-
const result = await
|
|
9976
|
+
const client2 = initClient(zeroVariablesByNameContract, config);
|
|
9977
|
+
const result = await client2.delete({
|
|
9825
9978
|
params: { name }
|
|
9826
9979
|
});
|
|
9827
9980
|
if (result.status === 204) {
|
|
@@ -9888,8 +10041,8 @@ var zeroModelProvidersByTypeContract = c34.router({
|
|
|
9888
10041
|
// src/lib/api/domains/zero-org-model-providers.ts
|
|
9889
10042
|
async function listZeroOrgModelProviders() {
|
|
9890
10043
|
const config = await getClientConfig();
|
|
9891
|
-
const
|
|
9892
|
-
const result = await
|
|
10044
|
+
const client2 = initClient(zeroModelProvidersMainContract, config);
|
|
10045
|
+
const result = await client2.list({ headers: {} });
|
|
9893
10046
|
if (result.status === 200) {
|
|
9894
10047
|
return result.body;
|
|
9895
10048
|
}
|
|
@@ -9897,8 +10050,8 @@ async function listZeroOrgModelProviders() {
|
|
|
9897
10050
|
}
|
|
9898
10051
|
async function upsertZeroOrgModelProvider(body) {
|
|
9899
10052
|
const config = await getClientConfig();
|
|
9900
|
-
const
|
|
9901
|
-
const result = await
|
|
10053
|
+
const client2 = initClient(zeroModelProvidersMainContract, config);
|
|
10054
|
+
const result = await client2.upsert({ body });
|
|
9902
10055
|
if (result.status === 200 || result.status === 201) {
|
|
9903
10056
|
return result.body;
|
|
9904
10057
|
}
|
|
@@ -9906,8 +10059,8 @@ async function upsertZeroOrgModelProvider(body) {
|
|
|
9906
10059
|
}
|
|
9907
10060
|
async function deleteZeroOrgModelProvider(type) {
|
|
9908
10061
|
const config = await getClientConfig();
|
|
9909
|
-
const
|
|
9910
|
-
const result = await
|
|
10062
|
+
const client2 = initClient(zeroModelProvidersByTypeContract, config);
|
|
10063
|
+
const result = await client2.delete({
|
|
9911
10064
|
params: { type }
|
|
9912
10065
|
});
|
|
9913
10066
|
if (result.status === 204) {
|
|
@@ -11127,43 +11280,43 @@ var zeroWorkflowAutomationsContract = c35.router({
|
|
|
11127
11280
|
// src/lib/api/domains/zero-workflows.ts
|
|
11128
11281
|
async function listWorkflows(query) {
|
|
11129
11282
|
const config = await getClientConfig();
|
|
11130
|
-
const
|
|
11131
|
-
const result = await
|
|
11283
|
+
const client2 = initClient(zeroWorkflowsCollectionContract, config);
|
|
11284
|
+
const result = await client2.list({ query });
|
|
11132
11285
|
if (result.status === 200) return result.body;
|
|
11133
11286
|
handleError(result, "Failed to list workflows");
|
|
11134
11287
|
}
|
|
11135
11288
|
async function createWorkflow(body) {
|
|
11136
11289
|
const config = await getClientConfig();
|
|
11137
|
-
const
|
|
11138
|
-
const result = await
|
|
11290
|
+
const client2 = initClient(zeroWorkflowsCollectionContract, config);
|
|
11291
|
+
const result = await client2.create({ body });
|
|
11139
11292
|
if (result.status === 201) return result.body;
|
|
11140
11293
|
handleError(result, `Failed to create workflow "${body.name}"`);
|
|
11141
11294
|
}
|
|
11142
11295
|
async function getWorkflow(workflowId) {
|
|
11143
11296
|
const config = await getClientConfig();
|
|
11144
|
-
const
|
|
11145
|
-
const result = await
|
|
11297
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11298
|
+
const result = await client2.get({ params: { workflowId } });
|
|
11146
11299
|
if (result.status === 200) return result.body;
|
|
11147
11300
|
handleError(result, `Workflow "${workflowId}" not found`);
|
|
11148
11301
|
}
|
|
11149
11302
|
async function updateWorkflow(workflowId, body) {
|
|
11150
11303
|
const config = await getClientConfig();
|
|
11151
|
-
const
|
|
11152
|
-
const result = await
|
|
11304
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11305
|
+
const result = await client2.update({ params: { workflowId }, body });
|
|
11153
11306
|
if (result.status === 200) return result.body;
|
|
11154
11307
|
handleError(result, `Failed to update workflow "${workflowId}"`);
|
|
11155
11308
|
}
|
|
11156
11309
|
async function deleteWorkflow(workflowId) {
|
|
11157
11310
|
const config = await getClientConfig();
|
|
11158
|
-
const
|
|
11159
|
-
const result = await
|
|
11311
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11312
|
+
const result = await client2.delete({ params: { workflowId } });
|
|
11160
11313
|
if (result.status === 204) return;
|
|
11161
11314
|
handleError(result, `Workflow "${workflowId}" not found`);
|
|
11162
11315
|
}
|
|
11163
11316
|
async function copyWorkflow(workflowId, toAgentId) {
|
|
11164
11317
|
const config = await getClientConfig();
|
|
11165
|
-
const
|
|
11166
|
-
const result = await
|
|
11318
|
+
const client2 = initClient(zeroWorkflowsDetailContract, config);
|
|
11319
|
+
const result = await client2.copy({
|
|
11167
11320
|
params: { workflowId },
|
|
11168
11321
|
body: { toAgentId }
|
|
11169
11322
|
});
|
|
@@ -11172,8 +11325,8 @@ async function copyWorkflow(workflowId, toAgentId) {
|
|
|
11172
11325
|
}
|
|
11173
11326
|
async function listWorkflowAutomations(workflowId) {
|
|
11174
11327
|
const config = await getClientConfig();
|
|
11175
|
-
const
|
|
11176
|
-
const result = await
|
|
11328
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11329
|
+
const result = await client2.list({ params: { workflowId } });
|
|
11177
11330
|
if (result.status === 200) return result.body;
|
|
11178
11331
|
handleError(
|
|
11179
11332
|
result,
|
|
@@ -11182,43 +11335,43 @@ async function listWorkflowAutomations(workflowId) {
|
|
|
11182
11335
|
}
|
|
11183
11336
|
async function createWorkflowAutomation(workflowId, body) {
|
|
11184
11337
|
const config = await getClientConfig();
|
|
11185
|
-
const
|
|
11186
|
-
const result = await
|
|
11338
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11339
|
+
const result = await client2.create({ params: { workflowId }, body });
|
|
11187
11340
|
if (result.status === 201) return result.body;
|
|
11188
11341
|
handleError(result, `Failed to add automation to workflow "${workflowId}"`);
|
|
11189
11342
|
}
|
|
11190
11343
|
async function getWorkflowAutomation(id) {
|
|
11191
11344
|
const config = await getClientConfig();
|
|
11192
|
-
const
|
|
11193
|
-
const result = await
|
|
11345
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11346
|
+
const result = await client2.get({ params: { id } });
|
|
11194
11347
|
if (result.status === 200) return result.body;
|
|
11195
11348
|
handleError(result, `Workflow automation "${id}" not found`);
|
|
11196
11349
|
}
|
|
11197
11350
|
async function updateWorkflowAutomation(id, body) {
|
|
11198
11351
|
const config = await getClientConfig();
|
|
11199
|
-
const
|
|
11200
|
-
const result = await
|
|
11352
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11353
|
+
const result = await client2.update({ params: { id }, body });
|
|
11201
11354
|
if (result.status === 200) return result.body;
|
|
11202
11355
|
handleError(result, `Failed to update workflow automation "${id}"`);
|
|
11203
11356
|
}
|
|
11204
11357
|
async function deleteWorkflowAutomation(id) {
|
|
11205
11358
|
const config = await getClientConfig();
|
|
11206
|
-
const
|
|
11207
|
-
const result = await
|
|
11359
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11360
|
+
const result = await client2.delete({ params: { id } });
|
|
11208
11361
|
if (result.status === 204) return;
|
|
11209
11362
|
handleError(result, `Workflow automation "${id}" not found`);
|
|
11210
11363
|
}
|
|
11211
11364
|
async function enableWorkflowAutomation(id) {
|
|
11212
11365
|
const config = await getClientConfig();
|
|
11213
|
-
const
|
|
11214
|
-
const result = await
|
|
11366
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11367
|
+
const result = await client2.enable({ params: { id } });
|
|
11215
11368
|
if (result.status === 200) return result.body;
|
|
11216
11369
|
handleError(result, `Failed to enable workflow automation "${id}"`);
|
|
11217
11370
|
}
|
|
11218
11371
|
async function disableWorkflowAutomation(id) {
|
|
11219
11372
|
const config = await getClientConfig();
|
|
11220
|
-
const
|
|
11221
|
-
const result = await
|
|
11373
|
+
const client2 = initClient(zeroWorkflowAutomationsContract, config);
|
|
11374
|
+
const result = await client2.disable({ params: { id } });
|
|
11222
11375
|
if (result.status === 200) return result.body;
|
|
11223
11376
|
handleError(result, `Failed to disable workflow automation "${id}"`);
|
|
11224
11377
|
}
|
|
@@ -11372,8 +11525,8 @@ var zeroMailContract = c36.router({
|
|
|
11372
11525
|
// src/lib/api/domains/zero-mail.ts
|
|
11373
11526
|
async function linkZeroMailDraft(args) {
|
|
11374
11527
|
const config = await getClientConfig();
|
|
11375
|
-
const
|
|
11376
|
-
const result = await
|
|
11528
|
+
const client2 = initClient(zeroMailContract, config);
|
|
11529
|
+
const result = await client2.linkDraft({
|
|
11377
11530
|
body: {
|
|
11378
11531
|
threadId: args.threadId,
|
|
11379
11532
|
agentId: args.agentId,
|
|
@@ -12140,8 +12293,8 @@ var integrationsSlackUploadCompleteContract = c37.router({
|
|
|
12140
12293
|
// src/lib/api/domains/integrations-slack.ts
|
|
12141
12294
|
async function sendSlackMessage(body) {
|
|
12142
12295
|
const config = await getClientConfig();
|
|
12143
|
-
const
|
|
12144
|
-
const result = await
|
|
12296
|
+
const client2 = initClient(integrationsSlackMessageContract, config);
|
|
12297
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12145
12298
|
if (result.status === 200) {
|
|
12146
12299
|
return result.body;
|
|
12147
12300
|
}
|
|
@@ -12149,8 +12302,8 @@ async function sendSlackMessage(body) {
|
|
|
12149
12302
|
}
|
|
12150
12303
|
async function initSlackFileUpload(body) {
|
|
12151
12304
|
const config = await getClientConfig();
|
|
12152
|
-
const
|
|
12153
|
-
const result = await
|
|
12305
|
+
const client2 = initClient(integrationsSlackUploadInitContract, config);
|
|
12306
|
+
const result = await client2.init({ body, headers: {} });
|
|
12154
12307
|
if (result.status === 200) {
|
|
12155
12308
|
return result.body;
|
|
12156
12309
|
}
|
|
@@ -12158,8 +12311,8 @@ async function initSlackFileUpload(body) {
|
|
|
12158
12311
|
}
|
|
12159
12312
|
async function completeSlackFileUpload(body) {
|
|
12160
12313
|
const config = await getClientConfig();
|
|
12161
|
-
const
|
|
12162
|
-
const result = await
|
|
12314
|
+
const client2 = initClient(integrationsSlackUploadCompleteContract, config);
|
|
12315
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12163
12316
|
if (result.status === 200) {
|
|
12164
12317
|
return result.body;
|
|
12165
12318
|
}
|
|
@@ -12167,8 +12320,8 @@ async function completeSlackFileUpload(body) {
|
|
|
12167
12320
|
}
|
|
12168
12321
|
async function materializeSlackFileUpload(body) {
|
|
12169
12322
|
const config = await getClientConfig();
|
|
12170
|
-
const
|
|
12171
|
-
const result = await
|
|
12323
|
+
const client2 = initClient(integrationsSlackUploadMaterializeContract, config);
|
|
12324
|
+
const result = await client2.materialize({ body, headers: {} });
|
|
12172
12325
|
if (result.status === 200) {
|
|
12173
12326
|
return result.body;
|
|
12174
12327
|
}
|
|
@@ -12227,8 +12380,8 @@ import { Readable as Readable2 } from "stream";
|
|
|
12227
12380
|
import { pipeline as pipeline2 } from "stream/promises";
|
|
12228
12381
|
async function listTelegramBots() {
|
|
12229
12382
|
const config = await getClientConfig();
|
|
12230
|
-
const
|
|
12231
|
-
const result = await
|
|
12383
|
+
const client2 = initClient(integrationsTelegramBotListContract, config);
|
|
12384
|
+
const result = await client2.listBots({ headers: {} });
|
|
12232
12385
|
if (result.status === 200) {
|
|
12233
12386
|
return result.body;
|
|
12234
12387
|
}
|
|
@@ -12236,8 +12389,8 @@ async function listTelegramBots() {
|
|
|
12236
12389
|
}
|
|
12237
12390
|
async function sendTelegramMessage(body) {
|
|
12238
12391
|
const config = await getClientConfig();
|
|
12239
|
-
const
|
|
12240
|
-
const result = await
|
|
12392
|
+
const client2 = initClient(integrationsTelegramMessageContract, config);
|
|
12393
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12241
12394
|
if (result.status === 200) {
|
|
12242
12395
|
return result.body;
|
|
12243
12396
|
}
|
|
@@ -12245,8 +12398,8 @@ async function sendTelegramMessage(body) {
|
|
|
12245
12398
|
}
|
|
12246
12399
|
async function initTelegramFileUpload(body) {
|
|
12247
12400
|
const config = await getClientConfig();
|
|
12248
|
-
const
|
|
12249
|
-
const result = await
|
|
12401
|
+
const client2 = initClient(integrationsTelegramUploadInitContract, config);
|
|
12402
|
+
const result = await client2.init({ body, headers: {} });
|
|
12250
12403
|
if (result.status === 200) {
|
|
12251
12404
|
return result.body;
|
|
12252
12405
|
}
|
|
@@ -12254,8 +12407,8 @@ async function initTelegramFileUpload(body) {
|
|
|
12254
12407
|
}
|
|
12255
12408
|
async function completeTelegramFileUpload(body) {
|
|
12256
12409
|
const config = await getClientConfig();
|
|
12257
|
-
const
|
|
12258
|
-
const result = await
|
|
12410
|
+
const client2 = initClient(integrationsTelegramUploadCompleteContract, config);
|
|
12411
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12259
12412
|
if (result.status === 200) {
|
|
12260
12413
|
return result.body;
|
|
12261
12414
|
}
|
|
@@ -12315,8 +12468,8 @@ import { Readable as Readable3 } from "stream";
|
|
|
12315
12468
|
import { pipeline as pipeline3 } from "stream/promises";
|
|
12316
12469
|
async function sendTeamsMessage(body) {
|
|
12317
12470
|
const config = await getClientConfig();
|
|
12318
|
-
const
|
|
12319
|
-
const result = await
|
|
12471
|
+
const client2 = initClient(integrationsTeamsMessageContract, config);
|
|
12472
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12320
12473
|
if (result.status === 200) {
|
|
12321
12474
|
return result.body;
|
|
12322
12475
|
}
|
|
@@ -12324,8 +12477,8 @@ async function sendTeamsMessage(body) {
|
|
|
12324
12477
|
}
|
|
12325
12478
|
async function initTeamsFileUpload(body) {
|
|
12326
12479
|
const config = await getClientConfig();
|
|
12327
|
-
const
|
|
12328
|
-
const result = await
|
|
12480
|
+
const client2 = initClient(integrationsTeamsUploadInitContract, config);
|
|
12481
|
+
const result = await client2.init({ body, headers: {} });
|
|
12329
12482
|
if (result.status === 200) {
|
|
12330
12483
|
return result.body;
|
|
12331
12484
|
}
|
|
@@ -12333,8 +12486,8 @@ async function initTeamsFileUpload(body) {
|
|
|
12333
12486
|
}
|
|
12334
12487
|
async function completeTeamsFileUpload(body) {
|
|
12335
12488
|
const config = await getClientConfig();
|
|
12336
|
-
const
|
|
12337
|
-
const result = await
|
|
12489
|
+
const client2 = initClient(integrationsTeamsUploadCompleteContract, config);
|
|
12490
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12338
12491
|
if (result.status === 200) {
|
|
12339
12492
|
return result.body;
|
|
12340
12493
|
}
|
|
@@ -12393,8 +12546,8 @@ import { Readable as Readable4 } from "stream";
|
|
|
12393
12546
|
import { pipeline as pipeline4 } from "stream/promises";
|
|
12394
12547
|
async function sendFeishuMessage(body) {
|
|
12395
12548
|
const config = await getClientConfig();
|
|
12396
|
-
const
|
|
12397
|
-
const result = await
|
|
12549
|
+
const client2 = initClient(integrationsFeishuMessageContract, config);
|
|
12550
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12398
12551
|
if (result.status === 200) {
|
|
12399
12552
|
return result.body;
|
|
12400
12553
|
}
|
|
@@ -12402,8 +12555,8 @@ async function sendFeishuMessage(body) {
|
|
|
12402
12555
|
}
|
|
12403
12556
|
async function initFeishuFileUpload(body) {
|
|
12404
12557
|
const config = await getClientConfig();
|
|
12405
|
-
const
|
|
12406
|
-
const result = await
|
|
12558
|
+
const client2 = initClient(integrationsFeishuUploadInitContract, config);
|
|
12559
|
+
const result = await client2.init({ body, headers: {} });
|
|
12407
12560
|
if (result.status === 200) {
|
|
12408
12561
|
return result.body;
|
|
12409
12562
|
}
|
|
@@ -12411,8 +12564,8 @@ async function initFeishuFileUpload(body) {
|
|
|
12411
12564
|
}
|
|
12412
12565
|
async function completeFeishuFileUpload(body) {
|
|
12413
12566
|
const config = await getClientConfig();
|
|
12414
|
-
const
|
|
12415
|
-
const result = await
|
|
12567
|
+
const client2 = initClient(integrationsFeishuUploadCompleteContract, config);
|
|
12568
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12416
12569
|
if (result.status === 200) {
|
|
12417
12570
|
return result.body;
|
|
12418
12571
|
}
|
|
@@ -12480,8 +12633,8 @@ import { Readable as Readable5 } from "stream";
|
|
|
12480
12633
|
import { pipeline as pipeline5 } from "stream/promises";
|
|
12481
12634
|
async function initGithubFileUpload(body) {
|
|
12482
12635
|
const config = await getClientConfig();
|
|
12483
|
-
const
|
|
12484
|
-
const result = await
|
|
12636
|
+
const client2 = initClient(integrationsGithubUploadInitContract, config);
|
|
12637
|
+
const result = await client2.init({ body, headers: {} });
|
|
12485
12638
|
if (result.status === 200) {
|
|
12486
12639
|
return result.body;
|
|
12487
12640
|
}
|
|
@@ -12489,8 +12642,8 @@ async function initGithubFileUpload(body) {
|
|
|
12489
12642
|
}
|
|
12490
12643
|
async function completeGithubFileUpload(body) {
|
|
12491
12644
|
const config = await getClientConfig();
|
|
12492
|
-
const
|
|
12493
|
-
const result = await
|
|
12645
|
+
const client2 = initClient(integrationsGithubUploadCompleteContract, config);
|
|
12646
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12494
12647
|
if (result.status === 200) {
|
|
12495
12648
|
return result.body;
|
|
12496
12649
|
}
|
|
@@ -12552,8 +12705,8 @@ import { Readable as Readable6 } from "stream";
|
|
|
12552
12705
|
import { pipeline as pipeline6 } from "stream/promises";
|
|
12553
12706
|
async function sendPhoneMessage(body) {
|
|
12554
12707
|
const config = await getClientConfig();
|
|
12555
|
-
const
|
|
12556
|
-
const result = await
|
|
12708
|
+
const client2 = initClient(integrationsPhoneMessageContract, config);
|
|
12709
|
+
const result = await client2.sendMessage({ body, headers: {} });
|
|
12557
12710
|
if (result.status === 200) {
|
|
12558
12711
|
return result.body;
|
|
12559
12712
|
}
|
|
@@ -12561,8 +12714,8 @@ async function sendPhoneMessage(body) {
|
|
|
12561
12714
|
}
|
|
12562
12715
|
async function initPhoneFileUpload(body) {
|
|
12563
12716
|
const config = await getClientConfig();
|
|
12564
|
-
const
|
|
12565
|
-
const result = await
|
|
12717
|
+
const client2 = initClient(integrationsPhoneUploadInitContract, config);
|
|
12718
|
+
const result = await client2.init({ body, headers: {} });
|
|
12566
12719
|
if (result.status === 200) {
|
|
12567
12720
|
return result.body;
|
|
12568
12721
|
}
|
|
@@ -12570,8 +12723,8 @@ async function initPhoneFileUpload(body) {
|
|
|
12570
12723
|
}
|
|
12571
12724
|
async function completePhoneFileUpload(body) {
|
|
12572
12725
|
const config = await getClientConfig();
|
|
12573
|
-
const
|
|
12574
|
-
const result = await
|
|
12726
|
+
const client2 = initClient(integrationsPhoneUploadCompleteContract, config);
|
|
12727
|
+
const result = await client2.complete({ body, headers: {} });
|
|
12575
12728
|
if (result.status === 200) {
|
|
12576
12729
|
return result.body;
|
|
12577
12730
|
}
|
|
@@ -12627,8 +12780,8 @@ async function downloadPhoneFile(fileId, outPath) {
|
|
|
12627
12780
|
init_esm_shims();
|
|
12628
12781
|
async function listZeroLogs(options) {
|
|
12629
12782
|
const config = await getClientConfig();
|
|
12630
|
-
const
|
|
12631
|
-
const result = await
|
|
12783
|
+
const client2 = initClient(logsListContract, config);
|
|
12784
|
+
const result = await client2.list({
|
|
12632
12785
|
query: {
|
|
12633
12786
|
agentId: options?.agentId,
|
|
12634
12787
|
status: options?.status,
|
|
@@ -12642,8 +12795,8 @@ async function listZeroLogs(options) {
|
|
|
12642
12795
|
}
|
|
12643
12796
|
async function searchZeroLogs(options) {
|
|
12644
12797
|
const config = await getClientConfig();
|
|
12645
|
-
const
|
|
12646
|
-
const result = await
|
|
12798
|
+
const client2 = initClient(zeroLogsSearchContract, config);
|
|
12799
|
+
const result = await client2.searchLogs({
|
|
12647
12800
|
query: {
|
|
12648
12801
|
keyword: options.keyword,
|
|
12649
12802
|
agentId: options.agentId,
|
|
@@ -12815,7 +12968,6 @@ export {
|
|
|
12815
12968
|
chatThreadEventSchema,
|
|
12816
12969
|
zeroAgentVisibilitySchema,
|
|
12817
12970
|
connectorRefSchema,
|
|
12818
|
-
connectorAuthMethodIdSchema,
|
|
12819
12971
|
createZeroAgent,
|
|
12820
12972
|
listZeroAgents,
|
|
12821
12973
|
getZeroAgent,
|
|
@@ -12826,6 +12978,7 @@ export {
|
|
|
12826
12978
|
getZeroAgentCustomConnectors,
|
|
12827
12979
|
listZeroUserPermissionGrants,
|
|
12828
12980
|
updateZeroAgentInstructions,
|
|
12981
|
+
connectorCatalogDiagnosticsSchema,
|
|
12829
12982
|
listWorkflows,
|
|
12830
12983
|
createWorkflow,
|
|
12831
12984
|
getWorkflow,
|
|
@@ -12907,6 +13060,14 @@ export {
|
|
|
12907
13060
|
createComputerUseAuthorizationRequest,
|
|
12908
13061
|
fetchComputerUseScreenshot,
|
|
12909
13062
|
fetchComputerUsePluginContent,
|
|
13063
|
+
ZERO_BROWSER_DEFAULT_TIMEOUT_MINUTES,
|
|
13064
|
+
ZERO_BROWSER_MAX_TIMEOUT_MINUTES,
|
|
13065
|
+
ZERO_BROWSER_DEFAULT_MAX_CREDITS,
|
|
13066
|
+
ZERO_BROWSER_MAX_CREDITS,
|
|
13067
|
+
zeroBrowserCreateRequestSchema,
|
|
13068
|
+
createZeroBrowser,
|
|
13069
|
+
resumeZeroBrowser,
|
|
13070
|
+
getCurrentZeroBrowser,
|
|
12910
13071
|
callZeroMaps,
|
|
12911
13072
|
callZeroWeather,
|
|
12912
13073
|
zeroScrapeFormatSchema,
|
|
@@ -12941,4 +13102,4 @@ export {
|
|
|
12941
13102
|
getHostedSiteFiles,
|
|
12942
13103
|
getHostedSiteDeployments
|
|
12943
13104
|
};
|
|
12944
|
-
//# sourceMappingURL=chunk-
|
|
13105
|
+
//# sourceMappingURL=chunk-MDKQRZ7S.js.map
|