@orq-ai/node 4.16.0-rc.13 → 4.16.0-rc.14
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/README.md +1 -1
- package/funcs/apiKeysCreate.d.ts +3 -2
- package/funcs/apiKeysCreate.d.ts.map +1 -1
- package/funcs/apiKeysCreate.js +4 -3
- package/funcs/apiKeysCreate.js.map +1 -1
- package/funcs/apiKeysDelete.js +1 -1
- package/funcs/apiKeysDelete.js.map +1 -1
- package/funcs/apiKeysGet.d.ts +1 -1
- package/funcs/apiKeysGet.js +2 -6
- package/funcs/apiKeysGet.js.map +1 -1
- package/funcs/apiKeysList.d.ts +1 -1
- package/funcs/apiKeysList.js +4 -11
- package/funcs/apiKeysList.js.map +1 -1
- package/funcs/apiKeysListCapabilities.d.ts +3 -3
- package/funcs/apiKeysListCapabilities.d.ts.map +1 -1
- package/funcs/apiKeysListCapabilities.js +3 -3
- package/funcs/apiKeysListCapabilities.js.map +1 -1
- package/funcs/apiKeysUpdate.d.ts +1 -1
- package/funcs/apiKeysUpdate.js +3 -5
- package/funcs/apiKeysUpdate.js.map +1 -1
- package/funcs/routerClassifyCreate.d.ts +1 -1
- package/funcs/routerClassifyCreate.js +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/models/components/classifyanswer.d.ts +2 -2
- package/models/components/constraints.d.ts +12 -0
- package/models/components/constraints.d.ts.map +1 -0
- package/models/components/{singleproject.js → constraints.js} +8 -8
- package/models/components/constraints.js.map +1 -0
- package/models/components/domain.d.ts +30 -31
- package/models/components/domain.d.ts.map +1 -1
- package/models/components/domain.js +20 -11
- package/models/components/domain.js.map +1 -1
- package/models/components/index.d.ts +2 -14
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +2 -14
- package/models/components/index.js.map +1 -1
- package/models/components/owner.d.ts +14 -0
- package/models/components/owner.d.ts.map +1 -0
- package/models/components/{userowner.js → owner.js} +8 -7
- package/models/components/owner.js.map +1 -0
- package/models/components/projectscope.d.ts +4 -13
- package/models/components/projectscope.d.ts.map +1 -1
- package/models/components/projectscope.js +7 -4
- package/models/components/projectscope.js.map +1 -1
- package/models/components/reasoningpart.js +1 -1
- package/models/operations/apikeycreate.d.ts +79 -0
- package/models/operations/apikeycreate.d.ts.map +1 -0
- package/models/{components/createapikeyrequest.js → operations/apikeycreate.js} +35 -21
- package/models/operations/apikeycreate.js.map +1 -0
- package/models/operations/apikeydelete.d.ts +1 -1
- package/models/operations/apikeyget.d.ts +1 -9
- package/models/operations/apikeyget.d.ts.map +1 -1
- package/models/operations/apikeyget.js +0 -2
- package/models/operations/apikeyget.js.map +1 -1
- package/models/operations/apikeylist.d.ts +18 -65
- package/models/operations/apikeylist.d.ts.map +1 -1
- package/models/operations/apikeylist.js +11 -15
- package/models/operations/apikeylist.js.map +1 -1
- package/models/operations/apikeylistcapabilities.d.ts +17 -0
- package/models/operations/apikeylistcapabilities.d.ts.map +1 -0
- package/models/{components/listcapabilitiesresponse.js → operations/apikeylistcapabilities.js} +8 -8
- package/models/operations/apikeylistcapabilities.js.map +1 -0
- package/models/operations/apikeyupdate.d.ts +73 -3
- package/models/operations/apikeyupdate.d.ts.map +1 -1
- package/models/operations/apikeyupdate.js +43 -3
- package/models/operations/apikeyupdate.js.map +1 -1
- package/models/operations/createclassify.d.ts +2 -2
- package/models/operations/createrouterresponse.d.ts +4 -4
- package/models/operations/createrouterresponse.d.ts.map +1 -1
- package/models/operations/createrouterresponse.js +5 -5
- package/models/operations/createrouterresponse.js.map +1 -1
- package/models/operations/createtool.js +4 -4
- package/models/operations/getalltools.js +4 -4
- package/models/operations/getv2humanevalsets.js +2 -2
- package/models/operations/getv2humanevalsetsid.js +2 -2
- package/models/operations/index.d.ts +2 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +2 -0
- package/models/operations/index.js.map +1 -1
- package/models/operations/patchv2humanevalsetsid.js +2 -2
- package/models/operations/postv2feedbackevaluation.js +4 -4
- package/models/operations/postv2humanevalsets.js +2 -2
- package/models/operations/retrievetool.js +4 -4
- package/models/operations/runagent.js +1 -1
- package/models/operations/streamrunagent.js +1 -1
- package/models/operations/updatetool.js +4 -4
- package/package.json +1 -1
- package/sdk/apikeys.d.ts +12 -12
- package/sdk/apikeys.d.ts.map +1 -1
- package/sdk/apikeys.js +12 -12
- package/sdk/apikeys.js.map +1 -1
- package/sdk/classify.d.ts +1 -1
- package/sdk/classify.js +1 -1
- package/sdk/sdk.d.ts +2 -2
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +3 -3
- package/sdk/sdk.js.map +1 -1
- package/src/funcs/apiKeysCreate.ts +6 -5
- package/src/funcs/apiKeysDelete.ts +1 -1
- package/src/funcs/apiKeysGet.ts +3 -8
- package/src/funcs/apiKeysList.ts +4 -11
- package/src/funcs/apiKeysListCapabilities.ts +6 -6
- package/src/funcs/apiKeysUpdate.ts +3 -5
- package/src/funcs/routerClassifyCreate.ts +1 -1
- package/src/lib/config.ts +2 -2
- package/src/models/components/classifyanswer.ts +2 -2
- package/src/models/components/constraints.ts +32 -0
- package/src/models/components/domain.ts +42 -39
- package/src/models/components/index.ts +2 -14
- package/src/models/components/owner.ts +35 -0
- package/src/models/components/projectscope.ts +11 -23
- package/src/models/components/reasoningpart.ts +1 -1
- package/src/models/operations/apikeycreate.ts +116 -0
- package/src/models/operations/apikeydelete.ts +1 -1
- package/src/models/operations/apikeyget.ts +1 -11
- package/src/models/operations/apikeylist.ts +23 -78
- package/src/models/operations/apikeylistcapabilities.ts +39 -0
- package/src/models/operations/apikeyupdate.ts +107 -5
- package/src/models/operations/createclassify.ts +2 -2
- package/src/models/operations/createrouterresponse.ts +6 -6
- package/src/models/operations/createtool.ts +4 -4
- package/src/models/operations/getalltools.ts +4 -4
- package/src/models/operations/getv2humanevalsets.ts +2 -2
- package/src/models/operations/getv2humanevalsetsid.ts +2 -2
- package/src/models/operations/index.ts +2 -0
- package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
- package/src/models/operations/postv2feedbackevaluation.ts +4 -4
- package/src/models/operations/postv2humanevalsets.ts +2 -2
- package/src/models/operations/retrievetool.ts +4 -4
- package/src/models/operations/runagent.ts +1 -1
- package/src/models/operations/streamrunagent.ts +1 -1
- package/src/models/operations/updatetool.ts +4 -4
- package/src/sdk/apikeys.ts +18 -18
- package/src/sdk/classify.ts +1 -1
- package/src/sdk/sdk.ts +5 -5
- package/models/components/allprojects.d.ts +0 -8
- package/models/components/allprojects.d.ts.map +0 -1
- package/models/components/allprojects.js +0 -47
- package/models/components/allprojects.js.map +0 -1
- package/models/components/apikeyowner.d.ts +0 -26
- package/models/components/apikeyowner.d.ts.map +0 -1
- package/models/components/apikeyowner.js +0 -57
- package/models/components/apikeyowner.js.map +0 -1
- package/models/components/apikeystatus.d.ts +0 -12
- package/models/components/apikeystatus.d.ts.map +0 -1
- package/models/components/apikeystatus.js +0 -49
- package/models/components/apikeystatus.js.map +0 -1
- package/models/components/createapikeyrequest.d.ts +0 -75
- package/models/components/createapikeyrequest.d.ts.map +0 -1
- package/models/components/createapikeyrequest.js.map +0 -1
- package/models/components/domaingroup.d.ts +0 -11
- package/models/components/domaingroup.d.ts.map +0 -1
- package/models/components/domaingroup.js +0 -49
- package/models/components/domaingroup.js.map +0 -1
- package/models/components/listcapabilitiesresponse.d.ts +0 -17
- package/models/components/listcapabilitiesresponse.d.ts.map +0 -1
- package/models/components/listcapabilitiesresponse.js.map +0 -1
- package/models/components/mcpaccess.d.ts +0 -67
- package/models/components/mcpaccess.d.ts.map +0 -1
- package/models/components/mcpaccess.js +0 -60
- package/models/components/mcpaccess.js.map +0 -1
- package/models/components/ownertype.d.ts +0 -11
- package/models/components/ownertype.d.ts.map +0 -1
- package/models/components/ownertype.js +0 -49
- package/models/components/ownertype.js.map +0 -1
- package/models/components/permissionmode.d.ts +0 -12
- package/models/components/permissionmode.d.ts.map +0 -1
- package/models/components/permissionmode.js +0 -49
- package/models/components/permissionmode.js.map +0 -1
- package/models/components/scopemode.d.ts +0 -10
- package/models/components/scopemode.d.ts.map +0 -1
- package/models/components/scopemode.js +0 -48
- package/models/components/scopemode.js.map +0 -1
- package/models/components/serviceaccountowner.d.ts +0 -8
- package/models/components/serviceaccountowner.d.ts.map +0 -1
- package/models/components/serviceaccountowner.js +0 -47
- package/models/components/serviceaccountowner.js.map +0 -1
- package/models/components/singleproject.d.ts +0 -15
- package/models/components/singleproject.d.ts.map +0 -1
- package/models/components/singleproject.js.map +0 -1
- package/models/components/updateapikeyrequest.d.ts +0 -68
- package/models/components/updateapikeyrequest.d.ts.map +0 -1
- package/models/components/updateapikeyrequest.js +0 -70
- package/models/components/updateapikeyrequest.js.map +0 -1
- package/models/components/userowner.d.ts +0 -15
- package/models/components/userowner.d.ts.map +0 -1
- package/models/components/userowner.js.map +0 -1
- package/src/models/components/allprojects.ts +0 -21
- package/src/models/components/apikeyowner.ts +0 -55
- package/src/models/components/apikeystatus.ts +0 -18
- package/src/models/components/createapikeyrequest.ts +0 -116
- package/src/models/components/domaingroup.ts +0 -17
- package/src/models/components/listcapabilitiesresponse.ts +0 -38
- package/src/models/components/mcpaccess.ts +0 -93
- package/src/models/components/ownertype.ts +0 -17
- package/src/models/components/permissionmode.ts +0 -19
- package/src/models/components/scopemode.ts +0 -16
- package/src/models/components/serviceaccountowner.ts +0 -25
- package/src/models/components/singleproject.ts +0 -35
- package/src/models/components/updateapikeyrequest.ts +0 -110
- package/src/models/components/userowner.ts +0 -35
|
@@ -1,93 +0,0 @@
|
|
|
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
|
-
|
|
8
|
-
/**
|
|
9
|
-
* McpAccess optionally restricts which MCP gateways an API key may
|
|
10
|
-
*
|
|
11
|
-
* @remarks
|
|
12
|
-
* reach at the data plane. It is orthogonal to permission_mode /
|
|
13
|
-
* access: the key must still hold the `mcp_gateway.execute` verb and
|
|
14
|
-
* project membership; McpAccess only narrows the reachable gateway set
|
|
15
|
-
* within that grant. Human sessions and keys without an McpAccess are
|
|
16
|
-
* unaffected.
|
|
17
|
-
*
|
|
18
|
-
* Semantics:
|
|
19
|
-
* - absent, or deny_all=false with an empty allowed_mcp_gateway_ids:
|
|
20
|
-
* no restriction — every gateway in the key's project scope is
|
|
21
|
-
* reachable.
|
|
22
|
-
* - deny_all=true: zero gateways are reachable. Wins over
|
|
23
|
-
* allowed_mcp_gateway_ids.
|
|
24
|
-
* - non-empty allowed_mcp_gateway_ids: only the listed gateway ids
|
|
25
|
-
* are reachable. Each id must look like `mcp_gateway_<ULID>`.
|
|
26
|
-
*/
|
|
27
|
-
export type McpAccess = {
|
|
28
|
-
/**
|
|
29
|
-
* When true, the key is denied every MCP gateway regardless of
|
|
30
|
-
*
|
|
31
|
-
* @remarks
|
|
32
|
-
* allowed_mcp_gateway_ids.
|
|
33
|
-
*/
|
|
34
|
-
denyAll?: boolean | undefined;
|
|
35
|
-
/**
|
|
36
|
-
* Allow-list of MCP gateway ids (`mcp_gateway_<ULID>`) the key may
|
|
37
|
-
*
|
|
38
|
-
* @remarks
|
|
39
|
-
* reach. Ignored when deny_all is true. Empty (with deny_all=false)
|
|
40
|
-
* means no restriction.
|
|
41
|
-
*/
|
|
42
|
-
allowedMcpGatewayIds?: Array<string> | undefined;
|
|
43
|
-
/**
|
|
44
|
-
* Allow-list of MCP toolset ids (`mcp_toolset_<ULID>`) the key is
|
|
45
|
-
*
|
|
46
|
-
* @remarks
|
|
47
|
-
* bound to. When non-empty, the key sees and may call only the tools
|
|
48
|
-
* that are both exposed by the target gateway and members of the
|
|
49
|
-
* union of these toolsets. Empty means no toolset restriction.
|
|
50
|
-
*/
|
|
51
|
-
toolsetIds?: Array<string> | undefined;
|
|
52
|
-
/**
|
|
53
|
-
* Allow-list of file system ids (`fsys_<ULID>`) the key may reach over
|
|
54
|
-
*
|
|
55
|
-
* @remarks
|
|
56
|
-
* the file system MCP endpoint. Ignored when deny_all is true. Empty
|
|
57
|
-
* (with deny_all=false) means no restriction. The access mode a key
|
|
58
|
-
* gets on a reachable file system is the file system's own
|
|
59
|
-
* external_access, never something the key carries.
|
|
60
|
-
*/
|
|
61
|
-
allowedFilesystemIds?: Array<string> | undefined;
|
|
62
|
-
};
|
|
63
|
-
|
|
64
|
-
/** @internal */
|
|
65
|
-
export type McpAccess$Outbound = {
|
|
66
|
-
deny_all?: boolean | undefined;
|
|
67
|
-
allowed_mcp_gateway_ids?: Array<string> | undefined;
|
|
68
|
-
toolset_ids?: Array<string> | undefined;
|
|
69
|
-
allowed_filesystem_ids?: Array<string> | undefined;
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
/** @internal */
|
|
73
|
-
export const McpAccess$outboundSchema: z.ZodType<
|
|
74
|
-
McpAccess$Outbound,
|
|
75
|
-
z.ZodTypeDef,
|
|
76
|
-
McpAccess
|
|
77
|
-
> = z.object({
|
|
78
|
-
denyAll: z.boolean().optional(),
|
|
79
|
-
allowedMcpGatewayIds: z.array(z.string()).optional(),
|
|
80
|
-
toolsetIds: z.array(z.string()).optional(),
|
|
81
|
-
allowedFilesystemIds: z.array(z.string()).optional(),
|
|
82
|
-
}).transform((v) => {
|
|
83
|
-
return remap$(v, {
|
|
84
|
-
denyAll: "deny_all",
|
|
85
|
-
allowedMcpGatewayIds: "allowed_mcp_gateway_ids",
|
|
86
|
-
toolsetIds: "toolset_ids",
|
|
87
|
-
allowedFilesystemIds: "allowed_filesystem_ids",
|
|
88
|
-
});
|
|
89
|
-
});
|
|
90
|
-
|
|
91
|
-
export function mcpAccessToJSON(mcpAccess: McpAccess): string {
|
|
92
|
-
return JSON.stringify(McpAccess$outboundSchema.parse(mcpAccess));
|
|
93
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
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);
|
|
@@ -1,19 +0,0 @@
|
|
|
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$outboundSchema: z.ZodNativeEnum<
|
|
18
|
-
typeof PermissionMode
|
|
19
|
-
> = z.nativeEnum(PermissionMode);
|
|
@@ -1,16 +0,0 @@
|
|
|
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
|
-
ScopeModeAll: "SCOPE_MODE_ALL",
|
|
10
|
-
ScopeModeSingle: "SCOPE_MODE_SINGLE",
|
|
11
|
-
} as const;
|
|
12
|
-
export type ScopeMode = ClosedEnum<typeof ScopeMode>;
|
|
13
|
-
|
|
14
|
-
/** @internal */
|
|
15
|
-
export const ScopeMode$inboundSchema: z.ZodNativeEnum<typeof ScopeMode> = z
|
|
16
|
-
.nativeEnum(ScopeMode);
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod/v3";
|
|
6
|
-
|
|
7
|
-
export type ServiceAccountOwner = {};
|
|
8
|
-
|
|
9
|
-
/** @internal */
|
|
10
|
-
export type ServiceAccountOwner$Outbound = {};
|
|
11
|
-
|
|
12
|
-
/** @internal */
|
|
13
|
-
export const ServiceAccountOwner$outboundSchema: z.ZodType<
|
|
14
|
-
ServiceAccountOwner$Outbound,
|
|
15
|
-
z.ZodTypeDef,
|
|
16
|
-
ServiceAccountOwner
|
|
17
|
-
> = z.object({});
|
|
18
|
-
|
|
19
|
-
export function serviceAccountOwnerToJSON(
|
|
20
|
-
serviceAccountOwner: ServiceAccountOwner,
|
|
21
|
-
): string {
|
|
22
|
-
return JSON.stringify(
|
|
23
|
-
ServiceAccountOwner$outboundSchema.parse(serviceAccountOwner),
|
|
24
|
-
);
|
|
25
|
-
}
|
|
@@ -1,35 +0,0 @@
|
|
|
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
|
-
|
|
8
|
-
export type SingleProject = {
|
|
9
|
-
/**
|
|
10
|
-
* Project ID this API key is scoped to.
|
|
11
|
-
*/
|
|
12
|
-
projectId: string;
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
/** @internal */
|
|
16
|
-
export type SingleProject$Outbound = {
|
|
17
|
-
project_id: string;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
/** @internal */
|
|
21
|
-
export const SingleProject$outboundSchema: z.ZodType<
|
|
22
|
-
SingleProject$Outbound,
|
|
23
|
-
z.ZodTypeDef,
|
|
24
|
-
SingleProject
|
|
25
|
-
> = z.object({
|
|
26
|
-
projectId: z.string(),
|
|
27
|
-
}).transform((v) => {
|
|
28
|
-
return remap$(v, {
|
|
29
|
-
projectId: "project_id",
|
|
30
|
-
});
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
export function singleProjectToJSON(singleProject: SingleProject): string {
|
|
34
|
-
return JSON.stringify(SingleProject$outboundSchema.parse(singleProject));
|
|
35
|
-
}
|
|
@@ -1,110 +0,0 @@
|
|
|
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 { AccessLevel, AccessLevel$outboundSchema } from "./accesslevel.js";
|
|
8
|
-
import { ApiKeyStatus, ApiKeyStatus$outboundSchema } from "./apikeystatus.js";
|
|
9
|
-
import {
|
|
10
|
-
McpAccess,
|
|
11
|
-
McpAccess$Outbound,
|
|
12
|
-
McpAccess$outboundSchema,
|
|
13
|
-
} from "./mcpaccess.js";
|
|
14
|
-
import {
|
|
15
|
-
PermissionMode,
|
|
16
|
-
PermissionMode$outboundSchema,
|
|
17
|
-
} from "./permissionmode.js";
|
|
18
|
-
import {
|
|
19
|
-
ProjectScope,
|
|
20
|
-
ProjectScope$Outbound,
|
|
21
|
-
ProjectScope$outboundSchema,
|
|
22
|
-
} from "./projectscope.js";
|
|
23
|
-
|
|
24
|
-
export type UpdateApiKeyRequest = {
|
|
25
|
-
/**
|
|
26
|
-
* New name. Omit to keep current.
|
|
27
|
-
*/
|
|
28
|
-
name?: string | undefined;
|
|
29
|
-
status?: ApiKeyStatus | undefined;
|
|
30
|
-
permissionMode?: PermissionMode | undefined;
|
|
31
|
-
/**
|
|
32
|
-
* Replacement access map. Required when changing to
|
|
33
|
-
*
|
|
34
|
-
* @remarks
|
|
35
|
-
* `PERMISSION_MODE_RESTRICTED`; ignored otherwise. Provide an empty
|
|
36
|
-
* map to clear. See `ApiKey.access` for the full catalog of valid
|
|
37
|
-
* keys (Domain.id) and AccessLevel string values, or fetch the
|
|
38
|
-
* live catalog via the capability catalog endpoint.
|
|
39
|
-
*/
|
|
40
|
-
access?: { [k: string]: AccessLevel } | undefined;
|
|
41
|
-
/**
|
|
42
|
-
* New project scope. Omit to keep current.
|
|
43
|
-
*/
|
|
44
|
-
projectScope?: ProjectScope | undefined;
|
|
45
|
-
/**
|
|
46
|
-
* New expiration. Omit to keep current. Set `clear_expires_at = true`
|
|
47
|
-
*
|
|
48
|
-
* @remarks
|
|
49
|
-
* to remove an existing expiration (a zero Timestamp here would still
|
|
50
|
-
* mean "no change" because of optional semantics).
|
|
51
|
-
*/
|
|
52
|
-
expiresAt?: Date | undefined;
|
|
53
|
-
/**
|
|
54
|
-
* Force-clear the expiration. Mutually exclusive with `expires_at`.
|
|
55
|
-
*/
|
|
56
|
-
clearExpiresAt?: boolean | undefined;
|
|
57
|
-
/**
|
|
58
|
-
* Replacement MCP-gateway access restriction. Absent leaves the
|
|
59
|
-
*
|
|
60
|
-
* @remarks
|
|
61
|
-
* current value intact; an explicitly-set McpAccess replaces it —
|
|
62
|
-
* including an empty one (deny_all=false + empty list), which clears
|
|
63
|
-
* any existing restriction. See McpAccess.
|
|
64
|
-
*/
|
|
65
|
-
mcpAccess?: McpAccess | undefined;
|
|
66
|
-
};
|
|
67
|
-
|
|
68
|
-
/** @internal */
|
|
69
|
-
export type UpdateApiKeyRequest$Outbound = {
|
|
70
|
-
name?: string | undefined;
|
|
71
|
-
status?: string | undefined;
|
|
72
|
-
permission_mode?: string | undefined;
|
|
73
|
-
access?: { [k: string]: string } | undefined;
|
|
74
|
-
project_scope?: ProjectScope$Outbound | undefined;
|
|
75
|
-
expires_at?: string | undefined;
|
|
76
|
-
clear_expires_at?: boolean | undefined;
|
|
77
|
-
mcp_access?: McpAccess$Outbound | undefined;
|
|
78
|
-
};
|
|
79
|
-
|
|
80
|
-
/** @internal */
|
|
81
|
-
export const UpdateApiKeyRequest$outboundSchema: z.ZodType<
|
|
82
|
-
UpdateApiKeyRequest$Outbound,
|
|
83
|
-
z.ZodTypeDef,
|
|
84
|
-
UpdateApiKeyRequest
|
|
85
|
-
> = z.object({
|
|
86
|
-
name: z.string().optional(),
|
|
87
|
-
status: ApiKeyStatus$outboundSchema.optional(),
|
|
88
|
-
permissionMode: PermissionMode$outboundSchema.optional(),
|
|
89
|
-
access: z.record(AccessLevel$outboundSchema).optional(),
|
|
90
|
-
projectScope: ProjectScope$outboundSchema.optional(),
|
|
91
|
-
expiresAt: z.date().transform(v => v.toISOString()).optional(),
|
|
92
|
-
clearExpiresAt: z.boolean().optional(),
|
|
93
|
-
mcpAccess: McpAccess$outboundSchema.optional(),
|
|
94
|
-
}).transform((v) => {
|
|
95
|
-
return remap$(v, {
|
|
96
|
-
permissionMode: "permission_mode",
|
|
97
|
-
projectScope: "project_scope",
|
|
98
|
-
expiresAt: "expires_at",
|
|
99
|
-
clearExpiresAt: "clear_expires_at",
|
|
100
|
-
mcpAccess: "mcp_access",
|
|
101
|
-
});
|
|
102
|
-
});
|
|
103
|
-
|
|
104
|
-
export function updateApiKeyRequestToJSON(
|
|
105
|
-
updateApiKeyRequest: UpdateApiKeyRequest,
|
|
106
|
-
): string {
|
|
107
|
-
return JSON.stringify(
|
|
108
|
-
UpdateApiKeyRequest$outboundSchema.parse(updateApiKeyRequest),
|
|
109
|
-
);
|
|
110
|
-
}
|
|
@@ -1,35 +0,0 @@
|
|
|
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
|
-
|
|
8
|
-
export type UserOwner = {
|
|
9
|
-
/**
|
|
10
|
-
* User ID that owns the API key.
|
|
11
|
-
*/
|
|
12
|
-
userId: string;
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
/** @internal */
|
|
16
|
-
export type UserOwner$Outbound = {
|
|
17
|
-
user_id: string;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
/** @internal */
|
|
21
|
-
export const UserOwner$outboundSchema: z.ZodType<
|
|
22
|
-
UserOwner$Outbound,
|
|
23
|
-
z.ZodTypeDef,
|
|
24
|
-
UserOwner
|
|
25
|
-
> = z.object({
|
|
26
|
-
userId: z.string(),
|
|
27
|
-
}).transform((v) => {
|
|
28
|
-
return remap$(v, {
|
|
29
|
-
userId: "user_id",
|
|
30
|
-
});
|
|
31
|
-
});
|
|
32
|
-
|
|
33
|
-
export function userOwnerToJSON(userOwner: UserOwner): string {
|
|
34
|
-
return JSON.stringify(UserOwner$outboundSchema.parse(userOwner));
|
|
35
|
-
}
|