@openrouter/sdk 0.0.1-beta.6 → 0.0.1-beta.7

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 (251) hide show
  1. package/jsr.json +1 -1
  2. package/lib/base64.d.ts +3 -3
  3. package/lib/base64.js +1 -1
  4. package/lib/config.d.ts +3 -3
  5. package/lib/config.js +3 -3
  6. package/lib/env.d.ts +2 -2
  7. package/lib/env.js +1 -1
  8. package/lib/schemas.d.ts +6 -4
  9. package/lib/schemas.js +1 -1
  10. package/models/activityitem.d.ts +5 -5
  11. package/models/activityitem.js +3 -2
  12. package/models/assistantmessage.d.ts +9 -9
  13. package/models/assistantmessage.js +1 -1
  14. package/models/chatcompletionfinishreason.d.ts +5 -5
  15. package/models/chatcompletionfinishreason.js +3 -3
  16. package/models/chaterror.d.ts +9 -9
  17. package/models/chaterror.js +9 -4
  18. package/models/chatgenerationparams.d.ts +33 -33
  19. package/models/chatgenerationparams.js +7 -7
  20. package/models/chatgenerationtokenusage.d.ts +13 -13
  21. package/models/chatgenerationtokenusage.js +1 -1
  22. package/models/chatmessagecontentitem.d.ts +5 -5
  23. package/models/chatmessagecontentitem.js +1 -1
  24. package/models/chatmessagecontentitemaudio.d.ts +13 -13
  25. package/models/chatmessagecontentitemaudio.js +5 -4
  26. package/models/chatmessagecontentitemimage.d.ts +13 -13
  27. package/models/chatmessagecontentitemimage.js +5 -4
  28. package/models/chatmessagecontentitemtext.d.ts +5 -5
  29. package/models/chatmessagecontentitemtext.js +1 -1
  30. package/models/chatmessagetokenlogprob.d.ts +9 -9
  31. package/models/chatmessagetokenlogprob.js +1 -1
  32. package/models/chatmessagetokenlogprobs.d.ts +5 -5
  33. package/models/chatmessagetokenlogprobs.js +1 -1
  34. package/models/chatmessagetoolcall.d.ts +9 -9
  35. package/models/chatmessagetoolcall.js +1 -1
  36. package/models/chatresponse.d.ts +5 -5
  37. package/models/chatresponse.js +3 -2
  38. package/models/chatresponsechoice.d.ts +5 -5
  39. package/models/chatresponsechoice.js +1 -1
  40. package/models/chatstreamingchoice.d.ts +5 -5
  41. package/models/chatstreamingchoice.js +1 -1
  42. package/models/chatstreamingmessagechunk.d.ts +9 -9
  43. package/models/chatstreamingmessagechunk.js +2 -2
  44. package/models/chatstreamingmessagetoolcall.d.ts +9 -9
  45. package/models/chatstreamingmessagetoolcall.js +1 -1
  46. package/models/chatstreamingresponsechunk.d.ts +13 -13
  47. package/models/chatstreamingresponsechunk.js +3 -5
  48. package/models/chatstreamoptions.d.ts +5 -5
  49. package/models/chatstreamoptions.js +1 -1
  50. package/models/completionchoice.d.ts +9 -9
  51. package/models/completionchoice.js +3 -3
  52. package/models/completioncreateparams.d.ts +33 -33
  53. package/models/completioncreateparams.js +10 -9
  54. package/models/completionlogprobs.d.ts +5 -5
  55. package/models/completionlogprobs.js +3 -3
  56. package/models/completionresponse.d.ts +5 -5
  57. package/models/completionresponse.js +1 -1
  58. package/models/completionusage.d.ts +5 -5
  59. package/models/completionusage.js +1 -1
  60. package/models/createchargerequest.d.ts +5 -5
  61. package/models/createchargerequest.js +1 -1
  62. package/models/errorresponse.d.ts +13 -13
  63. package/models/errorresponse.js +7 -6
  64. package/models/errors/chaterror.d.ts +5 -5
  65. package/models/errors/chaterror.js +4 -4
  66. package/models/errors/errorresponse.d.ts +5 -5
  67. package/models/errors/errorresponse.js +6 -5
  68. package/models/errors/listproviders.d.ts +5 -5
  69. package/models/errors/listproviders.js +4 -4
  70. package/models/errors/responsevalidationerror.js +1 -1
  71. package/models/errors/sdkvalidationerror.d.ts +2 -2
  72. package/models/errors/sdkvalidationerror.js +3 -50
  73. package/models/filecitationannotation.d.ts +9 -9
  74. package/models/filecitationannotation.js +2 -2
  75. package/models/filepathannotation.d.ts +9 -9
  76. package/models/filepathannotation.js +2 -2
  77. package/models/imagegenerationstatus.d.ts +5 -5
  78. package/models/imagegenerationstatus.js +3 -3
  79. package/models/jsonschemaconfig.d.ts +5 -5
  80. package/models/jsonschemaconfig.js +3 -3
  81. package/models/listendpointsresponse.d.ts +5 -5
  82. package/models/listendpointsresponse.js +1 -1
  83. package/models/message.d.ts +13 -13
  84. package/models/message.js +3 -2
  85. package/models/modelscountresponse.d.ts +5 -5
  86. package/models/modelscountresponse.js +1 -1
  87. package/models/modelslistresponse.d.ts +5 -5
  88. package/models/modelslistresponse.js +1 -1
  89. package/models/namedtoolchoice.d.ts +9 -9
  90. package/models/namedtoolchoice.js +1 -1
  91. package/models/openresponseseasyinputmessage.d.ts +33 -33
  92. package/models/openresponseseasyinputmessage.js +6 -9
  93. package/models/openresponsesformatjsonobject.d.ts +9 -9
  94. package/models/openresponsesformatjsonobject.js +2 -2
  95. package/models/openresponsesformatjsonschema.d.ts +9 -9
  96. package/models/openresponsesformatjsonschema.js +4 -4
  97. package/models/openresponsesformattext.d.ts +9 -9
  98. package/models/openresponsesformattext.js +2 -2
  99. package/models/openresponsesformattextconfig.d.ts +5 -5
  100. package/models/openresponsesformattextconfig.js +1 -1
  101. package/models/openresponsesfunctioncalloutput.d.ts +9 -9
  102. package/models/openresponsesfunctioncalloutput.js +2 -2
  103. package/models/openresponsesfunctiontoolcall.d.ts +9 -9
  104. package/models/openresponsesfunctiontoolcall.js +2 -2
  105. package/models/openresponsesinput.d.ts +5 -5
  106. package/models/openresponsesinput.js +1 -1
  107. package/models/openresponsesinputcontent.d.ts +5 -5
  108. package/models/openresponsesinputcontent.js +1 -1
  109. package/models/openresponsesinputfile.d.ts +9 -9
  110. package/models/openresponsesinputfile.js +2 -2
  111. package/models/openresponsesinputimage.d.ts +13 -13
  112. package/models/openresponsesinputimage.js +4 -4
  113. package/models/openresponsesinputitem.d.ts +5 -5
  114. package/models/openresponsesinputitem.js +1 -1
  115. package/models/openresponsesinputmessageitem.d.ts +25 -25
  116. package/models/openresponsesinputmessageitem.js +5 -7
  117. package/models/openresponsesinputtext.d.ts +9 -9
  118. package/models/openresponsesinputtext.js +2 -2
  119. package/models/openresponseslogprobs.d.ts +9 -9
  120. package/models/openresponseslogprobs.js +1 -1
  121. package/models/openresponsesnonstreamingresponse.d.ts +29 -29
  122. package/models/openresponsesnonstreamingresponse.js +17 -17
  123. package/models/openresponsesoutputtext.d.ts +13 -13
  124. package/models/openresponsesoutputtext.js +2 -2
  125. package/models/openresponsesprompt.d.ts +5 -5
  126. package/models/openresponsesprompt.js +3 -5
  127. package/models/openresponsesreasoning.d.ts +13 -13
  128. package/models/openresponsesreasoning.js +4 -4
  129. package/models/openresponsesreasoningconfig.d.ts +9 -9
  130. package/models/openresponsesreasoningconfig.js +3 -3
  131. package/models/openresponsesrefusalcontent.d.ts +9 -9
  132. package/models/openresponsesrefusalcontent.js +2 -2
  133. package/models/openresponsesrequest.d.ts +5 -5
  134. package/models/openresponsesrequest.js +1 -1
  135. package/models/openresponsesstreamevent.d.ts +233 -233
  136. package/models/openresponsesstreamevent.js +42 -43
  137. package/models/openresponsestextconfig.d.ts +9 -9
  138. package/models/openresponsestextconfig.js +5 -4
  139. package/models/openresponsestoolchoice.d.ts +25 -25
  140. package/models/openresponsestoolchoice.js +5 -5
  141. package/models/openresponsestoolunion.d.ts +13 -13
  142. package/models/openresponsestoolunion.js +4 -4
  143. package/models/openresponseswebsearch20250826tool.d.ts +13 -13
  144. package/models/openresponseswebsearch20250826tool.js +2 -2
  145. package/models/openresponseswebsearchpreview20250311tool.d.ts +9 -9
  146. package/models/openresponseswebsearchpreview20250311tool.js +2 -3
  147. package/models/openresponseswebsearchpreviewtool.d.ts +9 -9
  148. package/models/openresponseswebsearchpreviewtool.js +2 -2
  149. package/models/openresponseswebsearchtool.d.ts +13 -13
  150. package/models/openresponseswebsearchtool.js +2 -2
  151. package/models/operations/createapialpharesponses.d.ts +9 -9
  152. package/models/operations/createapialpharesponses.js +2 -3
  153. package/models/operations/createcoinbasecharge.d.ts +29 -29
  154. package/models/operations/createcoinbasecharge.js +7 -4
  155. package/models/operations/createkeys.d.ts +17 -17
  156. package/models/operations/createkeys.js +3 -3
  157. package/models/operations/deletekeys.d.ts +9 -9
  158. package/models/operations/deletekeys.js +1 -1
  159. package/models/operations/getcredits.d.ts +5 -5
  160. package/models/operations/getcredits.js +1 -1
  161. package/models/operations/getcurrentkey.d.ts +13 -13
  162. package/models/operations/getcurrentkey.js +1 -1
  163. package/models/operations/getgeneration.d.ts +17 -17
  164. package/models/operations/getgeneration.js +3 -3
  165. package/models/operations/getkey.d.ts +13 -13
  166. package/models/operations/getkey.js +5 -3
  167. package/models/operations/getmodels.d.ts +9 -9
  168. package/models/operations/getmodels.js +1 -1
  169. package/models/operations/getparameters.d.ts +25 -25
  170. package/models/operations/getparameters.js +5 -5
  171. package/models/operations/getuseractivity.d.ts +9 -9
  172. package/models/operations/getuseractivity.js +1 -1
  173. package/models/operations/list.d.ts +13 -13
  174. package/models/operations/list.js +7 -4
  175. package/models/operations/listendpoints.d.ts +9 -9
  176. package/models/operations/listendpoints.js +1 -1
  177. package/models/operations/listendpointszdr.d.ts +9 -9
  178. package/models/operations/listendpointszdr.js +1 -1
  179. package/models/operations/listmodelscount.d.ts +5 -5
  180. package/models/operations/listmodelscount.js +1 -1
  181. package/models/operations/listmodelsuser.d.ts +9 -9
  182. package/models/operations/listmodelsuser.js +1 -1
  183. package/models/operations/listproviders.d.ts +13 -13
  184. package/models/operations/listproviders.js +4 -4
  185. package/models/operations/sendchatcompletionrequest.d.ts +5 -5
  186. package/models/operations/sendchatcompletionrequest.js +2 -3
  187. package/models/operations/updatekeys.d.ts +21 -21
  188. package/models/operations/updatekeys.js +3 -3
  189. package/models/outputtextcontent.d.ts +13 -13
  190. package/models/outputtextcontent.js +2 -2
  191. package/models/publicendpoint.d.ts +5 -5
  192. package/models/publicendpoint.js +1 -1
  193. package/models/reasoningsummarytext.d.ts +9 -9
  194. package/models/reasoningsummarytext.js +2 -2
  195. package/models/reasoningsummaryverbosity.d.ts +5 -5
  196. package/models/reasoningsummaryverbosity.js +3 -3
  197. package/models/reasoningtextcontent.d.ts +9 -9
  198. package/models/reasoningtextcontent.js +2 -2
  199. package/models/refusalcontent.d.ts +9 -9
  200. package/models/refusalcontent.js +2 -2
  201. package/models/responseformatjsonschema.d.ts +5 -5
  202. package/models/responseformatjsonschema.js +1 -1
  203. package/models/responseformattextgrammar.d.ts +5 -5
  204. package/models/responseformattextgrammar.js +1 -1
  205. package/models/responseserrorfield.d.ts +9 -9
  206. package/models/responseserrorfield.js +3 -3
  207. package/models/responsesimagegenerationcall.d.ts +9 -9
  208. package/models/responsesimagegenerationcall.js +2 -2
  209. package/models/responsesoutputitem.d.ts +5 -5
  210. package/models/responsesoutputitem.js +1 -1
  211. package/models/responsesoutputitemfilesearchcall.d.ts +9 -9
  212. package/models/responsesoutputitemfilesearchcall.js +2 -2
  213. package/models/responsesoutputitemfunctioncall.d.ts +9 -9
  214. package/models/responsesoutputitemfunctioncall.js +2 -2
  215. package/models/responsesoutputitemreasoning.d.ts +9 -9
  216. package/models/responsesoutputitemreasoning.js +2 -2
  217. package/models/responsesoutputmessage.d.ts +33 -33
  218. package/models/responsesoutputmessage.js +9 -9
  219. package/models/responsessearchcontextsize.d.ts +5 -5
  220. package/models/responsessearchcontextsize.js +3 -3
  221. package/models/responsesusage.d.ts +17 -17
  222. package/models/responsesusage.js +3 -2
  223. package/models/responseswebsearchcalloutput.d.ts +9 -9
  224. package/models/responseswebsearchcalloutput.js +2 -2
  225. package/models/responseswebsearchuserlocation.d.ts +9 -9
  226. package/models/responseswebsearchuserlocation.js +2 -2
  227. package/models/security.d.ts +5 -5
  228. package/models/security.js +3 -2
  229. package/models/systemmessage.d.ts +9 -9
  230. package/models/systemmessage.js +3 -2
  231. package/models/tool.d.ts +9 -9
  232. package/models/tool.js +6 -6
  233. package/models/toolcallstatus.d.ts +5 -5
  234. package/models/toolcallstatus.js +3 -3
  235. package/models/toolchoicetypes.d.ts +29 -29
  236. package/models/toolchoicetypes.js +8 -9
  237. package/models/toolresponsemessage.d.ts +9 -9
  238. package/models/toolresponsemessage.js +1 -1
  239. package/models/urlcitationannotation.d.ts +9 -9
  240. package/models/urlcitationannotation.js +2 -2
  241. package/models/usermessage.d.ts +9 -9
  242. package/models/usermessage.js +7 -3
  243. package/models/websearchpreviewtooluserlocation.d.ts +9 -9
  244. package/models/websearchpreviewtooluserlocation.js +2 -2
  245. package/models/websearchstatus.d.ts +5 -5
  246. package/models/websearchstatus.js +3 -3
  247. package/package.json +1 -1
  248. package/types/blobs.d.ts +2 -2
  249. package/types/blobs.js +2 -2
  250. package/types/constdatetime.d.ts +2 -2
  251. package/types/constdatetime.js +1 -1
