@orq-ai/node 4.11.0-rc.3 → 4.11.0-rc.5

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 (177) hide show
  1. package/hooks/types.d.ts +1 -0
  2. package/hooks/types.d.ts.map +1 -1
  3. package/jsr.json +1 -1
  4. package/lib/config.d.ts +3 -3
  5. package/lib/config.js +3 -3
  6. package/lib/sdks.d.ts.map +1 -1
  7. package/lib/sdks.js +13 -4
  8. package/lib/sdks.js.map +1 -1
  9. package/models/components/modelmetadata.d.ts +2 -0
  10. package/models/components/modelmetadata.d.ts.map +1 -1
  11. package/models/components/modelmetadata.js +4 -0
  12. package/models/components/modelmetadata.js.map +1 -1
  13. package/models/components/reasoning.d.ts +40 -2
  14. package/models/components/reasoning.d.ts.map +1 -1
  15. package/models/components/reasoning.js +26 -3
  16. package/models/components/reasoning.js.map +1 -1
  17. package/models/components/reasoningparam.d.ts +40 -2
  18. package/models/components/reasoningparam.d.ts.map +1 -1
  19. package/models/components/reasoningparam.js +28 -3
  20. package/models/components/reasoningparam.js.map +1 -1
  21. package/models/components/reasoningpart.js +1 -1
  22. package/models/operations/createagentrequest.d.ts +298 -4
  23. package/models/operations/createagentrequest.d.ts.map +1 -1
  24. package/models/operations/createagentrequest.js +163 -9
  25. package/models/operations/createagentrequest.js.map +1 -1
  26. package/models/operations/createchatcompletion.d.ts +81 -4
  27. package/models/operations/createchatcompletion.d.ts.map +1 -1
  28. package/models/operations/createchatcompletion.js +45 -7
  29. package/models/operations/createchatcompletion.js.map +1 -1
  30. package/models/operations/createdataset.js +1 -1
  31. package/models/operations/createdatasetitem.js +4 -4
  32. package/models/operations/createdatasource.js +1 -1
  33. package/models/operations/createeval.js +16 -16
  34. package/models/operations/createprompt.d.ts +225 -12
  35. package/models/operations/createprompt.d.ts.map +1 -1
  36. package/models/operations/createprompt.js +124 -13
  37. package/models/operations/createprompt.js.map +1 -1
  38. package/models/operations/createrouterresponse.d.ts +353 -8
  39. package/models/operations/createrouterresponse.d.ts.map +1 -1
  40. package/models/operations/createrouterresponse.js +198 -7
  41. package/models/operations/createrouterresponse.js.map +1 -1
  42. package/models/operations/createtool.js +6 -6
  43. package/models/operations/deploymentgetconfig.d.ts +70 -4
  44. package/models/operations/deploymentgetconfig.d.ts.map +1 -1
  45. package/models/operations/deploymentgetconfig.js +43 -8
  46. package/models/operations/deploymentgetconfig.js.map +1 -1
  47. package/models/operations/deployments.d.ts +74 -8
  48. package/models/operations/deployments.d.ts.map +1 -1
  49. package/models/operations/deployments.js +43 -8
  50. package/models/operations/deployments.js.map +1 -1
  51. package/models/operations/getallprompts.d.ts +140 -4
  52. package/models/operations/getallprompts.d.ts.map +1 -1
  53. package/models/operations/getallprompts.js +79 -6
  54. package/models/operations/getallprompts.js.map +1 -1
  55. package/models/operations/getalltools.js +6 -6
  56. package/models/operations/getevals.js +16 -16
  57. package/models/operations/getoneprompt.d.ts +140 -4
  58. package/models/operations/getoneprompt.d.ts.map +1 -1
  59. package/models/operations/getoneprompt.js +79 -6
  60. package/models/operations/getoneprompt.js.map +1 -1
  61. package/models/operations/getpromptversion.d.ts +140 -4
  62. package/models/operations/getpromptversion.d.ts.map +1 -1
  63. package/models/operations/getpromptversion.js +78 -6
  64. package/models/operations/getpromptversion.js.map +1 -1
  65. package/models/operations/getv2humanevalsets.js +2 -2
  66. package/models/operations/getv2humanevalsetsid.js +2 -2
  67. package/models/operations/listagents.d.ts +140 -0
  68. package/models/operations/listagents.d.ts.map +1 -1
  69. package/models/operations/listagents.js +79 -3
  70. package/models/operations/listagents.js.map +1 -1
  71. package/models/operations/listdatasetdatapoints.js +4 -4
  72. package/models/operations/listdatasets.js +1 -1
  73. package/models/operations/listdatasources.js +1 -1
  74. package/models/operations/listknowledgebases.d.ts +3 -0
  75. package/models/operations/listknowledgebases.d.ts.map +1 -1
  76. package/models/operations/listknowledgebases.js +1 -1
  77. package/models/operations/listknowledgebases.js.map +1 -1
  78. package/models/operations/listpromptversions.d.ts +140 -4
  79. package/models/operations/listpromptversions.d.ts.map +1 -1
  80. package/models/operations/listpromptversions.js +79 -6
  81. package/models/operations/listpromptversions.js.map +1 -1
  82. package/models/operations/modelcreateawsbedrock.d.ts +4 -0
  83. package/models/operations/modelcreateawsbedrock.d.ts.map +1 -1
  84. package/models/operations/modelcreateawsbedrock.js +4 -0
  85. package/models/operations/modelcreateawsbedrock.js.map +1 -1
  86. package/models/operations/modelupdateawsbedrock.d.ts +4 -0
  87. package/models/operations/modelupdateawsbedrock.d.ts.map +1 -1
  88. package/models/operations/modelupdateawsbedrock.js +4 -0
  89. package/models/operations/modelupdateawsbedrock.js.map +1 -1
  90. package/models/operations/patchv2humanevalsetsid.js +2 -2
  91. package/models/operations/postv2feedbackevaluation.js +3 -3
  92. package/models/operations/postv2humanevalsets.js +2 -2
  93. package/models/operations/retrieveagentrequest.d.ts +140 -0
  94. package/models/operations/retrieveagentrequest.d.ts.map +1 -1
  95. package/models/operations/retrieveagentrequest.js +81 -2
  96. package/models/operations/retrieveagentrequest.js.map +1 -1
  97. package/models/operations/retrievedatapoint.js +4 -4
  98. package/models/operations/retrievedataset.js +1 -1
  99. package/models/operations/retrievedatasource.js +1 -1
  100. package/models/operations/retrievetool.js +6 -6
  101. package/models/operations/runagent.d.ts +154 -0
  102. package/models/operations/runagent.d.ts.map +1 -1
  103. package/models/operations/runagent.js +80 -5
  104. package/models/operations/runagent.js.map +1 -1
  105. package/models/operations/streamrunagent.d.ts +154 -0
  106. package/models/operations/streamrunagent.d.ts.map +1 -1
  107. package/models/operations/streamrunagent.js +82 -4
  108. package/models/operations/streamrunagent.js.map +1 -1
  109. package/models/operations/updateagent.d.ts +298 -4
  110. package/models/operations/updateagent.d.ts.map +1 -1
  111. package/models/operations/updateagent.js +162 -9
  112. package/models/operations/updateagent.js.map +1 -1
  113. package/models/operations/updatedatapoint.js +4 -4
  114. package/models/operations/updatedataset.js +1 -1
  115. package/models/operations/updatedatasource.js +1 -1
  116. package/models/operations/updateeval.js +16 -16
  117. package/models/operations/updateprompt.d.ts +225 -12
  118. package/models/operations/updateprompt.d.ts.map +1 -1
  119. package/models/operations/updateprompt.js +125 -14
  120. package/models/operations/updateprompt.js.map +1 -1
  121. package/models/operations/updatetool.js +7 -7
  122. package/package.json +8 -8
  123. package/sdk/feedback.d.ts +1 -4
  124. package/sdk/feedback.d.ts.map +1 -1
  125. package/sdk/feedback.js +1 -4
  126. package/sdk/feedback.js.map +1 -1
  127. package/src/hooks/types.ts +1 -0
  128. package/src/lib/config.ts +3 -3
  129. package/src/lib/sdks.ts +13 -4
  130. package/src/models/components/modelmetadata.ts +6 -0
  131. package/src/models/components/reasoning.ts +50 -4
  132. package/src/models/components/reasoningparam.ts +48 -4
  133. package/src/models/components/reasoningpart.ts +1 -1
  134. package/src/models/operations/createagentrequest.ts +460 -8
  135. package/src/models/operations/createchatcompletion.ts +129 -10
  136. package/src/models/operations/createdataset.ts +1 -1
  137. package/src/models/operations/createdatasetitem.ts +4 -4
  138. package/src/models/operations/createdatasource.ts +1 -1
  139. package/src/models/operations/createeval.ts +16 -16
  140. package/src/models/operations/createprompt.ts +356 -27
  141. package/src/models/operations/createrouterresponse.ts +540 -16
  142. package/src/models/operations/createtool.ts +6 -6
  143. package/src/models/operations/deploymentgetconfig.ts +105 -8
  144. package/src/models/operations/deployments.ts +113 -16
  145. package/src/models/operations/getallprompts.ts +210 -8
  146. package/src/models/operations/getalltools.ts +6 -6
  147. package/src/models/operations/getevals.ts +16 -16
  148. package/src/models/operations/getoneprompt.ts +208 -8
  149. package/src/models/operations/getpromptversion.ts +212 -8
  150. package/src/models/operations/getv2humanevalsets.ts +2 -2
  151. package/src/models/operations/getv2humanevalsetsid.ts +2 -2
  152. package/src/models/operations/listagents.ts +215 -0
  153. package/src/models/operations/listdatasetdatapoints.ts +4 -4
  154. package/src/models/operations/listdatasets.ts +1 -1
  155. package/src/models/operations/listdatasources.ts +1 -1
  156. package/src/models/operations/listknowledgebases.ts +4 -1
  157. package/src/models/operations/listpromptversions.ts +212 -8
  158. package/src/models/operations/modelcreateawsbedrock.ts +8 -0
  159. package/src/models/operations/modelupdateawsbedrock.ts +8 -0
  160. package/src/models/operations/patchv2humanevalsetsid.ts +2 -2
  161. package/src/models/operations/postv2feedbackevaluation.ts +3 -3
  162. package/src/models/operations/postv2humanevalsets.ts +2 -2
  163. package/src/models/operations/retrieveagentrequest.ts +222 -0
  164. package/src/models/operations/retrievedatapoint.ts +4 -4
  165. package/src/models/operations/retrievedataset.ts +1 -1
  166. package/src/models/operations/retrievedatasource.ts +1 -1
  167. package/src/models/operations/retrievetool.ts +6 -6
  168. package/src/models/operations/runagent.ts +236 -1
  169. package/src/models/operations/streamrunagent.ts +242 -1
  170. package/src/models/operations/updateagent.ts +464 -9
  171. package/src/models/operations/updatedatapoint.ts +4 -4
  172. package/src/models/operations/updatedataset.ts +1 -1
  173. package/src/models/operations/updatedatasource.ts +1 -1
  174. package/src/models/operations/updateeval.ts +16 -16
  175. package/src/models/operations/updateprompt.ts +356 -27
  176. package/src/models/operations/updatetool.ts +7 -7
  177. package/src/sdk/feedback.ts +1 -4
