@openrouter/sdk 0.12.19 → 0.12.21

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.
Files changed (62) hide show
  1. package/esm/lib/config.d.ts +2 -2
  2. package/esm/lib/config.js +2 -2
  3. package/esm/models/chatwebsearchshorthand.d.ts +1 -1
  4. package/esm/models/createworkspacerequest.d.ts +10 -0
  5. package/esm/models/createworkspacerequest.js +4 -0
  6. package/esm/models/generationresponse.d.ts +4 -0
  7. package/esm/models/generationresponse.js +2 -0
  8. package/esm/models/inputsunion.d.ts +18 -4
  9. package/esm/models/inputsunion.js +42 -0
  10. package/esm/models/outputapplypatchservertoolitem.d.ts +21 -1
  11. package/esm/models/outputapplypatchservertoolitem.js +20 -2
  12. package/esm/models/outputbashservertoolitem.d.ts +23 -1
  13. package/esm/models/outputbashservertoolitem.js +22 -2
  14. package/esm/models/outputbrowseruseservertoolitem.d.ts +21 -1
  15. package/esm/models/outputbrowseruseservertoolitem.js +20 -2
  16. package/esm/models/outputcodeinterpretercallitem.d.ts +43 -1
  17. package/esm/models/outputcodeinterpretercallitem.js +52 -2
  18. package/esm/models/outputcodeinterpreterservertoolitem.d.ts +24 -1
  19. package/esm/models/outputcodeinterpreterservertoolitem.js +23 -2
  20. package/esm/models/outputcomputercallitem.d.ts +33 -2
  21. package/esm/models/outputcomputercallitem.js +36 -1
  22. package/esm/models/outputfilesearchservertoolitem.d.ts +20 -1
  23. package/esm/models/outputfilesearchservertoolitem.js +19 -2
  24. package/esm/models/outputimagegenerationservertoolitem.d.ts +23 -1
  25. package/esm/models/outputimagegenerationservertoolitem.js +22 -2
  26. package/esm/models/outputitems.d.ts +31 -3
  27. package/esm/models/outputitems.js +19 -14
  28. package/esm/models/outputmcpservertoolitem.d.ts +21 -1
  29. package/esm/models/outputmcpservertoolitem.js +20 -2
  30. package/esm/models/outputmemoryservertoolitem.d.ts +24 -2
  31. package/esm/models/outputmemoryservertoolitem.js +23 -2
  32. package/esm/models/outputmodality.d.ts +1 -1
  33. package/esm/models/outputmodality.js +1 -1
  34. package/esm/models/outputsearchmodelsservertoolitem.d.ts +21 -1
  35. package/esm/models/outputsearchmodelsservertoolitem.js +20 -2
  36. package/esm/models/outputtexteditorservertoolitem.d.ts +23 -2
  37. package/esm/models/outputtexteditorservertoolitem.js +23 -2
  38. package/esm/models/outputtoolsearchservertoolitem.d.ts +20 -1
  39. package/esm/models/outputtoolsearchservertoolitem.js +19 -2
  40. package/esm/models/outputwebfetchservertoolitem.d.ts +22 -1
  41. package/esm/models/outputwebfetchservertoolitem.js +21 -2
  42. package/esm/models/providername.d.ts +2 -0
  43. package/esm/models/providername.js +2 -0
  44. package/esm/models/providerresponse.d.ts +2 -0
  45. package/esm/models/providerresponse.js +2 -0
  46. package/esm/models/searchqualitylevel.d.ts +2 -2
  47. package/esm/models/searchqualitylevel.js +1 -1
  48. package/esm/models/speechrequest.d.ts +12 -0
  49. package/esm/models/speechrequest.js +3 -0
  50. package/esm/models/updateworkspacerequest.d.ts +10 -0
  51. package/esm/models/updateworkspacerequest.js +4 -0
  52. package/esm/models/videogenerationrequest.d.ts +17 -0
  53. package/esm/models/videogenerationrequest.js +5 -0
  54. package/esm/models/websearchconfig.d.ts +1 -1
  55. package/esm/models/websearchplugin.d.ts +35 -0
  56. package/esm/models/websearchplugin.js +21 -0
  57. package/esm/models/websearchuserlocationservertool.d.ts +8 -8
  58. package/esm/models/websearchuserlocationservertool.js +4 -4
  59. package/esm/models/workspace.d.ts +8 -0
  60. package/esm/models/workspace.js +4 -0
  61. package/jsr.json +1 -1
  62. package/package.json +4 -4
@@ -1,5 +1,5 @@
1
1
  import * as z from "zod/v4";
2
- import { OpenEnum } from "../types/enums.js";
2
+ import { ClosedEnum, OpenEnum } from "../types/enums.js";
3
3
  import { Result as SafeParseResult } from "../types/fp.js";
4
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
5
5
  import { ToolCallStatus } from "./toolcallstatus.js";
@@ -9,6 +9,10 @@ export declare const ActionEnum: {
9
9
  readonly Delete: "delete";
10
10
  };
11
11
  export type ActionEnum = OpenEnum<typeof ActionEnum>;