@@ -1,14 +1,15 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { safeParse } from "../lib/schemas.js";
6
6
  /** @internal */
7
7
  export const Security$inboundSchema = z.object({
8
8
  apiKey: z.string().optional(),
9
9
  });
10
10
  /** @internal */
11
- export const Security$outboundSchema = z.object({
11
+ export const Security$outboundSchema = z
12
+ .object({
12
13
  apiKey: z.string().optional(),
13
14
  });
14
15
  /**
@@ -1,4 +1,4 @@
1
- import * as z from "zod/v3";
1
+ import * as z from "zod/v4";
2
2
  import { Result as SafeParseResult } from "../types/fp.js";
3
3
  import { ChatMessageContentItemText, ChatMessageContentItemText$Outbound } from "./chatmessagecontentitemtext.js";
4
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
@@ -9,27 +9,27 @@ export type SystemMessage = {
9
9
  name?: string | undefined;
10
10
  };
11
11
  /** @internal */
12
- export declare const SystemMessageContent$inboundSchema: z.ZodType<SystemMessageContent, z.ZodTypeDef, unknown>;
12
+ export declare const SystemMessageContent$inboundSchema: z.ZodType<SystemMessageContent, unknown>;
13
13
  /** @internal */
14
14
  export type SystemMessageContent$Outbound = string | Array<ChatMessageContentItemText$Outbound>;
15
15
  /** @internal */
16
- export declare const SystemMessageContent$outboundSchema: z.ZodType<SystemMessageContent$Outbound, z.ZodTypeDef, SystemMessageContent>;
16
+ export declare const SystemMessageContent$outboundSchema: z.ZodType<SystemMessageContent$Outbound, SystemMessageContent>;
17
17
  /**
18
18
  * @internal
19
19
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
20
20
  */
21
21
  export declare namespace SystemMessageContent$ {
22
22
  /** @deprecated use `SystemMessageContent$inboundSchema` instead. */
23
- const inboundSchema: z.ZodType<SystemMessageContent, z.ZodTypeDef, unknown>;
23
+ const inboundSchema: z.ZodType<SystemMessageContent, unknown, z.core.$ZodTypeInternals<SystemMessageContent, unknown>>;
24
24
  /** @deprecated use `SystemMessageContent$outboundSchema` instead. */
25
- const outboundSchema: z.ZodType<SystemMessageContent$Outbound, z.ZodTypeDef, SystemMessageContent>;
25
+ const outboundSchema: z.ZodType<SystemMessageContent$Outbound, SystemMessageContent, z.core.$ZodTypeInternals<SystemMessageContent$Outbound, SystemMessageContent>>;
26
26
  /** @deprecated use `SystemMessageContent$Outbound` instead. */
27
27
  type Outbound = SystemMessageContent$Outbound;
28
28
  }
29
29
  export declare function systemMessageContentToJSON(systemMessageContent: SystemMessageContent): string;
30
30
  export declare function systemMessageContentFromJSON(jsonString: string): SafeParseResult<SystemMessageContent, SDKValidationError>;
31
31
  /** @internal */
32
- export declare const SystemMessage$inboundSchema: z.ZodType<SystemMessage, z.ZodTypeDef, unknown>;
32
+ export declare const SystemMessage$inboundSchema: z.ZodType<SystemMessage, unknown>;
33
33
  /** @internal */
34
34
  export type SystemMessage$Outbound = {
35
35
  role: "system";
@@ -37,16 +37,16 @@ export type SystemMessage$Outbound = {
37
37
  name?: string | undefined;
38
38
  };
39
39
  /** @internal */
40
- export declare const SystemMessage$outboundSchema: z.ZodType<SystemMessage$Outbound, z.ZodTypeDef, SystemMessage>;
40
+ export declare const SystemMessage$outboundSchema: z.ZodType<SystemMessage$Outbound, SystemMessage>;
41
41
  /**
42
42
  * @internal
43
43
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
44
44
  */
45
45
  export declare namespace SystemMessage$ {
46
46
  /** @deprecated use `SystemMessage$inboundSchema` instead. */
47
- const inboundSchema: z.ZodType<SystemMessage, z.ZodTypeDef, unknown>;
47
+ const inboundSchema: z.ZodType<SystemMessage, unknown, z.core.$ZodTypeInternals<SystemMessage, unknown>>;
48
48
  /** @deprecated use `SystemMessage$outboundSchema` instead. */
49
- const outboundSchema: z.ZodType<SystemMessage$Outbound, z.ZodTypeDef, SystemMessage>;
49
+ const outboundSchema: z.ZodType<SystemMessage$Outbound, SystemMessage, z.core.$ZodTypeInternals<SystemMessage$Outbound, SystemMessage>>;
50
50
  /** @deprecated use `SystemMessage$Outbound` instead. */
51
51
  type Outbound = SystemMessage$Outbound;
52
52
  }
@@ -1,7 +1,7 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { safeParse } from "../lib/schemas.js";
6
6
  import { ChatMessageContentItemText$inboundSchema, ChatMessageContentItemText$outboundSchema, } from "./chatmessagecontentitemtext.js";
7
7
  /** @internal */
@@ -26,7 +26,8 @@ export function systemMessageContentFromJSON(jsonString) {
26
26
  return safeParse(jsonString, (x) => SystemMessageContent$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'SystemMessageContent' from JSON`);
27
27
  }
28
28
  /** @internal */
29
- export const SystemMessage$inboundSchema = z.object({
29
+ export const SystemMessage$inboundSchema = z
30
+ .object({
30
31
  role: z.literal("system"),
31
32
  content: z.union([
32
33
  z.string(),
package/models/tool.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import * as z from "zod/v3";
1
+ import * as z from "zod/v4";
2
2
  import { Result as SafeParseResult } from "../types/fp.js";
3
3
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
4
4
  export type ToolFunction = {
@@ -14,7 +14,7 @@ export type Tool = {
14
14
  function: ToolFunction;
15
15
  };
16
16
  /** @internal */
17
- export declare const ToolFunction$inboundSchema: z.ZodType<ToolFunction, z.ZodTypeDef, unknown>;
17
+ export declare const ToolFunction$inboundSchema: z.ZodType<ToolFunction, unknown>;
18
18
  /** @internal */
19
19
  export type ToolFunction$Outbound = {
20
20
  name: string;
@@ -25,39 +25,39 @@ export type ToolFunction$Outbound = {
25
25
  strict?: boolean | null | undefined;
26
26
  };
27
27
  /** @internal */
28
- export declare const ToolFunction$outboundSchema: z.ZodType<ToolFunction$Outbound, z.ZodTypeDef, ToolFunction>;
28
+ export declare const ToolFunction$outboundSchema: z.ZodType<ToolFunction$Outbound, ToolFunction>;
29
29
  /**
30
30
  * @internal
31
31
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
32
32
  */
33
33
  export declare namespace ToolFunction$ {
34
34
  /** @deprecated use `ToolFunction$inboundSchema` instead. */
35
- const inboundSchema: z.ZodType<ToolFunction, z.ZodTypeDef, unknown>;
35
+ const inboundSchema: z.ZodType<ToolFunction, unknown, z.core.$ZodTypeInternals<ToolFunction, unknown>>;
36
36
  /** @deprecated use `ToolFunction$outboundSchema` instead. */
37
- const outboundSchema: z.ZodType<ToolFunction$Outbound, z.ZodTypeDef, ToolFunction>;
37
+ const outboundSchema: z.ZodType<ToolFunction$Outbound, ToolFunction, z.core.$ZodTypeInternals<ToolFunction$Outbound, ToolFunction>>;
38
38
  /** @deprecated use `ToolFunction$Outbound` instead. */
39
39
  type Outbound = ToolFunction$Outbound;
40
40
  }
41
41
  export declare function toolFunctionToJSON(toolFunction: ToolFunction): string;
42
42
  export declare function toolFunctionFromJSON(jsonString: string): SafeParseResult<ToolFunction, SDKValidationError>;
43
43
  /** @internal */
44
- export declare const Tool$inboundSchema: z.ZodType<Tool, z.ZodTypeDef, unknown>;
44
+ export declare const Tool$inboundSchema: z.ZodType<Tool, unknown>;
45
45
  /** @internal */
46
46
  export type Tool$Outbound = {
47
47
  type: "function";
48
48
  function: ToolFunction$Outbound;
49
49
  };
50
50
  /** @internal */
51
- export declare const Tool$outboundSchema: z.ZodType<Tool$Outbound, z.ZodTypeDef, Tool>;
51
+ export declare const Tool$outboundSchema: z.ZodType<Tool$Outbound, Tool>;
52
52
  /**
53
53
  * @internal
54
54
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
55
55
  */
56
56
  export declare namespace Tool$ {
57
57
  /** @deprecated use `Tool$inboundSchema` instead. */
58
- const inboundSchema: z.ZodType<Tool, z.ZodTypeDef, unknown>;
58
+ const inboundSchema: z.ZodType<Tool, unknown, z.core.$ZodTypeInternals<Tool, unknown>>;
59
59
  /** @deprecated use `Tool$outboundSchema` instead. */
60
- const outboundSchema: z.ZodType<Tool$Outbound, z.ZodTypeDef, Tool>;
60
+ const outboundSchema: z.ZodType<Tool$Outbound, Tool, z.core.$ZodTypeInternals<Tool$Outbound, Tool>>;
61
61
  /** @deprecated use `Tool$Outbound` instead. */
62
62
  type Outbound = Tool$Outbound;
63
63
  }
package/models/tool.js CHANGED
@@ -1,20 +1,21 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { safeParse } from "../lib/schemas.js";
6
6
  /** @internal */
7
- export const ToolFunction$inboundSchema = z.object({
7
+ export const ToolFunction$inboundSchema = z
8
+ .object({
8
9
  name: z.string(),
9
10
  description: z.string().optional(),
10
- parameters: z.record(z.any()).optional(),
11
+ parameters: z.record(z.string(), z.any()).optional(),
11
12
  strict: z.nullable(z.boolean()).optional(),
12
13
  });
13
14
  /** @internal */
14
15
  export const ToolFunction$outboundSchema = z.object({
15
16
  name: z.string(),
16
17
  description: z.string().optional(),
17
- parameters: z.record(z.any()).optional(),
18
+ parameters: z.record(z.string(), z.any()).optional(),
18
19
  strict: z.nullable(z.boolean()).optional(),
19
20
  });
20
21
  /**
@@ -35,8 +36,7 @@ export function toolFunctionFromJSON(jsonString) {
35
36
  return safeParse(jsonString, (x) => ToolFunction$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ToolFunction' from JSON`);
36
37
  }
37
38
  /** @internal */
38
- export const Tool$inboundSchema = z
39
- .object({
39
+ export const Tool$inboundSchema = z.object({
40
40
  type: z.literal("function"),
41
41
  function: z.lazy(() => ToolFunction$inboundSchema),
42
42
  });
@@ -1,4 +1,4 @@
1
- import * as z from "zod/v3";
1
+ import * as z from "zod/v4";
2
2
  import { OpenEnum } from "../types/enums.js";
3
3
  export declare const ToolCallStatus: {
4
4
  readonly InProgress: "in_progress";
@@ -7,16 +7,16 @@ export declare const ToolCallStatus: {
7
7
  };
8
8
  export type ToolCallStatus = OpenEnum<typeof ToolCallStatus>;
9
9
  /** @internal */
10
- export declare const ToolCallStatus$inboundSchema: z.ZodType<ToolCallStatus, z.ZodTypeDef, unknown>;
10
+ export declare const ToolCallStatus$inboundSchema: z.ZodType<ToolCallStatus, unknown>;
11
11
  /** @internal */
12
- export declare const ToolCallStatus$outboundSchema: z.ZodType<ToolCallStatus, z.ZodTypeDef, ToolCallStatus>;
12
+ export declare const ToolCallStatus$outboundSchema: z.ZodType<ToolCallStatus, ToolCallStatus>;
13
13
  /**
14
14
  * @internal
15
15
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
16
16
  */
17
17
  export declare namespace ToolCallStatus$ {
18
18
  /** @deprecated use `ToolCallStatus$inboundSchema` instead. */
19
- const inboundSchema: z.ZodType<ToolCallStatus, z.ZodTypeDef, unknown>;
19
+ const inboundSchema: z.ZodType<ToolCallStatus, unknown, z.core.$ZodTypeInternals<ToolCallStatus, unknown>>;
20
20
  /** @deprecated use `ToolCallStatus$outboundSchema` instead. */
21
- const outboundSchema: z.ZodType<ToolCallStatus, z.ZodTypeDef, ToolCallStatus>;
21
+ const outboundSchema: z.ZodType<ToolCallStatus, ToolCallStatus, z.core.$ZodTypeInternals<ToolCallStatus, ToolCallStatus>>;
22
22
  }
@@ -1,7 +1,7 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { catchUnrecognizedEnum, } from "../types/enums.js";
6
6
  export const ToolCallStatus = {
7
7
  InProgress: "in_progress",
@@ -11,12 +11,12 @@ export const ToolCallStatus = {
11
11
  /** @internal */
12
12
  export const ToolCallStatus$inboundSchema = z
13
13
  .union([
14
- z.nativeEnum(ToolCallStatus),
14
+ z.enum(ToolCallStatus),
15
15
  z.string().transform(catchUnrecognizedEnum),
16
16
  ]);
17
17
  /** @internal */
18
18
  export const ToolCallStatus$outboundSchema = z.union([
19
- z.nativeEnum(ToolCallStatus),
19
+ z.enum(ToolCallStatus),
20
20
  z.string().and(z.custom()),
21
21
  ]);
22
22
  /**
@@ -1,4 +1,4 @@
1
- import * as z from "zod/v3";
1
+ import * as z from "zod/v4";
2
2
  import { ClosedEnum } from "../types/enums.js";
3
3
  import { Result as SafeParseResult } from "../types/fp.js";
4
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
@@ -30,132 +30,132 @@ export type ToolChoiceTypes = {
30
30
  type: TypeFileSearch | ToolChoiceTypesTypeWebSearchPreview | ToolChoiceTypesTypeWebSearchPreview20250311 | TypeComputerUsePreview | TypeCodeInterpreter;
31
31
  };
32
32
  /** @internal */
33
- export declare const TypeCodeInterpreter$inboundSchema: z.ZodNativeEnum<typeof TypeCodeInterpreter>;
33
+ export declare const TypeCodeInterpreter$inboundSchema: z.ZodEnum<typeof TypeCodeInterpreter>;
34
34
  /** @internal */
35
- export declare const TypeCodeInterpreter$outboundSchema: z.ZodNativeEnum<typeof TypeCodeInterpreter>;
35
+ export declare const TypeCodeInterpreter$outboundSchema: z.ZodEnum<typeof TypeCodeInterpreter>;
36
36
  /**
37
37
  * @internal
38
38
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
39
39
  */
40
40
  export declare namespace TypeCodeInterpreter$ {
41
41
  /** @deprecated use `TypeCodeInterpreter$inboundSchema` instead. */
42
- const inboundSchema: z.ZodNativeEnum<{
42
+ const inboundSchema: z.ZodEnum<{
43
43
  readonly CodeInterpreter: "code_interpreter";
44
44
  }>;
45
45
  /** @deprecated use `TypeCodeInterpreter$outboundSchema` instead. */
46
- const outboundSchema: z.ZodNativeEnum<{
46
+ const outboundSchema: z.ZodEnum<{
47
47
  readonly CodeInterpreter: "code_interpreter";
48
48
  }>;
49
49
  }
50
50
  /** @internal */
51
- export declare const TypeComputerUsePreview$inboundSchema: z.ZodNativeEnum<typeof TypeComputerUsePreview>;
51
+ export declare const TypeComputerUsePreview$inboundSchema: z.ZodEnum<typeof TypeComputerUsePreview>;
52
52
  /** @internal */
53
- export declare const TypeComputerUsePreview$outboundSchema: z.ZodNativeEnum<typeof TypeComputerUsePreview>;
53
+ export declare const TypeComputerUsePreview$outboundSchema: z.ZodEnum<typeof TypeComputerUsePreview>;
54
54
  /**
55
55
  * @internal
56
56
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
57
57
  */
58
58
  export declare namespace TypeComputerUsePreview$ {
59
59
  /** @deprecated use `TypeComputerUsePreview$inboundSchema` instead. */
60
- const inboundSchema: z.ZodNativeEnum<{
60
+ const inboundSchema: z.ZodEnum<{
61
61
  readonly ComputerUsePreview: "computer_use_preview";
62
62
  }>;
63
63
  /** @deprecated use `TypeComputerUsePreview$outboundSchema` instead. */
64
- const outboundSchema: z.ZodNativeEnum<{
64
+ const outboundSchema: z.ZodEnum<{
65
65
  readonly ComputerUsePreview: "computer_use_preview";
66
66
  }>;
67
67
  }
68
68
  /** @internal */
69
- export declare const ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema: z.ZodNativeEnum<typeof ToolChoiceTypesTypeWebSearchPreview20250311>;
69
+ export declare const ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema: z.ZodEnum<typeof ToolChoiceTypesTypeWebSearchPreview20250311>;
70
70
  /** @internal */
71
- export declare const ToolChoiceTypesTypeWebSearchPreview20250311$outboundSchema: z.ZodNativeEnum<typeof ToolChoiceTypesTypeWebSearchPreview20250311>;
71
+ export declare const ToolChoiceTypesTypeWebSearchPreview20250311$outboundSchema: z.ZodEnum<typeof ToolChoiceTypesTypeWebSearchPreview20250311>;
72
72
  /**
73
73
  * @internal
74
74
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
75
75
  */
76
76
  export declare namespace ToolChoiceTypesTypeWebSearchPreview20250311$ {
77
77
  /** @deprecated use `ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema` instead. */
78
- const inboundSchema: z.ZodNativeEnum<{
78
+ const inboundSchema: z.ZodEnum<{
79
79
  readonly WebSearchPreview20250311: "web_search_preview_2025_03_11";
80
80
  }>;
81
81
  /** @deprecated use `ToolChoiceTypesTypeWebSearchPreview20250311$outboundSchema` instead. */
82
- const outboundSchema: z.ZodNativeEnum<{
82
+ const outboundSchema: z.ZodEnum<{
83
83
  readonly WebSearchPreview20250311: "web_search_preview_2025_03_11";
84
84
  }>;
85
85
  }
86
86
  /** @internal */
87
- export declare const ToolChoiceTypesTypeWebSearchPreview$inboundSchema: z.ZodNativeEnum<typeof ToolChoiceTypesTypeWebSearchPreview>;
87
+ export declare const ToolChoiceTypesTypeWebSearchPreview$inboundSchema: z.ZodEnum<typeof ToolChoiceTypesTypeWebSearchPreview>;
88
88
  /** @internal */
89
- export declare const ToolChoiceTypesTypeWebSearchPreview$outboundSchema: z.ZodNativeEnum<typeof ToolChoiceTypesTypeWebSearchPreview>;
89
+ export declare const ToolChoiceTypesTypeWebSearchPreview$outboundSchema: z.ZodEnum<typeof ToolChoiceTypesTypeWebSearchPreview>;
90
90
  /**
91
91
  * @internal
92
92
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
93
93
  */
94
94
  export declare namespace ToolChoiceTypesTypeWebSearchPreview$ {
95
95
  /** @deprecated use `ToolChoiceTypesTypeWebSearchPreview$inboundSchema` instead. */
96
- const inboundSchema: z.ZodNativeEnum<{
96
+ const inboundSchema: z.ZodEnum<{
97
97
  readonly WebSearchPreview: "web_search_preview";
98
98
  }>;
99
99
  /** @deprecated use `ToolChoiceTypesTypeWebSearchPreview$outboundSchema` instead. */
100
- const outboundSchema: z.ZodNativeEnum<{
100
+ const outboundSchema: z.ZodEnum<{
101
101
  readonly WebSearchPreview: "web_search_preview";
102
102
  }>;
103
103
  }
104
104
  /** @internal */
105
- export declare const TypeFileSearch$inboundSchema: z.ZodNativeEnum<typeof TypeFileSearch>;
105
+ export declare const TypeFileSearch$inboundSchema: z.ZodEnum<typeof TypeFileSearch>;
106
106
  /** @internal */
107
- export declare const TypeFileSearch$outboundSchema: z.ZodNativeEnum<typeof TypeFileSearch>;
107
+ export declare const TypeFileSearch$outboundSchema: z.ZodEnum<typeof TypeFileSearch>;
108
108
  /**
109
109
  * @internal
110
110
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
111
111
  */
112
112
  export declare namespace TypeFileSearch$ {
113
113
  /** @deprecated use `TypeFileSearch$inboundSchema` instead. */
114
- const inboundSchema: z.ZodNativeEnum<{
114
+ const inboundSchema: z.ZodEnum<{
115
115
  readonly FileSearch: "file_search";
116
116
  }>;
117
117
  /** @deprecated use `TypeFileSearch$outboundSchema` instead. */
118
- const outboundSchema: z.ZodNativeEnum<{
118
+ const outboundSchema: z.ZodEnum<{
119
119
  readonly FileSearch: "file_search";
120
120
  }>;
121
121
  }
122
122
  /** @internal */
123
- export declare const Type$inboundSchema: z.ZodType<Type, z.ZodTypeDef, unknown>;
123
+ export declare const Type$inboundSchema: z.ZodType<Type, unknown>;
124
124
  /** @internal */
125
125
  export type Type$Outbound = string | string | string | string | string;
126
126
  /** @internal */
127
- export declare const Type$outboundSchema: z.ZodType<Type$Outbound, z.ZodTypeDef, Type>;
127
+ export declare const Type$outboundSchema: z.ZodType<Type$Outbound, Type>;
128
128
  /**
129
129
  * @internal
130
130
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
131
131
  */
132
132
  export declare namespace Type$ {
133
133
  /** @deprecated use `Type$inboundSchema` instead. */
134
- const inboundSchema: z.ZodType<Type, z.ZodTypeDef, unknown>;
134
+ const inboundSchema: z.ZodType<Type, unknown, z.core.$ZodTypeInternals<Type, unknown>>;
135
135
  /** @deprecated use `Type$outboundSchema` instead. */
136
- const outboundSchema: z.ZodType<string, z.ZodTypeDef, Type>;
136
+ const outboundSchema: z.ZodType<string, Type, z.core.$ZodTypeInternals<string, Type>>;
137
137
  /** @deprecated use `Type$Outbound` instead. */
138
138
  type Outbound = Type$Outbound;
139
139
  }
140
140
  export declare function typeToJSON(type: Type): string;
141
141
  export declare function typeFromJSON(jsonString: string): SafeParseResult<Type, SDKValidationError>;
142
142
  /** @internal */
143
- export declare const ToolChoiceTypes$inboundSchema: z.ZodType<ToolChoiceTypes, z.ZodTypeDef, unknown>;
143
+ export declare const ToolChoiceTypes$inboundSchema: z.ZodType<ToolChoiceTypes, unknown>;
144
144
  /** @internal */
145
145
  export type ToolChoiceTypes$Outbound = {
146
146
  type: string | string | string | string | string;
147
147
  };
148
148
  /** @internal */
149
- export declare const ToolChoiceTypes$outboundSchema: z.ZodType<ToolChoiceTypes$Outbound, z.ZodTypeDef, ToolChoiceTypes>;
149
+ export declare const ToolChoiceTypes$outboundSchema: z.ZodType<ToolChoiceTypes$Outbound, ToolChoiceTypes>;
150
150
  /**
151
151
  * @internal
152
152
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
153
153
  */
154
154
  export declare namespace ToolChoiceTypes$ {
155
155
  /** @deprecated use `ToolChoiceTypes$inboundSchema` instead. */
156
- const inboundSchema: z.ZodType<ToolChoiceTypes, z.ZodTypeDef, unknown>;
156
+ const inboundSchema: z.ZodType<ToolChoiceTypes, unknown, z.core.$ZodTypeInternals<ToolChoiceTypes, unknown>>;
157
157
  /** @deprecated use `ToolChoiceTypes$outboundSchema` instead. */
158
- const outboundSchema: z.ZodType<ToolChoiceTypes$Outbound, z.ZodTypeDef, ToolChoiceTypes>;
158
+ const outboundSchema: z.ZodType<ToolChoiceTypes$Outbound, ToolChoiceTypes, z.core.$ZodTypeInternals<ToolChoiceTypes$Outbound, ToolChoiceTypes>>;
159
159
  /** @deprecated use `ToolChoiceTypes$Outbound` instead. */
160
160
  type Outbound = ToolChoiceTypes$Outbound;
161
161
  }
@@ -1,7 +1,7 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { safeParse } from "../lib/schemas.js";
6
6
  export const TypeCodeInterpreter = {
7
7
  CodeInterpreter: "code_interpreter",
@@ -19,7 +19,7 @@ export const TypeFileSearch = {
19
19
  FileSearch: "file_search",
20
20
  };
21
21
  /** @internal */
22
- export const TypeCodeInterpreter$inboundSchema = z.nativeEnum(TypeCodeInterpreter);
22
+ export const TypeCodeInterpreter$inboundSchema = z.enum(TypeCodeInterpreter);
23
23
  /** @internal */
24
24
  export const TypeCodeInterpreter$outboundSchema = TypeCodeInterpreter$inboundSchema;
25
25
  /**
@@ -34,7 +34,7 @@ export var TypeCodeInterpreter$;
34
34
  TypeCodeInterpreter$.outboundSchema = TypeCodeInterpreter$outboundSchema;
35
35
  })(TypeCodeInterpreter$ || (TypeCodeInterpreter$ = {}));
36
36
  /** @internal */
37
- export const TypeComputerUsePreview$inboundSchema = z.nativeEnum(TypeComputerUsePreview);
37
+ export const TypeComputerUsePreview$inboundSchema = z.enum(TypeComputerUsePreview);
38
38
  /** @internal */
39
39
  export const TypeComputerUsePreview$outboundSchema = TypeComputerUsePreview$inboundSchema;
40
40
  /**
@@ -49,8 +49,7 @@ export var TypeComputerUsePreview$;
49
49
  TypeComputerUsePreview$.outboundSchema = TypeComputerUsePreview$outboundSchema;
50
50
  })(TypeComputerUsePreview$ || (TypeComputerUsePreview$ = {}));
51
51
  /** @internal */
52
- export const ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema = z
53
- .nativeEnum(ToolChoiceTypesTypeWebSearchPreview20250311);
52
+ export const ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema = z.enum(ToolChoiceTypesTypeWebSearchPreview20250311);
54
53
  /** @internal */
55
54
  export const ToolChoiceTypesTypeWebSearchPreview20250311$outboundSchema = ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema;
56
55
  /**
@@ -65,7 +64,7 @@ export var ToolChoiceTypesTypeWebSearchPreview20250311$;
65
64
  ToolChoiceTypesTypeWebSearchPreview20250311$.outboundSchema = ToolChoiceTypesTypeWebSearchPreview20250311$outboundSchema;
66
65
  })(ToolChoiceTypesTypeWebSearchPreview20250311$ || (ToolChoiceTypesTypeWebSearchPreview20250311$ = {}));
67
66
  /** @internal */
68
- export const ToolChoiceTypesTypeWebSearchPreview$inboundSchema = z.nativeEnum(ToolChoiceTypesTypeWebSearchPreview);
67
+ export const ToolChoiceTypesTypeWebSearchPreview$inboundSchema = z.enum(ToolChoiceTypesTypeWebSearchPreview);
69
68
  /** @internal */
70
69
  export const ToolChoiceTypesTypeWebSearchPreview$outboundSchema = ToolChoiceTypesTypeWebSearchPreview$inboundSchema;
71
70
  /**
@@ -80,7 +79,8 @@ export var ToolChoiceTypesTypeWebSearchPreview$;
80
79
  ToolChoiceTypesTypeWebSearchPreview$.outboundSchema = ToolChoiceTypesTypeWebSearchPreview$outboundSchema;
81
80
  })(ToolChoiceTypesTypeWebSearchPreview$ || (ToolChoiceTypesTypeWebSearchPreview$ = {}));
82
81
  /** @internal */
83
- export const TypeFileSearch$inboundSchema = z.nativeEnum(TypeFileSearch);
82
+ export const TypeFileSearch$inboundSchema = z
83
+ .enum(TypeFileSearch);
84
84
  /** @internal */
85
85
  export const TypeFileSearch$outboundSchema = TypeFileSearch$inboundSchema;
86
86
  /**
@@ -95,8 +95,7 @@ export var TypeFileSearch$;
95
95
  TypeFileSearch$.outboundSchema = TypeFileSearch$outboundSchema;
96
96
  })(TypeFileSearch$ || (TypeFileSearch$ = {}));
97
97
  /** @internal */
98
- export const Type$inboundSchema = z
99
- .union([
98
+ export const Type$inboundSchema = z.union([
100
99
  TypeFileSearch$inboundSchema,
101
100
  ToolChoiceTypesTypeWebSearchPreview$inboundSchema,
102
101
  ToolChoiceTypesTypeWebSearchPreview20250311$inboundSchema,
@@ -1,4 +1,4 @@
1
- import * as z from "zod/v3";
1
+ import * as z from "zod/v4";
2
2
  import { Result as SafeParseResult } from "../types/fp.js";
3
3
  import { ChatMessageContentItem, ChatMessageContentItem$Outbound } from "./chatmessagecontentitem.js";
4
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
@@ -9,27 +9,27 @@ export type ToolResponseMessage = {
9
9
  toolCallId: string;
10
10
  };
11
11
  /** @internal */
12
- export declare const ToolResponseMessageContent$inboundSchema: z.ZodType<ToolResponseMessageContent, z.ZodTypeDef, unknown>;
12
+ export declare const ToolResponseMessageContent$inboundSchema: z.ZodType<ToolResponseMessageContent, unknown>;
13
13
  /** @internal */
14
14
  export type ToolResponseMessageContent$Outbound = string | Array<ChatMessageContentItem$Outbound>;
15
15
  /** @internal */
16
- export declare const ToolResponseMessageContent$outboundSchema: z.ZodType<ToolResponseMessageContent$Outbound, z.ZodTypeDef, ToolResponseMessageContent>;
16
+ export declare const ToolResponseMessageContent$outboundSchema: z.ZodType<ToolResponseMessageContent$Outbound, ToolResponseMessageContent>;
17
17
  /**
18
18
  * @internal
19
19
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
20
20
  */
21
21
  export declare namespace ToolResponseMessageContent$ {
22
22
  /** @deprecated use `ToolResponseMessageContent$inboundSchema` instead. */
23
- const inboundSchema: z.ZodType<ToolResponseMessageContent, z.ZodTypeDef, unknown>;
23
+ const inboundSchema: z.ZodType<ToolResponseMessageContent, unknown, z.core.$ZodTypeInternals<ToolResponseMessageContent, unknown>>;
24
24
  /** @deprecated use `ToolResponseMessageContent$outboundSchema` instead. */
25
- const outboundSchema: z.ZodType<ToolResponseMessageContent$Outbound, z.ZodTypeDef, ToolResponseMessageContent>;
25
+ const outboundSchema: z.ZodType<ToolResponseMessageContent$Outbound, ToolResponseMessageContent, z.core.$ZodTypeInternals<ToolResponseMessageContent$Outbound, ToolResponseMessageContent>>;
26
26
  /** @deprecated use `ToolResponseMessageContent$Outbound` instead. */
27
27
  type Outbound = ToolResponseMessageContent$Outbound;
28
28
  }
29
29
  export declare function toolResponseMessageContentToJSON(toolResponseMessageContent: ToolResponseMessageContent): string;
30
30
  export declare function toolResponseMessageContentFromJSON(jsonString: string): SafeParseResult<ToolResponseMessageContent, SDKValidationError>;
31
31
  /** @internal */
32
- export declare const ToolResponseMessage$inboundSchema: z.ZodType<ToolResponseMessage, z.ZodTypeDef, unknown>;
32
+ export declare const ToolResponseMessage$inboundSchema: z.ZodType<ToolResponseMessage, unknown>;
33
33
  /** @internal */
34
34
  export type ToolResponseMessage$Outbound = {
35
35
  role: "tool";
@@ -37,16 +37,16 @@ export type ToolResponseMessage$Outbound = {
37
37
  tool_call_id: string;
38
38
  };
39
39
  /** @internal */
40
- export declare const ToolResponseMessage$outboundSchema: z.ZodType<ToolResponseMessage$Outbound, z.ZodTypeDef, ToolResponseMessage>;
40
+ export declare const ToolResponseMessage$outboundSchema: z.ZodType<ToolResponseMessage$Outbound, ToolResponseMessage>;
41
41
  /**
42
42
  * @internal
43
43
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
44
44
  */
45
45
  export declare namespace ToolResponseMessage$ {
46
46
  /** @deprecated use `ToolResponseMessage$inboundSchema` instead. */
47
- const inboundSchema: z.ZodType<ToolResponseMessage, z.ZodTypeDef, unknown>;
47
+ const inboundSchema: z.ZodType<ToolResponseMessage, unknown, z.core.$ZodTypeInternals<ToolResponseMessage, unknown>>;
48
48
  /** @deprecated use `ToolResponseMessage$outboundSchema` instead. */
49
- const outboundSchema: z.ZodType<ToolResponseMessage$Outbound, z.ZodTypeDef, ToolResponseMessage>;
49
+ const outboundSchema: z.ZodType<ToolResponseMessage$Outbound, ToolResponseMessage, z.core.$ZodTypeInternals<ToolResponseMessage$Outbound, ToolResponseMessage>>;
50
50
  /** @deprecated use `ToolResponseMessage$Outbound` instead. */
51
51
  type Outbound = ToolResponseMessage$Outbound;
52
52
  }
@@ -1,7 +1,7 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { remap as remap$ } from "../lib/primitives.js";
6
6
  import { safeParse } from "../lib/schemas.js";
7
7
  import { ChatMessageContentItem$inboundSchema, ChatMessageContentItem$outboundSchema, } from "./chatmessagecontentitem.js";
@@ -1,4 +1,4 @@
1
- import * as z from "zod/v3";
1
+ import * as z from "zod/v4";
2
2
  import { ClosedEnum } from "../types/enums.js";
3
3
  import { Result as SafeParseResult } from "../types/fp.js";
4
4
  import { SDKValidationError } from "./errors/sdkvalidationerror.js";
@@ -14,25 +14,25 @@ export type URLCitationAnnotation = {
14
14
  url: string;
15
15
  };
16
16
  /** @internal */
17
- export declare const URLCitationAnnotationType$inboundSchema: z.ZodNativeEnum<typeof URLCitationAnnotationType>;
17
+ export declare const URLCitationAnnotationType$inboundSchema: z.ZodEnum<typeof URLCitationAnnotationType>;
18
18
  /** @internal */
19
- export declare const URLCitationAnnotationType$outboundSchema: z.ZodNativeEnum<typeof URLCitationAnnotationType>;
19
+ export declare const URLCitationAnnotationType$outboundSchema: z.ZodEnum<typeof URLCitationAnnotationType>;
20
20
  /**
21
21
  * @internal
22
22
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
23
23
  */
24
24
  export declare namespace URLCitationAnnotationType$ {
25
25
  /** @deprecated use `URLCitationAnnotationType$inboundSchema` instead. */
26
- const inboundSchema: z.ZodNativeEnum<{
26
+ const inboundSchema: z.ZodEnum<{
27
27
  readonly UrlCitation: "url_citation";
28
28
  }>;
29
29
  /** @deprecated use `URLCitationAnnotationType$outboundSchema` instead. */
30
- const outboundSchema: z.ZodNativeEnum<{
30
+ const outboundSchema: z.ZodEnum<{
31
31
  readonly UrlCitation: "url_citation";
32
32
  }>;
33
33
  }
34
34
  /** @internal */
35
- export declare const URLCitationAnnotation$inboundSchema: z.ZodType<URLCitationAnnotation, z.ZodTypeDef, unknown>;
35
+ export declare const URLCitationAnnotation$inboundSchema: z.ZodType<URLCitationAnnotation, unknown>;
36
36
  /** @internal */
37
37
  export type URLCitationAnnotation$Outbound = {
38
38
  type: string;
@@ -42,16 +42,16 @@ export type URLCitationAnnotation$Outbound = {
42
42
  url: string;
43
43
  };
44
44
  /** @internal */
45
- export declare const URLCitationAnnotation$outboundSchema: z.ZodType<URLCitationAnnotation$Outbound, z.ZodTypeDef, URLCitationAnnotation>;
45
+ export declare const URLCitationAnnotation$outboundSchema: z.ZodType<URLCitationAnnotation$Outbound, URLCitationAnnotation>;
46
46
  /**
47
47
  * @internal
48
48
  * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
49
49
  */
50
50
  export declare namespace URLCitationAnnotation$ {
51
51
  /** @deprecated use `URLCitationAnnotation$inboundSchema` instead. */
52
- const inboundSchema: z.ZodType<URLCitationAnnotation, z.ZodTypeDef, unknown>;
52
+ const inboundSchema: z.ZodType<URLCitationAnnotation, unknown, z.core.$ZodTypeInternals<URLCitationAnnotation, unknown>>;
53
53
  /** @deprecated use `URLCitationAnnotation$outboundSchema` instead. */
54
- const outboundSchema: z.ZodType<URLCitationAnnotation$Outbound, z.ZodTypeDef, URLCitationAnnotation>;
54
+ const outboundSchema: z.ZodType<URLCitationAnnotation$Outbound, URLCitationAnnotation, z.core.$ZodTypeInternals<URLCitationAnnotation$Outbound, URLCitationAnnotation>>;
55
55
  /** @deprecated use `URLCitationAnnotation$Outbound` instead. */
56
56
  type Outbound = URLCitationAnnotation$Outbound;
57
57
  }
@@ -1,14 +1,14 @@
1
1
  /*
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
- import * as z from "zod/v3";
4
+ import * as z from "zod/v4";
5
5
  import { remap as remap$ } from "../lib/primitives.js";
6
6
  import { safeParse } from "../lib/schemas.js";
7
7
  export const URLCitationAnnotationType = {
8
8
  UrlCitation: "url_citation",
9
9
  };
10
10
  /** @internal */
11
- export const URLCitationAnnotationType$inboundSchema = z.nativeEnum(URLCitationAnnotationType);
11
+ export const URLCitationAnnotationType$inboundSchema = z.enum(URLCitationAnnotationType);
12
12
  /** @internal */
13
13
  export const URLCitationAnnotationType$outboundSchema = URLCitationAnnotationType$inboundSchema;
14
14
  /**