@@ -259,6 +259,68 @@ export type RunAgentModelConfigurationTimeout = {
259
259
  callTimeout: number;
260
260
  };
261
261
 
262
+ /**
263
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
264
+ */
265
+ export const RunAgentModelConfigurationAgentsType = {
266
+ Ephemeral: "ephemeral",
267
+ } as const;
268
+ /**
269
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
270
+ */
271
+ export type RunAgentModelConfigurationAgentsType = ClosedEnum<
272
+ typeof RunAgentModelConfigurationAgentsType
273
+ >;
274
+
275
+ /**
276
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
277
+ *
278
+ * @remarks
279
+ *
280
+ * - `5m`: 5 minutes
281
+ * - `1h`: 1 hour
282
+ *
283
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
284
+ */
285
+ export const RunAgentModelConfigurationTtl = {
286
+ Fivem: "5m",
287
+ Oneh: "1h",
288
+ } as const;
289
+ /**
290
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
291
+ *
292
+ * @remarks
293
+ *
294
+ * - `5m`: 5 minutes
295
+ * - `1h`: 1 hour
296
+ *
297
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
298
+ */
299
+ export type RunAgentModelConfigurationTtl = ClosedEnum<
300
+ typeof RunAgentModelConfigurationTtl
301
+ >;
302
+
303
+ /**
304
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
305
+ */
306
+ export type RunAgentModelConfigurationCacheControl = {
307
+ /**
308
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
309
+ */
310
+ type: RunAgentModelConfigurationAgentsType;
311
+ /**
312
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
313
+ *
314
+ * @remarks
315
+ *
316
+ * - `5m`: 5 minutes
317
+ * - `1h`: 1 hour
318
+ *
319
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
320
+ */
321
+ ttl?: RunAgentModelConfigurationTtl | undefined;
322
+ };
323
+
262
324
  /**
263
325
  * Model behavior parameters that control how the model generates responses. Common parameters: `temperature` (0-1, randomness), `max_completion_tokens` (max output length), `top_p` (sampling diversity). Advanced: `frequency_penalty`, `presence_penalty`, `response_format` (JSON/structured), `reasoning_effort`, `seed` (reproducibility). Support varies by model - consult AI Gateway documentation.
264
326
  */
