You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@ai-sdk/xai

Package Overview
Dependencies
Maintainers
3
Versions
342
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ai-sdk/xai - npm Package Compare versions

Comparing version
4.0.0-beta.11
to
4.0.0-beta.12
+9
-0
CHANGELOG.md
# @ai-sdk/xai
## 4.0.0-beta.12
### Patch Changes
- d20829e: feat(provider/xai): add moderation error, and costInUsdTicks to video model
- Updated dependencies [61753c3]
- @ai-sdk/provider-utils@5.0.0-beta.4
- @ai-sdk/openai-compatible@3.0.0-beta.6
## 4.0.0-beta.11

@@ -4,0 +13,0 @@

+6
-6
{
"name": "@ai-sdk/xai",
"version": "4.0.0-beta.11",
"version": "4.0.0-beta.12",
"license": "Apache-2.0",

@@ -32,5 +32,5 @@ "sideEffects": false,

"dependencies": {
"@ai-sdk/openai-compatible": "3.0.0-beta.5",
"@ai-sdk/provider-utils": "5.0.0-beta.3",
"@ai-sdk/provider": "4.0.0-beta.2"
"@ai-sdk/openai-compatible": "3.0.0-beta.6",
"@ai-sdk/provider": "4.0.0-beta.2",
"@ai-sdk/provider-utils": "5.0.0-beta.4"
},

@@ -42,4 +42,4 @@ "devDependencies": {

"zod": "3.25.76",
"@ai-sdk/test-server": "2.0.0-beta.0",
"@vercel/ai-tsconfig": "0.0.0"
"@vercel/ai-tsconfig": "0.0.0",
"@ai-sdk/test-server": "2.0.0-beta.0"
},

@@ -46,0 +46,0 @@ "peerDependencies": {

@@ -242,2 +242,10 @@ import {

) {
if (statusResponse.video?.respect_moderation === false) {
throw new AISDKError({
name: 'XAI_VIDEO_MODERATION_ERROR',
message:
'Video generation was blocked due to a content policy violation.',
});
}
if (!statusResponse.video?.url) {

@@ -272,2 +280,5 @@ throw new AISDKError({

: {}),
...(statusResponse.usage?.cost_in_usd_ticks != null
? { costInUsdTicks: statusResponse.usage.cost_in_usd_ticks }
: {}),
},

@@ -304,2 +315,7 @@ },

model: z.string().nullish(),
usage: z
.object({
cost_in_usd_ticks: z.number().nullish(),
})
.nullish(),
});

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display