@openrouter/sdk 1.5.116 → 1.5.118
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/esm/funcs/scimCreate.d.ts +3 -1
- package/esm/funcs/scimCreate.js +3 -1
- package/esm/funcs/scimCreateSyncJob.d.ts +3 -1
- package/esm/funcs/scimCreateSyncJob.js +3 -1
- package/esm/funcs/scimDelete.d.ts +3 -1
- package/esm/funcs/scimDelete.js +3 -1
- package/esm/funcs/scimUpdate.d.ts +3 -1
- package/esm/funcs/scimUpdate.js +3 -1
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/models/createworkspacerequest.d.ts +4 -4
- package/esm/models/imagegenerationrequest.d.ts +18 -0
- package/esm/models/imagegenerationrequest.js +12 -0
- package/esm/models/imagegenerationresponse.d.ts +10 -2
- package/esm/models/imagegenerationresponse.js +7 -1
- package/esm/models/updateworkspacerequest.d.ts +4 -4
- package/esm/sdk/scim.d.ts +12 -4
- package/esm/sdk/scim.js +12 -4
- package/jsr.json +1 -1
- package/package.json +5 -5
|
@@ -13,7 +13,9 @@ import { Result } from "../types/fp.js";
|
|
|
13
13
|
* Create a SCIM group mapping
|
|
14
14
|
*
|
|
15
15
|
* @remarks
|
|
16
|
-
* Create a SCIM group-to-workspace role mapping.
|
|
16
|
+
* Create a SCIM group-to-workspace role mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
17
|
+
*
|
|
18
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
17
19
|
*/
|
|
18
20
|
export declare function scimCreate(client: OpenRouterCore, request: operations.CreateScimGroupMappingRequest, options?: RequestOptions): APIPromise<Result<models.CreateScimGroupMappingResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.ConflictResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
19
21
|
//# sourceMappingURL=scimCreate.d.ts.map
|
package/esm/funcs/scimCreate.js
CHANGED
|
@@ -16,7 +16,9 @@ import { APIPromise } from "../types/async.js";
|
|
|
16
16
|
* Create a SCIM group mapping
|
|
17
17
|
*
|
|
18
18
|
* @remarks
|
|
19
|
-
* Create a SCIM group-to-workspace role mapping.
|
|
19
|
+
* Create a SCIM group-to-workspace role mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
20
|
+
*
|
|
21
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
20
22
|
*/
|
|
21
23
|
export function scimCreate(client, request, options) {
|
|
22
24
|
return new APIPromise($do(client, request, options));
|
|
@@ -12,7 +12,9 @@ import { Result } from "../types/fp.js";
|
|
|
12
12
|
* Start a SCIM directory sync
|
|
13
13
|
*
|
|
14
14
|
* @remarks
|
|
15
|
-
* Start a SCIM directory sync.
|
|
15
|
+
* Start a SCIM directory sync. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
16
|
+
*
|
|
17
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
16
18
|
*/
|
|
17
19
|
export declare function scimCreateSyncJob(client: OpenRouterCore, request?: operations.CreateScimSyncJobRequest | undefined, options?: RequestOptions): APIPromise<Result<operations.CreateScimSyncJobResponse, errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
18
20
|
//# sourceMappingURL=scimCreateSyncJob.d.ts.map
|
|
@@ -15,7 +15,9 @@ import { APIPromise } from "../types/async.js";
|
|
|
15
15
|
* Start a SCIM directory sync
|
|
16
16
|
*
|
|
17
17
|
* @remarks
|
|
18
|
-
* Start a SCIM directory sync.
|
|
18
|
+
* Start a SCIM directory sync. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
19
|
+
*
|
|
20
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
19
21
|
*/
|
|
20
22
|
export function scimCreateSyncJob(client, request, options) {
|
|
21
23
|
return new APIPromise($do(client, request, options));
|
|
@@ -13,7 +13,9 @@ import { Result } from "../types/fp.js";
|
|
|
13
13
|
* Delete a SCIM group mapping
|
|
14
14
|
*
|
|
15
15
|
* @remarks
|
|
16
|
-
* Delete a SCIM group-to-workspace mapping.
|
|
16
|
+
* Delete a SCIM group-to-workspace mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
17
|
+
*
|
|
18
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
17
19
|
*/
|
|
18
20
|
export declare function scimDelete(client: OpenRouterCore, request: operations.DeleteScimGroupMappingRequest, options?: RequestOptions): APIPromise<Result<models.DeleteScimGroupMappingResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
19
21
|
//# sourceMappingURL=scimDelete.d.ts.map
|
package/esm/funcs/scimDelete.js
CHANGED
|
@@ -16,7 +16,9 @@ import { APIPromise } from "../types/async.js";
|
|
|
16
16
|
* Delete a SCIM group mapping
|
|
17
17
|
*
|
|
18
18
|
* @remarks
|
|
19
|
-
* Delete a SCIM group-to-workspace mapping.
|
|
19
|
+
* Delete a SCIM group-to-workspace mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
20
|
+
*
|
|
21
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
20
22
|
*/
|
|
21
23
|
export function scimDelete(client, request, options) {
|
|
22
24
|
return new APIPromise($do(client, request, options));
|
|
@@ -13,7 +13,9 @@ import { Result } from "../types/fp.js";
|
|
|
13
13
|
* Update a SCIM group mapping
|
|
14
14
|
*
|
|
15
15
|
* @remarks
|
|
16
|
-
* Update a SCIM group mapping role.
|
|
16
|
+
* Update a SCIM group mapping role. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
17
|
+
*
|
|
18
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
17
19
|
*/
|
|
18
20
|
export declare function scimUpdate(client: OpenRouterCore, request: operations.UpdateScimGroupMappingRequest, options?: RequestOptions): APIPromise<Result<models.UpdateScimGroupMappingResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
19
21
|
//# sourceMappingURL=scimUpdate.d.ts.map
|
package/esm/funcs/scimUpdate.js
CHANGED
|
@@ -16,7 +16,9 @@ import { APIPromise } from "../types/async.js";
|
|
|
16
16
|
* Update a SCIM group mapping
|
|
17
17
|
*
|
|
18
18
|
* @remarks
|
|
19
|
-
* Update a SCIM group mapping role.
|
|
19
|
+
* Update a SCIM group mapping role. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
20
|
+
*
|
|
21
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
20
22
|
*/
|
|
21
23
|
export function scimUpdate(client, request, options) {
|
|
22
24
|
return new APIPromise($do(client, request, options));
|
package/esm/lib/config.d.ts
CHANGED
|
@@ -49,8 +49,8 @@ export declare function serverURLFromOptions(options: SDKOptions): URL | null;
|
|
|
49
49
|
export declare const SDK_METADATA: {
|
|
50
50
|
readonly language: "typescript";
|
|
51
51
|
readonly openapiDocVersion: "1.0.0";
|
|
52
|
-
readonly sdkVersion: "1.5.
|
|
52
|
+
readonly sdkVersion: "1.5.118";
|
|
53
53
|
readonly genVersion: "2.960.8";
|
|
54
|
-
readonly userAgent: "speakeasy-sdk/typescript 1.5.
|
|
54
|
+
readonly userAgent: "speakeasy-sdk/typescript 1.5.118 2.960.8 1.0.0 @openrouter/sdk";
|
|
55
55
|
};
|
|
56
56
|
//# sourceMappingURL=config.d.ts.map
|
package/esm/lib/config.js
CHANGED
|
@@ -25,8 +25,8 @@ export function serverURLFromOptions(options) {
|
|
|
25
25
|
export const SDK_METADATA = {
|
|
26
26
|
language: "typescript",
|
|
27
27
|
openapiDocVersion: "1.0.0",
|
|
28
|
-
sdkVersion: "1.5.
|
|
28
|
+
sdkVersion: "1.5.118",
|
|
29
29
|
genVersion: "2.960.8",
|
|
30
|
-
userAgent: "speakeasy-sdk/typescript 1.5.
|
|
30
|
+
userAgent: "speakeasy-sdk/typescript 1.5.118 2.960.8 1.0.0 @openrouter/sdk",
|
|
31
31
|
};
|
|
32
32
|
//# sourceMappingURL=config.js.map
|
|
@@ -38,15 +38,15 @@ export type CreateWorkspaceRequest = {
|
|
|
38
38
|
*/
|
|
39
39
|
disabledServerTools?: Array<CreateWorkspaceRequestDisabledServerTool> | null | undefined;
|
|
40
40
|
/**
|
|
41
|
-
* Optional array of API key IDs to filter I/O logging
|
|
41
|
+
* Optional array of API key IDs to filter I/O logging. Read-only for management keys: any value other than the default returns 403. Change it in the OpenRouter dashboard.
|
|
42
42
|
*/
|
|
43
43
|
ioLoggingApiKeyIds?: Array<number> | null | undefined;
|
|
44
44
|
/**
|
|
45
|
-
* Sampling rate for I/O logging (0.0001-1)
|
|
45
|
+
* Sampling rate for I/O logging (0.0001-1). Read-only for management keys: any value other than the default returns 403. Change it in the OpenRouter dashboard.
|
|
46
46
|
*/
|
|
47
47
|
ioLoggingSamplingRate?: number | undefined;
|
|
48
48
|
/**
|
|
49
|
-
* Whether data discount logging is enabled.
|
|
49
|
+
* Whether data discount logging is enabled. Read-only for management keys: any value other than the default returns 403. Change it in the OpenRouter dashboard.
|
|
50
50
|
*/
|
|
51
51
|
isDataDiscountLoggingEnabled?: boolean | undefined;
|
|
52
52
|
/**
|
|
@@ -54,7 +54,7 @@ export type CreateWorkspaceRequest = {
|
|
|
54
54
|
*/
|
|
55
55
|
isObservabilityBroadcastEnabled?: boolean | undefined;
|
|
56
56
|
/**
|
|
57
|
-
* Whether private logging is enabled
|
|
57
|
+
* Whether private logging is enabled. Read-only for management keys: any value other than the default returns 403. Change it in the OpenRouter dashboard.
|
|
58
58
|
*/
|
|
59
59
|
isObservabilityIoLoggingEnabled?: boolean | undefined;
|
|
60
60
|
/**
|
|
@@ -110,6 +110,17 @@ export declare const ImageGenerationRequestResolution: {
|
|
|
110
110
|
* Normalized resolution tier of the generated image. Concrete pixel dimensions are derived per-provider.
|
|
111
111
|
*/
|
|
112
112
|
export type ImageGenerationRequestResolution = OpenEnum<typeof ImageGenerationRequestResolution>;
|
|
113
|
+
/**
|
|
114
|
+
* `b64_json` (default) returns the image bytes inline. `url` stores each output in OpenRouter storage and returns a signed download URL in place of the bytes. The URL is a bearer link: anyone holding it can download the image until it expires, up to 24 hours after the image was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. The response falls back to `b64_json` when a URL cannot be issued: streaming responses, zero-data-retention requests (account settings, guardrails or `provider.zdr`) or endpoints, or storage being unavailable.
|
|
115
|
+
*/
|
|
116
|
+
export declare const ImageGenerationRequestResponseFormat: {
|
|
117
|
+
readonly B64Json: "b64_json";
|
|
118
|
+
readonly Url: "url";
|
|
119
|
+
};
|
|
120
|
+
/**
|
|
121
|
+
* `b64_json` (default) returns the image bytes inline. `url` stores each output in OpenRouter storage and returns a signed download URL in place of the bytes. The URL is a bearer link: anyone holding it can download the image until it expires, up to 24 hours after the image was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. The response falls back to `b64_json` when a URL cannot be issued: streaming responses, zero-data-retention requests (account settings, guardrails or `provider.zdr`) or endpoints, or storage being unavailable.
|
|
122
|
+
*/
|
|
123
|
+
export type ImageGenerationRequestResponseFormat = OpenEnum<typeof ImageGenerationRequestResponseFormat>;
|
|
113
124
|
/**
|
|
114
125
|
* Image generation request input
|
|
115
126
|
*/
|
|
@@ -170,6 +181,10 @@ export type ImageGenerationRequest = {
|
|
|
170
181
|
* Normalized resolution tier of the generated image. Concrete pixel dimensions are derived per-provider.
|
|
171
182
|
*/
|
|
172
183
|
resolution?: ImageGenerationRequestResolution | undefined;
|
|
184
|
+
/**
|
|
185
|
+
* `b64_json` (default) returns the image bytes inline. `url` stores each output in OpenRouter storage and returns a signed download URL in place of the bytes. The URL is a bearer link: anyone holding it can download the image until it expires, up to 24 hours after the image was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. The response falls back to `b64_json` when a URL cannot be issued: streaming responses, zero-data-retention requests (account settings, guardrails or `provider.zdr`) or endpoints, or storage being unavailable.
|
|
186
|
+
*/
|
|
187
|
+
responseFormat?: ImageGenerationRequestResponseFormat | undefined;
|
|
173
188
|
/**
|
|
174
189
|
* If specified, the generation will sample deterministically, such that repeated requests with the same seed and parameters should return the same result. Determinism is not guaranteed for all providers.
|
|
175
190
|
*/
|
|
@@ -223,6 +238,8 @@ export declare const ImageGenerationRequestQuality$outboundSchema: z.ZodType<str
|
|
|
223
238
|
/** @internal */
|
|
224
239
|
export declare const ImageGenerationRequestResolution$outboundSchema: z.ZodType<string, ImageGenerationRequestResolution>;
|
|
225
240
|
/** @internal */
|
|
241
|
+
export declare const ImageGenerationRequestResponseFormat$outboundSchema: z.ZodType<string, ImageGenerationRequestResponseFormat>;
|
|
242
|
+
/** @internal */
|
|
226
243
|
export type ImageGenerationRequest$Outbound = {
|
|
227
244
|
aspect_ratio?: string | undefined;
|
|
228
245
|
background?: string | undefined;
|
|
@@ -238,6 +255,7 @@ export type ImageGenerationRequest$Outbound = {
|
|
|
238
255
|
provider?: ImageGenerationProviderPreferences$Outbound | undefined;
|
|
239
256
|
quality?: string | undefined;
|
|
240
257
|
resolution?: string | undefined;
|
|
258
|
+
response_format?: string | undefined;
|
|
241
259
|
seed?: number | undefined;
|
|
242
260
|
session_id?: string | undefined;
|
|
243
261
|
size?: string | undefined;
|
|
@@ -83,6 +83,13 @@ export const ImageGenerationRequestResolution = {
|
|
|
83
83
|
TwoK: "2K",
|
|
84
84
|
FourK: "4K",
|
|
85
85
|
};
|
|
86
|
+
/**
|
|
87
|
+
* `b64_json` (default) returns the image bytes inline. `url` stores each output in OpenRouter storage and returns a signed download URL in place of the bytes. The URL is a bearer link: anyone holding it can download the image until it expires, up to 24 hours after the image was stored (use `expires_at`); the stored copy is deleted by the storage lifecycle within the following day. The response falls back to `b64_json` when a URL cannot be issued: streaming responses, zero-data-retention requests (account settings, guardrails or `provider.zdr`) or endpoints, or storage being unavailable.
|
|
88
|
+
*/
|
|
89
|
+
export const ImageGenerationRequestResponseFormat = {
|
|
90
|
+
B64Json: "b64_json",
|
|
91
|
+
Url: "url",
|
|
92
|
+
};
|
|
86
93
|
/** @internal */
|
|
87
94
|
export const ImageGenerationRequestAspectRatio$outboundSchema = openEnums.outboundSchema(ImageGenerationRequestAspectRatio);
|
|
88
95
|
/** @internal */
|
|
@@ -116,6 +123,8 @@ export const ImageGenerationRequestQuality$outboundSchema = openEnums.outboundSc
|
|
|
116
123
|
/** @internal */
|
|
117
124
|
export const ImageGenerationRequestResolution$outboundSchema = openEnums.outboundSchema(ImageGenerationRequestResolution);
|
|
118
125
|
/** @internal */
|
|
126
|
+
export const ImageGenerationRequestResponseFormat$outboundSchema = openEnums.outboundSchema(ImageGenerationRequestResponseFormat);
|
|
127
|
+
/** @internal */
|
|
119
128
|
export const ImageGenerationRequest$outboundSchema = z.object({
|
|
120
129
|
aspectRatio: ImageGenerationRequestAspectRatio$outboundSchema.optional(),
|
|
121
130
|
background: ImageGenerationRequestBackground$outboundSchema.optional(),
|
|
@@ -131,6 +140,8 @@ export const ImageGenerationRequest$outboundSchema = z.object({
|
|
|
131
140
|
provider: ImageGenerationProviderPreferences$outboundSchema.optional(),
|
|
132
141
|
quality: ImageGenerationRequestQuality$outboundSchema.optional(),
|
|
133
142
|
resolution: ImageGenerationRequestResolution$outboundSchema.optional(),
|
|
143
|
+
responseFormat: ImageGenerationRequestResponseFormat$outboundSchema
|
|
144
|
+
.optional(),
|
|
134
145
|
seed: z.int().optional(),
|
|
135
146
|
sessionId: z.string().optional(),
|
|
136
147
|
size: z.string().optional(),
|
|
@@ -145,6 +156,7 @@ export const ImageGenerationRequest$outboundSchema = z.object({
|
|
|
145
156
|
inputReferences: "input_references",
|
|
146
157
|
outputCompression: "output_compression",
|
|
147
158
|
outputFormat: "output_format",
|
|
159
|
+
responseFormat: "response_format",
|
|
148
160
|
sessionId: "session_id",
|
|
149
161
|
});
|
|
150
162
|
});
|
|
@@ -5,9 +5,9 @@ import { ImageGenerationLayer } from "./imagegenerationlayer.js";
|
|
|
5
5
|
import { ImageGenerationUsage } from "./imagegenerationusage.js";
|
|
6
6
|
export type ImageGenerationResponseData = {
|
|
7
7
|
/**
|
|
8
|
-
* Base64-encoded image bytes
|
|
8
|
+
* Base64-encoded image bytes. Present unless the request asked for `response_format: "url"` and `url` was issued.
|
|
9
9
|
*/
|
|
10
|
-
b64Json
|
|
10
|
+
b64Json?: string | undefined;
|
|
11
11
|
/**
|
|
12
12
|
* Layer metadata, present when the request asked the provider to split the image into layers (Seedream: `provider.options.seed.layer_decomposition: true` with the required `layer_decomposition_options.max_images`, 2 to 16). Decomposition requires `n` to be 1 or omitted; the response returns up to `max_images` images (the base image plus its layers).
|
|
13
13
|
*/
|
|
@@ -16,6 +16,10 @@ export type ImageGenerationResponseData = {
|
|
|
16
16
|
* Media type (MIME type) of the image, e.g. `image/png`, `image/jpeg`, `image/webp`, `image/svg+xml`. May be omitted if the format could not be determined.
|
|
17
17
|
*/
|
|
18
18
|
mediaType?: string | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Signed download URL for the image bytes, issued for `response_format: "url"` requests. Valid until `expires_at`. Absent when the response fell back to `b64_json`.
|
|
21
|
+
*/
|
|
22
|
+
url?: string | undefined;
|
|
19
23
|
};
|
|
20
24
|
/**
|
|
21
25
|
* Image generation response
|
|
@@ -29,6 +33,10 @@ export type ImageGenerationResponse = {
|
|
|
29
33
|
* Generated images
|
|
30
34
|
*/
|
|
31
35
|
data: Array<ImageGenerationResponseData>;
|
|
36
|
+
/**
|
|
37
|
+
* Unix timestamp (seconds) of the earliest expiry among the `url`s in `data`; treat every URL as expired after it. Present only when URLs were issued.
|
|
38
|
+
*/
|
|
39
|
+
expiresAt?: number | undefined;
|
|
32
40
|
/**
|
|
33
41
|
* Token and cost usage for the image generation request, when available
|
|
34
42
|
*/
|
|
@@ -8,9 +8,10 @@ import { ImageGenerationLayer$inboundSchema, } from "./imagegenerationlayer.js";
|
|
|
8
8
|
import { ImageGenerationUsage$inboundSchema, } from "./imagegenerationusage.js";
|
|
9
9
|
/** @internal */
|
|
10
10
|
export const ImageGenerationResponseData$inboundSchema = z.object({
|
|
11
|
-
b64_json: z.string(),
|
|
11
|
+
b64_json: z.string().optional(),
|
|
12
12
|
layer: ImageGenerationLayer$inboundSchema.optional(),
|
|
13
13
|
media_type: z.string().optional(),
|
|
14
|
+
url: z.string().optional(),
|
|
14
15
|
}).transform((v) => {
|
|
15
16
|
return remap$(v, {
|
|
16
17
|
"b64_json": "b64Json",
|
|
@@ -24,7 +25,12 @@ export function imageGenerationResponseDataFromJSON(jsonString) {
|
|
|
24
25
|
export const ImageGenerationResponse$inboundSchema = z.object({
|
|
25
26
|
created: z.int(),
|
|
26
27
|
data: z.array(z.lazy(() => ImageGenerationResponseData$inboundSchema)),
|
|
28
|
+
expires_at: z.int().optional(),
|
|
27
29
|
usage: ImageGenerationUsage$inboundSchema.optional(),
|
|
30
|
+
}).transform((v) => {
|
|
31
|
+
return remap$(v, {
|
|
32
|
+
"expires_at": "expiresAt",
|
|
33
|
+
});
|
|
28
34
|
});
|
|
29
35
|
export function imageGenerationResponseFromJSON(jsonString) {
|
|
30
36
|
return safeParse(jsonString, (x) => ImageGenerationResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ImageGenerationResponse' from JSON`);
|
|
@@ -38,15 +38,15 @@ export type UpdateWorkspaceRequest = {
|
|
|
38
38
|
*/
|
|
39
39
|
disabledServerTools?: Array<UpdateWorkspaceRequestDisabledServerTool> | null | undefined;
|
|
40
40
|
/**
|
|
41
|
-
* Optional array of API key IDs to filter I/O logging
|
|
41
|
+
* Optional array of API key IDs to filter I/O logging. Read-only for management keys: any value other than the stored one returns 403. Change it in the OpenRouter dashboard.
|
|
42
42
|
*/
|
|
43
43
|
ioLoggingApiKeyIds?: Array<number> | null | undefined;
|
|
44
44
|
/**
|
|
45
|
-
* Sampling rate for I/O logging (0.0001-1)
|
|
45
|
+
* Sampling rate for I/O logging (0.0001-1). Read-only for management keys: any value other than the stored one returns 403. Change it in the OpenRouter dashboard.
|
|
46
46
|
*/
|
|
47
47
|
ioLoggingSamplingRate?: number | undefined;
|
|
48
48
|
/**
|
|
49
|
-
* Whether data discount logging is enabled.
|
|
49
|
+
* Whether data discount logging is enabled. Read-only for management keys: any value other than the stored one returns 403. Change it in the OpenRouter dashboard.
|
|
50
50
|
*/
|
|
51
51
|
isDataDiscountLoggingEnabled?: boolean | undefined;
|
|
52
52
|
/**
|
|
@@ -54,7 +54,7 @@ export type UpdateWorkspaceRequest = {
|
|
|
54
54
|
*/
|
|
55
55
|
isObservabilityBroadcastEnabled?: boolean | undefined;
|
|
56
56
|
/**
|
|
57
|
-
* Whether private logging is enabled
|
|
57
|
+
* Whether private logging is enabled. Read-only for management keys: any value other than the stored one returns 403. Change it in the OpenRouter dashboard.
|
|
58
58
|
*/
|
|
59
59
|
isObservabilityIoLoggingEnabled?: boolean | undefined;
|
|
60
60
|
/**
|
package/esm/sdk/scim.d.ts
CHANGED
|
@@ -16,14 +16,18 @@ export declare class Scim extends ClientSDK {
|
|
|
16
16
|
* Create a SCIM group mapping
|
|
17
17
|
*
|
|
18
18
|
* @remarks
|
|
19
|
-
* Create a SCIM group-to-workspace role mapping.
|
|
19
|
+
* Create a SCIM group-to-workspace role mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
20
|
+
*
|
|
21
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
20
22
|
*/
|
|
21
23
|
create(request: operations.CreateScimGroupMappingRequest, options?: RequestOptions): Promise<models.CreateScimGroupMappingResponse>;
|
|
22
24
|
/**
|
|
23
25
|
* Delete a SCIM group mapping
|
|
24
26
|
*
|
|
25
27
|
* @remarks
|
|
26
|
-
* Delete a SCIM group-to-workspace mapping.
|
|
28
|
+
* Delete a SCIM group-to-workspace mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
29
|
+
*
|
|
30
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
27
31
|
*/
|
|
28
32
|
delete(request: operations.DeleteScimGroupMappingRequest, options?: RequestOptions): Promise<models.DeleteScimGroupMappingResponse>;
|
|
29
33
|
/**
|
|
@@ -37,7 +41,9 @@ export declare class Scim extends ClientSDK {
|
|
|
37
41
|
* Update a SCIM group mapping
|
|
38
42
|
*
|
|
39
43
|
* @remarks
|
|
40
|
-
* Update a SCIM group mapping role.
|
|
44
|
+
* Update a SCIM group mapping role. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
45
|
+
*
|
|
46
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
41
47
|
*/
|
|
42
48
|
update(request: operations.UpdateScimGroupMappingRequest, options?: RequestOptions): Promise<models.UpdateScimGroupMappingResponse>;
|
|
43
49
|
/**
|
|
@@ -53,7 +59,9 @@ export declare class Scim extends ClientSDK {
|
|
|
53
59
|
* Start a SCIM directory sync
|
|
54
60
|
*
|
|
55
61
|
* @remarks
|
|
56
|
-
* Start a SCIM directory sync.
|
|
62
|
+
* Start a SCIM directory sync. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
63
|
+
*
|
|
64
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
57
65
|
*/
|
|
58
66
|
createSyncJob(request?: operations.CreateScimSyncJobRequest | undefined, options?: RequestOptions): Promise<operations.CreateScimSyncJobResponse>;
|
|
59
67
|
/**
|
package/esm/sdk/scim.js
CHANGED
|
@@ -26,7 +26,9 @@ export class Scim extends ClientSDK {
|
|
|
26
26
|
* Create a SCIM group mapping
|
|
27
27
|
*
|
|
28
28
|
* @remarks
|
|
29
|
-
* Create a SCIM group-to-workspace role mapping.
|
|
29
|
+
* Create a SCIM group-to-workspace role mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
30
|
+
*
|
|
31
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
30
32
|
*/
|
|
31
33
|
async create(request, options) {
|
|
32
34
|
return unwrapAsync(scimCreate(this, request, options));
|
|
@@ -35,7 +37,9 @@ export class Scim extends ClientSDK {
|
|
|
35
37
|
* Delete a SCIM group mapping
|
|
36
38
|
*
|
|
37
39
|
* @remarks
|
|
38
|
-
* Delete a SCIM group-to-workspace mapping.
|
|
40
|
+
* Delete a SCIM group-to-workspace mapping. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
41
|
+
*
|
|
42
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
39
43
|
*/
|
|
40
44
|
async delete(request, options) {
|
|
41
45
|
return unwrapAsync(scimDelete(this, request, options));
|
|
@@ -53,7 +57,9 @@ export class Scim extends ClientSDK {
|
|
|
53
57
|
* Update a SCIM group mapping
|
|
54
58
|
*
|
|
55
59
|
* @remarks
|
|
56
|
-
* Update a SCIM group mapping role.
|
|
60
|
+
* Update a SCIM group mapping role. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
61
|
+
*
|
|
62
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
57
63
|
*/
|
|
58
64
|
async update(request, options) {
|
|
59
65
|
return unwrapAsync(scimUpdate(this, request, options));
|
|
@@ -71,7 +77,9 @@ export class Scim extends ClientSDK {
|
|
|
71
77
|
* Start a SCIM directory sync
|
|
72
78
|
*
|
|
73
79
|
* @remarks
|
|
74
|
-
* Start a SCIM directory sync.
|
|
80
|
+
* Start a SCIM directory sync. Disabled: no API key can perform this write, including management keys. Use the organization settings in the dashboard, which require step-up verification. A valid management key for an organization with SCIM access receives 403; an invalid key still receives 401 and an organization without SCIM access receives 404.
|
|
81
|
+
*
|
|
82
|
+
* @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
75
83
|
*/
|
|
76
84
|
async createSyncJob(request, options) {
|
|
77
85
|
return unwrapAsync(scimCreateSyncJob(this, request, options));
|
package/jsr.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openrouter/sdk",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.118",
|
|
4
4
|
"author": "OpenRouter",
|
|
5
5
|
"description": "The OpenRouter TypeScript SDK is a type-safe toolkit for building AI applications with access to 400+ language models through a unified API.",
|
|
6
6
|
"keywords": [
|
|
@@ -73,13 +73,13 @@
|
|
|
73
73
|
"lint": "eslint --cache --max-warnings=0 src",
|
|
74
74
|
"build": "node --max-old-space-size=8192 ./node_modules/typescript/bin/tsc && node scripts/unbarrel-imports.js",
|
|
75
75
|
"prepublishOnly": "npm run build",
|
|
76
|
-
"test": "vitest --run --project unit",
|
|
77
|
-
"test:watch": "vitest --watch --project unit",
|
|
78
|
-
"typecheck": "tsc --noEmit",
|
|
79
76
|
"postinstall": "node scripts/check-types.js || true",
|
|
80
77
|
"prepare": "npm run build",
|
|
81
|
-
"test
|
|
78
|
+
"test": "vitest --run --project unit",
|
|
82
79
|
"test:transit": "exit 0",
|
|
80
|
+
"typecheck": "tsc --noEmit",
|
|
81
|
+
"test:e2e": "vitest --run --project e2e",
|
|
82
|
+
"test:watch": "vitest --watch --project unit",
|
|
83
83
|
"typecheck:transit": "exit 0",
|
|
84
84
|
"compile": "node --max-old-space-size=8192 ./node_modules/typescript/bin/tsc && node scripts/unbarrel-imports.js"
|
|
85
85
|
},
|