@openrouter/sdk 1.2.115 → 1.2.116
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/lib/config.d.ts
CHANGED
|
@@ -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.
|
|
53
|
+
readonly sdkVersion: "1.2.116";
|
|
54
54
|
readonly genVersion: "2.914.0";
|
|
55
|
-
readonly userAgent: "speakeasy-sdk/typescript 1.2.
|
|
55
|
+
readonly userAgent: "speakeasy-sdk/typescript 1.2.116 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.
|
|
32
|
+
sdkVersion: "1.2.116",
|
|
33
33
|
genVersion: "2.914.0",
|
|
34
|
-
userAgent: "speakeasy-sdk/typescript 1.2.
|
|
34
|
+
userAgent: "speakeasy-sdk/typescript 1.2.116 2.914.0 1.0.0 @openrouter/sdk",
|
|
35
35
|
};
|
|
36
36
|
//# sourceMappingURL=config.js.map
|
|
@@ -1,17 +1,41 @@
|
|
|
1
1
|
import * as z from "zod/v4";
|
|
2
2
|
import { OpenEnum } from "../types/enums.js";
|
|
3
|
+
/**
|
|
4
|
+
* Deprecated: legacy alias of prefix_mismatch_behavior. Send only one of the two.
|
|
5
|
+
*
|
|
6
|
+
* @deprecated enum: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
7
|
+
*/
|
|
8
|
+
export declare const MismatchBehavior: {
|
|
9
|
+
readonly Error: "error";
|
|
10
|
+
readonly DropBlock: "drop_block";
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Deprecated: legacy alias of prefix_mismatch_behavior. Send only one of the two.
|
|
14
|
+
*
|
|
15
|
+
* @deprecated enum: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
16
|
+
*/
|
|
17
|
+
export type MismatchBehavior = OpenEnum<typeof MismatchBehavior>;
|
|
3
18
|
export declare const PrefixMismatchBehavior: {
|
|
4
19
|
readonly Error: "error";
|
|
5
20
|
readonly DropBlock: "drop_block";
|
|
6
21
|
};
|
|
7
22
|
export type PrefixMismatchBehavior = OpenEnum<typeof PrefixMismatchBehavior>;
|
|
8
23
|
export type AnthropicThinkingBlockBinding = {
|
|
24
|
+
/**
|
|
25
|
+
* Deprecated: legacy alias of prefix_mismatch_behavior. Send only one of the two.
|
|
26
|
+
*
|
|
27
|
+
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
28
|
+
*/
|
|
29
|
+
mismatchBehavior?: MismatchBehavior | null | undefined;
|
|
9
30
|
prefixMismatchBehavior?: PrefixMismatchBehavior | null | undefined;
|
|
10
31
|
};
|
|
11
32
|
/** @internal */
|
|
33
|
+
export declare const MismatchBehavior$outboundSchema: z.ZodType<string, MismatchBehavior>;
|
|
34
|
+
/** @internal */
|
|
12
35
|
export declare const PrefixMismatchBehavior$outboundSchema: z.ZodType<string, PrefixMismatchBehavior>;
|
|
13
36
|
/** @internal */
|
|
14
37
|
export type AnthropicThinkingBlockBinding$Outbound = {
|
|
38
|
+
mismatch_behavior?: string | null | undefined;
|
|
15
39
|
prefix_mismatch_behavior?: string | null | undefined;
|
|
16
40
|
};
|
|
17
41
|
/** @internal */
|
|
@@ -5,18 +5,31 @@
|
|
|
5
5
|
import * as z from "zod/v4";
|
|
6
6
|
import { remap as remap$ } from "../lib/primitives.js";
|
|
7
7
|
import * as openEnums from "../types/enums.js";
|
|
8
|
+
/**
|
|
9
|
+
* Deprecated: legacy alias of prefix_mismatch_behavior. Send only one of the two.
|
|
10
|
+
*
|
|
11
|
+
* @deprecated enum: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
12
|
+
*/
|
|
13
|
+
export const MismatchBehavior = {
|
|
14
|
+
Error: "error",
|
|
15
|
+
DropBlock: "drop_block",
|
|
16
|
+
};
|
|
8
17
|
export const PrefixMismatchBehavior = {
|
|
9
18
|
Error: "error",
|
|
10
19
|
DropBlock: "drop_block",
|
|
11
20
|
};
|
|
12
21
|
/** @internal */
|
|
22
|
+
export const MismatchBehavior$outboundSchema = openEnums.outboundSchema(MismatchBehavior);
|
|
23
|
+
/** @internal */
|
|
13
24
|
export const PrefixMismatchBehavior$outboundSchema = openEnums.outboundSchema(PrefixMismatchBehavior);
|
|
14
25
|
/** @internal */
|
|
15
26
|
export const AnthropicThinkingBlockBinding$outboundSchema = z.object({
|
|
27
|
+
mismatchBehavior: z.nullable(MismatchBehavior$outboundSchema).optional(),
|
|
16
28
|
prefixMismatchBehavior: z.nullable(PrefixMismatchBehavior$outboundSchema)
|
|
17
29
|
.optional(),
|
|
18
30
|
}).transform((v) => {
|
|
19
31
|
return remap$(v, {
|
|
32
|
+
mismatchBehavior: "mismatch_behavior",
|
|
20
33
|
prefixMismatchBehavior: "prefix_mismatch_behavior",
|
|
21
34
|
});
|
|
22
35
|
});
|
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.116",
|
|
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
|
+
"provenance": true,
|
|
25
|
+
"access": "public"
|
|
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": "vitest --run --project unit",
|
|
78
|
-
"test:watch": "vitest --watch --project unit",
|
|
76
|
+
"test:e2e": "vitest --run --project e2e",
|
|
79
77
|
"typecheck": "tsc --noEmit",
|
|
80
|
-
"compile": "tsc",
|
|
81
78
|
"prepare": "npm run build",
|
|
82
|
-
"test:e2e": "vitest --run --project e2e",
|
|
83
79
|
"test:transit": "exit 0",
|
|
84
|
-
"
|
|
80
|
+
"test:watch": "vitest --watch --project unit",
|
|
81
|
+
"typecheck:transit": "exit 0",
|
|
82
|
+
"compile": "tsc",
|
|
83
|
+
"postinstall": "node scripts/check-types.js || true",
|
|
84
|
+
"test": "vitest --run --project unit"
|
|
85
85
|
},
|
|
86
86
|
"peerDependencies": {},
|
|
87
87
|
"devDependencies": {
|