@openrouter/sdk 1.2.39 → 1.2.41
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/workspacesDelete.d.ts +1 -1
- package/esm/funcs/workspacesDelete.js +2 -6
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/models/imagegenerationproviderpreferences.d.ts +6 -0
- package/esm/models/imagegenerationproviderpreferences.js +2 -0
- package/esm/models/operations/deleteworkspace.d.ts +0 -5
- package/esm/models/operations/deleteworkspace.js +0 -2
- package/esm/models/provideroptions.d.ts +6 -0
- package/esm/models/provideroptions.js +2 -0
- package/esm/models/videogenerationrequest.d.ts +6 -0
- package/esm/models/videogenerationrequest.js +2 -0
- package/esm/sdk/workspaces.d.ts +1 -1
- package/esm/sdk/workspaces.js +1 -1
- package/jsr.json +1 -1
- package/package.json +9 -9
|
@@ -13,7 +13,7 @@ import { Result } from "../types/fp.js";
|
|
|
13
13
|
* Delete a workspace
|
|
14
14
|
*
|
|
15
15
|
* @remarks
|
|
16
|
-
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out.
|
|
16
|
+
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out. Deleting any workspace permanently deletes its budgets and guardrails and disables its classifiers and broadcast destinations. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
17
17
|
*/
|
|
18
18
|
export declare function workspacesDelete(client: OpenRouterCore, request: operations.DeleteWorkspaceRequest, options?: RequestOptions): APIPromise<Result<models.DeleteWorkspaceResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
|
|
19
19
|
//# sourceMappingURL=workspacesDelete.d.ts.map
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
3
|
* @generated-id: 548699dffed1
|
|
4
4
|
*/
|
|
5
|
-
import {
|
|
5
|
+
import { encodeSimple } from "../lib/encodings.js";
|
|
6
6
|
import { matchStatusCode } from "../lib/http.js";
|
|
7
7
|
import * as M from "../lib/matchers.js";
|
|
8
8
|
import { compactMap } from "../lib/primitives.js";
|
|
@@ -17,7 +17,7 @@ import { APIPromise } from "../types/async.js";
|
|
|
17
17
|
* Delete a workspace
|
|
18
18
|
*
|
|
19
19
|
* @remarks
|
|
20
|
-
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out.
|
|
20
|
+
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out. Deleting any workspace permanently deletes its budgets and guardrails and disables its classifiers and broadcast destinations. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
21
21
|
*/
|
|
22
22
|
export function workspacesDelete(client, request, options) {
|
|
23
23
|
return new APIPromise($do(client, request, options));
|
|
@@ -36,9 +36,6 @@ async function $do(client, request, options) {
|
|
|
36
36
|
}),
|
|
37
37
|
};
|
|
38
38
|
const path = pathToFunc("/workspaces/{id}")(pathParams);
|
|
39
|
-
const query = encodeFormQuery({
|
|
40
|
-
"confirm_default_settings_deletion": payload.confirm_default_settings_deletion,
|
|
41
|
-
});
|
|
42
39
|
const headers = new Headers(compactMap({
|
|
43
40
|
Accept: "application/json",
|
|
44
41
|
"HTTP-Referer": encodeSimple("HTTP-Referer", payload["HTTP-Referer"] ?? client._options.httpReferer, { explode: false, charEncoding: "none" }),
|
|
@@ -76,7 +73,6 @@ async function $do(client, request, options) {
|
|
|
76
73
|
baseURL: options?.serverURL,
|
|
77
74
|
path: path,
|
|
78
75
|
headers: headers,
|
|
79
|
-
query: query,
|
|
80
76
|
body: body,
|
|
81
77
|
userAgent: client._options.userAgent,
|
|
82
78
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
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.2.
|
|
52
|
+
readonly sdkVersion: "1.2.41";
|
|
53
53
|
readonly genVersion: "2.914.0";
|
|
54
|
-
readonly userAgent: "speakeasy-sdk/typescript 1.2.
|
|
54
|
+
readonly userAgent: "speakeasy-sdk/typescript 1.2.41 2.914.0 1.0.0 @openrouter/sdk";
|
|
55
55
|
};
|
|
56
56
|
//# sourceMappingURL=config.d.ts.map
|
package/esm/lib/config.js
CHANGED
|
@@ -26,8 +26,8 @@ export function serverURLFromOptions(options) {
|
|
|
26
26
|
export const SDK_METADATA = {
|
|
27
27
|
language: "typescript",
|
|
28
28
|
openapiDocVersion: "1.0.0",
|
|
29
|
-
sdkVersion: "1.2.
|
|
29
|
+
sdkVersion: "1.2.41",
|
|
30
30
|
genVersion: "2.914.0",
|
|
31
|
-
userAgent: "speakeasy-sdk/typescript 1.2.
|
|
31
|
+
userAgent: "speakeasy-sdk/typescript 1.2.41 2.914.0 1.0.0 @openrouter/sdk",
|
|
32
32
|
};
|
|
33
33
|
//# sourceMappingURL=config.js.map
|
|
@@ -26,6 +26,9 @@ export type ImageGenerationProviderPreferencesOptions = {
|
|
|
26
26
|
amazonBedrock?: {
|
|
27
27
|
[k: string]: any;
|
|
28
28
|
} | undefined;
|
|
29
|
+
amazonBedrockClaudeOnAws?: {
|
|
30
|
+
[k: string]: any;
|
|
31
|
+
} | undefined;
|
|
29
32
|
amazonNova?: {
|
|
30
33
|
[k: string]: any;
|
|
31
34
|
} | undefined;
|
|
@@ -473,6 +476,9 @@ export type ImageGenerationProviderPreferencesOptions$Outbound = {
|
|
|
473
476
|
"amazon-bedrock"?: {
|
|
474
477
|
[k: string]: any;
|
|
475
478
|
} | undefined;
|
|
479
|
+
"amazon-bedrock/claude-on-aws"?: {
|
|
480
|
+
[k: string]: any;
|
|
481
|
+
} | undefined;
|
|
476
482
|
"amazon-nova"?: {
|
|
477
483
|
[k: string]: any;
|
|
478
484
|
} | undefined;
|
|
@@ -25,6 +25,7 @@ export const ImageGenerationProviderPreferencesOptions$outboundSchema = z.object
|
|
|
25
25
|
akashml: z.record(z.string(), z.any()).optional(),
|
|
26
26
|
alibaba: z.record(z.string(), z.any()).optional(),
|
|
27
27
|
amazonBedrock: z.record(z.string(), z.any()).optional(),
|
|
28
|
+
amazonBedrockClaudeOnAws: z.record(z.string(), z.any()).optional(),
|
|
28
29
|
amazonNova: z.record(z.string(), z.any()).optional(),
|
|
29
30
|
ambient: z.record(z.string(), z.any()).optional(),
|
|
30
31
|
anthropic: z.record(z.string(), z.any()).optional(),
|
|
@@ -157,6 +158,7 @@ export const ImageGenerationProviderPreferencesOptions$outboundSchema = z.object
|
|
|
157
158
|
oneai: "01ai",
|
|
158
159
|
aionLabs: "aion-labs",
|
|
159
160
|
amazonBedrock: "amazon-bedrock",
|
|
161
|
+
amazonBedrockClaudeOnAws: "amazon-bedrock/claude-on-aws",
|
|
160
162
|
amazonNova: "amazon-nova",
|
|
161
163
|
arceeAi: "arcee-ai",
|
|
162
164
|
atlasCloud: "atlas-cloud",
|
|
@@ -44,10 +44,6 @@ export type DeleteWorkspaceRequest = {
|
|
|
44
44
|
* The workspace ID (UUID) or slug
|
|
45
45
|
*/
|
|
46
46
|
id: string;
|
|
47
|
-
/**
|
|
48
|
-
* Required to delete the default workspace (not yet generally available; callers not enabled for it receive a 403 while the capability rolls out). Deleting it permanently disables the account’s unscoped inference API keys (management/provisioning keys are retained) and its budgets, guardrails, classifiers, and broadcast destinations. Ignored for non-default workspaces.
|
|
49
|
-
*/
|
|
50
|
-
confirmDefaultSettingsDeletion?: boolean | undefined;
|
|
51
47
|
};
|
|
52
48
|
/** @internal */
|
|
53
49
|
export type DeleteWorkspaceRequest$Outbound = {
|
|
@@ -55,7 +51,6 @@ export type DeleteWorkspaceRequest$Outbound = {
|
|
|
55
51
|
appTitle?: string | undefined;
|
|
56
52
|
appCategories?: string | undefined;
|
|
57
53
|
id: string;
|
|
58
|
-
confirm_default_settings_deletion?: boolean | undefined;
|
|
59
54
|
};
|
|
60
55
|
/** @internal */
|
|
61
56
|
export declare const DeleteWorkspaceRequest$outboundSchema: z.ZodType<DeleteWorkspaceRequest$Outbound, DeleteWorkspaceRequest>;
|
|
@@ -10,11 +10,9 @@ export const DeleteWorkspaceRequest$outboundSchema = z.object({
|
|
|
10
10
|
appTitle: z.string().optional(),
|
|
11
11
|
appCategories: z.string().optional(),
|
|
12
12
|
id: z.string(),
|
|
13
|
-
confirmDefaultSettingsDeletion: z.boolean().optional(),
|
|
14
13
|
}).transform((v) => {
|
|
15
14
|
return remap$(v, {
|
|
16
15
|
httpReferer: "HTTP-Referer",
|
|
17
|
-
confirmDefaultSettingsDeletion: "confirm_default_settings_deletion",
|
|
18
16
|
});
|
|
19
17
|
});
|
|
20
18
|
export function deleteWorkspaceRequestToJSON(deleteWorkspaceRequest) {
|
|
@@ -21,6 +21,9 @@ export type ProviderOptions = {
|
|
|
21
21
|
amazonBedrock?: {
|
|
22
22
|
[k: string]: any;
|
|
23
23
|
} | undefined;
|
|
24
|
+
amazonBedrockClaudeOnAws?: {
|
|
25
|
+
[k: string]: any;
|
|
26
|
+
} | undefined;
|
|
24
27
|
amazonNova?: {
|
|
25
28
|
[k: string]: any;
|
|
26
29
|
} | undefined;
|
|
@@ -423,6 +426,9 @@ export type ProviderOptions$Outbound = {
|
|
|
423
426
|
"amazon-bedrock"?: {
|
|
424
427
|
[k: string]: any;
|
|
425
428
|
} | undefined;
|
|
429
|
+
"amazon-bedrock/claude-on-aws"?: {
|
|
430
|
+
[k: string]: any;
|
|
431
|
+
} | undefined;
|
|
426
432
|
"amazon-nova"?: {
|
|
427
433
|
[k: string]: any;
|
|
428
434
|
} | undefined;
|
|
@@ -12,6 +12,7 @@ export const ProviderOptions$outboundSchema = z.object({
|
|
|
12
12
|
akashml: z.record(z.string(), z.any()).optional(),
|
|
13
13
|
alibaba: z.record(z.string(), z.any()).optional(),
|
|
14
14
|
amazonBedrock: z.record(z.string(), z.any()).optional(),
|
|
15
|
+
amazonBedrockClaudeOnAws: z.record(z.string(), z.any()).optional(),
|
|
15
16
|
amazonNova: z.record(z.string(), z.any()).optional(),
|
|
16
17
|
ambient: z.record(z.string(), z.any()).optional(),
|
|
17
18
|
anthropic: z.record(z.string(), z.any()).optional(),
|
|
@@ -144,6 +145,7 @@ export const ProviderOptions$outboundSchema = z.object({
|
|
|
144
145
|
oneai: "01ai",
|
|
145
146
|
aionLabs: "aion-labs",
|
|
146
147
|
amazonBedrock: "amazon-bedrock",
|
|
148
|
+
amazonBedrockClaudeOnAws: "amazon-bedrock/claude-on-aws",
|
|
147
149
|
amazonNova: "amazon-nova",
|
|
148
150
|
arceeAi: "arcee-ai",
|
|
149
151
|
atlasCloud: "atlas-cloud",
|
|
@@ -42,6 +42,9 @@ export type VideoGenerationRequestOptions = {
|
|
|
42
42
|
amazonBedrock?: {
|
|
43
43
|
[k: string]: any;
|
|
44
44
|
} | undefined;
|
|
45
|
+
amazonBedrockClaudeOnAws?: {
|
|
46
|
+
[k: string]: any;
|
|
47
|
+
} | undefined;
|
|
45
48
|
amazonNova?: {
|
|
46
49
|
[k: string]: any;
|
|
47
50
|
} | undefined;
|
|
@@ -515,6 +518,9 @@ export type VideoGenerationRequestOptions$Outbound = {
|
|
|
515
518
|
"amazon-bedrock"?: {
|
|
516
519
|
[k: string]: any;
|
|
517
520
|
} | undefined;
|
|
521
|
+
"amazon-bedrock/claude-on-aws"?: {
|
|
522
|
+
[k: string]: any;
|
|
523
|
+
} | undefined;
|
|
518
524
|
"amazon-nova"?: {
|
|
519
525
|
[k: string]: any;
|
|
520
526
|
} | undefined;
|
|
@@ -43,6 +43,7 @@ export const VideoGenerationRequestOptions$outboundSchema = z.object({
|
|
|
43
43
|
akashml: z.record(z.string(), z.any()).optional(),
|
|
44
44
|
alibaba: z.record(z.string(), z.any()).optional(),
|
|
45
45
|
amazonBedrock: z.record(z.string(), z.any()).optional(),
|
|
46
|
+
amazonBedrockClaudeOnAws: z.record(z.string(), z.any()).optional(),
|
|
46
47
|
amazonNova: z.record(z.string(), z.any()).optional(),
|
|
47
48
|
ambient: z.record(z.string(), z.any()).optional(),
|
|
48
49
|
anthropic: z.record(z.string(), z.any()).optional(),
|
|
@@ -175,6 +176,7 @@ export const VideoGenerationRequestOptions$outboundSchema = z.object({
|
|
|
175
176
|
oneai: "01ai",
|
|
176
177
|
aionLabs: "aion-labs",
|
|
177
178
|
amazonBedrock: "amazon-bedrock",
|
|
179
|
+
amazonBedrockClaudeOnAws: "amazon-bedrock/claude-on-aws",
|
|
178
180
|
amazonNova: "amazon-nova",
|
|
179
181
|
arceeAi: "arcee-ai",
|
|
180
182
|
atlasCloud: "atlas-cloud",
|
package/esm/sdk/workspaces.d.ts
CHANGED
|
@@ -23,7 +23,7 @@ export declare class Workspaces extends ClientSDK {
|
|
|
23
23
|
* Delete a workspace
|
|
24
24
|
*
|
|
25
25
|
* @remarks
|
|
26
|
-
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out.
|
|
26
|
+
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out. Deleting any workspace permanently deletes its budgets and guardrails and disables its classifiers and broadcast destinations. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
27
27
|
*/
|
|
28
28
|
delete(request: operations.DeleteWorkspaceRequest, options?: RequestOptions): Promise<models.DeleteWorkspaceResponse>;
|
|
29
29
|
/**
|
package/esm/sdk/workspaces.js
CHANGED
|
@@ -40,7 +40,7 @@ export class Workspaces extends ClientSDK {
|
|
|
40
40
|
* Delete a workspace
|
|
41
41
|
*
|
|
42
42
|
* @remarks
|
|
43
|
-
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out.
|
|
43
|
+
* Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace is not yet generally available; callers not enabled for it receive a 403 while the capability rolls out. Deleting any workspace permanently deletes its budgets and guardrails and disables its classifiers and broadcast destinations. [Management key](/docs/guides/overview/auth/management-api-keys) required.
|
|
44
44
|
*/
|
|
45
45
|
async delete(request, options) {
|
|
46
46
|
return unwrapAsync(workspacesDelete(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.2.
|
|
3
|
+
"version": "1.2.41",
|
|
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": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"license": "Apache-2.0",
|
|
22
22
|
"packageManager": "pnpm@10.22.0",
|
|
23
23
|
"publishConfig": {
|
|
24
|
-
"
|
|
25
|
-
"
|
|
24
|
+
"access": "public",
|
|
25
|
+
"provenance": true
|
|
26
26
|
},
|
|
27
27
|
"type": "module",
|
|
28
28
|
"main": "./esm/index.js",
|
|
@@ -73,15 +73,15 @@
|
|
|
73
73
|
"lint": "eslint --cache --max-warnings=0 src",
|
|
74
74
|
"build": "tsc",
|
|
75
75
|
"prepublishOnly": "npm run build",
|
|
76
|
-
"
|
|
77
|
-
"test:transit": "exit 0",
|
|
78
|
-
"test:watch": "vitest --watch --project unit",
|
|
79
|
-
"typecheck": "tsc --noEmit",
|
|
76
|
+
"typecheck:transit": "exit 0",
|
|
80
77
|
"compile": "tsc",
|
|
81
78
|
"postinstall": "node scripts/check-types.js || true",
|
|
82
|
-
"
|
|
79
|
+
"test": "vitest --run --project unit",
|
|
80
|
+
"test:transit": "exit 0",
|
|
81
|
+
"test:watch": "vitest --watch --project unit",
|
|
83
82
|
"prepare": "npm run build",
|
|
84
|
-
"test": "vitest --run --project
|
|
83
|
+
"test:e2e": "vitest --run --project e2e",
|
|
84
|
+
"typecheck": "tsc --noEmit"
|
|
85
85
|
},
|
|
86
86
|
"peerDependencies": {},
|
|
87
87
|
"devDependencies": {
|