@openrouter/sdk 1.2.63 → 1.2.64

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.
@@ -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.63";
53
+ readonly sdkVersion: "1.2.64";
54
54
  readonly genVersion: "2.914.0";
55
- readonly userAgent: "speakeasy-sdk/typescript 1.2.63 2.914.0 1.0.0 @openrouter/sdk";
55
+ readonly userAgent: "speakeasy-sdk/typescript 1.2.64 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.63",
32
+ sdkVersion: "1.2.64",
33
33
  genVersion: "2.914.0",
34
- userAgent: "speakeasy-sdk/typescript 1.2.63 2.914.0 1.0.0 @openrouter/sdk",
34
+ userAgent: "speakeasy-sdk/typescript 1.2.64 2.914.0 1.0.0 @openrouter/sdk",
35
35
  };
36
36
  //# sourceMappingURL=config.js.map
@@ -4,6 +4,10 @@ import { ContainerNetworkPolicy, ContainerNetworkPolicy$Outbound } from "./conta
4
4
  * An OpenRouter-managed, auto-provisioned ephemeral container.
5
5
  */
6
6
  export type ContainerAutoEnvironment = {
7
+ /**
8
+ * Workspace file ids (or_file_…) to attach into the container before the first command runs. Each file is copied to the container home as a writable copy named {last 8 characters of the file id}-{base filename} (a file stored as data/report.csv with id or_file_…NR6q4V8w attaches to ~/NR6q4V8w-report.csv), so same-named files never collide; the source document is never modified. Unknown, foreign, or malformed ids fail the request with a 400 before any command executes. Max 20 ids.
9
+ */
10
+ fileIds?: Array<string> | undefined;
7
11
  /**
8
12
  * Network egress policy for the container. "disabled" blocks all outbound internet; "allowlist" permits only hosts matching the listed hostnames or * glob patterns (ports 80/443, DNS via Cloudflare resolvers). The policy is fixed when a container starts: sending a different policy to a warm container fails the request with a 409. Omitted: defaults to "disabled" (no outbound internet). For unrestricted egress, use an allowlist of ["*"].
9
13
  */
@@ -12,6 +16,7 @@ export type ContainerAutoEnvironment = {
12
16
  };
13
17
  /** @internal */
14
18
  export type ContainerAutoEnvironment$Outbound = {
19
+ file_ids?: Array<string> | undefined;
15
20
  network_policy?: ContainerNetworkPolicy$Outbound | undefined;
16
21
  type: "container_auto";
17
22
  };
@@ -7,10 +7,12 @@ import { remap as remap$ } from "../lib/primitives.js";
7
7
  import { ContainerNetworkPolicy$outboundSchema, } from "./containernetworkpolicy.js";
8
8
  /** @internal */
9
9
  export const ContainerAutoEnvironment$outboundSchema = z.object({
10
+ fileIds: z.array(z.string()).optional(),
10
11
  networkPolicy: ContainerNetworkPolicy$outboundSchema.optional(),
11
12
  type: z.literal("container_auto"),
12
13
  }).transform((v) => {
13
14
  return remap$(v, {
15
+ fileIds: "file_ids",
14
16
  networkPolicy: "network_policy",
15
17
  });
16
18
  });
@@ -8,6 +8,10 @@ export type ContainerReferenceEnvironment = {
8
8
  * Canonical container id to reuse (max 40 characters, letters/digits/underscores/hyphens). Any container_id previously returned by a bash or shell tool result works here and reattaches to the same container and files — including session-derived ids (sess_...) and generation-derived ids (gen_...). Note that a session-derived id is always sess_ + the sanitized session key, which is not necessarily the raw session id you sent. Using the same container_id from both the bash and shell tools shares the same files, with last-write-wins when both flush concurrently. A fresh name creates a new persistent container. Containers are always scoped to your account and workspace.
9
9
  */
10
10
  containerId: string;
11
+ /**
12
+ * Workspace file ids (or_file_…) to attach into the container before the first command runs. Each file is copied to the container home as a writable copy named {last 8 characters of the file id}-{base filename} (a file stored as data/report.csv with id or_file_…NR6q4V8w attaches to ~/NR6q4V8w-report.csv), so same-named files never collide; the source document is never modified. Unknown, foreign, or malformed ids fail the request with a 400 before any command executes. Max 20 ids.
13
+ */
14
+ fileIds?: Array<string> | undefined;
11
15
  /**
12
16
  * Network egress policy for the container. "disabled" blocks all outbound internet; "allowlist" permits only hosts matching the listed hostnames or * glob patterns (ports 80/443, DNS via Cloudflare resolvers). The policy is fixed when a container starts: sending a different policy to a warm container fails the request with a 409. Omitted: defaults to "disabled" (no outbound internet). For unrestricted egress, use an allowlist of ["*"].
13
17
  */
@@ -17,6 +21,7 @@ export type ContainerReferenceEnvironment = {
17
21
  /** @internal */
18
22
  export type ContainerReferenceEnvironment$Outbound = {
19
23
  container_id: string;
24
+ file_ids?: Array<string> | undefined;
20
25
  network_policy?: ContainerNetworkPolicy$Outbound | undefined;
21
26
  type: "container_reference";
22
27
  };
@@ -8,11 +8,13 @@ import { ContainerNetworkPolicy$outboundSchema, } from "./containernetworkpolicy
8
8
  /** @internal */
9
9
  export const ContainerReferenceEnvironment$outboundSchema = z.object({
10
10
  containerId: z.string(),
11
+ fileIds: z.array(z.string()).optional(),
11
12
  networkPolicy: ContainerNetworkPolicy$outboundSchema.optional(),
12
13
  type: z.literal("container_reference"),
13
14
  }).transform((v) => {
14
15
  return remap$(v, {
15
16
  containerId: "container_id",
17
+ fileIds: "file_ids",
16
18
  networkPolicy: "network_policy",
17
19
  });
18
20
  });
package/jsr.json CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  {
4
4
  "name": "@openrouter/sdk",
5
- "version": "1.2.63",
5
+ "version": "1.2.64",
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.63",
3
+ "version": "1.2.64",
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
- "provenance": true,
25
- "access": "public"
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
- "test:watch": "vitest --watch --project unit",
77
- "compile": "tsc",
78
- "postinstall": "node scripts/check-types.js || true",
79
- "prepare": "npm run build",
80
- "test": "vitest --run --project unit",
81
76
  "test:e2e": "vitest --run --project e2e",
77
+ "compile": "tsc",
82
78
  "test:transit": "exit 0",
79
+ "test:watch": "vitest --watch --project unit",
83
80
  "typecheck": "tsc --noEmit",
84
- "typecheck:transit": "exit 0"
81
+ "typecheck:transit": "exit 0",
82
+ "postinstall": "node scripts/check-types.js || true",
83
+ "prepare": "npm run build",
84
+ "test": "vitest --run --project unit"
85
85
  },
86
86
  "peerDependencies": {},
87
87
  "devDependencies": {