@@ -369,6 +431,14 @@ export type RunAgentModelConfigurationParameters = {
369
431
  * Timeout configuration to apply to the request. If the request exceeds the timeout, it will be retried or fallback to the next model if configured.
370
432
  */
371
433
  timeout?: RunAgentModelConfigurationTimeout | undefined;
434
+ /**
435
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
436
+ */
437
+ cacheControl?: RunAgentModelConfigurationCacheControl | undefined;
438
+ /**
439
+ * Used by OpenAI to cache responses for similar requests to optimize your cache hit rates. Replaces the legacy `user` field for prompt caching.
440
+ */
441
+ promptCacheKey?: string | undefined;
372
442
  };
373
443
 
374
444
  /**
@@ -664,6 +734,68 @@ export type RunAgentFallbackModelConfigurationTimeout = {
664
734
  callTimeout: number;
665
735
  };
666
736
 
737
+ /**
738
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
739
+ */
740
+ export const RunAgentFallbackModelConfigurationAgentsType = {
741
+ Ephemeral: "ephemeral",
742
+ } as const;
743
+ /**
744
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
745
+ */
746
+ export type RunAgentFallbackModelConfigurationAgentsType = ClosedEnum<
747
+ typeof RunAgentFallbackModelConfigurationAgentsType
748
+ >;
749
+
750
+ /**
751
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
752
+ *
753
+ * @remarks
754
+ *
755
+ * - `5m`: 5 minutes
756
+ * - `1h`: 1 hour
757
+ *
758
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
759
+ */
760
+ export const RunAgentFallbackModelConfigurationTtl = {
761
+ Fivem: "5m",
762
+ Oneh: "1h",
763
+ } as const;
764
+ /**
765
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
766
+ *
767
+ * @remarks
768
+ *
769
+ * - `5m`: 5 minutes
770
+ * - `1h`: 1 hour
771
+ *
772
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
773
+ */
774
+ export type RunAgentFallbackModelConfigurationTtl = ClosedEnum<
775
+ typeof RunAgentFallbackModelConfigurationTtl
776
+ >;
777
+
778
+ /**
779
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
780
+ */
781
+ export type RunAgentFallbackModelConfigurationCacheControl = {
782
+ /**
783
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
784
+ */
785
+ type: RunAgentFallbackModelConfigurationAgentsType;
786
+ /**
787
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
788
+ *
789
+ * @remarks
790
+ *
791
+ * - `5m`: 5 minutes
792
+ * - `1h`: 1 hour
793
+ *
794
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
795
+ */
796
+ ttl?: RunAgentFallbackModelConfigurationTtl | undefined;
797
+ };
798
+
667
799
  /**
668
800
  * Optional model parameters specific to this fallback model. Overrides primary model parameters if this fallback is used.
669
801
  */
