@ai-sdk/prodia 2.0.0-beta.5 → 2.0.0-beta.54

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/CHANGELOG.md CHANGED
@@ -1,11 +1,415 @@
1
1
  # @ai-sdk/prodia
2
2
 
3
+ ## 2.0.0-beta.54
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [0416e3e]
8
+ - @ai-sdk/provider@4.0.0-beta.20
9
+ - @ai-sdk/provider-utils@5.0.0-beta.50
10
+
11
+ ## 2.0.0-beta.53
12
+
13
+ ### Patch Changes
14
+
15
+ - b8396f0: trigger initial beta release
16
+ - Updated dependencies [b8396f0]
17
+ - @ai-sdk/provider-utils@5.0.0-beta.49
18
+ - @ai-sdk/provider@4.0.0-beta.19
19
+
20
+ ## 2.0.0-canary.52
21
+
22
+ ### Patch Changes
23
+
24
+ - Updated dependencies [aeda373]
25
+ - Updated dependencies [375fdd7]
26
+ - Updated dependencies [b4507d5]
27
+ - @ai-sdk/provider-utils@5.0.0-canary.48
28
+
29
+ ## 2.0.0-canary.51
30
+
31
+ ### Patch Changes
32
+
33
+ - 6e8917f: fix(prodia): validate user-supplied image URLs before fetching (SSRF)
34
+
35
+ The Prodia video model's `resolveVideoFileData` fetched a user-supplied `image` URL directly with `fetch()`, bypassing the SDK's SSRF guard. An attacker who could supply the image URL could make the server request internal endpoints (e.g. cloud metadata) and have the response uploaded to Prodia's API. The URL is now downloaded via `downloadBlob`, which routes through `validateDownloadUrl` and rejects private/internal addresses, matching the pattern used by other providers.
36
+
37
+ - Updated dependencies [bae5e2b]
38
+ - @ai-sdk/provider-utils@5.0.0-canary.47
39
+
40
+ ## 2.0.0-canary.50
41
+
42
+ ### Patch Changes
43
+
44
+ - Updated dependencies [ce769dd]
45
+ - @ai-sdk/provider@4.0.0-canary.18
46
+ - @ai-sdk/provider-utils@5.0.0-canary.46
47
+
48
+ ## 2.0.0-canary.49
49
+
50
+ ### Patch Changes
51
+
52
+ - Updated dependencies [ee798eb]
53
+ - Updated dependencies [daf6637]
54
+ - @ai-sdk/provider-utils@5.0.0-canary.45
55
+
56
+ ## 2.0.0-canary.48
57
+
58
+ ### Patch Changes
59
+
60
+ - Updated dependencies [6c93e36]
61
+ - Updated dependencies [f617ac2]
62
+ - @ai-sdk/provider-utils@5.0.0-canary.44
63
+
64
+ ## 2.0.0-canary.47
65
+
66
+ ### Patch Changes
67
+
68
+ - 7fc6bd6: Raise minimum supported Node.js version to 22. Supported versions: 22, 24, and 26.
69
+ - Updated dependencies [7fc6bd6]
70
+ - @ai-sdk/provider-utils@5.0.0-canary.43
71
+ - @ai-sdk/provider@4.0.0-canary.17
72
+
73
+ ## 2.0.0-canary.46
74
+
75
+ ### Patch Changes
76
+
77
+ - Updated dependencies [a6617c5]
78
+ - @ai-sdk/provider-utils@5.0.0-canary.42
79
+
80
+ ## 2.0.0-canary.45
81
+
82
+ ### Patch Changes
83
+
84
+ - Updated dependencies [28dfa06]
85
+ - Updated dependencies [e93fa91]
86
+ - @ai-sdk/provider-utils@5.0.0-canary.41
87
+
88
+ ## 2.0.0-canary.44
89
+
90
+ ### Patch Changes
91
+
92
+ - Updated dependencies [a7de9c9]
93
+ - @ai-sdk/provider-utils@5.0.0-canary.40
94
+
95
+ ## 2.0.0-canary.43
96
+
97
+ ### Patch Changes
98
+
99
+ - Updated dependencies [105f95b]
100
+ - @ai-sdk/provider-utils@5.0.0-canary.39
101
+
102
+ ## 2.0.0-canary.42
103
+
104
+ ### Patch Changes
105
+
106
+ - Updated dependencies [ca446f8]
107
+ - @ai-sdk/provider-utils@5.0.0-canary.38
108
+
109
+ ## 2.0.0-canary.41
110
+
111
+ ### Patch Changes
112
+
113
+ - Updated dependencies [d848405]
114
+ - @ai-sdk/provider-utils@5.0.0-canary.37
115
+
116
+ ## 2.0.0-canary.40
117
+
118
+ ### Patch Changes
119
+
120
+ - Updated dependencies [ca39020]
121
+ - @ai-sdk/provider-utils@5.0.0-canary.36
122
+
123
+ ## 2.0.0-canary.39
124
+
125
+ ### Patch Changes
126
+
127
+ - Updated dependencies [f634bac]
128
+ - @ai-sdk/provider-utils@5.0.0-canary.35
129
+
130
+ ## 2.0.0-canary.38
131
+
132
+ ### Patch Changes
133
+
134
+ - Updated dependencies [69254e0]
135
+ - Updated dependencies [3015fc3]
136
+ - @ai-sdk/provider-utils@5.0.0-canary.34
137
+
138
+ ## 2.0.0-canary.37
139
+
140
+ ### Patch Changes
141
+
142
+ - Updated dependencies [2427d88]
143
+ - @ai-sdk/provider-utils@5.0.0-canary.33
144
+
145
+ ## 2.0.0-canary.36
146
+
147
+ ### Patch Changes
148
+
149
+ - Updated dependencies [5463d0d]
150
+ - @ai-sdk/provider-utils@5.0.0-canary.32
151
+ - @ai-sdk/provider@4.0.0-canary.16
152
+
153
+ ## 2.0.0-canary.35
154
+
155
+ ### Patch Changes
156
+
157
+ - 0c4c275: trigger initial canary release
158
+ - Updated dependencies [0c4c275]
159
+ - @ai-sdk/provider-utils@5.0.0-canary.31
160
+ - @ai-sdk/provider@4.0.0-canary.15
161
+
162
+ ## 2.0.0-beta.34
163
+
164
+ ### Major Changes
165
+
166
+ - 04e9009: chore: make provider implementations code patterns more consistent, including renaming certain exported symbols
167
+
168
+ For all externally exported symbols that were renamed, the old names continue to work via deprecated aliases.
169
+
170
+ ### Patch Changes
171
+
172
+ - Updated dependencies [08d2129]
173
+ - @ai-sdk/provider-utils@5.0.0-beta.30
174
+
175
+ ## 2.0.0-beta.33
176
+
177
+ ### Patch Changes
178
+
179
+ - 9bd6512: feat(provider): change file part data property to be tagged with a type and remove the image part type
180
+ - 258c093: chore: ensure consistent import handling and avoid import duplicates or cycles
181
+ - Updated dependencies [9bd6512]
182
+ - Updated dependencies [258c093]
183
+ - Updated dependencies [b6783da]
184
+ - @ai-sdk/provider-utils@5.0.0-beta.29
185
+ - @ai-sdk/provider@4.0.0-beta.14
186
+
187
+ ## 2.0.0-beta.32
188
+
189
+ ### Patch Changes
190
+
191
+ - 9f0e36c: trigger release for all packages after provenance setup
192
+ - Updated dependencies [9f0e36c]
193
+ - @ai-sdk/provider@4.0.0-beta.13
194
+ - @ai-sdk/provider-utils@5.0.0-beta.28
195
+
196
+ ## 2.0.0-beta.31
197
+
198
+ ### Patch Changes
199
+
200
+ - Updated dependencies [785fe16]
201
+ - Updated dependencies [67df0a0]
202
+ - Updated dependencies [befb78c]
203
+ - Updated dependencies [0458559]
204
+ - Updated dependencies [5852c0a]
205
+ - Updated dependencies [fc92055]
206
+ - @ai-sdk/provider-utils@5.0.0-beta.27
207
+
208
+ ## 2.0.0-beta.30
209
+
210
+ ### Patch Changes
211
+
212
+ - Updated dependencies [2e98477]
213
+ - @ai-sdk/provider-utils@5.0.0-beta.26
214
+
215
+ ## 2.0.0-beta.29
216
+
217
+ ### Patch Changes
218
+
219
+ - Updated dependencies [eea8d98]
220
+ - @ai-sdk/provider-utils@5.0.0-beta.25
221
+
222
+ ## 2.0.0-beta.28
223
+
224
+ ### Patch Changes
225
+
226
+ - Updated dependencies [f807e45]
227
+ - @ai-sdk/provider-utils@5.0.0-beta.24
228
+
229
+ ## 2.0.0-beta.27
230
+
231
+ ### Patch Changes
232
+
233
+ - Updated dependencies [350ea38]
234
+ - @ai-sdk/provider-utils@5.0.0-beta.23
235
+
236
+ ## 2.0.0-beta.26
237
+
238
+ ### Patch Changes
239
+
240
+ - Updated dependencies [083947b]
241
+ - @ai-sdk/provider-utils@5.0.0-beta.22
242
+
243
+ ## 2.0.0-beta.25
244
+
245
+ ### Patch Changes
246
+
247
+ - Updated dependencies [add1126]
248
+ - @ai-sdk/provider-utils@5.0.0-beta.21
249
+
250
+ ## 2.0.0-beta.24
251
+
252
+ ### Patch Changes
253
+
254
+ - b3976a2: Add workflow serialization support to all provider models.
255
+
256
+ **`@ai-sdk/provider-utils`:** New `serializeModel()` helper that extracts only serializable properties from a model instance, filtering out functions and objects containing functions. Third-party provider authors can use this to add workflow support to their own models.
257
+
258
+ **All providers:** `headers` is now optional in provider config types. This is non-breaking — existing code that passes `headers` continues to work. Custom provider implementations that construct model configs manually can now omit `headers`, which is useful when models are deserialized from a workflow step boundary where auth is provided separately.
259
+
260
+ All provider model classes now include `WORKFLOW_SERIALIZE` and `WORKFLOW_DESERIALIZE` static methods, enabling them to cross workflow step boundaries without serialization errors.
261
+
262
+ - Updated dependencies [b3976a2]
263
+ - Updated dependencies [ff5eba1]
264
+ - @ai-sdk/provider-utils@5.0.0-beta.20
265
+ - @ai-sdk/provider@4.0.0-beta.12
266
+
267
+ ## 2.0.0-beta.23
268
+
269
+ ### Major Changes
270
+
271
+ - ef992f8: Remove CommonJS exports from all packages. All packages are now ESM-only (`"type": "module"`). Consumers using `require()` must switch to ESM `import` syntax.
272
+
273
+ ### Patch Changes
274
+
275
+ - Updated dependencies [ef992f8]
276
+ - @ai-sdk/provider@4.0.0-beta.11
277
+ - @ai-sdk/provider-utils@5.0.0-beta.19
278
+
279
+ ## 2.0.0-beta.22
280
+
281
+ ### Patch Changes
282
+
283
+ - Updated dependencies [90e2d8a]
284
+ - @ai-sdk/provider-utils@5.0.0-beta.18
285
+
286
+ ## 2.0.0-beta.21
287
+
288
+ ### Patch Changes
289
+
290
+ - Updated dependencies [3ae1786]
291
+ - @ai-sdk/provider-utils@5.0.0-beta.17
292
+
293
+ ## 2.0.0-beta.20
294
+
295
+ ### Patch Changes
296
+
297
+ - Updated dependencies [176466a]
298
+ - @ai-sdk/provider@4.0.0-beta.10
299
+ - @ai-sdk/provider-utils@5.0.0-beta.16
300
+
301
+ ## 2.0.0-beta.19
302
+
303
+ ### Patch Changes
304
+
305
+ - Updated dependencies [e311194]
306
+ - @ai-sdk/provider@4.0.0-beta.9
307
+ - @ai-sdk/provider-utils@5.0.0-beta.15
308
+
309
+ ## 2.0.0-beta.18
310
+
311
+ ### Patch Changes
312
+
313
+ - Updated dependencies [34bd95d]
314
+ - Updated dependencies [008271d]
315
+ - @ai-sdk/provider@4.0.0-beta.8
316
+ - @ai-sdk/provider-utils@5.0.0-beta.14
317
+
318
+ ## 2.0.0-beta.17
319
+
320
+ ### Patch Changes
321
+
322
+ - Updated dependencies [b0c2869]
323
+ - Updated dependencies [7e26e81]
324
+ - @ai-sdk/provider-utils@5.0.0-beta.13
325
+
326
+ ## 2.0.0-beta.16
327
+
328
+ ### Patch Changes
329
+
330
+ - Updated dependencies [46d1149]
331
+ - @ai-sdk/provider-utils@5.0.0-beta.12
332
+
333
+ ## 2.0.0-beta.15
334
+
335
+ ### Patch Changes
336
+
337
+ - Updated dependencies [6fd51c0]
338
+ - @ai-sdk/provider-utils@5.0.0-beta.11
339
+ - @ai-sdk/provider@4.0.0-beta.7
340
+
341
+ ## 2.0.0-beta.14
342
+
343
+ ### Patch Changes
344
+
345
+ - c29a26f: feat(provider): add support for provider references and uploading files as supported per provider
346
+ - Updated dependencies [c29a26f]
347
+ - @ai-sdk/provider-utils@5.0.0-beta.10
348
+ - @ai-sdk/provider@4.0.0-beta.6
349
+
350
+ ## 2.0.0-beta.13
351
+
352
+ ### Patch Changes
353
+
354
+ - 38fc777: Add AI Gateway hint to provider READMEs
355
+
356
+ ## 2.0.0-beta.12
357
+
358
+ ### Patch Changes
359
+
360
+ - Updated dependencies [2e17091]
361
+ - @ai-sdk/provider-utils@5.0.0-beta.9
362
+
363
+ ## 2.0.0-beta.11
364
+
365
+ ### Patch Changes
366
+
367
+ - Updated dependencies [986c6fd]
368
+ - Updated dependencies [493295c]
369
+ - @ai-sdk/provider-utils@5.0.0-beta.8
370
+
371
+ ## 2.0.0-beta.10
372
+
373
+ ### Patch Changes
374
+
375
+ - Updated dependencies [1f509d4]
376
+ - @ai-sdk/provider-utils@5.0.0-beta.7
377
+ - @ai-sdk/provider@4.0.0-beta.5
378
+
379
+ ## 2.0.0-beta.9
380
+
381
+ ### Patch Changes
382
+
383
+ - 5259a95: chore: add warning for providers that do not support new reasoning parameter
384
+
385
+ ## 2.0.0-beta.8
386
+
387
+ ### Patch Changes
388
+
389
+ - Updated dependencies [3887c70]
390
+ - @ai-sdk/provider-utils@5.0.0-beta.6
391
+ - @ai-sdk/provider@4.0.0-beta.4
392
+
393
+ ## 2.0.0-beta.7
394
+
395
+ ### Patch Changes
396
+
397
+ - Updated dependencies [776b617]
398
+ - @ai-sdk/provider-utils@5.0.0-beta.5
399
+ - @ai-sdk/provider@4.0.0-beta.3
400
+
401
+ ## 2.0.0-beta.6
402
+
403
+ ### Patch Changes
404
+
405
+ - Updated dependencies [61753c3]
406
+ - @ai-sdk/provider-utils@5.0.0-beta.4
407
+
3
408
  ## 2.0.0-beta.5