12
+ export declare const OutputMemoryServerToolItemType: {
13
+ readonly OpenrouterMemory: "openrouter:memory";
14
+ };
15
+ export type OutputMemoryServerToolItemType = ClosedEnum<typeof OutputMemoryServerToolItemType>;
12
16
  /**
13
17
  * An openrouter:memory server tool output item
14
18
  */
@@ -17,12 +21,30 @@ export type OutputMemoryServerToolItem = {
17
21
  id?: string | undefined;
18
22
  key?: string | undefined;
19
23
  status: ToolCallStatus;
20
- type: "openrouter:memory";
24
+ type: OutputMemoryServerToolItemType;
21
25
  value?: any | null | undefined;
22
26
  };
23
27
  /** @internal */
24
28
  export declare const ActionEnum$inboundSchema: z.ZodType<ActionEnum, unknown>;
25
29
  /** @internal */
30
+ export declare const ActionEnum$outboundSchema: z.ZodType<string, ActionEnum>;
31
+ /** @internal */
32
+ export declare const OutputMemoryServerToolItemType$inboundSchema: z.ZodEnum<typeof OutputMemoryServerToolItemType>;
33
+ /** @internal */
34
+ export declare const OutputMemoryServerToolItemType$outboundSchema: z.ZodEnum<typeof OutputMemoryServerToolItemType>;
35
+ /** @internal */
26
36
  export declare const OutputMemoryServerToolItem$inboundSchema: z.ZodType<OutputMemoryServerToolItem, unknown>;
37
+ /** @internal */
38
+ export type OutputMemoryServerToolItem$Outbound = {
39
+ action?: string | undefined;
40
+ id?: string | undefined;
41
+ key?: string | undefined;
42
+ status: string;
43
+ type: string;
44
+ value?: any | null | undefined;
45
+ };
46
+ /** @internal */
47
+ export declare const OutputMemoryServerToolItem$outboundSchema: z.ZodType<OutputMemoryServerToolItem$Outbound, OutputMemoryServerToolItem>;
48
+ export declare function outputMemoryServerToolItemToJSON(outputMemoryServerToolItem: OutputMemoryServerToolItem): string;
27
49
  export declare function outputMemoryServerToolItemFromJSON(jsonString: string): SafeParseResult<OutputMemoryServerToolItem, SDKValidationError>;
28
50
  //# sourceMappingURL=outputmemoryservertoolitem.d.ts.map
@@ -5,23 +5,44 @@
5
5
  import * as z from "zod/v4";
6
6
  import { safeParse } from "../lib/schemas.js";
7
7
  import * as openEnums from "../types/enums.js";
8
- import { ToolCallStatus$inboundSchema, } from "./toolcallstatus.js";
8
+ import { ToolCallStatus$inboundSchema, ToolCallStatus$outboundSchema, } from "./toolcallstatus.js";
9
9
  export const ActionEnum = {
10
10
  Read: "read",
11
11
  Write: "write",
12
12
  Delete: "delete",
13
13
  };
14
+ export const OutputMemoryServerToolItemType = {
15
+ OpenrouterMemory: "openrouter:memory",
16
+ };
14
17
  /** @internal */
15
18
  export const ActionEnum$inboundSchema = openEnums.inboundSchema(ActionEnum);
16
19
  /** @internal */
20
+ export const ActionEnum$outboundSchema = openEnums.outboundSchema(ActionEnum);
21
+ /** @internal */
22
+ export const OutputMemoryServerToolItemType$inboundSchema = z.enum(OutputMemoryServerToolItemType);
23
+ /** @internal */
24
+ export const OutputMemoryServerToolItemType$outboundSchema = OutputMemoryServerToolItemType$inboundSchema;
25
+ /** @internal */
17
26
  export const OutputMemoryServerToolItem$inboundSchema = z.object({
18
27
  action: ActionEnum$inboundSchema.optional(),
19
28
  id: z.string().optional(),
20
29
  key: z.string().optional(),
21
30
  status: ToolCallStatus$inboundSchema,
22
- type: z.literal("openrouter:memory"),
31
+ type: OutputMemoryServerToolItemType$inboundSchema,
32
+ value: z.nullable(z.any()).optional(),
33
+ });
34
+ /** @internal */
35
+ export const OutputMemoryServerToolItem$outboundSchema = z.object({
36
+ action: ActionEnum$outboundSchema.optional(),
37
+ id: z.string().optional(),
38
+ key: z.string().optional(),
39
+ status: ToolCallStatus$outboundSchema,
40
+ type: OutputMemoryServerToolItemType$outboundSchema,
23
41
  value: z.nullable(z.any()).optional(),
24
42
  });
