@meetkai/mka1 0.54.24 → 0.54.26
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 +302 -283
- package/bin/mcp-server.js +670 -11
- package/bin/mcp-server.js.map +24 -13
- package/dist/commonjs/funcs/authOrgsGetById.d.ts +19 -0
- package/dist/commonjs/funcs/authOrgsGetById.d.ts.map +1 -0
- package/dist/commonjs/funcs/authOrgsGetById.js +146 -0
- package/dist/commonjs/funcs/authOrgsGetById.js.map +1 -0
- package/dist/commonjs/funcs/authOrgsUpdate.d.ts +19 -0
- package/dist/commonjs/funcs/authOrgsUpdate.d.ts.map +1 -0
- package/dist/commonjs/funcs/authOrgsUpdate.js +149 -0
- package/dist/commonjs/funcs/authOrgsUpdate.js.map +1 -0
- package/dist/commonjs/funcs/llmBatchesCreate.d.ts +1 -1
- package/dist/commonjs/funcs/llmBatchesCreate.js +1 -1
- package/dist/commonjs/lib/config.d.ts +2 -2
- package/dist/commonjs/lib/config.js +2 -2
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.js +1 -1
- package/dist/commonjs/mcp-server/tools/llmBatchesCreate.js +1 -1
- package/dist/commonjs/mcp-server/tools/llmBatchesCreate.js.map +1 -1
- package/dist/commonjs/models/components/basicorganization.d.ts +41 -0
- package/dist/commonjs/models/components/basicorganization.d.ts.map +1 -0
- package/dist/commonjs/models/components/basicorganization.js +80 -0
- package/dist/commonjs/models/components/basicorganization.js.map +1 -0
- package/dist/commonjs/models/components/batchendpoint.d.ts +1 -0
- package/dist/commonjs/models/components/batchendpoint.d.ts.map +1 -1
- package/dist/commonjs/models/components/batchendpoint.js +1 -0
- package/dist/commonjs/models/components/batchendpoint.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +7 -0
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +7 -0
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/organizationcodeconfig.d.ts +20 -0
- package/dist/commonjs/models/components/organizationcodeconfig.d.ts.map +1 -0
- package/dist/commonjs/models/components/organizationcodeconfig.js +58 -0
- package/dist/commonjs/models/components/organizationcodeconfig.js.map +1 -0
- package/dist/commonjs/models/components/organizationmetadata.d.ts +23 -0
- package/dist/commonjs/models/components/organizationmetadata.d.ts.map +1 -0
- package/dist/commonjs/models/components/organizationmetadata.js +69 -0
- package/dist/commonjs/models/components/organizationmetadata.js.map +1 -0
- package/dist/commonjs/models/components/organizationmetadataoutput.d.ts +23 -0
- package/dist/commonjs/models/components/organizationmetadataoutput.d.ts.map +1 -0
- package/dist/commonjs/models/components/organizationmetadataoutput.js +69 -0
- package/dist/commonjs/models/components/organizationmetadataoutput.js.map +1 -0
- package/dist/commonjs/models/components/schema0.d.ts +17 -0
- package/dist/commonjs/models/components/schema0.d.ts.map +1 -0
- package/dist/commonjs/models/components/schema0.js +66 -0
- package/dist/commonjs/models/components/schema0.js.map +1 -0
- package/dist/commonjs/models/components/schema1.d.ts +17 -0
- package/dist/commonjs/models/components/schema1.d.ts.map +1 -0
- package/dist/commonjs/models/components/schema1.js +66 -0
- package/dist/commonjs/models/components/schema1.js.map +1 -0
- package/dist/commonjs/models/components/updateorganizationbody.d.ts +18 -0
- package/dist/commonjs/models/components/updateorganizationbody.d.ts.map +1 -0
- package/dist/commonjs/models/components/updateorganizationbody.js +59 -0
- package/dist/commonjs/models/components/updateorganizationbody.js.map +1 -0
- package/dist/commonjs/models/errors/getjwtfromkey.d.ts +9 -9
- package/dist/commonjs/models/errors/getjwtfromkey.d.ts.map +1 -1
- package/dist/commonjs/models/errors/getjwtfromkey.js +11 -11
- package/dist/commonjs/models/errors/getjwtfromkey.js.map +1 -1
- package/dist/commonjs/models/errors/getorgbyid.d.ts +211 -0
- package/dist/commonjs/models/errors/getorgbyid.d.ts.map +1 -0
- package/dist/commonjs/models/errors/getorgbyid.js +298 -0
- package/dist/commonjs/models/errors/getorgbyid.js.map +1 -0
- package/dist/commonjs/models/errors/index.d.ts +2 -0
- package/dist/commonjs/models/errors/index.d.ts.map +1 -1
- package/dist/commonjs/models/errors/index.js +2 -0
- package/dist/commonjs/models/errors/index.js.map +1 -1
- package/dist/commonjs/models/errors/updateorganization.d.ts +257 -0
- package/dist/commonjs/models/errors/updateorganization.d.ts.map +1 -0
- package/dist/commonjs/models/errors/updateorganization.js +353 -0
- package/dist/commonjs/models/errors/updateorganization.js.map +1 -0
- package/dist/commonjs/models/operations/getorgbyid.d.ts +37 -0
- package/dist/commonjs/models/operations/getorgbyid.d.ts.map +1 -0
- package/dist/commonjs/models/operations/getorgbyid.js +87 -0
- package/dist/commonjs/models/operations/getorgbyid.js.map +1 -0
- package/dist/commonjs/models/operations/index.d.ts +2 -0
- package/dist/commonjs/models/operations/index.d.ts.map +1 -1
- package/dist/commonjs/models/operations/index.js +2 -0
- package/dist/commonjs/models/operations/index.js.map +1 -1
- package/dist/commonjs/models/operations/updateorganization.d.ts +40 -0
- package/dist/commonjs/models/operations/updateorganization.d.ts.map +1 -0
- package/dist/commonjs/models/operations/updateorganization.js +92 -0
- package/dist/commonjs/models/operations/updateorganization.js.map +1 -0
- package/dist/commonjs/react-query/authOrgsGetById.core.d.ts +15 -0
- package/dist/commonjs/react-query/authOrgsGetById.core.d.ts.map +1 -0
- package/dist/commonjs/react-query/authOrgsGetById.core.js +36 -0
- package/dist/commonjs/react-query/authOrgsGetById.core.js.map +1 -0
- package/dist/commonjs/react-query/authOrgsGetById.d.ts +39 -0
- package/dist/commonjs/react-query/authOrgsGetById.d.ts.map +1 -0
- package/dist/commonjs/react-query/authOrgsGetById.js +60 -0
- package/dist/commonjs/react-query/authOrgsGetById.js.map +1 -0
- package/dist/commonjs/react-query/authOrgsUpdate.d.ts +31 -0
- package/dist/commonjs/react-query/authOrgsUpdate.d.ts.map +1 -0
- package/dist/commonjs/react-query/authOrgsUpdate.js +47 -0
- package/dist/commonjs/react-query/authOrgsUpdate.js.map +1 -0
- package/dist/commonjs/react-query/index.d.ts +2 -0
- package/dist/commonjs/react-query/index.d.ts.map +1 -1
- package/dist/commonjs/react-query/index.js +2 -0
- package/dist/commonjs/react-query/index.js.map +1 -1
- package/dist/commonjs/react-query/llmBatchesCreate.d.ts +1 -1
- package/dist/commonjs/react-query/llmBatchesCreate.js +1 -1
- package/dist/commonjs/sdk/batches.d.ts +1 -1
- package/dist/commonjs/sdk/batches.js +1 -1
- package/dist/commonjs/sdk/orgs.d.ts +15 -0
- package/dist/commonjs/sdk/orgs.d.ts.map +1 -1
- package/dist/commonjs/sdk/orgs.js +20 -0
- package/dist/commonjs/sdk/orgs.js.map +1 -1
- package/dist/esm/funcs/authOrgsGetById.d.ts +19 -0
- package/dist/esm/funcs/authOrgsGetById.d.ts.map +1 -0
- package/dist/esm/funcs/authOrgsGetById.js +110 -0
- package/dist/esm/funcs/authOrgsGetById.js.map +1 -0
- package/dist/esm/funcs/authOrgsUpdate.d.ts +19 -0
- package/dist/esm/funcs/authOrgsUpdate.d.ts.map +1 -0
- package/dist/esm/funcs/authOrgsUpdate.js +113 -0
- package/dist/esm/funcs/authOrgsUpdate.js.map +1 -0
- package/dist/esm/funcs/llmBatchesCreate.d.ts +1 -1
- package/dist/esm/funcs/llmBatchesCreate.js +1 -1
- package/dist/esm/lib/config.d.ts +2 -2
- package/dist/esm/lib/config.js +2 -2
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.js +1 -1
- package/dist/esm/mcp-server/tools/llmBatchesCreate.js +1 -1
- package/dist/esm/mcp-server/tools/llmBatchesCreate.js.map +1 -1
- package/dist/esm/models/components/basicorganization.d.ts +41 -0
- package/dist/esm/models/components/basicorganization.d.ts.map +1 -0
- package/dist/esm/models/components/basicorganization.js +42 -0
- package/dist/esm/models/components/basicorganization.js.map +1 -0
- package/dist/esm/models/components/batchendpoint.d.ts +1 -0
- package/dist/esm/models/components/batchendpoint.d.ts.map +1 -1
- package/dist/esm/models/components/batchendpoint.js +1 -0
- package/dist/esm/models/components/batchendpoint.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +7 -0
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +7 -0
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/organizationcodeconfig.d.ts +20 -0
- package/dist/esm/models/components/organizationcodeconfig.d.ts.map +1 -0
- package/dist/esm/models/components/organizationcodeconfig.js +20 -0
- package/dist/esm/models/components/organizationcodeconfig.js.map +1 -0
- package/dist/esm/models/components/organizationmetadata.d.ts +23 -0
- package/dist/esm/models/components/organizationmetadata.d.ts.map +1 -0
- package/dist/esm/models/components/organizationmetadata.js +31 -0
- package/dist/esm/models/components/organizationmetadata.js.map +1 -0
- package/dist/esm/models/components/organizationmetadataoutput.d.ts +23 -0
- package/dist/esm/models/components/organizationmetadataoutput.d.ts.map +1 -0
- package/dist/esm/models/components/organizationmetadataoutput.js +31 -0
- package/dist/esm/models/components/organizationmetadataoutput.js.map +1 -0
- package/dist/esm/models/components/schema0.d.ts +17 -0
- package/dist/esm/models/components/schema0.d.ts.map +1 -0
- package/dist/esm/models/components/schema0.js +28 -0
- package/dist/esm/models/components/schema0.js.map +1 -0
- package/dist/esm/models/components/schema1.d.ts +17 -0
- package/dist/esm/models/components/schema1.d.ts.map +1 -0
- package/dist/esm/models/components/schema1.js +28 -0
- package/dist/esm/models/components/schema1.js.map +1 -0
- package/dist/esm/models/components/updateorganizationbody.d.ts +18 -0
- package/dist/esm/models/components/updateorganizationbody.d.ts.map +1 -0
- package/dist/esm/models/components/updateorganizationbody.js +21 -0
- package/dist/esm/models/components/updateorganizationbody.js.map +1 -0
- package/dist/esm/models/errors/getjwtfromkey.d.ts +9 -9
- package/dist/esm/models/errors/getjwtfromkey.d.ts.map +1 -1
- package/dist/esm/models/errors/getjwtfromkey.js +8 -8
- package/dist/esm/models/errors/getjwtfromkey.js.map +1 -1
- package/dist/esm/models/errors/getorgbyid.d.ts +211 -0
- package/dist/esm/models/errors/getorgbyid.d.ts.map +1 -0
- package/dist/esm/models/errors/getorgbyid.js +254 -0
- package/dist/esm/models/errors/getorgbyid.js.map +1 -0
- package/dist/esm/models/errors/index.d.ts +2 -0
- package/dist/esm/models/errors/index.d.ts.map +1 -1
- package/dist/esm/models/errors/index.js +2 -0
- package/dist/esm/models/errors/index.js.map +1 -1
- package/dist/esm/models/errors/updateorganization.d.ts +257 -0
- package/dist/esm/models/errors/updateorganization.d.ts.map +1 -0
- package/dist/esm/models/errors/updateorganization.js +306 -0
- package/dist/esm/models/errors/updateorganization.js.map +1 -0
- package/dist/esm/models/operations/getorgbyid.d.ts +37 -0
- package/dist/esm/models/operations/getorgbyid.d.ts.map +1 -0
- package/dist/esm/models/operations/getorgbyid.js +47 -0
- package/dist/esm/models/operations/getorgbyid.js.map +1 -0
- package/dist/esm/models/operations/index.d.ts +2 -0
- package/dist/esm/models/operations/index.d.ts.map +1 -1
- package/dist/esm/models/operations/index.js +2 -0
- package/dist/esm/models/operations/index.js.map +1 -1
- package/dist/esm/models/operations/updateorganization.d.ts +40 -0
- package/dist/esm/models/operations/updateorganization.d.ts.map +1 -0
- package/dist/esm/models/operations/updateorganization.js +52 -0
- package/dist/esm/models/operations/updateorganization.js.map +1 -0
- package/dist/esm/react-query/authOrgsGetById.core.d.ts +15 -0
- package/dist/esm/react-query/authOrgsGetById.core.d.ts.map +1 -0
- package/dist/esm/react-query/authOrgsGetById.core.js +31 -0
- package/dist/esm/react-query/authOrgsGetById.core.js.map +1 -0
- package/dist/esm/react-query/authOrgsGetById.d.ts +39 -0
- package/dist/esm/react-query/authOrgsGetById.d.ts.map +1 -0
- package/dist/esm/react-query/authOrgsGetById.js +50 -0
- package/dist/esm/react-query/authOrgsGetById.js.map +1 -0
- package/dist/esm/react-query/authOrgsUpdate.d.ts +31 -0
- package/dist/esm/react-query/authOrgsUpdate.d.ts.map +1 -0
- package/dist/esm/react-query/authOrgsUpdate.js +42 -0
- package/dist/esm/react-query/authOrgsUpdate.js.map +1 -0
- package/dist/esm/react-query/index.d.ts +2 -0
- package/dist/esm/react-query/index.d.ts.map +1 -1
- package/dist/esm/react-query/index.js +2 -0
- package/dist/esm/react-query/index.js.map +1 -1
- package/dist/esm/react-query/llmBatchesCreate.d.ts +1 -1
- package/dist/esm/react-query/llmBatchesCreate.js +1 -1
- package/dist/esm/sdk/batches.d.ts +1 -1
- package/dist/esm/sdk/batches.js +1 -1
- package/dist/esm/sdk/orgs.d.ts +15 -0
- package/dist/esm/sdk/orgs.d.ts.map +1 -1
- package/dist/esm/sdk/orgs.js +20 -0
- package/dist/esm/sdk/orgs.js.map +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/authOrgsGetById.ts +251 -0
- package/src/funcs/authOrgsUpdate.ts +264 -0
- package/src/funcs/llmBatchesCreate.ts +1 -1
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/mcp-server/tools/llmBatchesCreate.ts +1 -1
- package/src/models/components/basicorganization.ts +100 -0
- package/src/models/components/batchendpoint.ts +1 -0
- package/src/models/components/index.ts +7 -0
- package/src/models/components/organizationcodeconfig.ts +54 -0
- package/src/models/components/organizationmetadata.ts +80 -0
- package/src/models/components/organizationmetadataoutput.ts +80 -0
- package/src/models/components/schema0.ts +55 -0
- package/src/models/components/schema1.ts +55 -0
- package/src/models/components/updateorganizationbody.ts +57 -0
- package/src/models/errors/getjwtfromkey.ts +28 -21
- package/src/models/errors/getorgbyid.ts +499 -0
- package/src/models/errors/index.ts +2 -0
- package/src/models/errors/updateorganization.ts +631 -0
- package/src/models/operations/getorgbyid.ts +114 -0
- package/src/models/operations/index.ts +2 -0
- package/src/models/operations/updateorganization.ts +121 -0
- package/src/react-query/authOrgsGetById.core.ts +78 -0
- package/src/react-query/authOrgsGetById.ts +148 -0
- package/src/react-query/authOrgsUpdate.ts +122 -0
- package/src/react-query/index.ts +2 -0
- package/src/react-query/llmBatchesCreate.ts +1 -1
- package/src/sdk/batches.ts +1 -1
- package/src/sdk/orgs.ts +41 -0
|
@@ -0,0 +1,264 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { SDKCore } from "../core.js";
|
|
6
|
+
import { encodeJSON, encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import { matchStatusCode } from "../lib/http.js";
|
|
8
|
+
import * as M from "../lib/matchers.js";
|
|
9
|
+
import { compactMap } from "../lib/primitives.js";
|
|
10
|
+
import { safeParse } from "../lib/schemas.js";
|
|
11
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
12
|
+
import { resolveSecurity } from "../lib/security.js";
|
|
13
|
+
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import * as components from "../models/components/index.js";
|
|
15
|
+
import {
|
|
16
|
+
ConnectionError,
|
|
17
|
+
InvalidRequestError,
|
|
18
|
+
RequestAbortedError,
|
|
19
|
+
RequestTimeoutError,
|
|
20
|
+
UnexpectedClientError,
|
|
21
|
+
} from "../models/errors/httpclienterrors.js";
|
|
22
|
+
import * as errors from "../models/errors/index.js";
|
|
23
|
+
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
24
|
+
import { SDKError } from "../models/errors/sdkerror.js";
|
|
25
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
26
|
+
import * as operations from "../models/operations/index.js";
|
|
27
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
28
|
+
import { Result } from "../types/fp.js";
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Patch organization metadata (cluster-admin)
|
|
32
|
+
*
|
|
33
|
+
* @remarks
|
|
34
|
+
* Merges supplied top-level metadata keys while preserving omitted siblings. metadata.codeConfig accepts one releaseManifestUrl; codeConfig:null removes that override.
|
|
35
|
+
*/
|
|
36
|
+
export function authOrgsUpdate(
|
|
37
|
+
client: SDKCore,
|
|
38
|
+
security: operations.UpdateOrganizationSecurity,
|
|
39
|
+
request: operations.UpdateOrganizationRequest,
|
|
40
|
+
options?: RequestOptions,
|
|
41
|
+
): APIPromise<
|
|
42
|
+
Result<
|
|
43
|
+
components.BasicOrganization,
|
|
44
|
+
| errors.UpdateOrganizationResponseBody
|
|
45
|
+
| errors.UpdateOrganizationAuthOrgsResponseBody
|
|
46
|
+
| errors.UpdateOrganizationAuthOrgsResponseResponseBody
|
|
47
|
+
| errors.UpdateOrganizationAuthOrgsResponse404ResponseBody
|
|
48
|
+
| errors.UpdateOrganizationAuthOrgsResponse409ResponseBody
|
|
49
|
+
| errors.UpdateOrganizationAuthOrgsResponse410ResponseBody
|
|
50
|
+
| errors.UpdateOrganizationAuthOrgsResponse413ResponseBody
|
|
51
|
+
| errors.UpdateOrganizationAuthOrgsResponse429ResponseBody
|
|
52
|
+
| errors.UpdateOrganizationAuthOrgsResponse500ResponseBody
|
|
53
|
+
| SDKError
|
|
54
|
+
| ResponseValidationError
|
|
55
|
+
| ConnectionError
|
|
56
|
+
| RequestAbortedError
|
|
57
|
+
| RequestTimeoutError
|
|
58
|
+
| InvalidRequestError
|
|
59
|
+
| UnexpectedClientError
|
|
60
|
+
| SDKValidationError
|
|
61
|
+
>
|
|
62
|
+
> {
|
|
63
|
+
return new APIPromise($do(
|
|
64
|
+
client,
|
|
65
|
+
security,
|
|
66
|
+
request,
|
|
67
|
+
options,
|
|
68
|
+
));
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
async function $do(
|
|
72
|
+
client: SDKCore,
|
|
73
|
+
security: operations.UpdateOrganizationSecurity,
|
|
74
|
+
request: operations.UpdateOrganizationRequest,
|
|
75
|
+
options?: RequestOptions,
|
|
76
|
+
): Promise<
|
|
77
|
+
[
|
|
78
|
+
Result<
|
|
79
|
+
components.BasicOrganization,
|
|
80
|
+
| errors.UpdateOrganizationResponseBody
|
|
81
|
+
| errors.UpdateOrganizationAuthOrgsResponseBody
|
|
82
|
+
| errors.UpdateOrganizationAuthOrgsResponseResponseBody
|
|
83
|
+
| errors.UpdateOrganizationAuthOrgsResponse404ResponseBody
|
|
84
|
+
| errors.UpdateOrganizationAuthOrgsResponse409ResponseBody
|
|
85
|
+
| errors.UpdateOrganizationAuthOrgsResponse410ResponseBody
|
|
86
|
+
| errors.UpdateOrganizationAuthOrgsResponse413ResponseBody
|
|
87
|
+
| errors.UpdateOrganizationAuthOrgsResponse429ResponseBody
|
|
88
|
+
| errors.UpdateOrganizationAuthOrgsResponse500ResponseBody
|
|
89
|
+
| SDKError
|
|
90
|
+
| ResponseValidationError
|
|
91
|
+
| ConnectionError
|
|
92
|
+
| RequestAbortedError
|
|
93
|
+
| RequestTimeoutError
|
|
94
|
+
| InvalidRequestError
|
|
95
|
+
| UnexpectedClientError
|
|
96
|
+
| SDKValidationError
|
|
97
|
+
>,
|
|
98
|
+
APICall,
|
|
99
|
+
]
|
|
100
|
+
> {
|
|
101
|
+
const parsed = safeParse(
|
|
102
|
+
request,
|
|
103
|
+
(value) => operations.UpdateOrganizationRequest$outboundSchema.parse(value),
|
|
104
|
+
"Input validation failed",
|
|
105
|
+
);
|
|
106
|
+
if (!parsed.ok) {
|
|
107
|
+
return [parsed, { status: "invalid" }];
|
|
108
|
+
}
|
|
109
|
+
const payload = parsed.value;
|
|
110
|
+
const body = encodeJSON("body", payload.UpdateOrganizationBody, {
|
|
111
|
+
explode: true,
|
|
112
|
+
});
|
|
113
|
+
|
|
114
|
+
const pathParams = {
|
|
115
|
+
orgId: encodeSimple("orgId", payload.orgId, {
|
|
116
|
+
explode: false,
|
|
117
|
+
charEncoding: "percent",
|
|
118
|
+
}),
|
|
119
|
+
};
|
|
120
|
+
const path = pathToFunc("/api/v1/authentication/orgs/{orgId}")(pathParams);
|
|
121
|
+
|
|
122
|
+
const headers = new Headers(compactMap({
|
|
123
|
+
"Content-Type": "application/json",
|
|
124
|
+
Accept: "application/json",
|
|
125
|
+
"X-On-Behalf-Of": encodeSimple(
|
|
126
|
+
"X-On-Behalf-Of",
|
|
127
|
+
payload["X-On-Behalf-Of"],
|
|
128
|
+
{ explode: false, charEncoding: "none" },
|
|
129
|
+
),
|
|
130
|
+
}));
|
|
131
|
+
|
|
132
|
+
const requestSecurity = resolveSecurity(
|
|
133
|
+
[
|
|
134
|
+
{
|
|
135
|
+
fieldName: "Authorization",
|
|
136
|
+
type: "http:bearer",
|
|
137
|
+
value: security?.bearerAuth,
|
|
138
|
+
},
|
|
139
|
+
],
|
|
140
|
+
[
|
|
141
|
+
{
|
|
142
|
+
fieldName: "__Secure-mka1-auth-v2.session_token",
|
|
143
|
+
type: "apiKey:cookie",
|
|
144
|
+
value: security?.sessionCookie,
|
|
145
|
+
},
|
|
146
|
+
],
|
|
147
|
+
);
|
|
148
|
+
|
|
149
|
+
const context = {
|
|
150
|
+
options: client._options,
|
|
151
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
152
|
+
operationID: "updateOrganization",
|
|
153
|
+
oAuth2Scopes: null,
|
|
154
|
+
|
|
155
|
+
resolvedSecurity: requestSecurity,
|
|
156
|
+
|
|
157
|
+
securitySource: security,
|
|
158
|
+
retryConfig: options?.retries
|
|
159
|
+
|| client._options.retryConfig
|
|
160
|
+
|| {
|
|
161
|
+
strategy: "backoff",
|
|
162
|
+
backoff: {
|
|
163
|
+
initialInterval: 500,
|
|
164
|
+
maxInterval: 5000,
|
|
165
|
+
exponent: 1.5,
|
|
166
|
+
maxElapsedTime: 15000,
|
|
167
|
+
},
|
|
168
|
+
retryConnectionErrors: true,
|
|
169
|
+
}
|
|
170
|
+
|| { strategy: "none" },
|
|
171
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
const requestRes = client._createRequest(context, {
|
|
175
|
+
security: requestSecurity,
|
|
176
|
+
method: "PATCH",
|
|
177
|
+
baseURL: options?.serverURL,
|
|
178
|
+
path: path,
|
|
179
|
+
headers: headers,
|
|
180
|
+
body: body,
|
|
181
|
+
userAgent: client._options.userAgent,
|
|
182
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
183
|
+
}, options);
|
|
184
|
+
if (!requestRes.ok) {
|
|
185
|
+
return [requestRes, { status: "invalid" }];
|
|
186
|
+
}
|
|
187
|
+
const req = requestRes.value;
|
|
188
|
+
|
|
189
|
+
const doResult = await client._do(req, {
|
|
190
|
+
context,
|
|
191
|
+
isErrorStatusCode: (statusCode: number) =>
|
|
192
|
+
matchStatusCode({ status: statusCode } as Response, ["4XX", "5XX"]),
|
|
193
|
+
retryConfig: context.retryConfig,
|
|
194
|
+
retryCodes: context.retryCodes,
|
|
195
|
+
});
|
|
196
|
+
if (!doResult.ok) {
|
|
197
|
+
return [doResult, { status: "request-error", request: req }];
|
|
198
|
+
}
|
|
199
|
+
const response = doResult.value;
|
|
200
|
+
|
|
201
|
+
const responseFields = {
|
|
202
|
+
HttpMeta: { Response: response, Request: req },
|
|
203
|
+
};
|
|
204
|
+
|
|
205
|
+
const [result] = await M.match<
|
|
206
|
+
components.BasicOrganization,
|
|
207
|
+
| errors.UpdateOrganizationResponseBody
|
|
208
|
+
| errors.UpdateOrganizationAuthOrgsResponseBody
|
|
209
|
+
| errors.UpdateOrganizationAuthOrgsResponseResponseBody
|
|
210
|
+
| errors.UpdateOrganizationAuthOrgsResponse404ResponseBody
|
|
211
|
+
| errors.UpdateOrganizationAuthOrgsResponse409ResponseBody
|
|
212
|
+
| errors.UpdateOrganizationAuthOrgsResponse410ResponseBody
|
|
213
|
+
| errors.UpdateOrganizationAuthOrgsResponse413ResponseBody
|
|
214
|
+
| errors.UpdateOrganizationAuthOrgsResponse429ResponseBody
|
|
215
|
+
| errors.UpdateOrganizationAuthOrgsResponse500ResponseBody
|
|
216
|
+
| SDKError
|
|
217
|
+
| ResponseValidationError
|
|
218
|
+
| ConnectionError
|
|
219
|
+
| RequestAbortedError
|
|
220
|
+
| RequestTimeoutError
|
|
221
|
+
| InvalidRequestError
|
|
222
|
+
| UnexpectedClientError
|
|
223
|
+
| SDKValidationError
|
|
224
|
+
>(
|
|
225
|
+
M.json(200, components.BasicOrganization$inboundSchema),
|
|
226
|
+
M.jsonErr(400, errors.UpdateOrganizationResponseBody$inboundSchema),
|
|
227
|
+
M.jsonErr(401, errors.UpdateOrganizationAuthOrgsResponseBody$inboundSchema),
|
|
228
|
+
M.jsonErr(
|
|
229
|
+
403,
|
|
230
|
+
errors.UpdateOrganizationAuthOrgsResponseResponseBody$inboundSchema,
|
|
231
|
+
),
|
|
232
|
+
M.jsonErr(
|
|
233
|
+
404,
|
|
234
|
+
errors.UpdateOrganizationAuthOrgsResponse404ResponseBody$inboundSchema,
|
|
235
|
+
),
|
|
236
|
+
M.jsonErr(
|
|
237
|
+
409,
|
|
238
|
+
errors.UpdateOrganizationAuthOrgsResponse409ResponseBody$inboundSchema,
|
|
239
|
+
),
|
|
240
|
+
M.jsonErr(
|
|
241
|
+
410,
|
|
242
|
+
errors.UpdateOrganizationAuthOrgsResponse410ResponseBody$inboundSchema,
|
|
243
|
+
),
|
|
244
|
+
M.jsonErr(
|
|
245
|
+
413,
|
|
246
|
+
errors.UpdateOrganizationAuthOrgsResponse413ResponseBody$inboundSchema,
|
|
247
|
+
),
|
|
248
|
+
M.jsonErr(
|
|
249
|
+
429,
|
|
250
|
+
errors.UpdateOrganizationAuthOrgsResponse429ResponseBody$inboundSchema,
|
|
251
|
+
),
|
|
252
|
+
M.jsonErr(
|
|
253
|
+
500,
|
|
254
|
+
errors.UpdateOrganizationAuthOrgsResponse500ResponseBody$inboundSchema,
|
|
255
|
+
),
|
|
256
|
+
M.fail("4XX"),
|
|
257
|
+
M.fail("5XX"),
|
|
258
|
+
)(response, req, { extraFields: responseFields });
|
|
259
|
+
if (!result.ok) {
|
|
260
|
+
return [result, { status: "complete", request: req, response }];
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
return [result, { status: "complete", request: req, response }];
|
|
264
|
+
}
|
|
@@ -30,7 +30,7 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* Create a batch
|
|
31
31
|
*
|
|
32
32
|
* @remarks
|
|
33
|
-
* Creates and executes a batch from an uploaded JSONL file of requests. Each line must have custom_id, method, url, and body fields.
|
|
33
|
+
* Creates and executes a batch from an uploaded JSONL file of requests. Each line must have custom_id, method, url, and body fields. Text batches also require write:responses.
|
|
34
34
|
*
|
|
35
35
|
* If set, this operation will use {@link Security.bearerAuth} from the global security.
|
|
36
36
|
*/
|
package/src/lib/config.ts
CHANGED
|
@@ -65,7 +65,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
65
65
|
export const SDK_METADATA = {
|
|
66
66
|
language: "typescript",
|
|
67
67
|
openapiDocVersion: "1.1.0",
|
|
68
|
-
sdkVersion: "0.54.
|
|
68
|
+
sdkVersion: "0.54.26",
|
|
69
69
|
genVersion: "2.935.1",
|
|
70
|
-
userAgent: "speakeasy-sdk/typescript 0.54.
|
|
70
|
+
userAgent: "speakeasy-sdk/typescript 0.54.26 2.935.1 1.1.0 @meetkai/mka1",
|
|
71
71
|
} as const;
|
package/src/mcp-server/server.ts
CHANGED
|
@@ -14,7 +14,7 @@ export const tool$llmBatchesCreate: ToolDefinition<typeof args> = {
|
|
|
14
14
|
name: "llm-batches-create",
|
|
15
15
|
description: `Create a batch
|
|
16
16
|
|
|
17
|
-
Creates and executes a batch from an uploaded JSONL file of requests. Each line must have custom_id, method, url, and body fields.`,
|
|
17
|
+
Creates and executes a batch from an uploaded JSONL file of requests. Each line must have custom_id, method, url, and body fields. Text batches also require write:responses.`,
|
|
18
18
|
args,
|
|
19
19
|
tool: async (client, args, ctx) => {
|
|
20
20
|
const [result, apiCall] = await llmBatchesCreate(
|
|
@@ -0,0 +1,100 @@
|
|
|
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 { ClosedEnum } from "../../types/enums.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
OrganizationMetadataOutput,
|
|
12
|
+
OrganizationMetadataOutput$inboundSchema,
|
|
13
|
+
OrganizationMetadataOutput$Outbound,
|
|
14
|
+
OrganizationMetadataOutput$outboundSchema,
|
|
15
|
+
} from "./organizationmetadataoutput.js";
|
|
16
|
+
|
|
17
|
+
export const BasicOrganizationStatus = {
|
|
18
|
+
Active: "active",
|
|
19
|
+
Suspended: "suspended",
|
|
20
|
+
Deleted: "deleted",
|
|
21
|
+
} as const;
|
|
22
|
+
export type BasicOrganizationStatus = ClosedEnum<
|
|
23
|
+
typeof BasicOrganizationStatus
|
|
24
|
+
>;
|
|
25
|
+
|
|
26
|
+
export type BasicOrganization = {
|
|
27
|
+
id: string;
|
|
28
|
+
name: string;
|
|
29
|
+
slug: string;
|
|
30
|
+
logo: string | null;
|
|
31
|
+
createdAt: string;
|
|
32
|
+
status: BasicOrganizationStatus;
|
|
33
|
+
metadata: OrganizationMetadataOutput | null;
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
/** @internal */
|
|
37
|
+
export const BasicOrganizationStatus$inboundSchema: z.ZodNativeEnum<
|
|
38
|
+
typeof BasicOrganizationStatus
|
|
39
|
+
> = z.nativeEnum(BasicOrganizationStatus);
|
|
40
|
+
/** @internal */
|
|
41
|
+
export const BasicOrganizationStatus$outboundSchema: z.ZodNativeEnum<
|
|
42
|
+
typeof BasicOrganizationStatus
|
|
43
|
+
> = BasicOrganizationStatus$inboundSchema;
|
|
44
|
+
|
|
45
|
+
/** @internal */
|
|
46
|
+
export const BasicOrganization$inboundSchema: z.ZodType<
|
|
47
|
+
BasicOrganization,
|
|
48
|
+
z.ZodTypeDef,
|
|
49
|
+
unknown
|
|
50
|
+
> = z.object({
|
|
51
|
+
id: z.string(),
|
|
52
|
+
name: z.string(),
|
|
53
|
+
slug: z.string(),
|
|
54
|
+
logo: z.nullable(z.string()),
|
|
55
|
+
createdAt: z.string(),
|
|
56
|
+
status: BasicOrganizationStatus$inboundSchema,
|
|
57
|
+
metadata: z.nullable(OrganizationMetadataOutput$inboundSchema),
|
|
58
|
+
});
|
|
59
|
+
/** @internal */
|
|
60
|
+
export type BasicOrganization$Outbound = {
|
|
61
|
+
id: string;
|
|
62
|
+
name: string;
|
|
63
|
+
slug: string;
|
|
64
|
+
logo: string | null;
|
|
65
|
+
createdAt: string;
|
|
66
|
+
status: string;
|
|
67
|
+
metadata: OrganizationMetadataOutput$Outbound | null;
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
/** @internal */
|
|
71
|
+
export const BasicOrganization$outboundSchema: z.ZodType<
|
|
72
|
+
BasicOrganization$Outbound,
|
|
73
|
+
z.ZodTypeDef,
|
|
74
|
+
BasicOrganization
|
|
75
|
+
> = z.object({
|
|
76
|
+
id: z.string(),
|
|
77
|
+
name: z.string(),
|
|
78
|
+
slug: z.string(),
|
|
79
|
+
logo: z.nullable(z.string()),
|
|
80
|
+
createdAt: z.string(),
|
|
81
|
+
status: BasicOrganizationStatus$outboundSchema,
|
|
82
|
+
metadata: z.nullable(OrganizationMetadataOutput$outboundSchema),
|
|
83
|
+
});
|
|
84
|
+
|
|
85
|
+
export function basicOrganizationToJSON(
|
|
86
|
+
basicOrganization: BasicOrganization,
|
|
87
|
+
): string {
|
|
88
|
+
return JSON.stringify(
|
|
89
|
+
BasicOrganization$outboundSchema.parse(basicOrganization),
|
|
90
|
+
);
|
|
91
|
+
}
|
|
92
|
+
export function basicOrganizationFromJSON(
|
|
93
|
+
jsonString: string,
|
|
94
|
+
): SafeParseResult<BasicOrganization, SDKValidationError> {
|
|
95
|
+
return safeParse(
|
|
96
|
+
jsonString,
|
|
97
|
+
(x) => BasicOrganization$inboundSchema.parse(JSON.parse(x)),
|
|
98
|
+
`Failed to parse 'BasicOrganization' from JSON`,
|
|
99
|
+
);
|
|
100
|
+
}
|
|
@@ -7,6 +7,7 @@ import { ClosedEnum } from "../../types/enums.js";
|
|
|
7
7
|
|
|
8
8
|
export const BatchEndpoint = {
|
|
9
9
|
RootV1ChatCompletions: "/v1/chat/completions",
|
|
10
|
+
RootV1Responses: "/v1/responses",
|
|
10
11
|
RootV1Embeddings: "/v1/embeddings",
|
|
11
12
|
RootV1ImagesGenerations: "/v1/images/generations",
|
|
12
13
|
} as const;
|
|
@@ -34,6 +34,7 @@ export * from "./autoendpoint.js";
|
|
|
34
34
|
export * from "./balancedorgautomodel.js";
|
|
35
35
|
export * from "./banwordsconfig.js";
|
|
36
36
|
export * from "./banwordsguardrail.js";
|
|
37
|
+
export * from "./basicorganization.js";
|
|
37
38
|
export * from "./batchendpoint.js";
|
|
38
39
|
export * from "./batcherrordata.js";
|
|
39
40
|
export * from "./batcherrors.js";
|
|
@@ -404,6 +405,9 @@ export * from "./openaichatcompletionusage.js";
|
|
|
404
405
|
export * from "./openairequestmessage.js";
|
|
405
406
|
export * from "./openaitooldefinition.js";
|
|
406
407
|
export * from "./openpageaction.js";
|
|
408
|
+
export * from "./organizationcodeconfig.js";
|
|
409
|
+
export * from "./organizationmetadata.js";
|
|
410
|
+
export * from "./organizationmetadataoutput.js";
|
|
407
411
|
export * from "./orgautomodel.js";
|
|
408
412
|
export * from "./otherchunkingstrategy.js";
|
|
409
413
|
export * from "./outputaudioitem.js";
|
|
@@ -533,6 +537,8 @@ export * from "./sandboxusageoperation.js";
|
|
|
533
537
|
export * from "./sandboxusagepage.js";
|
|
534
538
|
export * from "./sandboxusageresult.js";
|
|
535
539
|
export * from "./saveenvironmentrequest.js";
|
|
540
|
+
export * from "./schema0.js";
|
|
541
|
+
export * from "./schema1.js";
|
|
536
542
|
export * from "./schemacreateresponse.js";
|
|
537
543
|
export * from "./schemadeleteresponse.js";
|
|
538
544
|
export * from "./schemagetresponse.js";
|
|
@@ -610,6 +616,7 @@ export * from "./updateguardrailsresponse.js";
|
|
|
610
616
|
export * from "./updatemcpserverrequest.js";
|
|
611
617
|
export * from "./updatememoryentryrequest.js";
|
|
612
618
|
export * from "./updatememorystorerequest.js";
|
|
619
|
+
export * from "./updateorganizationbody.js";
|
|
613
620
|
export * from "./updatepromptresponse.js";
|
|
614
621
|
export * from "./updateresponserequest.js";
|
|
615
622
|
export * from "./updatevectorstorefileattributesrequest.js";
|
|
@@ -0,0 +1,54 @@
|
|
|
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 OrganizationCodeConfig = {
|
|
11
|
+
/**
|
|
12
|
+
* Canonical public HTTPS URL ending in /latest/manifest.json. Credentials, non-default ports, queries, fragments, path-normalization spellings, and private or reserved hosts are rejected.
|
|
13
|
+
*/
|
|
14
|
+
releaseManifestUrl: string;
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
/** @internal */
|
|
18
|
+
export const OrganizationCodeConfig$inboundSchema: z.ZodType<
|
|
19
|
+
OrganizationCodeConfig,
|
|
20
|
+
z.ZodTypeDef,
|
|
21
|
+
unknown
|
|
22
|
+
> = z.object({
|
|
23
|
+
releaseManifestUrl: z.string(),
|
|
24
|
+
});
|
|
25
|
+
/** @internal */
|
|
26
|
+
export type OrganizationCodeConfig$Outbound = {
|
|
27
|
+
releaseManifestUrl: string;
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
/** @internal */
|
|
31
|
+
export const OrganizationCodeConfig$outboundSchema: z.ZodType<
|
|
32
|
+
OrganizationCodeConfig$Outbound,
|
|
33
|
+
z.ZodTypeDef,
|
|
34
|
+
OrganizationCodeConfig
|
|
35
|
+
> = z.object({
|
|
36
|
+
releaseManifestUrl: z.string(),
|
|
37
|
+
});
|
|
38
|
+
|
|
39
|
+
export function organizationCodeConfigToJSON(
|
|
40
|
+
organizationCodeConfig: OrganizationCodeConfig,
|
|
41
|
+
): string {
|
|
42
|
+
return JSON.stringify(
|
|
43
|
+
OrganizationCodeConfig$outboundSchema.parse(organizationCodeConfig),
|
|
44
|
+
);
|
|
45
|
+
}
|
|
46
|
+
export function organizationCodeConfigFromJSON(
|
|
47
|
+
jsonString: string,
|
|
48
|
+
): SafeParseResult<OrganizationCodeConfig, SDKValidationError> {
|
|
49
|
+
return safeParse(
|
|
50
|
+
jsonString,
|
|
51
|
+
(x) => OrganizationCodeConfig$inboundSchema.parse(JSON.parse(x)),
|
|
52
|
+
`Failed to parse 'OrganizationCodeConfig' from JSON`,
|
|
53
|
+
);
|
|
54
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
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 {
|
|
8
|
+
collectExtraKeys as collectExtraKeys$,
|
|
9
|
+
safeParse,
|
|
10
|
+
} from "../../lib/schemas.js";
|
|
11
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
12
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
13
|
+
import {
|
|
14
|
+
OrganizationCodeConfig,
|
|
15
|
+
OrganizationCodeConfig$inboundSchema,
|
|
16
|
+
OrganizationCodeConfig$Outbound,
|
|
17
|
+
OrganizationCodeConfig$outboundSchema,
|
|
18
|
+
} from "./organizationcodeconfig.js";
|
|
19
|
+
import {
|
|
20
|
+
Schema0,
|
|
21
|
+
Schema0$inboundSchema,
|
|
22
|
+
Schema0$outboundSchema,
|
|
23
|
+
} from "./schema0.js";
|
|
24
|
+
|
|
25
|
+
export type OrganizationMetadata = {
|
|
26
|
+
codeConfig?: OrganizationCodeConfig | null | undefined;
|
|
27
|
+
additionalProperties?: { [k: string]: Schema0 | null } | undefined;
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
/** @internal */
|
|
31
|
+
export const OrganizationMetadata$inboundSchema: z.ZodType<
|
|
32
|
+
OrganizationMetadata,
|
|
33
|
+
z.ZodTypeDef,
|
|
34
|
+
unknown
|
|
35
|
+
> = collectExtraKeys$(
|
|
36
|
+
z.object({
|
|
37
|
+
codeConfig: z.nullable(OrganizationCodeConfig$inboundSchema).optional(),
|
|
38
|
+
}).catchall(Schema0$inboundSchema),
|
|
39
|
+
"additionalProperties",
|
|
40
|
+
true,
|
|
41
|
+
);
|
|
42
|
+
/** @internal */
|
|
43
|
+
export type OrganizationMetadata$Outbound = {
|
|
44
|
+
codeConfig?: OrganizationCodeConfig$Outbound | null | undefined;
|
|
45
|
+
[additionalProperties: string]: unknown;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
/** @internal */
|
|
49
|
+
export const OrganizationMetadata$outboundSchema: z.ZodType<
|
|
50
|
+
OrganizationMetadata$Outbound,
|
|
51
|
+
z.ZodTypeDef,
|
|
52
|
+
OrganizationMetadata
|
|
53
|
+
> = z.object({
|
|
54
|
+
codeConfig: z.nullable(OrganizationCodeConfig$outboundSchema).optional(),
|
|
55
|
+
additionalProperties: z.record(z.nullable(Schema0$outboundSchema)).optional(),
|
|
56
|
+
}).transform((v) => {
|
|
57
|
+
return {
|
|
58
|
+
...v.additionalProperties,
|
|
59
|
+
...remap$(v, {
|
|
60
|
+
additionalProperties: null,
|
|
61
|
+
}),
|
|
62
|
+
};
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
export function organizationMetadataToJSON(
|
|
66
|
+
organizationMetadata: OrganizationMetadata,
|
|
67
|
+
): string {
|
|
68
|
+
return JSON.stringify(
|
|
69
|
+
OrganizationMetadata$outboundSchema.parse(organizationMetadata),
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
export function organizationMetadataFromJSON(
|
|
73
|
+
jsonString: string,
|
|
74
|
+
): SafeParseResult<OrganizationMetadata, SDKValidationError> {
|
|
75
|
+
return safeParse(
|
|
76
|
+
jsonString,
|
|
77
|
+
(x) => OrganizationMetadata$inboundSchema.parse(JSON.parse(x)),
|
|
78
|
+
`Failed to parse 'OrganizationMetadata' from JSON`,
|
|
79
|
+
);
|
|
80
|
+
}
|
|
@@ -0,0 +1,80 @@
|
|
|
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 {
|
|
8
|
+
collectExtraKeys as collectExtraKeys$,
|
|
9
|
+
safeParse,
|
|
10
|
+
} from "../../lib/schemas.js";
|
|
11
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
12
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
13
|
+
import {
|
|
14
|
+
OrganizationCodeConfig,
|
|
15
|
+
OrganizationCodeConfig$inboundSchema,
|
|
16
|
+
OrganizationCodeConfig$Outbound,
|
|
17
|
+
OrganizationCodeConfig$outboundSchema,
|
|
18
|
+
} from "./organizationcodeconfig.js";
|
|
19
|
+
import {
|
|
20
|
+
Schema1,
|
|
21
|
+
Schema1$inboundSchema,
|
|
22
|
+
Schema1$outboundSchema,
|
|
23
|
+
} from "./schema1.js";
|
|
24
|
+
|
|
25
|
+
export type OrganizationMetadataOutput = {
|
|
26
|
+
codeConfig?: OrganizationCodeConfig | null | undefined;
|
|
27
|
+
additionalProperties?: { [k: string]: Schema1 | null } | undefined;
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
/** @internal */
|
|
31
|
+
export const OrganizationMetadataOutput$inboundSchema: z.ZodType<
|
|
32
|
+
OrganizationMetadataOutput,
|
|
33
|
+
z.ZodTypeDef,
|
|
34
|
+
unknown
|
|
35
|
+
> = collectExtraKeys$(
|
|
36
|
+
z.object({
|
|
37
|
+
codeConfig: z.nullable(OrganizationCodeConfig$inboundSchema).optional(),
|
|
38
|
+
}).catchall(Schema1$inboundSchema),
|
|
39
|
+
"additionalProperties",
|
|
40
|
+
true,
|
|
41
|
+
);
|
|
42
|
+
/** @internal */
|
|
43
|
+
export type OrganizationMetadataOutput$Outbound = {
|
|
44
|
+
codeConfig?: OrganizationCodeConfig$Outbound | null | undefined;
|
|
45
|
+
[additionalProperties: string]: unknown;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
/** @internal */
|
|
49
|
+
export const OrganizationMetadataOutput$outboundSchema: z.ZodType<
|
|
50
|
+
OrganizationMetadataOutput$Outbound,
|
|
51
|
+
z.ZodTypeDef,
|
|
52
|
+
OrganizationMetadataOutput
|
|
53
|
+
> = z.object({
|
|
54
|
+
codeConfig: z.nullable(OrganizationCodeConfig$outboundSchema).optional(),
|
|
55
|
+
additionalProperties: z.record(z.nullable(Schema1$outboundSchema)).optional(),
|
|
56
|
+
}).transform((v) => {
|
|
57
|
+
return {
|
|
58
|
+
...v.additionalProperties,
|
|
59
|
+
...remap$(v, {
|
|
60
|
+
additionalProperties: null,
|
|
61
|
+
}),
|
|
62
|
+
};
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
export function organizationMetadataOutputToJSON(
|
|
66
|
+
organizationMetadataOutput: OrganizationMetadataOutput,
|
|
67
|
+
): string {
|
|
68
|
+
return JSON.stringify(
|
|
69
|
+
OrganizationMetadataOutput$outboundSchema.parse(organizationMetadataOutput),
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
export function organizationMetadataOutputFromJSON(
|
|
73
|
+
jsonString: string,
|
|
74
|
+
): SafeParseResult<OrganizationMetadataOutput, SDKValidationError> {
|
|
75
|
+
return safeParse(
|
|
76
|
+
jsonString,
|
|
77
|
+
(x) => OrganizationMetadataOutput$inboundSchema.parse(JSON.parse(x)),
|
|
78
|
+
`Failed to parse 'OrganizationMetadataOutput' from JSON`,
|
|
79
|
+
);
|
|
80
|
+
}
|