4
409
 
5
410
  ### Patch Changes
6
411
 
7
412
  - e2bdcd6: feat(provider/prodia): Add LanguageModel and VideoModel support to the Prodia provider.
8
-
9
413
  - **LanguageModel**: Supports Nano Banana (`inference.nano-banana.img2img.v2`) for img2img generation with text+image output via multipart form-data requests. Implements both `doGenerate` and `doStream`.
10
414
  - **VideoModel**: Supports Wan 2.2 Lightning for text-to-video (`inference.wan2-2.lightning.txt2vid.v0`) and image-to-video (`inference.wan2-2.lightning.img2vid.v0`) generation.
11
415
  - Extract shared multipart parsing and error handling infrastructure into `prodia-api.ts`.
package/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  The **[Prodia provider](https://ai-sdk.dev/providers/ai-sdk-providers/prodia)** for the [AI SDK](https://ai-sdk.dev/docs) adds image model support for the [Prodia API](https://docs.prodia.com/).
4
4
 
5
+ > **Deploying to Vercel?** With Vercel's AI Gateway you can access Prodia (and hundreds of models from other providers) — no additional packages, API keys, or extra cost. [Get started with AI Gateway](https://vercel.com/ai-gateway).
6
+
5
7
  ## Setup
6
8
 
7
9
  The Prodia provider is available in the `@ai-sdk/prodia` module. You can install it with
package/dist/index.d.ts CHANGED
@@ -2,11 +2,6 @@ import * as _ai_sdk_provider_utils from '@ai-sdk/provider-utils';
2
2
  import { InferSchema, FetchFunction } from '@ai-sdk/provider-utils';
3
3
  import { ProviderV4, LanguageModelV4, ImageModelV4, Experimental_VideoModelV4 } from '@ai-sdk/provider';
4
4
 
5
- /**
6
- * Prodia job types for image generation.
7
- */
8
- type ProdiaImageModelId = 'inference.flux-fast.schnell.txt2img.v2' | 'inference.flux.schnell.txt2img.v2' | (string & {});
9
-
10
5
  declare const prodiaImageModelOptionsSchema: _ai_sdk_provider_utils.LazySchema<{
11
6
  steps?: number | undefined;
12
7
  width?: number | undefined;
@@ -18,9 +13,9 @@ declare const prodiaImageModelOptionsSchema: _ai_sdk_provider_utils.LazySchema<{
18
13
  type ProdiaImageModelOptions = InferSchema<typeof prodiaImageModelOptionsSchema>;
19
14
 
20
15
  /**
21
- * Prodia job types for language model (multimodal img2img).
16
+ * Prodia job types for image generation.
22
17
  */
23
- type ProdiaLanguageModelId = 'inference.nano-banana.img2img.v2' | (string & {});
18
+ type ProdiaImageModelId = 'inference.flux-fast.schnell.txt2img.v2' | 'inference.flux.schnell.txt2img.v2' | (string & {});
24
19
 
25
20
  declare const prodiaLanguageModelOptionsSchema: _ai_sdk_provider_utils.LazySchema<{
26
21
  aspectRatio?: "1:1" | "2:3" | "3:2" | "4:5" | "5:4" | "4:7" | "7:4" | "9:16" | "16:9" | "9:21" | "21:9" | undefined;
@@ -28,15 +23,20 @@ declare const prodiaLanguageModelOptionsSchema: _ai_sdk_provider_utils.LazySchem
28
23
  type ProdiaLanguageModelOptions = InferSchema<typeof prodiaLanguageModelOptionsSchema>;
29
24
 
30
25
  /**
31
- * Prodia job types for video generation.
26
+ * Prodia job types for language model (multimodal img2img).
32
27
  */
33
- type ProdiaVideoModelId = 'inference.wan2-2.lightning.txt2vid.v0' | 'inference.wan2-2.lightning.img2vid.v0' | (string & {});
28
+ type ProdiaLanguageModelId = 'inference.nano-banana.img2img.v2' | (string & {});
34
29
 
35
30
  declare const prodiaVideoModelOptionsSchema: _ai_sdk_provider_utils.LazySchema<{
36
31
  resolution?: string | undefined;
37
32
  }>;
38
33
  type ProdiaVideoModelOptions = InferSchema<typeof prodiaVideoModelOptionsSchema>;
39
34
 
35
+ /**
36
+ * Prodia job types for video generation.
37
+ */
38
+ type ProdiaVideoModelId = 'inference.wan2-2.lightning.txt2vid.v0' | 'inference.wan2-2.lightning.img2vid.v0' | (string & {});
39
+
40
40
  interface ProdiaProviderSettings {
41
41
  /**
42
42
  * Prodia API key. Default value is taken from the `PRODIA_TOKEN` environment variable.