@@ -782,6 +914,14 @@ export type RunAgentFallbackModelConfigurationParameters = {
782
914
  * Timeout configuration to apply to the request. If the request exceeds the timeout, it will be retried or fallback to the next model if configured.
783
915
  */
784
916
  timeout?: RunAgentFallbackModelConfigurationTimeout | undefined;
917
+ /**
918
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
919
+ */
920
+ cacheControl?: RunAgentFallbackModelConfigurationCacheControl | undefined;
921
+ /**
922
+ * Used by OpenAI to cache responses for similar requests to optimize your cache hit rates. Replaces the legacy `user` field for prompt caching.
923
+ */
924
+ promptCacheKey?: string | undefined;
785
925
  };
786
926
 
787
927
  /**
@@ -2370,6 +2510,44 @@ export function runAgentModelConfigurationTimeoutToJSON(
2370
2510
  );
2371
2511
  }
2372
2512
 
2513
+ /** @internal */
2514
+ export const RunAgentModelConfigurationAgentsType$outboundSchema:
2515
+ z.ZodNativeEnum<typeof RunAgentModelConfigurationAgentsType> = z.nativeEnum(
2516
+ RunAgentModelConfigurationAgentsType,
2517
+ );
2518
+
2519
+ /** @internal */
2520
+ export const RunAgentModelConfigurationTtl$outboundSchema: z.ZodNativeEnum<
2521
+ typeof RunAgentModelConfigurationTtl
2522
+ > = z.nativeEnum(RunAgentModelConfigurationTtl);
2523
+
2524
+ /** @internal */
2525
+ export type RunAgentModelConfigurationCacheControl$Outbound = {
2526
+ type: string;
2527
+ ttl: string;
2528
+ };
2529
+
2530
+ /** @internal */
2531
+ export const RunAgentModelConfigurationCacheControl$outboundSchema: z.ZodType<
2532
+ RunAgentModelConfigurationCacheControl$Outbound,
2533
+ z.ZodTypeDef,
2534
+ RunAgentModelConfigurationCacheControl
2535
+ > = z.object({
2536
+ type: RunAgentModelConfigurationAgentsType$outboundSchema,
2537
+ ttl: RunAgentModelConfigurationTtl$outboundSchema.default("5m"),
2538
+ });
2539
+
2540
+ export function runAgentModelConfigurationCacheControlToJSON(
2541
+ runAgentModelConfigurationCacheControl:
2542
+ RunAgentModelConfigurationCacheControl,
2543
+ ): string {
2544
+ return JSON.stringify(
2545
+ RunAgentModelConfigurationCacheControl$outboundSchema.parse(
2546
+ runAgentModelConfigurationCacheControl,
2547
+ ),
2548
+ );
2549
+ }
2550
+
2373
2551
  /** @internal */
2374
2552
  export type RunAgentModelConfigurationParameters$Outbound = {
2375
2553
  name?: string | undefined;
@@ -2402,6 +2580,8 @@ export type RunAgentModelConfigurationParameters$Outbound = {
2402
2580
  cache?: RunAgentModelConfigurationCache$Outbound | undefined;
2403
2581
  load_balancer?: RunAgentLoadBalancer1$Outbound | undefined;
2404
2582
  timeout?: RunAgentModelConfigurationTimeout$Outbound | undefined;
2583
+ cache_control?: RunAgentModelConfigurationCacheControl$Outbound | undefined;
2584
+ prompt_cache_key?: string | undefined;
2405
2585
  };
2406
2586
 
2407
2587
  /** @internal */
@@ -2452,6 +2632,10 @@ export const RunAgentModelConfigurationParameters$outboundSchema: z.ZodType<
2452
2632
  loadBalancer: z.lazy(() => RunAgentLoadBalancer1$outboundSchema).optional(),
2453
2633
  timeout: z.lazy(() => RunAgentModelConfigurationTimeout$outboundSchema)
2454
2634
  .optional(),
2635
+ cacheControl: z.lazy(() =>
2636
+ RunAgentModelConfigurationCacheControl$outboundSchema
2637
+ ).optional(),
2638
+ promptCacheKey: z.string().optional(),
2455
2639
  }).transform((v) => {
2456
2640
  return remap$(v, {
2457
2641
  frequencyPenalty: "frequency_penalty",
@@ -2465,6 +2649,8 @@ export const RunAgentModelConfigurationParameters$outboundSchema: z.ZodType<
2465
2649
  toolChoice: "tool_choice",
2466
2650
  parallelToolCalls: "parallel_tool_calls",
2467
2651
  loadBalancer: "load_balancer",
2652
+ cacheControl: "cache_control",
2653
+ promptCacheKey: "prompt_cache_key",
2468
2654
  });
2469
2655
  });