43
+ export function outputMemoryServerToolItemToJSON(outputMemoryServerToolItem) {
44
+ return JSON.stringify(OutputMemoryServerToolItem$outboundSchema.parse(outputMemoryServerToolItem));
45
+ }
25
46
  export function outputMemoryServerToolItemFromJSON(jsonString) {
26
47
  return safeParse(jsonString, (x) => OutputMemoryServerToolItem$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputMemoryServerToolItem' from JSON`);
27
48
  }
@@ -7,7 +7,7 @@ export declare const OutputModality: {
7
7
  readonly Audio: "audio";
8
8
  readonly Video: "video";
9
9
  readonly Rerank: "rerank";
10
- readonly Tts: "tts";
10
+ readonly Speech: "speech";
11
11
  };
12
12
  export type OutputModality = OpenEnum<typeof OutputModality>;
13
13
  /** @internal */
@@ -10,7 +10,7 @@ export const OutputModality = {
10
10
  Audio: "audio",
11
11
  Video: "video",
12
12
  Rerank: "rerank",
13
- Tts: "tts",
13
+ Speech: "speech",
14
14
  };
15
15
  /** @internal */
16
16
  export const OutputModality$inboundSchema = openEnums.inboundSchema(OutputModality);
@@ -1,7 +1,12 @@
1
1
  import * as z from "zod/v4";
2
+ import { ClosedEnum } from "../types/enums.js";
2
3
  import { Result as SafeParseResult } from "../types/fp.js";
3
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
5
  import { ToolCallStatus } from "./toolcallstatus.js";
6
+ export declare const OutputSearchModelsServerToolItemType: {
7
+ readonly OpenrouterExperimentalSearchModels: "openrouter:experimental__search_models";
8
+ };
9
+ export type OutputSearchModelsServerToolItemType = ClosedEnum<typeof OutputSearchModelsServerToolItemType>;
5
10
  /**
6
11
  * An openrouter:experimental__search_models server tool output item
7
12
  */
@@ -13,9 +18,24 @@ export type OutputSearchModelsServerToolItem = {
13
18
  id?: string | undefined;
14
19
  query?: string | undefined;
15
20
  status: ToolCallStatus;
16
- type: "openrouter:experimental__search_models";
21
+ type: OutputSearchModelsServerToolItemType;
17
22
  };
18
23
  /** @internal */
24
+ export declare const OutputSearchModelsServerToolItemType$inboundSchema: z.ZodEnum<typeof OutputSearchModelsServerToolItemType>;
25
+ /** @internal */
26
+ export declare const OutputSearchModelsServerToolItemType$outboundSchema: z.ZodEnum<typeof OutputSearchModelsServerToolItemType>;
27
+ /** @internal */
19
28
  export declare const OutputSearchModelsServerToolItem$inboundSchema: z.ZodType<OutputSearchModelsServerToolItem, unknown>;
29
+ /** @internal */
30
+ export type OutputSearchModelsServerToolItem$Outbound = {
31
+ arguments?: string | undefined;
32
+ id?: string | undefined;
33
+ query?: string | undefined;
34
+ status: string;
35
+ type: string;
36
+ };
37
+ /** @internal */
38
+ export declare const OutputSearchModelsServerToolItem$outboundSchema: z.ZodType<OutputSearchModelsServerToolItem$Outbound, OutputSearchModelsServerToolItem>;
39
+ export declare function outputSearchModelsServerToolItemToJSON(outputSearchModelsServerToolItem: OutputSearchModelsServerToolItem): string;
20
40
  export declare function outputSearchModelsServerToolItemFromJSON(jsonString: string): SafeParseResult<OutputSearchModelsServerToolItem, SDKValidationError>;
21
41
  //# sourceMappingURL=outputsearchmodelsservertoolitem.d.ts.map
@@ -4,15 +4,33 @@
4
4
  */
5
5
  import * as z from "zod/v4";
6
6
  import { safeParse } from "../lib/schemas.js";
7
- import { ToolCallStatus$inboundSchema, } from "./toolcallstatus.js";
7
+ import { ToolCallStatus$inboundSchema, ToolCallStatus$outboundSchema, } from "./toolcallstatus.js";
8
+ export const OutputSearchModelsServerToolItemType = {
9
+ OpenrouterExperimentalSearchModels: "openrouter:experimental__search_models",
10
+ };
11
+ /** @internal */
12
+ export const OutputSearchModelsServerToolItemType$inboundSchema = z.enum(OutputSearchModelsServerToolItemType);
13
+ /** @internal */
14
+ export const OutputSearchModelsServerToolItemType$outboundSchema = OutputSearchModelsServerToolItemType$inboundSchema;
8
15
  /** @internal */
9
16
  export const OutputSearchModelsServerToolItem$inboundSchema = z.object({
10
17
  arguments: z.string().optional(),
11
18
  id: z.string().optional(),
12
19
  query: z.string().optional(),
13
20
  status: ToolCallStatus$inboundSchema,
14
- type: z.literal("openrouter:experimental__search_models"),
21
+ type: OutputSearchModelsServerToolItemType$inboundSchema,
22
+ });
23
+ /** @internal */
24
+ export const OutputSearchModelsServerToolItem$outboundSchema = z.object({
25
+ arguments: z.string().optional(),
26
+ id: z.string().optional(),
27
+ query: z.string().optional(),
28
+ status: ToolCallStatus$outboundSchema,
29
+ type: OutputSearchModelsServerToolItemType$outboundSchema,
15
30
  });
31
+ export function outputSearchModelsServerToolItemToJSON(outputSearchModelsServerToolItem) {
32
+ return JSON.stringify(OutputSearchModelsServerToolItem$outboundSchema.parse(outputSearchModelsServerToolItem));
33
+ }
16
34
  export function outputSearchModelsServerToolItemFromJSON(jsonString) {
17
35
  return safeParse(jsonString, (x) => OutputSearchModelsServerToolItem$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputSearchModelsServerToolItem' from JSON`);
18
36
  }
@@ -1,5 +1,5 @@
1
1
  import * as z from "zod/v4";
2
- import { OpenEnum } from "../types/enums.js";
2
+ import { ClosedEnum, OpenEnum } from "../types/enums.js";
3
3
  import { Result as SafeParseResult } from "../types/fp.js";
4
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
5
5
  import { ToolCallStatus } from "./toolcallstatus.js";
@@ -10,6 +10,10 @@ export declare const Command: {
10
10
  readonly Insert: "insert";
11
11
  };
12
12
  export type Command = OpenEnum<typeof Command>;
13
+ export declare const OutputTextEditorServerToolItemType: {
14
+ readonly OpenrouterTextEditor: "openrouter:text_editor";
15
+ };
16
+ export type OutputTextEditorServerToolItemType = ClosedEnum<typeof OutputTextEditorServerToolItemType>;
13
17
  /**
14
18
  * An openrouter:text_editor server tool output item
15
19
  */
@@ -18,11 +22,28 @@ export type OutputTextEditorServerToolItem = {
18
22
  filePath?: string | undefined;
19
23
  id?: string | undefined;
20
24
  status: ToolCallStatus;
21
- type: "openrouter:text_editor";
25
+ type: OutputTextEditorServerToolItemType;
22
26
  };
23
27
  /** @internal */
24
28
  export declare const Command$inboundSchema: z.ZodType<Command, unknown>;
25
29
  /** @internal */
30
+ export declare const Command$outboundSchema: z.ZodType<string, Command>;
31
+ /** @internal */
32
+ export declare const OutputTextEditorServerToolItemType$inboundSchema: z.ZodEnum<typeof OutputTextEditorServerToolItemType>;
33
+ /** @internal */
34
+ export declare const OutputTextEditorServerToolItemType$outboundSchema: z.ZodEnum<typeof OutputTextEditorServerToolItemType>;
35
+ /** @internal */
26
36
  export declare const OutputTextEditorServerToolItem$inboundSchema: z.ZodType<OutputTextEditorServerToolItem, unknown>;
37
+ /** @internal */
38
+ export type OutputTextEditorServerToolItem$Outbound = {
39
+ command?: string | undefined;
40
+ filePath?: string | undefined;
41
+ id?: string | undefined;
42
+ status: string;
43
+ type: string;
44
+ };
45
+ /** @internal */
46
+ export declare const OutputTextEditorServerToolItem$outboundSchema: z.ZodType<OutputTextEditorServerToolItem$Outbound, OutputTextEditorServerToolItem>;
47
+ export declare function outputTextEditorServerToolItemToJSON(outputTextEditorServerToolItem: OutputTextEditorServerToolItem): string;
27
48
  export declare function outputTextEditorServerToolItemFromJSON(jsonString: string): SafeParseResult<OutputTextEditorServerToolItem, SDKValidationError>;
28
49
  //# sourceMappingURL=outputtexteditorservertoolitem.d.ts.map
@@ -5,24 +5,45 @@
5
5
  import * as z from "zod/v4";
6
6
  import { safeParse } from "../lib/schemas.js";
7
7
  import * as openEnums from "../types/enums.js";
8
- import { ToolCallStatus$inboundSchema, } from "./toolcallstatus.js";
8
+ import { ToolCallStatus$inboundSchema, ToolCallStatus$outboundSchema, } from "./toolcallstatus.js";
9
9
  export const Command = {
10
10
  View: "view",
11
11
  Create: "create",
12
12
  StrReplace: "str_replace",
13
13
  Insert: "insert",
14
14
  };
15
+ export const OutputTextEditorServerToolItemType = {
16
+ OpenrouterTextEditor: "openrouter:text_editor",
17
+ };
15
18
  /** @internal */
16
19
  export const Command$inboundSchema = openEnums
17
20
  .inboundSchema(Command);
18
21
  /** @internal */
22
+ export const Command$outboundSchema = openEnums
23
+ .outboundSchema(Command);
24
+ /** @internal */
25
+ export const OutputTextEditorServerToolItemType$inboundSchema = z.enum(OutputTextEditorServerToolItemType);
26
+ /** @internal */
27
+ export const OutputTextEditorServerToolItemType$outboundSchema = OutputTextEditorServerToolItemType$inboundSchema;
28
+ /** @internal */
19
29
  export const OutputTextEditorServerToolItem$inboundSchema = z.object({
20
30
  command: Command$inboundSchema.optional(),
21
31
  filePath: z.string().optional(),
22
32
  id: z.string().optional(),
23
33
  status: ToolCallStatus$inboundSchema,
24
- type: z.literal("openrouter:text_editor"),
34
+ type: OutputTextEditorServerToolItemType$inboundSchema,
25
35
  });
36
+ /** @internal */
37
+ export const OutputTextEditorServerToolItem$outboundSchema = z.object({
38
+ command: Command$outboundSchema.optional(),
39
+ filePath: z.string().optional(),
40
+ id: z.string().optional(),
41
+ status: ToolCallStatus$outboundSchema,
42
+ type: OutputTextEditorServerToolItemType$outboundSchema,
43
+ });
44
+ export function outputTextEditorServerToolItemToJSON(outputTextEditorServerToolItem) {
45
+ return JSON.stringify(OutputTextEditorServerToolItem$outboundSchema.parse(outputTextEditorServerToolItem));
46
+ }
26
47
  export function outputTextEditorServerToolItemFromJSON(jsonString) {
27
48
  return safeParse(jsonString, (x) => OutputTextEditorServerToolItem$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputTextEditorServerToolItem' from JSON`);
28
49
  }
@@ -1,7 +1,12 @@
1
1
  import * as z from "zod/v4";
2
+ import { ClosedEnum } from "../types/enums.js";
2
3
  import { Result as SafeParseResult } from "../types/fp.js";
3
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
5
  import { ToolCallStatus } from "./toolcallstatus.js";
6
+ export declare const OutputToolSearchServerToolItemType: {
7
+ readonly OpenrouterToolSearch: "openrouter:tool_search";
8
+ };
9
+ export type OutputToolSearchServerToolItemType = ClosedEnum<typeof OutputToolSearchServerToolItemType>;
5
10
  /**
6
11
  * An openrouter:tool_search server tool output item
7
12
  */
@@ -9,9 +14,23 @@ export type OutputToolSearchServerToolItem = {
9
14
  id?: string | undefined;
10
15
  query?: string | undefined;
11
16
  status: ToolCallStatus;
12
- type: "openrouter:tool_search";
17
+ type: OutputToolSearchServerToolItemType;
13
18
  };
14
19
  /** @internal */
20
+ export declare const OutputToolSearchServerToolItemType$inboundSchema: z.ZodEnum<typeof OutputToolSearchServerToolItemType>;
21
+ /** @internal */
22
+ export declare const OutputToolSearchServerToolItemType$outboundSchema: z.ZodEnum<typeof OutputToolSearchServerToolItemType>;
23
+ /** @internal */
15
24
  export declare const OutputToolSearchServerToolItem$inboundSchema: z.ZodType<OutputToolSearchServerToolItem, unknown>;
25
+ /** @internal */
26
+ export type OutputToolSearchServerToolItem$Outbound = {
27
+ id?: string | undefined;
28
+ query?: string | undefined;
29
+ status: string;
30
+ type: string;
31
+ };
32
+ /** @internal */
33
+ export declare const OutputToolSearchServerToolItem$outboundSchema: z.ZodType<OutputToolSearchServerToolItem$Outbound, OutputToolSearchServerToolItem>;
34
+ export declare function outputToolSearchServerToolItemToJSON(outputToolSearchServerToolItem: OutputToolSearchServerToolItem): string;
16
35
  export declare function outputToolSearchServerToolItemFromJSON(jsonString: string): SafeParseResult<OutputToolSearchServerToolItem, SDKValidationError>;
17
36
  //# sourceMappingURL=outputtoolsearchservertoolitem.d.ts.map
@@ -4,14 +4,31 @@
4
4
  */
5
5
  import * as z from "zod/v4";
6
6
  import { safeParse } from "../lib/schemas.js";
7
- import { ToolCallStatus$inboundSchema, } from "./toolcallstatus.js";
7
+ import { ToolCallStatus$inboundSchema, ToolCallStatus$outboundSchema, } from "./toolcallstatus.js";
8
+ export const OutputToolSearchServerToolItemType = {
9
+ OpenrouterToolSearch: "openrouter:tool_search",
10
+ };
11
+ /** @internal */
12
+ export const OutputToolSearchServerToolItemType$inboundSchema = z.enum(OutputToolSearchServerToolItemType);
13
+ /** @internal */
14
+ export const OutputToolSearchServerToolItemType$outboundSchema = OutputToolSearchServerToolItemType$inboundSchema;
8
15
  /** @internal */
9
16
  export const OutputToolSearchServerToolItem$inboundSchema = z.object({
10
17
  id: z.string().optional(),
11
18
  query: z.string().optional(),
12
19
  status: ToolCallStatus$inboundSchema,
13
- type: z.literal("openrouter:tool_search"),
20
+ type: OutputToolSearchServerToolItemType$inboundSchema,
14
21
  });
22
+ /** @internal */
23
+ export const OutputToolSearchServerToolItem$outboundSchema = z.object({
24
+ id: z.string().optional(),
25
+ query: z.string().optional(),
26
+ status: ToolCallStatus$outboundSchema,
27
+ type: OutputToolSearchServerToolItemType$outboundSchema,
28
+ });
29
+ export function outputToolSearchServerToolItemToJSON(outputToolSearchServerToolItem) {
30
+ return JSON.stringify(OutputToolSearchServerToolItem$outboundSchema.parse(outputToolSearchServerToolItem));
31
+ }
15
32
  export function outputToolSearchServerToolItemFromJSON(jsonString) {
16
33
  return safeParse(jsonString, (x) => OutputToolSearchServerToolItem$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputToolSearchServerToolItem' from JSON`);
17
34
  }
@@ -1,7 +1,12 @@
1
1
  import * as z from "zod/v4";
2
+ import { ClosedEnum } from "../types/enums.js";
2
3
  import { Result as SafeParseResult } from "../types/fp.js";
3
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
5
  import { ToolCallStatus } from "./toolcallstatus.js";
6
+ export declare const OutputWebFetchServerToolItemType: {
7
+ readonly OpenrouterWebFetch: "openrouter:web_fetch";
8
+ };
9
+ export type OutputWebFetchServerToolItemType = ClosedEnum<typeof OutputWebFetchServerToolItemType>;
5
10
  /**
6
11
  * An openrouter:web_fetch server tool output item
7
12
  */
@@ -10,10 +15,26 @@ export type OutputWebFetchServerToolItem = {
10
15
  id?: string | undefined;
11
16
  status: ToolCallStatus;
12
17
  title?: string | undefined;
13
- type: "openrouter:web_fetch";
18
+ type: OutputWebFetchServerToolItemType;
14
19
  url?: string | undefined;
15
20
  };
16
21
  /** @internal */
22
+ export declare const OutputWebFetchServerToolItemType$inboundSchema: z.ZodEnum<typeof OutputWebFetchServerToolItemType>;
23
+ /** @internal */
24
+ export declare const OutputWebFetchServerToolItemType$outboundSchema: z.ZodEnum<typeof OutputWebFetchServerToolItemType>;
25
+ /** @internal */
17
26
  export declare const OutputWebFetchServerToolItem$inboundSchema: z.ZodType<OutputWebFetchServerToolItem, unknown>;
27
+ /** @internal */
28
+ export type OutputWebFetchServerToolItem$Outbound = {
29
+ content?: string | undefined;
30
+ id?: string | undefined;
31
+ status: string;
32
+ title?: string | undefined;
33
+ type: string;
34
+ url?: string | undefined;
35
+ };
36
+ /** @internal */
37
+ export declare const OutputWebFetchServerToolItem$outboundSchema: z.ZodType<OutputWebFetchServerToolItem$Outbound, OutputWebFetchServerToolItem>;
38
+ export declare function outputWebFetchServerToolItemToJSON(outputWebFetchServerToolItem: OutputWebFetchServerToolItem): string;
18
39
  export declare function outputWebFetchServerToolItemFromJSON(jsonString: string): SafeParseResult<OutputWebFetchServerToolItem, SDKValidationError>;
19
40
  //# sourceMappingURL=outputwebfetchservertoolitem.d.ts.map
@@ -4,16 +4,35 @@
4
4
  */
5
5
  import * as z from "zod/v4";
6
6
  import { safeParse } from "../lib/schemas.js";
7
- import { ToolCallStatus$inboundSchema, } from "./toolcallstatus.js";
7
+ import { ToolCallStatus$inboundSchema, ToolCallStatus$outboundSchema, } from "./toolcallstatus.js";
8
+ export const OutputWebFetchServerToolItemType = {
9
+ OpenrouterWebFetch: "openrouter:web_fetch",
10
+ };
11
+ /** @internal */
12
+ export const OutputWebFetchServerToolItemType$inboundSchema = z.enum(OutputWebFetchServerToolItemType);
13
+ /** @internal */
14
+ export const OutputWebFetchServerToolItemType$outboundSchema = OutputWebFetchServerToolItemType$inboundSchema;
8
15
  /** @internal */
9
16
  export const OutputWebFetchServerToolItem$inboundSchema = z.object({
10
17
  content: z.string().optional(),
11
18
  id: z.string().optional(),
12
19
  status: ToolCallStatus$inboundSchema,
13
20
  title: z.string().optional(),
14
- type: z.literal("openrouter:web_fetch"),
21
+ type: OutputWebFetchServerToolItemType$inboundSchema,
15
22
  url: z.string().optional(),
16
23
  });
24
+ /** @internal */
25
+ export const OutputWebFetchServerToolItem$outboundSchema = z.object({
26
+ content: z.string().optional(),
27
+ id: z.string().optional(),
28
+ status: ToolCallStatus$outboundSchema,
29
+ title: z.string().optional(),
30
+ type: OutputWebFetchServerToolItemType$outboundSchema,
31
+ url: z.string().optional(),
32
+ });
33
+ export function outputWebFetchServerToolItemToJSON(outputWebFetchServerToolItem) {
34
+ return JSON.stringify(OutputWebFetchServerToolItem$outboundSchema.parse(outputWebFetchServerToolItem));
35
+ }
17
36
  export function outputWebFetchServerToolItemFromJSON(jsonString) {
18
37
  return safeParse(jsonString, (x) => OutputWebFetchServerToolItem$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputWebFetchServerToolItem' from JSON`);
19
38
  }
@@ -53,12 +53,14 @@ export declare const ProviderName: {
53
53
  readonly Morph: "Morph";
54
54
  readonly NCompass: "NCompass";
55
55
  readonly Nebius: "Nebius";
56
+ readonly NexAGI: "Nex AGI";
56
57
  readonly NextBit: "NextBit";
57
58
  readonly Novita: "Novita";
58
59
  readonly Nvidia: "Nvidia";
59
60
  readonly OpenAI: "OpenAI";
60
61
  readonly OpenInference: "OpenInference";
61
62
  readonly Parasail: "Parasail";
63
+ readonly Poolside: "Poolside";
62
64
  readonly Perplexity: "Perplexity";
63
65
  readonly Phala: "Phala";
64
66
  readonly Recraft: "Recraft";
@@ -56,12 +56,14 @@ export const ProviderName = {
56
56
  Morph: "Morph",
57
57
  NCompass: "NCompass",
58
58
  Nebius: "Nebius",
59
+ NexAGI: "Nex AGI",
59
60
  NextBit: "NextBit",
60
61
  Novita: "Novita",
61
62
  Nvidia: "Nvidia",
62
63
  OpenAI: "OpenAI",
63
64
  OpenInference: "OpenInference",
64
65
  Parasail: "Parasail",
66
+ Poolside: "Poolside",
65
67
  Perplexity: "Perplexity",
66
68
  Phala: "Phala",
67
69
  Recraft: "Recraft",
@@ -86,12 +86,14 @@ export declare const ProviderResponseProviderName: {
86
86
  readonly Morph: "Morph";
87
87
  readonly NCompass: "NCompass";
88
88
  readonly Nebius: "Nebius";
89
+ readonly NexAGI: "Nex AGI";
89
90
  readonly NextBit: "NextBit";
90
91
  readonly Novita: "Novita";
91
92
  readonly Nvidia: "Nvidia";
92
93
  readonly OpenAI: "OpenAI";
93
94
  readonly OpenInference: "OpenInference";
94
95
  readonly Parasail: "Parasail";
96
+ readonly Poolside: "Poolside";
95
97
  readonly Perplexity: "Perplexity";
96
98
  readonly Phala: "Phala";
97
99
  readonly Recraft: "Recraft";
@@ -90,12 +90,14 @@ export const ProviderResponseProviderName = {
90
90
  Morph: "Morph",
91
91
  NCompass: "NCompass",
92
92
  Nebius: "Nebius",
93
+ NexAGI: "Nex AGI",
93
94
  NextBit: "NextBit",
94
95
  Novita: "Novita",
95
96
  Nvidia: "Nvidia",
96
97
  OpenAI: "OpenAI",
97
98
  OpenInference: "OpenInference",
98
99
  Parasail: "Parasail",
100
+ Poolside: "Poolside",
99
101
  Perplexity: "Perplexity",
100
102
  Phala: "Phala",
101
103
  Recraft: "Recraft",
@@ -1,7 +1,7 @@
1
1
  import * as z from "zod/v4";
2
2
  import { OpenEnum } from "../types/enums.js";
3
3
  /**
4
- * How much context to retrieve per result. Defaults to medium (15000 chars). Only applies when using the Exa engine; ignored with native provider search.
4
+ * How much context to retrieve per result. Defaults to medium (15000 chars). Applies to Exa and Parallel engines; ignored with native provider search and Firecrawl.
5
5
  */
6
6
  export declare const SearchQualityLevel: {
7
7
  readonly Low: "low";
@@ -9,7 +9,7 @@ export declare const SearchQualityLevel: {
9
9
  readonly High: "high";
10
10
  };
11
11
  /**
12
- * How much context to retrieve per result. Defaults to medium (15000 chars). Only applies when using the Exa engine; ignored with native provider search.
12
+ * How much context to retrieve per result. Defaults to medium (15000 chars). Applies to Exa and Parallel engines; ignored with native provider search and Firecrawl.
13
13
  */
14
14
  export type SearchQualityLevel = OpenEnum<typeof SearchQualityLevel>;
15
15
  /** @internal */
@@ -4,7 +4,7 @@
4
4
  */
5
5
  import * as openEnums from "../types/enums.js";
6
6
  /**
7
- * How much context to retrieve per result. Defaults to medium (15000 chars). Only applies when using the Exa engine; ignored with native provider search.
7
+ * How much context to retrieve per result. Defaults to medium (15000 chars). Applies to Exa and Parallel engines; ignored with native provider search and Firecrawl.
8
8
  */
9
9
  export const SearchQualityLevel = {
10
10
  Low: "low",
@@ -217,6 +217,9 @@ export type SpeechRequestOptions = {
217
217
  nebius?: {
218
218
  [k: string]: any | null;
219
219
  } | undefined;
220
+ nexAgi?: {
221
+ [k: string]: any | null;
222
+ } | undefined;
220
223
  nextbit?: {
221
224
  [k: string]: any | null;
222
225
  } | undefined;
@@ -247,6 +250,9 @@ export type SpeechRequestOptions = {
247
250
  phala?: {
248
251
  [k: string]: any | null;
249
252
  } | undefined;
253
+ poolside?: {
254
+ [k: string]: any | null;
255
+ } | undefined;
250
256
  recraft?: {
251
257
  [k: string]: any | null;
252
258
  } | undefined;
@@ -590,6 +596,9 @@ export type SpeechRequestOptions$Outbound = {
590
596
  nebius?: {
591
597
  [k: string]: any | null;
592
598
  } | undefined;
599
+ "nex-agi"?: {
600
+ [k: string]: any | null;
601
+ } | undefined;
593
602
  nextbit?: {
594
603
  [k: string]: any | null;
595
604
  } | undefined;
@@ -620,6 +629,9 @@ export type SpeechRequestOptions$Outbound = {
620
629
  phala?: {
621
630
  [k: string]: any | null;
622
631
  } | undefined;
632
+ poolside?: {
633
+ [k: string]: any | null;
634
+ } | undefined;
623
635
  recraft?: {
624
636
  [k: string]: any | null;
625
637
  } | undefined;
@@ -85,6 +85,7 @@ export const SpeechRequestOptions$outboundSchema = z.object({
85
85
  morph: z.record(z.string(), z.nullable(z.any())).optional(),
86
86
  ncompass: z.record(z.string(), z.nullable(z.any())).optional(),
87
87
  nebius: z.record(z.string(), z.nullable(z.any())).optional(),
88
+ nexAgi: z.record(z.string(), z.nullable(z.any())).optional(),
88
89
  nextbit: z.record(z.string(), z.nullable(z.any())).optional(),
89
90
  nineteen: z.record(z.string(), z.nullable(z.any())).optional(),
90
91
  novita: z.record(z.string(), z.nullable(z.any())).optional(),
@@ -95,6 +96,7 @@ export const SpeechRequestOptions$outboundSchema = z.object({
95
96
  parasail: z.record(z.string(), z.nullable(z.any())).optional(),
96
97
  perplexity: z.record(z.string(), z.nullable(z.any())).optional(),
97
98
  phala: z.record(z.string(), z.nullable(z.any())).optional(),
99
+ poolside: z.record(z.string(), z.nullable(z.any())).optional(),
98
100
  recraft: z.record(z.string(), z.nullable(z.any())).optional(),
99
101
  recursal: z.record(z.string(), z.nullable(z.any())).optional(),
100
102
  reflection: z.record(z.string(), z.nullable(z.any())).optional(),
@@ -138,6 +140,7 @@ export const SpeechRequestOptions$outboundSchema = z.object({
138
140
  ioNet: "io-net",
139
141
  lynnPrivate: "lynn-private",
140
142
  mancerOld: "mancer-old",
143
+ nexAgi: "nex-agi",
141
144
  openInference: "open-inference",
142
145
  sambanovaCloaked: "sambanova-cloaked",
143
146
  sfCompute: "sf-compute",
@@ -16,6 +16,14 @@ export type UpdateWorkspaceRequest = {
16
16
  * New description for the workspace
17
17
  */
18
18
  description?: string | null | undefined;
19
+ /**
20
+ * Optional array of API key IDs to filter I/O logging
21
+ */
22
+ ioLoggingApiKeyIds?: Array<number> | null | undefined;
23
+ /**
24
+ * Sampling rate for I/O logging (0.0001-1)
25
+ */
26
+ ioLoggingSamplingRate?: number | undefined;
19
27
  /**
20
28
  * Whether data discount logging is enabled
21
29
  */
@@ -43,6 +51,8 @@ export type UpdateWorkspaceRequest$Outbound = {
43
51
  default_provider_sort?: string | null | undefined;
44
52
  default_text_model?: string | null | undefined;
45
53
  description?: string | null | undefined;
54
+ io_logging_api_key_ids?: Array<number> | null | undefined;
55
+ io_logging_sampling_rate?: number | undefined;
46
56
  is_data_discount_logging_enabled?: boolean | undefined;
47
57
  is_observability_broadcast_enabled?: boolean | undefined;
48
58
  is_observability_io_logging_enabled?: boolean | undefined;
@@ -10,6 +10,8 @@ export const UpdateWorkspaceRequest$outboundSchema = z.object({
10
10
  defaultProviderSort: z.nullable(z.string()).optional(),
11
11
  defaultTextModel: z.nullable(z.string()).optional(),
12
12
  description: z.nullable(z.string()).optional(),
13
+ ioLoggingApiKeyIds: z.nullable(z.array(z.int())).optional(),
14
+ ioLoggingSamplingRate: z.number().optional(),
13
15
  isDataDiscountLoggingEnabled: z.boolean().optional(),
14
16
  isObservabilityBroadcastEnabled: z.boolean().optional(),
15
17
  isObservabilityIoLoggingEnabled: z.boolean().optional(),
@@ -20,6 +22,8 @@ export const UpdateWorkspaceRequest$outboundSchema = z.object({
20
22
  defaultImageModel: "default_image_model",
21
23
  defaultProviderSort: "default_provider_sort",
22
24
  defaultTextModel: "default_text_model",
25
+ ioLoggingApiKeyIds: "io_logging_api_key_ids",
26
+ ioLoggingSamplingRate: "io_logging_sampling_rate",
23
27
  isDataDiscountLoggingEnabled: "is_data_discount_logging_enabled",
24
28
  isObservabilityBroadcastEnabled: "is_observability_broadcast_enabled",
25
29
  isObservabilityIoLoggingEnabled: "is_observability_io_logging_enabled",