@orq-ai/node 4.9.18 → 4.9.22
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/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/models/components/reasoningpart.js +1 -1
- package/models/operations/createcontact.js +1 -1
- package/models/operations/createdataset.js +1 -1
- package/models/operations/createdatasetitem.js +4 -4
- package/models/operations/createdatasource.js +1 -1
- package/models/operations/createeval.js +16 -16
- package/models/operations/createidentity.js +1 -1
- package/models/operations/createtool.js +6 -6
- package/models/operations/getalltools.js +6 -6
- package/models/operations/getevals.js +16 -16
- package/models/operations/getv2humanevalsets.js +2 -2
- package/models/operations/getv2humanevalsetsid.js +2 -2
- package/models/operations/listdatasetdatapoints.js +4 -4
- package/models/operations/listdatasets.js +1 -1
- package/models/operations/listdatasources.js +1 -1
- package/models/operations/listidentities.js +1 -1
- package/models/operations/patchv2humanevalsetsid.js +2 -2
- package/models/operations/postv2feedbackevaluation.js +3 -3
- package/models/operations/postv2humanevalsets.js +2 -2
- package/models/operations/retrievedatapoint.js +4 -4
- package/models/operations/retrievedataset.js +1 -1
- package/models/operations/retrievedatasource.js +1 -1
- package/models/operations/retrieveidentity.js +1 -1
- package/models/operations/retrievetool.js +6 -6
- package/models/operations/runagent.js +1 -1
- package/models/operations/streamrunagent.js +1 -1
- package/models/operations/updatedatapoint.js +4 -4
- package/models/operations/updatedataset.js +1 -1
- package/models/operations/updatedatasource.js +1 -1
- package/models/operations/updateeval.js +16 -16
- package/models/operations/updateidentity.js +1 -1
- package/models/operations/updatetool.js +7 -7
- package/package.json +8 -8
- package/packages/orq-rc/src/funcs/apiKeysCreate.ts +162 -0
- package/packages/orq-rc/src/funcs/apiKeysDelete.ts +168 -0
- package/packages/orq-rc/src/funcs/apiKeysGet.ts +168 -0
- package/packages/orq-rc/src/funcs/apiKeysList.ts +175 -0
- package/packages/orq-rc/src/funcs/apiKeysListCapabilities.ts +144 -0
- package/packages/orq-rc/src/funcs/apiKeysUpdate.ts +171 -0
- package/packages/orq-rc/src/funcs/filesList.ts +1 -0
- package/packages/orq-rc/src/lib/config.ts +3 -3
- package/packages/orq-rc/src/models/components/allprojects.ts +39 -0
- package/packages/orq-rc/src/models/components/apikey.ts +178 -0
- package/packages/orq-rc/src/models/components/apikeyowner.ts +82 -0
- package/packages/orq-rc/src/models/components/apikeystatus.ts +21 -0
- package/packages/orq-rc/src/models/components/createapikeyrequest.ts +91 -0
- package/packages/orq-rc/src/models/components/createapikeyresponse.ts +49 -0
- package/packages/orq-rc/src/models/components/createfilerequest.ts +11 -3
- package/packages/orq-rc/src/models/components/deleteapikeyresponse.ts +27 -0
- package/packages/orq-rc/src/models/components/domain.ts +82 -0
- package/packages/orq-rc/src/models/components/domaingroup.ts +18 -0
- package/packages/orq-rc/src/models/components/file.ts +9 -2
- package/packages/orq-rc/src/models/components/filepurpose.ts +21 -0
- package/packages/orq-rc/src/models/components/getapikeyresponse.ts +40 -0
- package/packages/orq-rc/src/models/components/index.ts +23 -0
- package/packages/orq-rc/src/models/components/inputtokensdetails.ts +6 -0
- package/packages/orq-rc/src/models/components/legacytokenfamily.ts +19 -0
- package/packages/orq-rc/src/models/components/listapikeysresponse.ts +56 -0
- package/packages/orq-rc/src/models/components/listcapabilitiesresponse.ts +39 -0
- package/packages/orq-rc/src/models/components/ownertype.ts +17 -0
- package/packages/orq-rc/src/models/components/permissionmode.ts +23 -0
- package/packages/orq-rc/src/models/components/projectscope.ts +70 -0
- package/packages/orq-rc/src/models/components/reasoningpart.ts +1 -1
- package/packages/orq-rc/src/models/components/scopemode.ts +17 -0
- package/packages/orq-rc/src/models/components/serviceaccountowner.ts +43 -0
- package/packages/orq-rc/src/models/components/singleproject.ts +56 -0
- package/packages/orq-rc/src/models/components/updateapikeyrequest.ts +99 -0
- package/packages/orq-rc/src/models/components/updateapikeyresponse.ts +40 -0
- package/packages/orq-rc/src/models/components/userowner.ts +56 -0
- package/packages/orq-rc/src/models/operations/apikeydelete.ts +39 -0
- package/packages/orq-rc/src/models/operations/apikeyget.ts +39 -0
- package/packages/orq-rc/src/models/operations/apikeylist.ts +107 -0
- package/packages/orq-rc/src/models/operations/apikeyupdate.ts +44 -0
- package/packages/orq-rc/src/models/operations/createdataset.ts +1 -1
- package/packages/orq-rc/src/models/operations/createdatasetitem.ts +4 -4
- package/packages/orq-rc/src/models/operations/createdatasource.ts +1 -1
- package/packages/orq-rc/src/models/operations/createeval.ts +70 -70
- package/packages/orq-rc/src/models/operations/createtool.ts +6 -6
- package/packages/orq-rc/src/models/operations/filelist.ts +4 -0
- package/packages/orq-rc/src/models/operations/getalltools.ts +6 -6
- package/packages/orq-rc/src/models/operations/getevals.ts +40 -40
- package/packages/orq-rc/src/models/operations/getv2humanevalsets.ts +2 -2
- package/packages/orq-rc/src/models/operations/getv2humanevalsetsid.ts +2 -2
- package/packages/orq-rc/src/models/operations/index.ts +4 -0
- package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +4 -4
- package/packages/orq-rc/src/models/operations/listdatasets.ts +1 -1
- package/packages/orq-rc/src/models/operations/listdatasources.ts +1 -1
- package/packages/orq-rc/src/models/operations/patchv2humanevalsetsid.ts +2 -2
- package/packages/orq-rc/src/models/operations/postv2feedbackevaluation.ts +3 -3
- package/packages/orq-rc/src/models/operations/postv2humanevalsets.ts +2 -2
- package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +4 -4
- package/packages/orq-rc/src/models/operations/retrievedataset.ts +1 -1
- package/packages/orq-rc/src/models/operations/retrievedatasource.ts +1 -1
- package/packages/orq-rc/src/models/operations/retrievetool.ts +6 -6
- package/packages/orq-rc/src/models/operations/runagent.ts +1 -1
- package/packages/orq-rc/src/models/operations/streamrunagent.ts +1 -1
- package/packages/orq-rc/src/models/operations/updatedatapoint.ts +4 -4
- package/packages/orq-rc/src/models/operations/updatedataset.ts +1 -1
- package/packages/orq-rc/src/models/operations/updatedatasource.ts +1 -1
- package/packages/orq-rc/src/models/operations/updateeval.ts +46 -46
- package/packages/orq-rc/src/models/operations/updatetool.ts +7 -7
- package/packages/orq-rc/src/sdk/apikeys.ts +116 -0
- package/packages/orq-rc/src/sdk/sdk.ts +6 -0
- package/src/lib/config.ts +3 -3
- package/src/models/components/reasoningpart.ts +1 -1
- package/src/models/operations/createcontact.ts +1 -1
- package/src/models/operations/createdataset.ts +1 -1
- package/src/models/operations/createdatasetitem.ts +4 -4
- package/src/models/operations/createdatasource.ts +1 -1
- package/src/models/operations/createeval.ts +16 -16
- package/src/models/operations/createidentity.ts +1 -1
- package/src/models/operations/createtool.ts +6 -6
- package/src/models/operations/getalltools.ts +6 -6
- package/src/models/operations/getevals.ts +16 -16
- package/src/models/operations/getv2humanevalsets.ts +2 -2
- package/src/models/operations/getv2humanevalsetsid.ts +2 -2
- package/src/models/operations/listdatasetdatapoints.ts +4 -4
- package/src/models/operations/listdatasets.ts +1 -1
- package/src/models/operations/listdatasources.ts +1 -1
- package/src/models/operations/listidentities.ts +1 -1
- package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
- package/src/models/operations/postv2feedbackevaluation.ts +3 -3
- package/src/models/operations/postv2humanevalsets.ts +2 -2
- package/src/models/operations/retrievedatapoint.ts +4 -4
- package/src/models/operations/retrievedataset.ts +1 -1
- package/src/models/operations/retrievedatasource.ts +1 -1
- package/src/models/operations/retrieveidentity.ts +1 -1
- package/src/models/operations/retrievetool.ts +6 -6
- package/src/models/operations/runagent.ts +1 -1
- package/src/models/operations/streamrunagent.ts +1 -1
- package/src/models/operations/updatedatapoint.ts +4 -4
- package/src/models/operations/updatedataset.ts +1 -1
- package/src/models/operations/updatedatasource.ts +1 -1
- package/src/models/operations/updateeval.ts +16 -16
- package/src/models/operations/updateidentity.ts +1 -1
- package/src/models/operations/updatetool.ts +7 -7
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const FilePurpose = {
|
|
9
|
+
FilePurposeUnspecified: "FILE_PURPOSE_UNSPECIFIED",
|
|
10
|
+
FilePurposeRetrieval: "FILE_PURPOSE_RETRIEVAL",
|
|
11
|
+
FilePurposeKnowledgeDatasource: "FILE_PURPOSE_KNOWLEDGE_DATASOURCE",
|
|
12
|
+
FilePurposeBatch: "FILE_PURPOSE_BATCH",
|
|
13
|
+
} as const;
|
|
14
|
+
export type FilePurpose = ClosedEnum<typeof FilePurpose>;
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const FilePurpose$inboundSchema: z.ZodNativeEnum<typeof FilePurpose> = z
|
|
18
|
+
.nativeEnum(FilePurpose);
|
|
19
|
+
/** @internal */
|
|
20
|
+
export const FilePurpose$outboundSchema: z.ZodNativeEnum<typeof FilePurpose> =
|
|
21
|
+
FilePurpose$inboundSchema;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import { ApiKey, ApiKey$inboundSchema } from "./apikey.js";
|
|
11
|
+
|
|
12
|
+
export type GetApiKeyResponse = {
|
|
13
|
+
/**
|
|
14
|
+
* Requested api-key. Raw token never included.
|
|
15
|
+
*/
|
|
16
|
+
apiKey?: ApiKey | undefined;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/** @internal */
|
|
20
|
+
export const GetApiKeyResponse$inboundSchema: z.ZodType<
|
|
21
|
+
GetApiKeyResponse,
|
|
22
|
+
z.ZodTypeDef,
|
|
23
|
+
unknown
|
|
24
|
+
> = z.object({
|
|
25
|
+
api_key: ApiKey$inboundSchema.optional(),
|
|
26
|
+
}).transform((v) => {
|
|
27
|
+
return remap$(v, {
|
|
28
|
+
"api_key": "apiKey",
|
|
29
|
+
});
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
export function getApiKeyResponseFromJSON(
|
|
33
|
+
jsonString: string,
|
|
34
|
+
): SafeParseResult<GetApiKeyResponse, SDKValidationError> {
|
|
35
|
+
return safeParse(
|
|
36
|
+
jsonString,
|
|
37
|
+
(x) => GetApiKeyResponse$inboundSchema.parse(JSON.parse(x)),
|
|
38
|
+
`Failed to parse 'GetApiKeyResponse' from JSON`,
|
|
39
|
+
);
|
|
40
|
+
}
|
|
@@ -12,10 +12,16 @@ export * from "./agentmessagecreatedstreamingevent.js";
|
|
|
12
12
|
export * from "./agentresponsemessage.js";
|
|
13
13
|
export * from "./agentstartedstreamingevent.js";
|
|
14
14
|
export * from "./agentthoughtstreamingevent.js";
|
|
15
|
+
export * from "./allprojects.js";
|
|
16
|
+
export * from "./apikey.js";
|
|
17
|
+
export * from "./apikeyowner.js";
|
|
18
|
+
export * from "./apikeystatus.js";
|
|
15
19
|
export * from "./audiocontentpartschema.js";
|
|
16
20
|
export * from "./budgetlimit.js";
|
|
17
21
|
export * from "./conversationparam.js";
|
|
18
22
|
export * from "./createagentresponse.js";
|
|
23
|
+
export * from "./createapikeyrequest.js";
|
|
24
|
+
export * from "./createapikeyresponse.js";
|
|
19
25
|
export * from "./createfilerequest.js";
|
|
20
26
|
export * from "./createfileresponse.js";
|
|
21
27
|
export * from "./createidentityrequest.js";
|
|
@@ -26,10 +32,13 @@ export * from "./createskillrequest.js";
|
|
|
26
32
|
export * from "./createskillresponse.js";
|
|
27
33
|
export * from "./datapart.js";
|
|
28
34
|
export * from "./datapoint.js";
|
|
35
|
+
export * from "./deleteapikeyresponse.js";
|
|
29
36
|
export * from "./deletefileresponse.js";
|
|
30
37
|
export * from "./deleteidentityresponse.js";
|
|
31
38
|
export * from "./deleteprojectresponse.js";
|
|
32
39
|
export * from "./deleteskillresponse.js";
|
|
40
|
+
export * from "./domain.js";
|
|
41
|
+
export * from "./domaingroup.js";
|
|
33
42
|
export * from "./errorpart.js";
|
|
34
43
|
export * from "./errorstreamingevent.js";
|
|
35
44
|
export * from "./evaluatorref.js";
|
|
@@ -43,8 +52,10 @@ export * from "./fallbackconfig.js";
|
|
|
43
52
|
export * from "./file.js";
|
|
44
53
|
export * from "./filecontentpartschema.js";
|
|
45
54
|
export * from "./filepart.js";
|
|
55
|
+
export * from "./filepurpose.js";
|
|
46
56
|
export * from "./filter.js";
|
|
47
57
|
export * from "./getagentresponse.js";
|
|
58
|
+
export * from "./getapikeyresponse.js";
|
|
48
59
|
export * from "./getfilecontentresponse.js";
|
|
49
60
|
export * from "./getfileresponse.js";
|
|
50
61
|
export * from "./getprojectresponse.js";
|
|
@@ -57,7 +68,10 @@ export * from "./imagecontentpartschema.js";
|
|
|
57
68
|
export * from "./incompletedetails.js";
|
|
58
69
|
export * from "./inputtokensdetails.js";
|
|
59
70
|
export * from "./invokedeploymentrequest.js";
|
|
71
|
+
export * from "./legacytokenfamily.js";
|
|
60
72
|
export * from "./limits.js";
|
|
73
|
+
export * from "./listapikeysresponse.js";
|
|
74
|
+
export * from "./listcapabilitiesresponse.js";
|
|
61
75
|
export * from "./listfilesresponse.js";
|
|
62
76
|
export * from "./listidentitiesresponse.js";
|
|
63
77
|
export * from "./listprojectsresponse.js";
|
|
@@ -66,12 +80,15 @@ export * from "./memoryparam.js";
|
|
|
66
80
|
export * from "./modelref.js";
|
|
67
81
|
export * from "./modelsconfig.js";
|
|
68
82
|
export * from "./outputtokensdetails.js";
|
|
83
|
+
export * from "./ownertype.js";
|
|
69
84
|
export * from "./partdelta.js";
|
|
70
85
|
export * from "./partdeltaevent.js";
|
|
71
86
|
export * from "./partdoneevent.js";
|
|
87
|
+
export * from "./permissionmode.js";
|
|
72
88
|
export * from "./policy.js";
|
|
73
89
|
export * from "./policyretryconfig.js";
|
|
74
90
|
export * from "./project.js";
|
|
91
|
+
export * from "./projectscope.js";
|
|
75
92
|
export * from "./publiccontact.js";
|
|
76
93
|
export * from "./publicidentity.js";
|
|
77
94
|
export * from "./publicmodelentry.js";
|
|
@@ -101,7 +118,10 @@ export * from "./responsethread.js";
|
|
|
101
118
|
export * from "./retrieveidentityresponse.js";
|
|
102
119
|
export * from "./reviewoutcome.js";
|
|
103
120
|
export * from "./routingrule.js";
|
|
121
|
+
export * from "./scopemode.js";
|
|
104
122
|
export * from "./security.js";
|
|
123
|
+
export * from "./serviceaccountowner.js";
|
|
124
|
+
export * from "./singleproject.js";
|
|
105
125
|
export * from "./skill.js";
|
|
106
126
|
export * from "./streamoptions.js";
|
|
107
127
|
export * from "./telemetry.js";
|
|
@@ -123,6 +143,8 @@ export * from "./toolreviewdoneevent.js";
|
|
|
123
143
|
export * from "./toolreviewrequestedevent.js";
|
|
124
144
|
export * from "./toolstartedevent.js";
|
|
125
145
|
export * from "./totals.js";
|
|
146
|
+
export * from "./updateapikeyrequest.js";
|
|
147
|
+
export * from "./updateapikeyresponse.js";
|
|
126
148
|
export * from "./updatefilerequest.js";
|
|
127
149
|
export * from "./updatefileresponse.js";
|
|
128
150
|
export * from "./updateidentityrequest.js";
|
|
@@ -131,3 +153,4 @@ export * from "./updateprojectrequest.js";
|
|
|
131
153
|
export * from "./updateprojectresponse.js";
|
|
132
154
|
export * from "./updateskillrequest.js";
|
|
133
155
|
export * from "./updateskillresponse.js";
|
|
156
|
+
export * from "./userowner.js";
|
|
@@ -9,6 +9,8 @@ import { Result as SafeParseResult } from "../../types/fp.js";
|
|
|
9
9
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
10
|
|
|
11
11
|
export type InputTokensDetails = {
|
|
12
|
+
cacheCreation1hTokens?: number | undefined;
|
|
13
|
+
cacheCreation5mTokens?: number | undefined;
|
|
12
14
|
cacheCreationTokens: number;
|
|
13
15
|
cachedTokens: number;
|
|
14
16
|
};
|
|
@@ -19,10 +21,14 @@ export const InputTokensDetails$inboundSchema: z.ZodType<
|
|
|
19
21
|
z.ZodTypeDef,
|
|
20
22
|
unknown
|
|
21
23
|
> = z.object({
|
|
24
|
+
cache_creation_1h_tokens: z.number().int().optional(),
|
|
25
|
+
cache_creation_5m_tokens: z.number().int().optional(),
|
|
22
26
|
cache_creation_tokens: z.number().int(),
|
|
23
27
|
cached_tokens: z.number().int(),
|
|
24
28
|
}).transform((v) => {
|
|
25
29
|
return remap$(v, {
|
|
30
|
+
"cache_creation_1h_tokens": "cacheCreation1hTokens",
|
|
31
|
+
"cache_creation_5m_tokens": "cacheCreation5mTokens",
|
|
26
32
|
"cache_creation_tokens": "cacheCreationTokens",
|
|
27
33
|
"cached_tokens": "cachedTokens",
|
|
28
34
|
});
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const LegacyTokenFamily = {
|
|
9
|
+
LegacyTokenFamilyUnspecified: "LEGACY_TOKEN_FAMILY_UNSPECIFIED",
|
|
10
|
+
LegacyTokenFamilyRouterJwt: "LEGACY_TOKEN_FAMILY_ROUTER_JWT",
|
|
11
|
+
LegacyTokenFamilyProjectJwt: "LEGACY_TOKEN_FAMILY_PROJECT_JWT",
|
|
12
|
+
LegacyTokenFamilyWorkspaceJwt: "LEGACY_TOKEN_FAMILY_WORKSPACE_JWT",
|
|
13
|
+
} as const;
|
|
14
|
+
export type LegacyTokenFamily = ClosedEnum<typeof LegacyTokenFamily>;
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const LegacyTokenFamily$inboundSchema: z.ZodNativeEnum<
|
|
18
|
+
typeof LegacyTokenFamily
|
|
19
|
+
> = z.nativeEnum(LegacyTokenFamily);
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import { ApiKey, ApiKey$inboundSchema } from "./apikey.js";
|
|
11
|
+
|
|
12
|
+
export type ListApiKeysResponse = {
|
|
13
|
+
/**
|
|
14
|
+
* Object discriminator for list responses; always `list`.
|
|
15
|
+
*/
|
|
16
|
+
object?: string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* Page of api-keys, ordered newest first. `token_hash` and
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* `api_key` are always elided in list responses.
|
|
22
|
+
*/
|
|
23
|
+
data?: Array<ApiKey> | undefined;
|
|
24
|
+
/**
|
|
25
|
+
* Whether more api-keys are available in the selected pagination
|
|
26
|
+
*
|
|
27
|
+
* @remarks
|
|
28
|
+
* direction.
|
|
29
|
+
*/
|
|
30
|
+
hasMore?: boolean | undefined;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
/** @internal */
|
|
34
|
+
export const ListApiKeysResponse$inboundSchema: z.ZodType<
|
|
35
|
+
ListApiKeysResponse,
|
|
36
|
+
z.ZodTypeDef,
|
|
37
|
+
unknown
|
|
38
|
+
> = z.object({
|
|
39
|
+
object: z.string().optional(),
|
|
40
|
+
data: z.array(ApiKey$inboundSchema).optional(),
|
|
41
|
+
has_more: z.boolean().optional(),
|
|
42
|
+
}).transform((v) => {
|
|
43
|
+
return remap$(v, {
|
|
44
|
+
"has_more": "hasMore",
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
export function listApiKeysResponseFromJSON(
|
|
49
|
+
jsonString: string,
|
|
50
|
+
): SafeParseResult<ListApiKeysResponse, SDKValidationError> {
|
|
51
|
+
return safeParse(
|
|
52
|
+
jsonString,
|
|
53
|
+
(x) => ListApiKeysResponse$inboundSchema.parse(JSON.parse(x)),
|
|
54
|
+
`Failed to parse 'ListApiKeysResponse' from JSON`,
|
|
55
|
+
);
|
|
56
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
import { Domain, Domain$inboundSchema } from "./domain.js";
|
|
10
|
+
|
|
11
|
+
export type ListCapabilitiesResponse = {
|
|
12
|
+
/**
|
|
13
|
+
* Full capability catalog. Order is stable: workspace-admin first,
|
|
14
|
+
*
|
|
15
|
+
* @remarks
|
|
16
|
+
* then platform, then gateway. Within a group, entries are sorted
|
|
17
|
+
* alphabetically by display_name.
|
|
18
|
+
*/
|
|
19
|
+
domains?: Array<Domain> | undefined;
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
/** @internal */
|
|
23
|
+
export const ListCapabilitiesResponse$inboundSchema: z.ZodType<
|
|
24
|
+
ListCapabilitiesResponse,
|
|
25
|
+
z.ZodTypeDef,
|
|
26
|
+
unknown
|
|
27
|
+
> = z.object({
|
|
28
|
+
domains: z.array(Domain$inboundSchema).optional(),
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
export function listCapabilitiesResponseFromJSON(
|
|
32
|
+
jsonString: string,
|
|
33
|
+
): SafeParseResult<ListCapabilitiesResponse, SDKValidationError> {
|
|
34
|
+
return safeParse(
|
|
35
|
+
jsonString,
|
|
36
|
+
(x) => ListCapabilitiesResponse$inboundSchema.parse(JSON.parse(x)),
|
|
37
|
+
`Failed to parse 'ListCapabilitiesResponse' from JSON`,
|
|
38
|
+
);
|
|
39
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const OwnerType = {
|
|
9
|
+
OwnerTypeUnspecified: "OWNER_TYPE_UNSPECIFIED",
|
|
10
|
+
OwnerTypeUser: "OWNER_TYPE_USER",
|
|
11
|
+
OwnerTypeServiceAccount: "OWNER_TYPE_SERVICE_ACCOUNT",
|
|
12
|
+
} as const;
|
|
13
|
+
export type OwnerType = ClosedEnum<typeof OwnerType>;
|
|
14
|
+
|
|
15
|
+
/** @internal */
|
|
16
|
+
export const OwnerType$outboundSchema: z.ZodNativeEnum<typeof OwnerType> = z
|
|
17
|
+
.nativeEnum(OwnerType);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const PermissionMode = {
|
|
9
|
+
PermissionModeUnspecified: "PERMISSION_MODE_UNSPECIFIED",
|
|
10
|
+
PermissionModeAll: "PERMISSION_MODE_ALL",
|
|
11
|
+
PermissionModeRestricted: "PERMISSION_MODE_RESTRICTED",
|
|
12
|
+
PermissionModeReadOnly: "PERMISSION_MODE_READ_ONLY",
|
|
13
|
+
} as const;
|
|
14
|
+
export type PermissionMode = ClosedEnum<typeof PermissionMode>;
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const PermissionMode$inboundSchema: z.ZodNativeEnum<
|
|
18
|
+
typeof PermissionMode
|
|
19
|
+
> = z.nativeEnum(PermissionMode);
|
|
20
|
+
/** @internal */
|
|
21
|
+
export const PermissionMode$outboundSchema: z.ZodNativeEnum<
|
|
22
|
+
typeof PermissionMode
|
|
23
|
+
> = PermissionMode$inboundSchema;
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
import {
|
|
10
|
+
AllProjects,
|
|
11
|
+
AllProjects$inboundSchema,
|
|
12
|
+
AllProjects$Outbound,
|
|
13
|
+
AllProjects$outboundSchema,
|
|
14
|
+
} from "./allprojects.js";
|
|
15
|
+
import {
|
|
16
|
+
SingleProject,
|
|
17
|
+
SingleProject$inboundSchema,
|
|
18
|
+
SingleProject$Outbound,
|
|
19
|
+
SingleProject$outboundSchema,
|
|
20
|
+
} from "./singleproject.js";
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Project authorization scope. Single-project or all-projects.
|
|
24
|
+
*
|
|
25
|
+
* @remarks
|
|
26
|
+
* Multi-project use cases are served by minting per-project keys or by
|
|
27
|
+
* using an all-projects key with `restricted` mode.
|
|
28
|
+
*/
|
|
29
|
+
export type ProjectScope = {
|
|
30
|
+
all?: AllProjects | undefined;
|
|
31
|
+
single?: SingleProject | undefined;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
/** @internal */
|
|
35
|
+
export const ProjectScope$inboundSchema: z.ZodType<
|
|
36
|
+
ProjectScope,
|
|
37
|
+
z.ZodTypeDef,
|
|
38
|
+
unknown
|
|
39
|
+
> = z.object({
|
|
40
|
+
all: AllProjects$inboundSchema.optional(),
|
|
41
|
+
single: SingleProject$inboundSchema.optional(),
|
|
42
|
+
});
|
|
43
|
+
/** @internal */
|
|
44
|
+
export type ProjectScope$Outbound = {
|
|
45
|
+
all?: AllProjects$Outbound | undefined;
|
|
46
|
+
single?: SingleProject$Outbound | undefined;
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
/** @internal */
|
|
50
|
+
export const ProjectScope$outboundSchema: z.ZodType<
|
|
51
|
+
ProjectScope$Outbound,
|
|
52
|
+
z.ZodTypeDef,
|
|
53
|
+
ProjectScope
|
|
54
|
+
> = z.object({
|
|
55
|
+
all: AllProjects$outboundSchema.optional(),
|
|
56
|
+
single: SingleProject$outboundSchema.optional(),
|
|
57
|
+
});
|
|
58
|
+
|
|
59
|
+
export function projectScopeToJSON(projectScope: ProjectScope): string {
|
|
60
|
+
return JSON.stringify(ProjectScope$outboundSchema.parse(projectScope));
|
|
61
|
+
}
|
|
62
|
+
export function projectScopeFromJSON(
|
|
63
|
+
jsonString: string,
|
|
64
|
+
): SafeParseResult<ProjectScope, SDKValidationError> {
|
|
65
|
+
return safeParse(
|
|
66
|
+
jsonString,
|
|
67
|
+
(x) => ProjectScope$inboundSchema.parse(JSON.parse(x)),
|
|
68
|
+
`Failed to parse 'ProjectScope' from JSON`,
|
|
69
|
+
);
|
|
70
|
+
}
|
|
@@ -40,7 +40,7 @@ export const ReasoningPart$inboundSchema: z.ZodType<
|
|
|
40
40
|
z.ZodTypeDef,
|
|
41
41
|
unknown
|
|
42
42
|
> = z.object({
|
|
43
|
-
_id: z.string().default("
|
|
43
|
+
_id: z.string().default("reasoning_01ksfyhcesynycmnqq79fqhzq2"),
|
|
44
44
|
metadata: z.record(z.any()).optional(),
|
|
45
45
|
kind: z.literal("reasoning"),
|
|
46
46
|
reasoning: z.string(),
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const ScopeMode = {
|
|
9
|
+
ScopeModeUnspecified: "SCOPE_MODE_UNSPECIFIED",
|
|
10
|
+
ScopeModeAll: "SCOPE_MODE_ALL",
|
|
11
|
+
ScopeModeSingle: "SCOPE_MODE_SINGLE",
|
|
12
|
+
} as const;
|
|
13
|
+
export type ScopeMode = ClosedEnum<typeof ScopeMode>;
|
|
14
|
+
|
|
15
|
+
/** @internal */
|
|
16
|
+
export const ScopeMode$inboundSchema: z.ZodNativeEnum<typeof ScopeMode> = z
|
|
17
|
+
.nativeEnum(ScopeMode);
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
|
|
10
|
+
export type ServiceAccountOwner = {};
|
|
11
|
+
|
|
12
|
+
/** @internal */
|
|
13
|
+
export const ServiceAccountOwner$inboundSchema: z.ZodType<
|
|
14
|
+
ServiceAccountOwner,
|
|
15
|
+
z.ZodTypeDef,
|
|
16
|
+
unknown
|
|
17
|
+
> = z.object({});
|
|
18
|
+
/** @internal */
|
|
19
|
+
export type ServiceAccountOwner$Outbound = {};
|
|
20
|
+
|
|
21
|
+
/** @internal */
|
|
22
|
+
export const ServiceAccountOwner$outboundSchema: z.ZodType<
|
|
23
|
+
ServiceAccountOwner$Outbound,
|
|
24
|
+
z.ZodTypeDef,
|
|
25
|
+
ServiceAccountOwner
|
|
26
|
+
> = z.object({});
|
|
27
|
+
|
|
28
|
+
export function serviceAccountOwnerToJSON(
|
|
29
|
+
serviceAccountOwner: ServiceAccountOwner,
|
|
30
|
+
): string {
|
|
31
|
+
return JSON.stringify(
|
|
32
|
+
ServiceAccountOwner$outboundSchema.parse(serviceAccountOwner),
|
|
33
|
+
);
|
|
34
|
+
}
|
|
35
|
+
export function serviceAccountOwnerFromJSON(
|
|
36
|
+
jsonString: string,
|
|
37
|
+
): SafeParseResult<ServiceAccountOwner, SDKValidationError> {
|
|
38
|
+
return safeParse(
|
|
39
|
+
jsonString,
|
|
40
|
+
(x) => ServiceAccountOwner$inboundSchema.parse(JSON.parse(x)),
|
|
41
|
+
`Failed to parse 'ServiceAccountOwner' from JSON`,
|
|
42
|
+
);
|
|
43
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
|
|
11
|
+
export type SingleProject = {
|
|
12
|
+
projectId?: string | undefined;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
/** @internal */
|
|
16
|
+
export const SingleProject$inboundSchema: z.ZodType<
|
|
17
|
+
SingleProject,
|
|
18
|
+
z.ZodTypeDef,
|
|
19
|
+
unknown
|
|
20
|
+
> = z.object({
|
|
21
|
+
project_id: z.string().optional(),
|
|
22
|
+
}).transform((v) => {
|
|
23
|
+
return remap$(v, {
|
|
24
|
+
"project_id": "projectId",
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
/** @internal */
|
|
28
|
+
export type SingleProject$Outbound = {
|
|
29
|
+
project_id?: string | undefined;
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
/** @internal */
|
|
33
|
+
export const SingleProject$outboundSchema: z.ZodType<
|
|
34
|
+
SingleProject$Outbound,
|
|
35
|
+
z.ZodTypeDef,
|
|
36
|
+
SingleProject
|
|
37
|
+
> = z.object({
|
|
38
|
+
projectId: z.string().optional(),
|
|
39
|
+
}).transform((v) => {
|
|
40
|
+
return remap$(v, {
|
|
41
|
+
projectId: "project_id",
|
|
42
|
+
});
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
export function singleProjectToJSON(singleProject: SingleProject): string {
|
|
46
|
+
return JSON.stringify(SingleProject$outboundSchema.parse(singleProject));
|
|
47
|
+
}
|
|
48
|
+
export function singleProjectFromJSON(
|
|
49
|
+
jsonString: string,
|
|
50
|
+
): SafeParseResult<SingleProject, SDKValidationError> {
|
|
51
|
+
return safeParse(
|
|
52
|
+
jsonString,
|
|
53
|
+
(x) => SingleProject$inboundSchema.parse(JSON.parse(x)),
|
|
54
|
+
`Failed to parse 'SingleProject' from JSON`,
|
|
55
|
+
);
|
|
56
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { ApiKeyStatus, ApiKeyStatus$outboundSchema } from "./apikeystatus.js";
|
|
8
|
+
import {
|
|
9
|
+
PermissionMode,
|
|
10
|
+
PermissionMode$outboundSchema,
|
|
11
|
+
} from "./permissionmode.js";
|
|
12
|
+
import {
|
|
13
|
+
ProjectScope,
|
|
14
|
+
ProjectScope$Outbound,
|
|
15
|
+
ProjectScope$outboundSchema,
|
|
16
|
+
} from "./projectscope.js";
|
|
17
|
+
|
|
18
|
+
export type UpdateApiKeyRequest = {
|
|
19
|
+
/**
|
|
20
|
+
* API key id to update.
|
|
21
|
+
*/
|
|
22
|
+
apiKeyId?: string | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* New name. Omit to keep current.
|
|
25
|
+
*/
|
|
26
|
+
name?: string | undefined;
|
|
27
|
+
status?: ApiKeyStatus | undefined;
|
|
28
|
+
permissionMode?: PermissionMode | undefined;
|
|
29
|
+
/**
|
|
30
|
+
* Replacement access map. Required when changing to
|
|
31
|
+
*
|
|
32
|
+
* @remarks
|
|
33
|
+
* `PERMISSION_MODE_RESTRICTED`; ignored otherwise. Provide an empty
|
|
34
|
+
* map to clear. See `ApiKey.access` for the full catalog of valid
|
|
35
|
+
* keys (Domain.id) and AccessLevel string values, or fetch the
|
|
36
|
+
* live catalog via the `ListCapabilities` RPC.
|
|
37
|
+
*/
|
|
38
|
+
access?: { [k: string]: number } | undefined;
|
|
39
|
+
/**
|
|
40
|
+
* New project scope. Omit to keep current.
|
|
41
|
+
*/
|
|
42
|
+
projectScope?: ProjectScope | undefined;
|
|
43
|
+
/**
|
|
44
|
+
* New expiration. Omit to keep current. Set `clear_expires_at = true`
|
|
45
|
+
*
|
|
46
|
+
* @remarks
|
|
47
|
+
* to remove an existing expiration (a zero Timestamp here would still
|
|
48
|
+
* mean "no change" because of optional semantics).
|
|
49
|
+
*/
|
|
50
|
+
expiresAt?: Date | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Force-clear the expiration. Mutually exclusive with `expires_at`.
|
|
53
|
+
*/
|
|
54
|
+
clearExpiresAt?: boolean | undefined;
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
/** @internal */
|
|
58
|
+
export type UpdateApiKeyRequest$Outbound = {
|
|
59
|
+
api_key_id?: string | undefined;
|
|
60
|
+
name?: string | undefined;
|
|
61
|
+
status?: string | undefined;
|
|
62
|
+
permission_mode?: string | undefined;
|
|
63
|
+
access?: { [k: string]: number } | undefined;
|
|
64
|
+
project_scope?: ProjectScope$Outbound | undefined;
|
|
65
|
+
expires_at?: string | undefined;
|
|
66
|
+
clear_expires_at?: boolean | undefined;
|
|
67
|
+
};
|
|
68
|
+
|
|
69
|
+
/** @internal */
|
|
70
|
+
export const UpdateApiKeyRequest$outboundSchema: z.ZodType<
|
|
71
|
+
UpdateApiKeyRequest$Outbound,
|
|
72
|
+
z.ZodTypeDef,
|
|
73
|
+
UpdateApiKeyRequest
|
|
74
|
+
> = z.object({
|
|
75
|
+
apiKeyId: z.string().optional(),
|
|
76
|
+
name: z.string().optional(),
|
|
77
|
+
status: ApiKeyStatus$outboundSchema.optional(),
|
|
78
|
+
permissionMode: PermissionMode$outboundSchema.optional(),
|
|
79
|
+
access: z.record(z.number().int()).optional(),
|
|
80
|
+
projectScope: ProjectScope$outboundSchema.optional(),
|
|
81
|
+
expiresAt: z.date().transform(v => v.toISOString()).optional(),
|
|
82
|
+
clearExpiresAt: z.boolean().optional(),
|
|
83
|
+
}).transform((v) => {
|
|
84
|
+
return remap$(v, {
|
|
85
|
+
apiKeyId: "api_key_id",
|
|
86
|
+
permissionMode: "permission_mode",
|
|
87
|
+
projectScope: "project_scope",
|
|
88
|
+
expiresAt: "expires_at",
|
|
89
|
+
clearExpiresAt: "clear_expires_at",
|
|
90
|
+
});
|
|
91
|
+
});
|
|
92
|
+
|
|
93
|
+
export function updateApiKeyRequestToJSON(
|
|
94
|
+
updateApiKeyRequest: UpdateApiKeyRequest,
|
|
95
|
+
): string {
|
|
96
|
+
return JSON.stringify(
|
|
97
|
+
UpdateApiKeyRequest$outboundSchema.parse(updateApiKeyRequest),
|
|
98
|
+
);
|
|
99
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import { ApiKey, ApiKey$inboundSchema } from "./apikey.js";
|
|
11
|
+
|
|
12
|
+
export type UpdateApiKeyResponse = {
|
|
13
|
+
/**
|
|
14
|
+
* Updated api-key.
|
|
15
|
+
*/
|
|
16
|
+
apiKey?: ApiKey | undefined;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/** @internal */
|
|
20
|
+
export const UpdateApiKeyResponse$inboundSchema: z.ZodType<
|
|
21
|
+
UpdateApiKeyResponse,
|
|
22
|
+
z.ZodTypeDef,
|
|
23
|
+
unknown
|
|
24
|
+
> = z.object({
|
|
25
|
+
api_key: ApiKey$inboundSchema.optional(),
|
|
26
|
+
}).transform((v) => {
|
|
27
|
+
return remap$(v, {
|
|
28
|
+
"api_key": "apiKey",
|
|
29
|
+
});
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
export function updateApiKeyResponseFromJSON(
|
|
33
|
+
jsonString: string,
|
|
34
|
+
): SafeParseResult<UpdateApiKeyResponse, SDKValidationError> {
|
|
35
|
+
return safeParse(
|
|
36
|
+
jsonString,
|
|
37
|
+
(x) => UpdateApiKeyResponse$inboundSchema.parse(JSON.parse(x)),
|
|
38
|
+
`Failed to parse 'UpdateApiKeyResponse' from JSON`,
|
|
39
|
+
);
|
|
40
|
+
}
|