@openrouter/sdk 1.5.120 → 1.5.121
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
|
@@ -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.121";
|
|
53
53
|
readonly genVersion: "2.960.8";
|
|
54
|
-
readonly userAgent: "speakeasy-sdk/typescript 1.5.
|
|
54
|
+
readonly userAgent: "speakeasy-sdk/typescript 1.5.121 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.121",
|
|
29
29
|
genVersion: "2.960.8",
|
|
30
|
-
userAgent: "speakeasy-sdk/typescript 1.5.
|
|
30
|
+
userAgent: "speakeasy-sdk/typescript 1.5.121 2.960.8 1.0.0 @openrouter/sdk",
|
|
31
31
|
};
|
|
32
32
|
//# sourceMappingURL=config.js.map
|
|
@@ -12,6 +12,19 @@ export declare const VideoGenerationResponseStatus: {
|
|
|
12
12
|
readonly Expired: "expired";
|
|
13
13
|
};
|
|
14
14
|
export type VideoGenerationResponseStatus = OpenEnum<typeof VideoGenerationResponseStatus>;
|
|
15
|
+
/**
|
|
16
|
+
* The step within `status` for a job that is not finished: `submitting` and `queued_at_provider` under `pending`, `generating` and `finalizing` under `in_progress`. When present, it only moves forward, and steps may be skipped between polls. It is absent once the job is finished and can also be absent mid-job when the step is unknown, so use `status` to tell whether the job is finished.
|
|
17
|
+
*/
|
|
18
|
+
export declare const StatusDetail: {
|
|
19
|
+
readonly Submitting: "submitting";
|
|
20
|
+
readonly QueuedAtProvider: "queued_at_provider";
|
|
21
|
+
readonly Generating: "generating";
|
|
22
|
+
readonly Finalizing: "finalizing";
|
|
23
|
+
};
|
|
24
|
+
/**
|
|
25
|
+
* The step within `status` for a job that is not finished: `submitting` and `queued_at_provider` under `pending`, `generating` and `finalizing` under `in_progress`. When present, it only moves forward, and steps may be skipped between polls. It is absent once the job is finished and can also be absent mid-job when the step is unknown, so use `status` to tell whether the job is finished.
|
|
26
|
+
*/
|
|
27
|
+
export type StatusDetail = OpenEnum<typeof StatusDetail>;
|
|
15
28
|
export type VideoGenerationResponse = {
|
|
16
29
|
error?: string | undefined;
|
|
17
30
|
/**
|
|
@@ -27,7 +40,15 @@ export type VideoGenerationResponse = {
|
|
|
27
40
|
*/
|
|
28
41
|
id: string;
|
|
29
42
|
pollingUrl: string;
|
|
43
|
+
/**
|
|
44
|
+
* Percent complete, from 0 to 100 and possibly fractional, reported by the provider while `status_detail` is `generating`. Present only for providers that report it, and absent once the job moves to `finalizing`.
|
|
45
|
+
*/
|
|
46
|
+
progress?: number | undefined;
|
|
30
47
|
status: VideoGenerationResponseStatus;
|
|
48
|
+
/**
|
|
49
|
+
* The step within `status` for a job that is not finished: `submitting` and `queued_at_provider` under `pending`, `generating` and `finalizing` under `in_progress`. When present, it only moves forward, and steps may be skipped between polls. It is absent once the job is finished and can also be absent mid-job when the step is unknown, so use `status` to tell whether the job is finished.
|
|
50
|
+
*/
|
|
51
|
+
statusDetail?: StatusDetail | undefined;
|
|
31
52
|
/**
|
|
32
53
|
* OpenRouter content URLs for each output. They need your API key in the `Authorization` header and keep working for as long as the output is available.
|
|
33
54
|
*/
|
|
@@ -44,6 +65,8 @@ export type VideoGenerationResponse = {
|
|
|
44
65
|
/** @internal */
|
|
45
66
|
export declare const VideoGenerationResponseStatus$inboundSchema: z.ZodType<VideoGenerationResponseStatus, unknown>;
|
|
46
67
|
/** @internal */
|
|
68
|
+
export declare const StatusDetail$inboundSchema: z.ZodType<StatusDetail, unknown>;
|
|
69
|
+
/** @internal */
|
|
47
70
|
export declare const VideoGenerationResponse$inboundSchema: z.ZodType<VideoGenerationResponse, unknown>;
|
|
48
71
|
export declare function videoGenerationResponseFromJSON(jsonString: string): SafeParseResult<VideoGenerationResponse, SDKValidationError>;
|
|
49
72
|
//# sourceMappingURL=videogenerationresponse.d.ts.map
|
|
@@ -14,16 +14,29 @@ export const VideoGenerationResponseStatus = {
|
|
|
14
14
|
Cancelled: "cancelled",
|
|
15
15
|
Expired: "expired",
|
|
16
16
|
};
|
|
17
|
+
/**
|
|
18
|
+
* The step within `status` for a job that is not finished: `submitting` and `queued_at_provider` under `pending`, `generating` and `finalizing` under `in_progress`. When present, it only moves forward, and steps may be skipped between polls. It is absent once the job is finished and can also be absent mid-job when the step is unknown, so use `status` to tell whether the job is finished.
|
|
19
|
+
*/
|
|
20
|
+
export const StatusDetail = {
|
|
21
|
+
Submitting: "submitting",
|
|
22
|
+
QueuedAtProvider: "queued_at_provider",
|
|
23
|
+
Generating: "generating",
|
|
24
|
+
Finalizing: "finalizing",
|
|
25
|
+
};
|
|
17
26
|
/** @internal */
|
|
18
27
|
export const VideoGenerationResponseStatus$inboundSchema = openEnums.inboundSchema(VideoGenerationResponseStatus);
|
|
19
28
|
/** @internal */
|
|
29
|
+
export const StatusDetail$inboundSchema = openEnums.inboundSchema(StatusDetail);
|
|
30
|
+
/** @internal */
|
|
20
31
|
export const VideoGenerationResponse$inboundSchema = z.object({
|
|
21
32
|
error: z.string().optional(),
|
|
22
33
|
expires_at: z.int().optional(),
|
|
23
34
|
generation_id: z.string().optional(),
|
|
24
35
|
id: z.string(),
|
|
25
36
|
polling_url: z.string(),
|
|
37
|
+
progress: z.number().optional(),
|
|
26
38
|
status: VideoGenerationResponseStatus$inboundSchema,
|
|
39
|
+
status_detail: StatusDetail$inboundSchema.optional(),
|
|
27
40
|
unsigned_urls: z.array(z.string()).optional(),
|
|
28
41
|
urls: z.array(z.string()).optional(),
|
|
29
42
|
usage: VideoGenerationUsage$inboundSchema.optional(),
|
|
@@ -32,6 +45,7 @@ export const VideoGenerationResponse$inboundSchema = z.object({
|
|
|
32
45
|
"expires_at": "expiresAt",
|
|
33
46
|
"generation_id": "generationId",
|
|
34
47
|
"polling_url": "pollingUrl",
|
|
48
|
+
"status_detail": "statusDetail",
|
|
35
49
|
"unsigned_urls": "unsignedUrls",
|
|
36
50
|
});
|
|
37
51
|
});
|
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.121",
|
|
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": "node --max-old-space-size=8192 ./node_modules/typescript/bin/tsc && node scripts/unbarrel-imports.js",
|
|
75
75
|
"prepublishOnly": "npm run build",
|
|
76
|
-
"
|
|
77
|
-
"test:watch": "vitest --watch --project unit",
|
|
78
|
-
"typecheck:transit": "exit 0",
|
|
76
|
+
"compile": "node --max-old-space-size=8192 ./node_modules/typescript/bin/tsc && node scripts/unbarrel-imports.js",
|
|
79
77
|
"postinstall": "node scripts/check-types.js || true",
|
|
78
|
+
"prepare": "npm run build",
|
|
80
79
|
"test": "vitest --run --project unit",
|
|
80
|
+
"test:transit": "exit 0",
|
|
81
|
+
"test:e2e": "vitest --run --project e2e",
|
|
82
|
+
"test:watch": "vitest --watch --project unit",
|
|
81
83
|
"typecheck": "tsc --noEmit",
|
|
82
|
-
"
|
|
83
|
-
"prepare": "npm run build",
|
|
84
|
-
"test:e2e": "vitest --run --project e2e"
|
|
84
|
+
"typecheck:transit": "exit 0"
|
|
85
85
|
},
|
|
86
86
|
"peerDependencies": {
|
|
87
87
|
|