2470
2656
 
@@ -3086,6 +3272,45 @@ export function runAgentFallbackModelConfigurationTimeoutToJSON(
3086
3272
  );
3087
3273
  }
3088
3274
 
3275
+ /** @internal */
3276
+ export const RunAgentFallbackModelConfigurationAgentsType$outboundSchema:
3277
+ z.ZodNativeEnum<typeof RunAgentFallbackModelConfigurationAgentsType> = z
3278
+ .nativeEnum(RunAgentFallbackModelConfigurationAgentsType);
3279
+
3280
+ /** @internal */
3281
+ export const RunAgentFallbackModelConfigurationTtl$outboundSchema:
3282
+ z.ZodNativeEnum<typeof RunAgentFallbackModelConfigurationTtl> = z.nativeEnum(
3283
+ RunAgentFallbackModelConfigurationTtl,
3284
+ );
3285
+
3286
+ /** @internal */
3287
+ export type RunAgentFallbackModelConfigurationCacheControl$Outbound = {
3288
+ type: string;
3289
+ ttl: string;
3290
+ };
3291
+
3292
+ /** @internal */
3293
+ export const RunAgentFallbackModelConfigurationCacheControl$outboundSchema:
3294
+ z.ZodType<
3295
+ RunAgentFallbackModelConfigurationCacheControl$Outbound,
3296
+ z.ZodTypeDef,
3297
+ RunAgentFallbackModelConfigurationCacheControl
3298
+ > = z.object({
3299
+ type: RunAgentFallbackModelConfigurationAgentsType$outboundSchema,
3300
+ ttl: RunAgentFallbackModelConfigurationTtl$outboundSchema.default("5m"),
3301
+ });
3302
+
3303
+ export function runAgentFallbackModelConfigurationCacheControlToJSON(
3304
+ runAgentFallbackModelConfigurationCacheControl:
3305
+ RunAgentFallbackModelConfigurationCacheControl,
3306
+ ): string {
3307
+ return JSON.stringify(
3308
+ RunAgentFallbackModelConfigurationCacheControl$outboundSchema.parse(
3309
+ runAgentFallbackModelConfigurationCacheControl,
3310
+ ),
3311
+ );
3312
+ }
3313
+
3089
3314
  /** @internal */
3090
3315
  export type RunAgentFallbackModelConfigurationParameters$Outbound = {
3091
3316
  name?: string | undefined;
@@ -3122,6 +3347,10 @@ export type RunAgentFallbackModelConfigurationParameters$Outbound = {
3122
3347
  cache?: RunAgentFallbackModelConfigurationCache$Outbound | undefined;
3123
3348
  load_balancer?: RunAgentLoadBalancerAgents1$Outbound | undefined;
3124
3349
  timeout?: RunAgentFallbackModelConfigurationTimeout$Outbound | undefined;
3350
+ cache_control?:
3351
+ | RunAgentFallbackModelConfigurationCacheControl$Outbound
3352
+ | undefined;
3353
+ prompt_cache_key?: string | undefined;
3125
3354
  };
3126
3355
 
3127
3356
  /** @internal */
@@ -3178,6 +3407,10 @@ export const RunAgentFallbackModelConfigurationParameters$outboundSchema:
3178
3407
  timeout: z.lazy(() =>
3179
3408
  RunAgentFallbackModelConfigurationTimeout$outboundSchema
3180
3409
  ).optional(),
3410
+ cacheControl: z.lazy(() =>
3411
+ RunAgentFallbackModelConfigurationCacheControl$outboundSchema
3412
+ ).optional(),
3413
+ promptCacheKey: z.string().optional(),
3181
3414
  }).transform((v) => {
3182
3415
  return remap$(v, {
3183
3416
  frequencyPenalty: "frequency_penalty",
@@ -3191,6 +3424,8 @@ export const RunAgentFallbackModelConfigurationParameters$outboundSchema:
3191
3424
  toolChoice: "tool_choice",
3192
3425
  parallelToolCalls: "parallel_tool_calls",
3193
3426
  loadBalancer: "load_balancer",
3427
+ cacheControl: "cache_control",
3428
+ promptCacheKey: "prompt_cache_key",
3194
3429
  });
3195
3430
  });
3196
3431
 
@@ -3626,7 +3861,7 @@ export const Tools$outboundSchema: z.ZodType<
3626
3861
  z.ZodTypeDef,
3627
3862
  Tools
