@ai-sdk/xai 4.0.0-beta.29 → 4.0.0-beta.30

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1700,6 +1700,12 @@ var xaiResponsesChunkSchema = z6.union([
1700
1700
  usage: xaiResponsesUsageSchema.nullish()
1701
1701
  })
1702
1702
  }),
1703
+ z6.object({
1704
+ type: z6.literal("error"),
1705
+ code: z6.string().nullish(),
1706
+ message: z6.string(),
1707
+ param: z6.string().nullish()
1708
+ }),
1703
1709
  z6.object({
1704
1710
  type: z6.literal("response.done"),
1705
1711
  response: xaiResponsesResponseSchema
@@ -2552,6 +2558,10 @@ var XaiResponsesLanguageModel = class {
2552
2558
  }
2553
2559
  return;
2554
2560
  }
2561
+ if (event.type === "error") {
2562
+ controller.enqueue({ type: "error", error: event });
2563
+ return;
2564
+ }
2555
2565
  if (event.type === "response.custom_tool_call_input.delta" || event.type === "response.custom_tool_call_input.done") {
2556
2566
  return;
2557
2567
  }
@@ -2841,7 +2851,7 @@ var xaiTools = {
2841
2851
  };
2842
2852
 
2843
2853
  // src/version.ts
2844
- var VERSION = true ? "4.0.0-beta.29" : "0.0.0-test";
2854
+ var VERSION = true ? "4.0.0-beta.30" : "0.0.0-test";
2845
2855
 
2846
2856
  // src/files/xai-files.ts
2847
2857
  import {