@openrouter/sdk 1.2.123 → 1.2.124

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.
@@ -15,5 +15,5 @@ import { Result } from "../types/fp.js";
15
15
  * @remarks
16
16
  * Assign multiple API keys to a specific guardrail. A key may hold at most one guardrail; assigning replaces any existing assignment. [Management key](/docs/guides/overview/auth/management-api-keys) required.
17
17
  */
18
- export declare function guardrailsBulkAssignKeys(client: OpenRouterCore, request: operations.BulkAssignKeysToGuardrailRequest, options?: RequestOptions): APIPromise<Result<models.BulkAssignKeysResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
18
+ export declare function guardrailsBulkAssignKeys(client: OpenRouterCore, request: operations.BulkAssignKeysToGuardrailRequest, options?: RequestOptions): APIPromise<Result<models.BulkAssignKeysResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
19
19
  //# sourceMappingURL=guardrailsBulkAssignKeys.d.ts.map
@@ -97,7 +97,7 @@ async function $do(client, request, options) {
97
97
  const responseFields = {
98
98
  HttpMeta: { Response: response, Request: req },
99
99
  };
100
- const [result] = await M.match(M.json(200, models.BulkAssignKeysResponse$inboundSchema), M.jsonErr(400, errors.BadRequestResponseError$inboundSchema), M.jsonErr(401, errors.UnauthorizedResponseError$inboundSchema), M.jsonErr(404, errors.NotFoundResponseError$inboundSchema), M.jsonErr(500, errors.InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
100
+ const [result] = await M.match(M.json(200, models.BulkAssignKeysResponse$inboundSchema), M.jsonErr(400, errors.BadRequestResponseError$inboundSchema), M.jsonErr(401, errors.UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors.ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors.NotFoundResponseError$inboundSchema), M.jsonErr(500, errors.InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
101
101
  if (!result.ok) {
102
102
  return [result, { status: "complete", request: req, response }];
103
103
  }
@@ -15,5 +15,5 @@ import { Result } from "../types/fp.js";
15
15
  * @remarks
16
16
  * Update an existing guardrail, or materialize an unconfigured workspace default guardrail. Collection fields use replace semantics: send the full desired set on every update. [Management key](/docs/guides/overview/auth/management-api-keys) required.
17
17
  */
18
- export declare function guardrailsUpdate(client: OpenRouterCore, request: operations.UpdateGuardrailRequest, options?: RequestOptions): APIPromise<Result<models.UpdateGuardrailResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.NotFoundResponseError | errors.ConflictResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
18
+ export declare function guardrailsUpdate(client: OpenRouterCore, request: operations.UpdateGuardrailRequest, options?: RequestOptions): APIPromise<Result<models.UpdateGuardrailResponse, errors.BadRequestResponseError | errors.UnauthorizedResponseError | errors.ForbiddenResponseError | errors.NotFoundResponseError | errors.ConflictResponseError | errors.InternalServerResponseError | OpenRouterError | ResponseValidationError | ConnectionError | RequestAbortedError | RequestTimeoutError | InvalidRequestError | UnexpectedClientError | SDKValidationError>>;
19
19
  //# sourceMappingURL=guardrailsUpdate.d.ts.map
@@ -97,7 +97,7 @@ async function $do(client, request, options) {
97
97
  const responseFields = {
98
98
  HttpMeta: { Response: response, Request: req },
99
99
  };
100
- const [result] = await M.match(M.json(200, models.UpdateGuardrailResponse$inboundSchema), M.jsonErr(400, errors.BadRequestResponseError$inboundSchema), M.jsonErr(401, errors.UnauthorizedResponseError$inboundSchema), M.jsonErr(404, errors.NotFoundResponseError$inboundSchema), M.jsonErr(409, errors.ConflictResponseError$inboundSchema), M.jsonErr(500, errors.InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
100
+ const [result] = await M.match(M.json(200, models.UpdateGuardrailResponse$inboundSchema), M.jsonErr(400, errors.BadRequestResponseError$inboundSchema), M.jsonErr(401, errors.UnauthorizedResponseError$inboundSchema), M.jsonErr(403, errors.ForbiddenResponseError$inboundSchema), M.jsonErr(404, errors.NotFoundResponseError$inboundSchema), M.jsonErr(409, errors.ConflictResponseError$inboundSchema), M.jsonErr(500, errors.InternalServerResponseError$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response, req, { extraFields: responseFields });
101
101
  if (!result.ok) {
102
102
  return [result, { status: "complete", request: req, response }];
103
103
  }
@@ -50,8 +50,8 @@ export declare function serverURLFromOptions(options: SDKOptions): URL | null;
50
50
  export declare const SDK_METADATA: {
51
51
  readonly language: "typescript";
52
52
  readonly openapiDocVersion: "1.0.0";
53
- readonly sdkVersion: "1.2.123";
53
+ readonly sdkVersion: "1.2.124";
54
54
  readonly genVersion: "2.914.0";
55
- readonly userAgent: "speakeasy-sdk/typescript 1.2.123 2.914.0 1.0.0 @openrouter/sdk";
55
+ readonly userAgent: "speakeasy-sdk/typescript 1.2.124 2.914.0 1.0.0 @openrouter/sdk";
56
56
  };
57
57
  //# sourceMappingURL=config.d.ts.map
package/esm/lib/config.js CHANGED
@@ -29,8 +29,8 @@ export function serverURLFromOptions(options) {
29
29
  export const SDK_METADATA = {
30
30
  language: "typescript",
31
31
  openapiDocVersion: "1.0.0",
32
- sdkVersion: "1.2.123",
32
+ sdkVersion: "1.2.124",
33
33
  genVersion: "2.914.0",
34
- userAgent: "speakeasy-sdk/typescript 1.2.123 2.914.0 1.0.0 @openrouter/sdk",
34
+ userAgent: "speakeasy-sdk/typescript 1.2.124 2.914.0 1.0.0 @openrouter/sdk",
35
35
  };
36
36
  //# sourceMappingURL=config.js.map
package/jsr.json CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  {
4
4
  "name": "@openrouter/sdk",
5
- "version": "1.2.123",
5
+ "version": "1.2.124",
6
6
  "exports": {
7
7
  ".": "./src/index.ts",
8
8
  "./models/errors": "./src/models/errors/index.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openrouter/sdk",
3
- "version": "1.2.123",
3
+ "version": "1.2.124",
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,15 +73,15 @@
73
73
  "lint": "eslint --cache --max-warnings=0 src",
74
74
  "build": "tsc",
75
75
  "prepublishOnly": "npm run build",
76
+ "typecheck:transit": "exit 0",
76
77
  "prepare": "npm run build",
77
- "test": "vitest --run --project unit",
78
78
  "test:e2e": "vitest --run --project e2e",
79
- "test:transit": "exit 0",
80
- "test:watch": "vitest --watch --project unit",
81
79
  "typecheck": "tsc --noEmit",
82
- "typecheck:transit": "exit 0",
83
80
  "compile": "tsc",
84
- "postinstall": "node scripts/check-types.js || true"
81
+ "postinstall": "node scripts/check-types.js || true",
82
+ "test": "vitest --run --project unit",
83
+ "test:transit": "exit 0",
84
+ "test:watch": "vitest --watch --project unit"
85
85
  },
86
86
  "peerDependencies": {},
87
87
  "devDependencies": {