3628
3863
  > = z.object({
3629
- id: z.string().default("01KTKNH3CPN1QZMENW1493XVFF"),
3864
+ id: z.string().default("01KTPAB2RKRYARF1JZRSWA9H24"),
3630
3865
  name: z.string(),
3631
3866
  description: z.string().optional(),
3632
3867
  schema: z.lazy(() => AgentToolInputRunSchema$outboundSchema),
@@ -264,6 +264,68 @@ export type StreamRunAgentModelConfigurationTimeout = {
264
264
  callTimeout: number;
265
265
  };
266
266
 
267
+ /**
268
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
269
+ */
270
+ export const StreamRunAgentModelConfigurationAgentsType = {
271
+ Ephemeral: "ephemeral",
272
+ } as const;
273
+ /**
274
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
275
+ */
276
+ export type StreamRunAgentModelConfigurationAgentsType = ClosedEnum<
277
+ typeof StreamRunAgentModelConfigurationAgentsType
278
+ >;
279
+
280
+ /**
281
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
282
+ *
283
+ * @remarks
284
+ *
285
+ * - `5m`: 5 minutes
286
+ * - `1h`: 1 hour
287
+ *
288
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
289
+ */
290
+ export const StreamRunAgentModelConfigurationTtl = {
291
+ Fivem: "5m",
292
+ Oneh: "1h",
293
+ } as const;
294
+ /**
295
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
296
+ *
297
+ * @remarks
298
+ *
299
+ * - `5m`: 5 minutes
300
+ * - `1h`: 1 hour
301
+ *
302
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
303
+ */
304
+ export type StreamRunAgentModelConfigurationTtl = ClosedEnum<
305
+ typeof StreamRunAgentModelConfigurationTtl
306
+ >;
307
+
308
+ /**
309
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
310
+ */
311
+ export type StreamRunAgentModelConfigurationCacheControl = {
312
+ /**
313
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
314
+ */
315
+ type: StreamRunAgentModelConfigurationAgentsType;
316
+ /**
317
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
318
+ *
319
+ * @remarks
320
+ *
321
+ * - `5m`: 5 minutes
322
+ * - `1h`: 1 hour
323
+ *
324
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
325
+ */
326
+ ttl?: StreamRunAgentModelConfigurationTtl | undefined;
327
+ };
328
+
267
329
  /**
268
330
  * Model behavior parameters that control how the model generates responses. Common parameters: `temperature` (0-1, randomness), `max_completion_tokens` (max output length), `top_p` (sampling diversity). Advanced: `frequency_penalty`, `presence_penalty`, `response_format` (JSON/structured), `reasoning_effort`, `seed` (reproducibility). Support varies by model - consult AI Gateway documentation.
269
331
  */
@@ -380,6 +442,14 @@ export type StreamRunAgentModelConfigurationParameters = {
380
442
  * Timeout configuration to apply to the request. If the request exceeds the timeout, it will be retried or fallback to the next model if configured.
381
443
  */
382
444
  timeout?: StreamRunAgentModelConfigurationTimeout | undefined;
445
+ /**
446
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
447
+ */
448
+ cacheControl?: StreamRunAgentModelConfigurationCacheControl | undefined;
449
+ /**
450
+ * Used by OpenAI to cache responses for similar requests to optimize your cache hit rates. Replaces the legacy `user` field for prompt caching.
451
+ */
452
+ promptCacheKey?: string | undefined;
383
453
  };
384
454
 
385
455
  /**
@@ -682,6 +752,68 @@ export type StreamRunAgentFallbackModelConfigurationTimeout = {
682
752
  callTimeout: number;
683
753
  };
684
754
 
755
+ /**
756
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
757
+ */
758
+ export const StreamRunAgentFallbackModelConfigurationAgentsType = {
759
+ Ephemeral: "ephemeral",
760
+ } as const;
761
+ /**
762
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
763
+ */
764
+ export type StreamRunAgentFallbackModelConfigurationAgentsType = ClosedEnum<
765
+ typeof StreamRunAgentFallbackModelConfigurationAgentsType
766
+ >;
767
+
768
+ /**
769
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
770
+ *
771
+ * @remarks
772
+ *
773
+ * - `5m`: 5 minutes
774
+ * - `1h`: 1 hour
775
+ *
776
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
777
+ */
778
+ export const StreamRunAgentFallbackModelConfigurationTtl = {
779
+ Fivem: "5m",
780
+ Oneh: "1h",
781
+ } as const;
782
+ /**
783
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
784
+ *
785
+ * @remarks
786
+ *
787
+ * - `5m`: 5 minutes
788
+ * - `1h`: 1 hour
789
+ *
790
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
791
+ */
792
+ export type StreamRunAgentFallbackModelConfigurationTtl = ClosedEnum<
793
+ typeof StreamRunAgentFallbackModelConfigurationTtl
794
+ >;
795
+
796
+ /**
797
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
798
+ */
799
+ export type StreamRunAgentFallbackModelConfigurationCacheControl = {
800
+ /**
801
+ * Create a cache control breakpoint at this content block. Accepts only the value "ephemeral".
802
+ */
803
+ type: StreamRunAgentFallbackModelConfigurationAgentsType;
804
+ /**
805
+ * The time-to-live for the cache control breakpoint. This may be one of the following values:
806
+ *
807
+ * @remarks
808
+ *
809
+ * - `5m`: 5 minutes
810
+ * - `1h`: 1 hour
811
+ *
812
+ * Defaults to `5m`. Only supported by `Anthropic` Claude models.
813
+ */
814
+ ttl?: StreamRunAgentFallbackModelConfigurationTtl | undefined;
815
+ };
816
+
685
817
  /**
686
818
  * Optional model parameters specific to this fallback model. Overrides primary model parameters if this fallback is used.
687
819
  */
@@ -804,6 +936,16 @@ export type StreamRunAgentFallbackModelConfigurationParameters = {
804
936
  * Timeout configuration to apply to the request. If the request exceeds the timeout, it will be retried or fallback to the next model if configured.
805
937
  */
806
938
  timeout?: StreamRunAgentFallbackModelConfigurationTimeout | undefined;
939
+ /**
940
+ * Provider-level prompt caching configuration applied to the request. Creates a cache control breakpoint covering the request content. Only supported by `Anthropic` Claude models.
941
+ */
942
+ cacheControl?:
943
+ | StreamRunAgentFallbackModelConfigurationCacheControl
944
+ | undefined;
945
+ /**
946
+ * Used by OpenAI to cache responses for similar requests to optimize your cache hit rates. Replaces the legacy `user` field for prompt caching.
947
+ */
948
+ promptCacheKey?: string | undefined;
807
949
  };
808
950
 
809
951
  /**
@@ -2353,6 +2495,45 @@ export function streamRunAgentModelConfigurationTimeoutToJSON(
2353
2495
  );
2354
2496
  }
2355
2497
 
2498
+ /** @internal */
2499
+ export const StreamRunAgentModelConfigurationAgentsType$outboundSchema:
2500
+ z.ZodNativeEnum<typeof StreamRunAgentModelConfigurationAgentsType> = z
2501
+ .nativeEnum(StreamRunAgentModelConfigurationAgentsType);
2502
+
2503
+ /** @internal */
2504
+ export const StreamRunAgentModelConfigurationTtl$outboundSchema:
2505
+ z.ZodNativeEnum<typeof StreamRunAgentModelConfigurationTtl> = z.nativeEnum(
2506
+ StreamRunAgentModelConfigurationTtl,
2507
+ );
2508
+
2509
+ /** @internal */
2510
+ export type StreamRunAgentModelConfigurationCacheControl$Outbound = {
2511
+ type: string;
2512
+ ttl: string;
2513
+ };
2514
+
2515
+ /** @internal */
2516
+ export const StreamRunAgentModelConfigurationCacheControl$outboundSchema:
2517
+ z.ZodType<
2518
+ StreamRunAgentModelConfigurationCacheControl$Outbound,
2519
+ z.ZodTypeDef,
2520
+ StreamRunAgentModelConfigurationCacheControl
2521
+ > = z.object({
2522
+ type: StreamRunAgentModelConfigurationAgentsType$outboundSchema,
2523
+ ttl: StreamRunAgentModelConfigurationTtl$outboundSchema.default("5m"),
2524
+ });
2525
+
2526
+ export function streamRunAgentModelConfigurationCacheControlToJSON(
2527
+ streamRunAgentModelConfigurationCacheControl:
2528
+ StreamRunAgentModelConfigurationCacheControl,
2529
+ ): string {
2530
+ return JSON.stringify(
2531
+ StreamRunAgentModelConfigurationCacheControl$outboundSchema.parse(
2532
+ streamRunAgentModelConfigurationCacheControl,
2533
+ ),
2534
+ );
2535
+ }
2536
+
2356
2537
  /** @internal */
2357
2538
  export type StreamRunAgentModelConfigurationParameters$Outbound = {
2358
2539
  name?: string | undefined;
@@ -2389,6 +2570,10 @@ export type StreamRunAgentModelConfigurationParameters$Outbound = {
2389
2570
  cache?: StreamRunAgentModelConfigurationCache$Outbound | undefined;
2390
2571
  load_balancer?: StreamRunAgentLoadBalancer1$Outbound | undefined;
2391
2572
  timeout?: StreamRunAgentModelConfigurationTimeout$Outbound | undefined;
2573
+ cache_control?:
2574
+ | StreamRunAgentModelConfigurationCacheControl$Outbound
2575
+ | undefined;
2576
+ prompt_cache_key?: string | undefined;
2392
2577
  };
2393
2578
 
2394
2579
  /** @internal */
@@ -2442,6 +2627,10 @@ export const StreamRunAgentModelConfigurationParameters$outboundSchema:
2442
2627
  timeout: z.lazy(() =>
2443
2628
  StreamRunAgentModelConfigurationTimeout$outboundSchema
2444
2629
  ).optional(),
2630
+ cacheControl: z.lazy(() =>
2631
+ StreamRunAgentModelConfigurationCacheControl$outboundSchema
2632
+ ).optional(),
2633
+ promptCacheKey: z.string().optional(),
2445
2634
  }).transform((v) => {
2446
2635
  return remap$(v, {
2447
2636
  frequencyPenalty: "frequency_penalty",
@@ -2455,6 +2644,8 @@ export const StreamRunAgentModelConfigurationParameters$outboundSchema:
2455
2644
  toolChoice: "tool_choice",
2456
2645
  parallelToolCalls: "parallel_tool_calls",
2457
2646
  loadBalancer: "load_balancer",
2647
+ cacheControl: "cache_control",
2648
+ promptCacheKey: "prompt_cache_key",
2458
2649
  });
2459
2650
  });
2460
2651
 
@@ -3095,6 +3286,46 @@ export function streamRunAgentFallbackModelConfigurationTimeoutToJSON(
3095
3286
  );
3096
3287
  }
3097
3288
 
3289
+ /** @internal */
3290
+ export const StreamRunAgentFallbackModelConfigurationAgentsType$outboundSchema:
3291
+ z.ZodNativeEnum<typeof StreamRunAgentFallbackModelConfigurationAgentsType> = z
3292
+ .nativeEnum(StreamRunAgentFallbackModelConfigurationAgentsType);
3293
+
3294
+ /** @internal */
3295
+ export const StreamRunAgentFallbackModelConfigurationTtl$outboundSchema:
3296
+ z.ZodNativeEnum<typeof StreamRunAgentFallbackModelConfigurationTtl> = z
3297
+ .nativeEnum(StreamRunAgentFallbackModelConfigurationTtl);
3298
+
3299
+ /** @internal */
3300
+ export type StreamRunAgentFallbackModelConfigurationCacheControl$Outbound = {
3301
+ type: string;
3302
+ ttl: string;
3303
+ };
3304
+
3305
+ /** @internal */
3306
+ export const StreamRunAgentFallbackModelConfigurationCacheControl$outboundSchema:
3307
+ z.ZodType<
3308
+ StreamRunAgentFallbackModelConfigurationCacheControl$Outbound,
3309
+ z.ZodTypeDef,
3310
+ StreamRunAgentFallbackModelConfigurationCacheControl
3311
+ > = z.object({
3312
+ type: StreamRunAgentFallbackModelConfigurationAgentsType$outboundSchema,
3313
+ ttl: StreamRunAgentFallbackModelConfigurationTtl$outboundSchema.default(
3314
+ "5m",
3315
+ ),
3316
+ });
3317
+
3318
+ export function streamRunAgentFallbackModelConfigurationCacheControlToJSON(
3319
+ streamRunAgentFallbackModelConfigurationCacheControl:
3320
+ StreamRunAgentFallbackModelConfigurationCacheControl,
3321
+ ): string {
3322
+ return JSON.stringify(
3323
+ StreamRunAgentFallbackModelConfigurationCacheControl$outboundSchema.parse(
3324
+ streamRunAgentFallbackModelConfigurationCacheControl,
3325
+ ),
3326
+ );
3327
+ }
3328
+
3098
3329
  /** @internal */
3099
3330
  export type StreamRunAgentFallbackModelConfigurationParameters$Outbound = {
3100
3331
  name?: string | undefined;
@@ -3133,6 +3364,10 @@ export type StreamRunAgentFallbackModelConfigurationParameters$Outbound = {
3133
3364
  timeout?:
3134
3365
  | StreamRunAgentFallbackModelConfigurationTimeout$Outbound
3135
3366
  | undefined;
3367
+ cache_control?:
3368
+ | StreamRunAgentFallbackModelConfigurationCacheControl$Outbound
3369
+ | undefined;
3370
+ prompt_cache_key?: string | undefined;
3136
3371
  };
3137
3372
 
3138
3373
  /** @internal */
@@ -3196,6 +3431,10 @@ export const StreamRunAgentFallbackModelConfigurationParameters$outboundSchema:
3196
3431
  timeout: z.lazy(() =>
3197
3432
  StreamRunAgentFallbackModelConfigurationTimeout$outboundSchema
3198
3433
  ).optional(),
3434
+ cacheControl: z.lazy(() =>
3435
+ StreamRunAgentFallbackModelConfigurationCacheControl$outboundSchema
3436
+ ).optional(),
3437
+ promptCacheKey: z.string().optional(),
3199
3438
  }).transform((v) => {
3200
3439
  return remap$(v, {
3201
3440
  frequencyPenalty: "frequency_penalty",
@@ -3209,6 +3448,8 @@ export const StreamRunAgentFallbackModelConfigurationParameters$outboundSchema:
3209
3448
  toolChoice: "tool_choice",
3210
3449
  parallelToolCalls: "parallel_tool_calls",
3211
3450
  loadBalancer: "load_balancer",
3451
+ cacheControl: "cache_control",
3452
+ promptCacheKey: "prompt_cache_key",
3212
3453
  });
3213
3454
  });
3214
3455
 
@@ -3675,7 +3916,7 @@ export const AgentToolInputRunTools$outboundSchema: z.ZodType<
3675
3916
  z.ZodTypeDef,
3676
3917
  AgentToolInputRunTools
3677
3918
  > = z.object({
3678
- id: z.string().default("01KTKNH3E2VB9B1T40QQKNVW65"),
3919
+ id: z.string().default("01KTPAB2T342884JG2M9S0ZT3R"),
3679
3920
  name: z.string(),
3680
3921
  description: z.string().optional(),
3681
3922
  schema: z.lazy(() =>