v0-api 0.3.0 → 0.3.1

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.
@@ -1,7 +1,7 @@
1
1
  import * as z from 'zod';
2
2
 
3
3
  // @ts-nocheck
4
- const chatDetailSchema = z.object({
4
+ const chatDetailSchema = z.strictObject({
5
5
  id: z.string().describe("A unique identifier for the chat."),
6
6
  object: z.enum([
7
7
  "chat"
@@ -24,7 +24,7 @@ const chatDetailSchema = z.object({
24
24
  vercelProjectId: z.string().optional().describe("Optional ID of the linked Vercel project, if connected."),
25
25
  webUrl: z.string().describe("Web URL to view this chat in the browser."),
26
26
  apiUrl: z.string().describe("API URL to access this chat via the API."),
27
- latestVersion: z.object({
27
+ latestVersion: z.strictObject({
28
28
  id: z.string().describe("A unique identifier for the version."),
29
29
  object: z.enum([
30
30
  "version"
@@ -38,18 +38,18 @@ const chatDetailSchema = z.object({
38
38
  screenshotUrl: z.string().optional().describe("URL to retrieve a screenshot of this version."),
39
39
  createdAt: z.iso.datetime().describe("The date and time when the version was created, in ISO 8601 format."),
40
40
  updatedAt: z.iso.datetime().optional().describe("The date and time when the version was last updated, in ISO 8601 format."),
41
- files: z.array(z.object({
41
+ files: z.array(z.strictObject({
42
42
  object: z.enum([
43
43
  "file"
44
44
  ]).describe("Fixed value identifying this object as a file."),
45
45
  name: z.string().describe("The name of the file, including its extension."),
46
46
  content: z.string().describe("The full contents of the file as a raw string."),
47
47
  locked: z.boolean().describe("Whether the file is locked to prevent AI from overwriting it during new version generation.")
48
- }).strict()).describe("A list of files that were generated or included in this version.")
49
- }).strict().optional().describe("Full details of the most recent generated version, if available."),
48
+ })).describe("A list of files that were generated or included in this version.")
49
+ }).optional().describe("Full details of the most recent generated version, if available."),
50
50
  metadata: z.object({}).catchall(z.string()).describe("Arbitrary key-value data associated with this chat."),
51
51
  url: z.string().describe("The canonical URL to access this chat."),
52
- messages: z.array(z.object({
52
+ messages: z.array(z.strictObject({
53
53
  id: z.string().describe("A unique identifier for the message."),
54
54
  object: z.enum([
55
55
  "message"
@@ -62,7 +62,7 @@ const chatDetailSchema = z.object({
62
62
  ]),
63
63
  z.tuple([
64
64
  z.literal(1),
65
- z.object({
65
+ z.strictObject({
66
66
  toJSONSchema: z.string(),
67
67
  def: z.string(),
68
68
  type: z.string(),
@@ -119,7 +119,7 @@ const chatDetailSchema = z.object({
119
119
  omit: z.string(),
120
120
  partial: z.string(),
121
121
  required: z.string()
122
- }).strict()
122
+ })
123
123
  ])
124
124
  ])).optional().describe("The parsed content of the message as an array structure containing AST nodes. This is an experimental field that may change."),
125
125
  createdAt: z.string().describe("The ISO timestamp representing when the message was created."),
@@ -163,7 +163,7 @@ const chatDetailSchema = z.object({
163
163
  apiUrl: z.string().describe("API URL to access this message via the API."),
164
164
  authorId: z.string().nullable().describe("The ID of the user who sent the message."),
165
165
  parentId: z.string().nullish().describe("The ID of the parent message."),
166
- attachments: z.array(z.object({
166
+ attachments: z.array(z.strictObject({
167
167
  url: z.string().describe("The URL where the attachment file can be accessed."),
168
168
  name: z.string().optional().describe("The original filename of the attachment."),
169
169
  contentType: z.string().optional().describe("The MIME type of the attachment file (e.g., image/png, application/pdf)."),
@@ -174,16 +174,16 @@ const chatDetailSchema = z.object({
174
174
  "screenshot",
175
175
  "zip"
176
176
  ]).optional().describe("Optional v0-specific attachment type for enhanced processing.")
177
- }).strict()).optional()
178
- }).strict()).describe("All messages exchanged in the chat, including user and assistant entries."),
179
- files: z.array(z.object({
177
+ })).optional()
178
+ })).describe("All messages exchanged in the chat, including user and assistant entries."),
179
+ files: z.array(z.strictObject({
180
180
  lang: z.string().describe("Programming language used in the file (e.g., JavaScript, Python)."),
181
181
  meta: z.object({}).catchall(z.string()).describe("A key-value map of metadata associated with the file (e.g., path, type)."),
182
182
  source: z.string().describe("The origin or identifier of the file source (e.g., path or upload label).")
183
- }).strict()).optional().describe("Optional array of files associated with the chat context."),
183
+ })).optional().describe("Optional array of files associated with the chat context."),
184
184
  demo: z.string().optional().describe("Deprecated demo URL used for previewing the chat result."),
185
185
  text: z.string().describe("The main user prompt or instruction that started the chat."),
186
- modelConfiguration: z.object({
186
+ modelConfiguration: z.strictObject({
187
187
  modelId: z.enum([
188
188
  "v0-auto",
189
189
  "v0-max",
@@ -208,12 +208,12 @@ const chatDetailSchema = z.object({
208
208
  z.null()
209
209
  ]).optional(),
210
210
  fast: z.boolean().optional()
211
- }).strict().optional().describe("The configuration used to generate responses in this chat."),
212
- permissions: z.object({
211
+ }).optional().describe("The configuration used to generate responses in this chat."),
212
+ permissions: z.strictObject({
213
213
  write: z.boolean().describe("If true, the user has write access to the chat.")
214
- }).strict()
215
- }).strict().describe("Detailed representation of a chat, including its messages, files, versions, and model configuration.");
216
- const chatSummarySchema = z.object({
214
+ })
215
+ }).describe("Detailed representation of a chat, including its messages, files, versions, and model configuration.");
216
+ const chatSummarySchema = z.strictObject({
217
217
  id: z.string().describe("A unique identifier for the chat."),
218
218
  object: z.enum([
219
219
  "chat"
@@ -236,7 +236,7 @@ const chatSummarySchema = z.object({
236
236
  vercelProjectId: z.string().optional().describe("Optional ID of the linked Vercel project, if connected."),
237
237
  webUrl: z.string().describe("Web URL to view this chat in the browser."),
238
238
  apiUrl: z.string().describe("API URL to access this chat via the API."),
239
- latestVersion: z.object({
239
+ latestVersion: z.strictObject({
240
240
  id: z.string().describe("A unique identifier for the version."),
241
241
  object: z.enum([
242
242
  "version"
@@ -250,10 +250,10 @@ const chatSummarySchema = z.object({
250
250
  screenshotUrl: z.string().optional().describe("URL to retrieve a screenshot of this version."),
251
251
  createdAt: z.iso.datetime().describe("The date and time when the version was created, in ISO 8601 format."),
252
252
  updatedAt: z.iso.datetime().optional().describe("The date and time when the version was last updated, in ISO 8601 format.")
253
- }).strict().optional().describe("The most recent generated version of the chat, if available."),
253
+ }).optional().describe("The most recent generated version of the chat, if available."),
254
254
  metadata: z.object({}).catchall(z.string()).describe("Arbitrary key-value data associated with this chat.")
255
- }).strict().describe("Summary of a chat, including metadata like privacy, author, latest version, and URLs.");
256
- const deploymentDetailSchema = z.object({
255
+ }).describe("Summary of a chat, including metadata like privacy, author, latest version, and URLs.");
256
+ const deploymentDetailSchema = z.strictObject({
257
257
  id: z.string().describe("A unique identifier for the deployment."),
258
258
  object: z.enum([
259
259
  "deployment"
@@ -264,8 +264,8 @@ const deploymentDetailSchema = z.object({
264
264
  versionId: z.string().describe("The ID of the version that this deployment is scoped to."),
265
265
  apiUrl: z.url().describe("The API endpoint URL for accessing this deployment programmatically."),
266
266
  webUrl: z.url().describe("The web URL where the deployment can be viewed or managed.")
267
- }).strict();
268
- const deploymentSummarySchema = z.object({
267
+ });
268
+ const deploymentSummarySchema = z.strictObject({
269
269
  id: z.string().describe("A unique identifier for the deployment."),
270
270
  object: z.enum([
271
271
  "deployment"
@@ -276,8 +276,8 @@ const deploymentSummarySchema = z.object({
276
276
  versionId: z.string().describe("The ID of the version that this deployment is scoped to."),
277
277
  apiUrl: z.url().describe("The API endpoint URL for accessing this deployment programmatically."),
278
278
  webUrl: z.url().describe("The web URL where the deployment can be viewed or managed.")
279
- }).strict();
280
- const environmentVariableDetailSchemaSchema = z.object({
279
+ });
280
+ const environmentVariableDetailSchemaSchema = z.strictObject({
281
281
  id: z.string().describe("A unique identifier for the environment variable."),
282
282
  object: z.enum([
283
283
  "environment_variable"
@@ -287,8 +287,8 @@ const environmentVariableDetailSchemaSchema = z.object({
287
287
  decrypted: z.boolean().describe("Whether the value is decrypted or encrypted."),
288
288
  createdAt: z.number().describe("The timestamp when the environment variable was created."),
289
289
  updatedAt: z.number().optional().describe("The timestamp when the environment variable was last updated.")
290
- }).strict().describe("Detailed information for an environment variable including its value.");
291
- const environmentVariableSummarySchemaSchema = z.object({
290
+ }).describe("Detailed information for an environment variable including its value.");
291
+ const environmentVariableSummarySchemaSchema = z.strictObject({
292
292
  id: z.string().describe("A unique identifier for the environment variable."),
293
293
  object: z.enum([
294
294
  "environment_variable"
@@ -298,12 +298,12 @@ const environmentVariableSummarySchemaSchema = z.object({
298
298
  decrypted: z.boolean().describe("Whether the value is decrypted or encrypted."),
299
299
  createdAt: z.number().describe("The timestamp when the environment variable was created."),
300
300
  updatedAt: z.number().optional().describe("The timestamp when the environment variable was last updated.")
301
- }).strict().describe("Summary information for an environment variable.");
302
- const environmentVariablesListSchemaSchema = z.object({
301
+ }).describe("Summary information for an environment variable.");
302
+ const environmentVariablesListSchemaSchema = z.strictObject({
303
303
  object: z.enum([
304
304
  "list"
305
305
  ]).describe("Fixed value identifying this as a list response."),
306
- data: z.array(z.object({
306
+ data: z.array(z.strictObject({
307
307
  id: z.string().describe("A unique identifier for the environment variable."),
308
308
  object: z.enum([
309
309
  "environment_variable"
@@ -313,23 +313,23 @@ const environmentVariablesListSchemaSchema = z.object({
313
313
  decrypted: z.boolean().describe("Whether the value is decrypted or encrypted."),
314
314
  createdAt: z.number().describe("The timestamp when the environment variable was created."),
315
315
  updatedAt: z.number().optional().describe("The timestamp when the environment variable was last updated.")
316
- }).strict()).describe("Array of environment variable details.")
317
- }).strict().describe("List response containing environment variables.");
318
- const fileDetailSchema = z.object({
316
+ })).describe("Array of environment variable details.")
317
+ }).describe("List response containing environment variables.");
318
+ const fileDetailSchema = z.strictObject({
319
319
  object: z.enum([
320
320
  "file"
321
321
  ]).describe("Fixed value identifying this object as a file."),
322
322
  name: z.string().describe("The name of the file, including its extension."),
323
323
  content: z.string().describe("The full contents of the file as a raw string."),
324
324
  locked: z.boolean().describe("Whether the file is locked to prevent AI from overwriting it during new version generation.")
325
- }).strict().describe("Detailed representation of a file, including its content and lock status.");
326
- const fileSummarySchema = z.object({
325
+ }).describe("Detailed representation of a file, including its content and lock status.");
326
+ const fileSummarySchema = z.strictObject({
327
327
  object: z.enum([
328
328
  "file"
329
329
  ]).describe("Fixed value identifying this object as a file."),
330
330
  name: z.string().describe("The name of the file, including its extension.")
331
- }).strict().describe("Basic metadata about a file, such as its type and name.");
332
- const hookDetailSchema = z.object({
331
+ }).describe("Basic metadata about a file, such as its type and name.");
332
+ const hookDetailSchema = z.strictObject({
333
333
  id: z.string().describe("A unique identifier for the webhook."),
334
334
  object: z.enum([
335
335
  "hook"
@@ -346,8 +346,8 @@ const hookDetailSchema = z.object({
346
346
  ])).describe("List of event types this webhook is subscribed to."),
347
347
  chatId: z.string().optional().describe("Optional ID of the chat that this webhook is scoped to."),
348
348
  url: z.string().describe("Target URL that receives event payloads for this webhook.")
349
- }).strict().describe("Full configuration details for a webhook, including its scope and subscription.");
350
- const hookEventDetailSchema = z.object({
349
+ }).describe("Full configuration details for a webhook, including its scope and subscription.");
350
+ const hookEventDetailSchema = z.strictObject({
351
351
  id: z.string().describe("A unique identifier for the webhook event log entry."),
352
352
  object: z.enum([
353
353
  "hook_event"
@@ -367,66 +367,66 @@ const hookEventDetailSchema = z.object({
367
367
  "success"
368
368
  ]).optional().default("pending").describe("The delivery status of the webhook (e.g., delivered, failed)."),
369
369
  createdAt: z.iso.datetime().describe("Timestamp of when the webhook event was triggered.")
370
- }).strict().describe("Detailed record of a webhook event, including its type, status, and timestamp.");
371
- const hookSummarySchema = z.object({
370
+ }).describe("Detailed record of a webhook event, including its type, status, and timestamp.");
371
+ const hookSummarySchema = z.strictObject({
372
372
  id: z.string().describe("A unique identifier for the webhook."),
373
373
  object: z.enum([
374
374
  "hook"
375
375
  ]).describe("Fixed value identifying this object as a webhook."),
376
376
  name: z.string().describe("A user-defined name to label the webhook.")
377
- }).strict().describe("Summary of a webhook, including its ID and display name.");
378
- const integrationConnectionDetailSchemaSchema = z.object({
377
+ }).describe("Summary of a webhook, including its ID and display name.");
378
+ const integrationConnectionDetailSchemaSchema = z.strictObject({
379
379
  object: z.enum([
380
380
  "integration_connection"
381
381
  ]).describe("The object type."),
382
382
  id: z.string().describe("The unique ID of the integration connection (format: {projectId}_{integrationId})."),
383
383
  connected: z.boolean().describe("Whether the integration is connected to the project."),
384
- integration: z.object({
384
+ integration: z.strictObject({
385
385
  id: z.string().describe("The ID of the integration."),
386
386
  object: z.enum([
387
387
  "integration"
388
388
  ]).describe("The object type."),
389
389
  slug: z.string().describe("The slug of the integration."),
390
390
  name: z.string().describe("The name of the integration.")
391
- }).strict().describe("Information about the connected integration."),
391
+ }).describe("Information about the connected integration."),
392
392
  metadata: z.object({}).catchall(z.unknown()).optional().describe("Additional metadata about the integration connection.")
393
- }).strict().describe("Detailed information about an integration connection to a project.");
394
- const integrationConnectionListSchemaSchema = z.object({
393
+ }).describe("Detailed information about an integration connection to a project.");
394
+ const integrationConnectionListSchemaSchema = z.strictObject({
395
395
  object: z.enum([
396
396
  "list"
397
397
  ]).describe("Fixed value identifying this as a list response."),
398
- data: z.array(z.object({
398
+ data: z.array(z.strictObject({
399
399
  object: z.enum([
400
400
  "integration_connection"
401
401
  ]).describe("The object type."),
402
402
  id: z.string().describe("The unique ID of the integration connection (format: {projectId}_{integrationId})."),
403
403
  connected: z.boolean().describe("Whether the integration is connected to the project."),
404
- integration: z.object({
404
+ integration: z.strictObject({
405
405
  id: z.string().describe("The ID of the integration."),
406
406
  object: z.enum([
407
407
  "integration"
408
408
  ]).describe("The object type."),
409
409
  slug: z.string().describe("The slug of the integration."),
410
410
  name: z.string().describe("The name of the integration.")
411
- }).strict().describe("Information about the connected integration.")
412
- }).strict()).describe("Array of integration connection summaries.")
413
- }).strict().describe("List response containing integration connections.");
414
- const integrationConnectionSummarySchemaSchema = z.object({
411
+ }).describe("Information about the connected integration.")
412
+ })).describe("Array of integration connection summaries.")
413
+ }).describe("List response containing integration connections.");
414
+ const integrationConnectionSummarySchemaSchema = z.strictObject({
415
415
  object: z.enum([
416
416
  "integration_connection"
417
417
  ]).describe("The object type."),
418
418
  id: z.string().describe("The unique ID of the integration connection (format: {projectId}_{integrationId})."),
419
419
  connected: z.boolean().describe("Whether the integration is connected to the project."),
420
- integration: z.object({
420
+ integration: z.strictObject({
421
421
  id: z.string().describe("The ID of the integration."),
422
422
  object: z.enum([
423
423
  "integration"
424
424
  ]).describe("The object type."),
425
425
  slug: z.string().describe("The slug of the integration."),
426
426
  name: z.string().describe("The name of the integration.")
427
- }).strict().describe("Information about the connected integration.")
428
- }).strict().describe("Summary information about an integration connection to a project.");
429
- const integrationDetailSchemaSchema = z.object({
427
+ }).describe("Information about the connected integration.")
428
+ }).describe("Summary information about an integration connection to a project.");
429
+ const integrationDetailSchemaSchema = z.strictObject({
430
430
  id: z.string().describe("The ID of the integration."),
431
431
  object: z.enum([
432
432
  "integration"
@@ -435,12 +435,12 @@ const integrationDetailSchemaSchema = z.object({
435
435
  name: z.string().describe("The name of the integration."),
436
436
  description: z.string().describe("A short description of the integration."),
437
437
  iconUrl: z.string().describe("URL to the integration icon.")
438
- }).strict().describe("Detailed information about an integration.");
439
- const integrationListSchemaSchema = z.object({
438
+ }).describe("Detailed information about an integration.");
439
+ const integrationListSchemaSchema = z.strictObject({
440
440
  object: z.enum([
441
441
  "list"
442
442
  ]).describe("Fixed value identifying this as a list response."),
443
- data: z.array(z.object({
443
+ data: z.array(z.strictObject({
444
444
  id: z.string().describe("The ID of the integration."),
445
445
  object: z.enum([
446
446
  "integration"
@@ -449,17 +449,17 @@ const integrationListSchemaSchema = z.object({
449
449
  name: z.string().describe("The name of the integration."),
450
450
  description: z.string().describe("A short description of the integration."),
451
451
  iconUrl: z.string().describe("URL to the integration icon.")
452
- }).strict()).describe("Array of integration details.")
453
- }).strict().describe("List of available integrations.");
454
- const integrationSummarySchemaSchema = z.object({
452
+ })).describe("Array of integration details.")
453
+ }).describe("List of available integrations.");
454
+ const integrationSummarySchemaSchema = z.strictObject({
455
455
  id: z.string().describe("The ID of the integration."),
456
456
  object: z.enum([
457
457
  "integration"
458
458
  ]).describe("The object type."),
459
459
  slug: z.string().describe("The slug of the integration."),
460
460
  name: z.string().describe("The name of the integration.")
461
- }).strict().describe("Basic information about an integration.");
462
- const messageDetailSchema = z.object({
461
+ }).describe("Basic information about an integration.");
462
+ const messageDetailSchema = z.strictObject({
463
463
  id: z.string().describe("A unique identifier for the message."),
464
464
  object: z.enum([
465
465
  "message"
@@ -472,7 +472,7 @@ const messageDetailSchema = z.object({
472
472
  ]),
473
473
  z.tuple([
474
474
  z.literal(1),
475
- z.object({
475
+ z.strictObject({
476
476
  toJSONSchema: z.string(),
477
477
  def: z.string(),
478
478
  type: z.string(),
@@ -529,7 +529,7 @@ const messageDetailSchema = z.object({
529
529
  omit: z.string(),
530
530
  partial: z.string(),
531
531
  required: z.string()
532
- }).strict()
532
+ })
533
533
  ])
534
534
  ])).optional().describe("The parsed content of the message as an array structure containing AST nodes. This is an experimental field that may change."),
535
535
  createdAt: z.string().describe("The ISO timestamp representing when the message was created."),
@@ -573,7 +573,7 @@ const messageDetailSchema = z.object({
573
573
  apiUrl: z.string().describe("API URL to access this message via the API."),
574
574
  authorId: z.string().nullable().describe("The ID of the user who sent the message."),
575
575
  parentId: z.string().nullish().describe("The ID of the parent message."),
576
- attachments: z.array(z.object({
576
+ attachments: z.array(z.strictObject({
577
577
  url: z.string().describe("The URL where the attachment file can be accessed."),
578
578
  name: z.string().optional().describe("The original filename of the attachment."),
579
579
  contentType: z.string().optional().describe("The MIME type of the attachment file (e.g., image/png, application/pdf)."),
@@ -584,10 +584,10 @@ const messageDetailSchema = z.object({
584
584
  "screenshot",
585
585
  "zip"
586
586
  ]).optional().describe("Optional v0-specific attachment type for enhanced processing.")
587
- }).strict()).optional(),
587
+ })).optional(),
588
588
  chatId: z.string().describe("The ID of the chat to which this message belongs.")
589
- }).strict().describe("Detailed message object extending MessageSummary with chat metadata.");
590
- const messageSummarySchema = z.object({
589
+ }).describe("Detailed message object extending MessageSummary with chat metadata.");
590
+ const messageSummarySchema = z.strictObject({
591
591
  id: z.string().describe("A unique identifier for the message."),
592
592
  object: z.enum([
593
593
  "message"
@@ -600,7 +600,7 @@ const messageSummarySchema = z.object({
600
600
  ]),
601
601
  z.tuple([
602
602
  z.literal(1),
603
- z.object({
603
+ z.strictObject({
604
604
  toJSONSchema: z.string(),
605
605
  def: z.string(),
606
606
  type: z.string(),
@@ -657,7 +657,7 @@ const messageSummarySchema = z.object({
657
657
  omit: z.string(),
658
658
  partial: z.string(),
659
659
  required: z.string()
660
- }).strict()
660
+ })
661
661
  ])
662
662
  ])).optional().describe("The parsed content of the message as an array structure containing AST nodes. This is an experimental field that may change."),
663
663
  createdAt: z.string().describe("The ISO timestamp representing when the message was created."),
@@ -701,7 +701,7 @@ const messageSummarySchema = z.object({
701
701
  apiUrl: z.string().describe("API URL to access this message via the API."),
702
702
  authorId: z.string().nullable().describe("The ID of the user who sent the message."),
703
703
  parentId: z.string().nullish().describe("The ID of the parent message."),
704
- attachments: z.array(z.object({
704
+ attachments: z.array(z.strictObject({
705
705
  url: z.string().describe("The URL where the attachment file can be accessed."),
706
706
  name: z.string().optional().describe("The original filename of the attachment."),
707
707
  contentType: z.string().optional().describe("The MIME type of the attachment file (e.g., image/png, application/pdf)."),
@@ -712,13 +712,13 @@ const messageSummarySchema = z.object({
712
712
  "screenshot",
713
713
  "zip"
714
714
  ]).optional().describe("Optional v0-specific attachment type for enhanced processing.")
715
- }).strict()).optional()
716
- }).strict().describe("Summary of a single message within a chat, including role, content, type, timestamp, and API URL.");
717
- const messageSummaryListSchema = z.object({
715
+ })).optional()
716
+ }).describe("Summary of a single message within a chat, including role, content, type, timestamp, and API URL.");
717
+ const messageSummaryListSchema = z.strictObject({
718
718
  object: z.enum([
719
719
  "list"
720
720
  ]).describe("Fixed value identifying this as a list response."),
721
- data: z.array(z.object({
721
+ data: z.array(z.strictObject({
722
722
  id: z.string().describe("A unique identifier for the message."),
723
723
  object: z.enum([
724
724
  "message"
@@ -731,7 +731,7 @@ const messageSummaryListSchema = z.object({
731
731
  ]),
732
732
  z.tuple([
733
733
  z.literal(1),
734
- z.object({
734
+ z.strictObject({
735
735
  toJSONSchema: z.string(),
736
736
  def: z.string(),
737
737
  type: z.string(),
@@ -788,7 +788,7 @@ const messageSummaryListSchema = z.object({
788
788
  omit: z.string(),
789
789
  partial: z.string(),
790
790
  required: z.string()
791
- }).strict()
791
+ })
792
792
  ])
793
793
  ])).optional().describe("The parsed content of the message as an array structure containing AST nodes. This is an experimental field that may change."),
794
794
  createdAt: z.string().describe("The ISO timestamp representing when the message was created."),
@@ -832,7 +832,7 @@ const messageSummaryListSchema = z.object({
832
832
  apiUrl: z.string().describe("API URL to access this message via the API."),
833
833
  authorId: z.string().nullable().describe("The ID of the user who sent the message."),
834
834
  parentId: z.string().nullish().describe("The ID of the parent message."),
835
- attachments: z.array(z.object({
835
+ attachments: z.array(z.strictObject({
836
836
  url: z.string().describe("The URL where the attachment file can be accessed."),
837
837
  name: z.string().optional().describe("The original filename of the attachment."),
838
838
  contentType: z.string().optional().describe("The MIME type of the attachment file (e.g., image/png, application/pdf)."),
@@ -843,19 +843,19 @@ const messageSummaryListSchema = z.object({
843
843
  "screenshot",
844
844
  "zip"
845
845
  ]).optional().describe("Optional v0-specific attachment type for enhanced processing.")
846
- }).strict()).optional()
847
- }).strict()).describe("Array of message summaries in this page of results."),
848
- pagination: z.object({
846
+ })).optional()
847
+ })).describe("Array of message summaries in this page of results."),
848
+ pagination: z.strictObject({
849
849
  hasMore: z.boolean().describe("Indicates if there are more results available beyond this page."),
850
850
  nextCursor: z.string().optional().describe("Cursor for fetching the next page of results."),
851
851
  nextUrl: z.string().optional().describe("API URL for retrieving the next page of results.")
852
- }).strict().describe("Pagination metadata for navigating through multiple pages of results.")
853
- }).strict().describe("List response containing multiple message summaries with cursor-based pagination.");
854
- const notificationPreferenceSchemaSchema = z.object({
852
+ }).describe("Pagination metadata for navigating through multiple pages of results.")
853
+ }).describe("List response containing multiple message summaries with cursor-based pagination.");
854
+ const notificationPreferenceSchemaSchema = z.strictObject({
855
855
  liveActivity: z.boolean().describe("Whether the user wants to receive live activities."),
856
856
  pushNotifications: z.boolean().describe("Whether the user wants to receive push notifications.")
857
- }).strict().describe("User preference for notification delivery methods.");
858
- const productDetailSchemaSchema = z.object({
857
+ }).describe("User preference for notification delivery methods.");
858
+ const productDetailSchemaSchema = z.strictObject({
859
859
  object: z.enum([
860
860
  "product"
861
861
  ]).describe("The object type."),
@@ -869,12 +869,12 @@ const productDetailSchemaSchema = z.object({
869
869
  "published"
870
870
  ]).optional().describe("The product's availability in v0. 'in-review' products only appear for teams with the review view and should be rendered as such."),
871
871
  iconBackgroundColor: z.string().optional().describe("Background color for the product icon.")
872
- }).strict().describe("Detailed information about a marketplace or store product.");
873
- const productListSchemaSchema = z.object({
872
+ }).describe("Detailed information about a marketplace or store product.");
873
+ const productListSchemaSchema = z.strictObject({
874
874
  object: z.enum([
875
875
  "list"
876
876
  ]).describe("Fixed value identifying this as a list response."),
877
- data: z.array(z.object({
877
+ data: z.array(z.strictObject({
878
878
  object: z.enum([
879
879
  "product"
880
880
  ]).describe("The object type."),
@@ -887,9 +887,9 @@ const productListSchemaSchema = z.object({
887
887
  "in-review",
888
888
  "published"
889
889
  ]).optional().describe("The product's availability in v0. 'in-review' products only appear for teams with the review view and should be rendered as such.")
890
- }).strict()).describe("Array of product summaries.")
891
- }).strict().describe("List of available marketplace and store products.");
892
- const productSummarySchemaSchema = z.object({
890
+ })).describe("Array of product summaries.")
891
+ }).describe("List of available marketplace and store products.");
892
+ const productSummarySchemaSchema = z.strictObject({
893
893
  object: z.enum([
894
894
  "product"
895
895
  ]).describe("The object type."),
@@ -902,8 +902,8 @@ const productSummarySchemaSchema = z.object({
902
902
  "in-review",
903
903
  "published"
904
904
  ]).optional().describe("The product's availability in v0. 'in-review' products only appear for teams with the review view and should be rendered as such.")
905
- }).strict().describe("Summary information about a marketplace or store product.");
906
- const projectDetailSchema = z.object({
905
+ }).describe("Summary information about a marketplace or store product.");
906
+ const projectDetailSchema = z.strictObject({
907
907
  id: z.string().describe("A unique identifier for the project."),
908
908
  object: z.enum([
909
909
  "project"
@@ -920,7 +920,7 @@ const projectDetailSchema = z.object({
920
920
  webUrl: z.url().describe("The web URL where the project can be viewed or managed."),
921
921
  description: z.string().optional().describe("The description of the project."),
922
922
  instructions: z.string().optional().describe("The instructions for the project."),
923
- chats: z.array(z.object({
923
+ chats: z.array(z.strictObject({
924
924
  id: z.string().describe("A unique identifier for the chat."),
925
925
  object: z.enum([
926
926
  "chat"
@@ -943,7 +943,7 @@ const projectDetailSchema = z.object({
943
943
  vercelProjectId: z.string().optional().describe("Optional ID of the linked Vercel project, if connected."),
944
944
  webUrl: z.string().describe("Web URL to view this chat in the browser."),
945
945
  apiUrl: z.string().describe("API URL to access this chat via the API."),
946
- latestVersion: z.object({
946
+ latestVersion: z.strictObject({
947
947
  id: z.string().describe("A unique identifier for the version."),
948
948
  object: z.enum([
949
949
  "version"
@@ -957,11 +957,11 @@ const projectDetailSchema = z.object({
957
957
  screenshotUrl: z.string().optional().describe("URL to retrieve a screenshot of this version."),
958
958
  createdAt: z.iso.datetime().describe("The date and time when the version was created, in ISO 8601 format."),
959
959
  updatedAt: z.iso.datetime().optional().describe("The date and time when the version was last updated, in ISO 8601 format.")
960
- }).strict().optional().describe("The most recent generated version of the chat, if available."),
960
+ }).optional().describe("The most recent generated version of the chat, if available."),
961
961
  metadata: z.object({}).catchall(z.string()).describe("Arbitrary key-value data associated with this chat.")
962
- }).strict()).describe("List of all chats that are associated with this project.")
963
- }).strict().describe("Full representation of a project, including its associated chats.");
964
- const projectSummarySchema = z.object({
962
+ })).describe("List of all chats that are associated with this project.")
963
+ }).describe("Full representation of a project, including its associated chats.");
964
+ const projectSummarySchema = z.strictObject({
965
965
  id: z.string().describe("A unique identifier for the project."),
966
966
  object: z.enum([
967
967
  "project"
@@ -976,15 +976,15 @@ const projectSummarySchema = z.object({
976
976
  updatedAt: z.iso.datetime().optional().describe("The ISO timestamp of the most recent update, if available."),
977
977
  apiUrl: z.url().describe("The API endpoint URL for accessing this project programmatically."),
978
978
  webUrl: z.url().describe("The web URL where the project can be viewed or managed.")
979
- }).strict().describe("Summary of a project, including metadata, timestamps, and optional Vercel linkage.");
980
- const scopeSummarySchema = z.object({
979
+ }).describe("Summary of a project, including metadata, timestamps, and optional Vercel linkage.");
980
+ const scopeSummarySchema = z.strictObject({
981
981
  id: z.string().describe("A unique identifier for the scope (e.g., user or team workspace)."),
982
982
  object: z.enum([
983
983
  "scope"
984
984
  ]).describe("Fixed value identifying this object as a scope."),
985
985
  name: z.string().optional().describe("An optional human-readable name for the scope.")
986
- }).strict().describe("Basic information about a workspace or identity context for projects and chats.");
987
- const searchResultItemSchema = z.object({
986
+ }).describe("Basic information about a workspace or identity context for projects and chats.");
987
+ const searchResultItemSchema = z.strictObject({
988
988
  id: z.string().describe("The unique ID of the item returned in the search result."),
989
989
  object: z.enum([
990
990
  "chat",
@@ -995,8 +995,8 @@ const searchResultItemSchema = z.object({
995
995
  updatedAt: z.iso.datetime().optional().describe("The ISO timestamp of the last update to the item."),
996
996
  apiUrl: z.string().describe("API endpoint for accessing the item programmatically."),
997
997
  webUrl: z.string().describe("Web URL for viewing the item in the interface.")
998
- }).strict().describe("Generic result returned from a search query, representing either a chat or a project.");
999
- const userDetailSchemaSchema = z.object({
998
+ }).describe("Generic result returned from a search query, representing either a chat or a project.");
999
+ const userDetailSchemaSchema = z.strictObject({
1000
1000
  id: z.string().describe("A unique identifier for the user."),
1001
1001
  object: z.enum([
1002
1002
  "user"
@@ -1006,42 +1006,42 @@ const userDetailSchemaSchema = z.object({
1006
1006
  avatar: z.string().describe("URL to the user's avatar image."),
1007
1007
  createdAt: z.iso.datetime().describe("The ISO timestamp representing when the user was created."),
1008
1008
  updatedAt: z.iso.datetime().optional().describe("The ISO timestamp of the last update to the user.")
1009
- }).strict();
1010
- const userPreferencesPostResponseSchemaSchema = z.object({
1009
+ });
1010
+ const userPreferencesPostResponseSchemaSchema = z.strictObject({
1011
1011
  object: z.enum([
1012
1012
  "user_preferences"
1013
1013
  ]).describe("Object type identifier."),
1014
1014
  preferences: z.union([
1015
- z.object({
1016
- notifications: z.object({
1015
+ z.strictObject({
1016
+ notifications: z.strictObject({
1017
1017
  liveActivity: z.boolean().describe("Whether the user wants to receive live activities."),
1018
1018
  pushNotifications: z.boolean().describe("Whether the user wants to receive push notifications.")
1019
- }).strict().describe("The user's preferred method for receiving notifications.")
1020
- }).strict(),
1019
+ }).describe("The user's preferred method for receiving notifications.")
1020
+ }),
1021
1021
  z.null()
1022
1022
  ]).describe("The updated preferences if successful, or null if failed.")
1023
- }).strict().describe("Response schema for updating user preferences.");
1024
- const userPreferencesResponseSchemaSchema = z.object({
1023
+ }).describe("Response schema for updating user preferences.");
1024
+ const userPreferencesResponseSchemaSchema = z.strictObject({
1025
1025
  object: z.enum([
1026
1026
  "user_preferences"
1027
1027
  ]).describe("Object type identifier."),
1028
1028
  preferences: z.union([
1029
- z.object({
1030
- notifications: z.object({
1029
+ z.strictObject({
1030
+ notifications: z.strictObject({
1031
1031
  liveActivity: z.boolean().describe("Whether the user wants to receive live activities."),
1032
1032
  pushNotifications: z.boolean().describe("Whether the user wants to receive push notifications.")
1033
- }).strict().describe("The user's preferred method for receiving notifications.")
1034
- }).strict(),
1033
+ }).describe("The user's preferred method for receiving notifications.")
1034
+ }),
1035
1035
  z.null()
1036
1036
  ]).describe("The user's current preferences, or null if errored.")
1037
- }).strict().describe("Response schema for retrieving user preferences.");
1038
- const userPreferencesSchemaSchema = z.object({
1039
- notifications: z.object({
1037
+ }).describe("Response schema for retrieving user preferences.");
1038
+ const userPreferencesSchemaSchema = z.strictObject({
1039
+ notifications: z.strictObject({
1040
1040
  liveActivity: z.boolean().describe("Whether the user wants to receive live activities."),
1041
1041
  pushNotifications: z.boolean().describe("Whether the user wants to receive push notifications.")
1042
- }).strict().describe("The user's preferred method for receiving notifications.")
1043
- }).strict().describe("User preferences configuration including notification settings.");
1044
- const userSummarySchemaSchema = z.object({
1042
+ }).describe("The user's preferred method for receiving notifications.")
1043
+ }).describe("User preferences configuration including notification settings.");
1044
+ const userSummarySchemaSchema = z.strictObject({
1045
1045
  id: z.string().describe("A unique identifier for the user."),
1046
1046
  object: z.enum([
1047
1047
  "user"
@@ -1051,22 +1051,22 @@ const userSummarySchemaSchema = z.object({
1051
1051
  avatar: z.string().describe("URL to the user's avatar image."),
1052
1052
  createdAt: z.iso.datetime().describe("The ISO timestamp representing when the user was created."),
1053
1053
  updatedAt: z.iso.datetime().optional().describe("The ISO timestamp of the last update to the user.")
1054
- }).strict().describe("Details of the authenticated user, including profile and contact information.");
1055
- const vercelProjectDetailSchema = z.object({
1054
+ }).describe("Details of the authenticated user, including profile and contact information.");
1055
+ const vercelProjectDetailSchema = z.strictObject({
1056
1056
  id: z.string().describe("A unique identifier for the linked Vercel project."),
1057
1057
  object: z.enum([
1058
1058
  "vercel_project"
1059
1059
  ]).describe("Fixed value identifying this object as a Vercel project."),
1060
1060
  name: z.string().describe("The name of the Vercel project.")
1061
- }).strict();
1062
- const vercelProjectSummarySchema = z.object({
1061
+ });
1062
+ const vercelProjectSummarySchema = z.strictObject({
1063
1063
  id: z.string().describe("A unique identifier for the linked Vercel project."),
1064
1064
  object: z.enum([
1065
1065
  "vercel_project"
1066
1066
  ]).describe("Fixed value identifying this object as a Vercel project."),
1067
1067
  name: z.string().describe("The name of the Vercel project.")
1068
- }).strict().describe("Basic metadata about a Vercel project connected to a v0 project.");
1069
- const versionDetailSchema = z.object({
1068
+ }).describe("Basic metadata about a Vercel project connected to a v0 project.");
1069
+ const versionDetailSchema = z.strictObject({
1070
1070
  id: z.string().describe("A unique identifier for the version."),
1071
1071
  object: z.enum([
1072
1072
  "version"
@@ -1080,16 +1080,16 @@ const versionDetailSchema = z.object({
1080
1080
  screenshotUrl: z.string().optional().describe("URL to retrieve a screenshot of this version."),
1081
1081
  createdAt: z.iso.datetime().describe("The date and time when the version was created, in ISO 8601 format."),
1082
1082
  updatedAt: z.iso.datetime().optional().describe("The date and time when the version was last updated, in ISO 8601 format."),
1083
- files: z.array(z.object({
1083
+ files: z.array(z.strictObject({
1084
1084
  object: z.enum([
1085
1085
  "file"
1086
1086
  ]).describe("Fixed value identifying this object as a file."),
1087
1087
  name: z.string().describe("The name of the file, including its extension."),
1088
1088
  content: z.string().describe("The full contents of the file as a raw string."),
1089
1089
  locked: z.boolean().describe("Whether the file is locked to prevent AI from overwriting it during new version generation.")
1090
- }).strict()).describe("A list of files that were generated or included in this version.")
1091
- }).strict().describe("Detailed version data including file contents.");
1092
- const versionSummarySchema = z.object({
1090
+ })).describe("A list of files that were generated or included in this version.")
1091
+ }).describe("Detailed version data including file contents.");
1092
+ const versionSummarySchema = z.strictObject({
1093
1093
  id: z.string().describe("A unique identifier for the version."),
1094
1094
  object: z.enum([
1095
1095
  "version"
@@ -1103,12 +1103,12 @@ const versionSummarySchema = z.object({
1103
1103
  screenshotUrl: z.string().optional().describe("URL to retrieve a screenshot of this version."),
1104
1104
  createdAt: z.iso.datetime().describe("The date and time when the version was created, in ISO 8601 format."),
1105
1105
  updatedAt: z.iso.datetime().optional().describe("The date and time when the version was last updated, in ISO 8601 format.")
1106
- }).strict().describe("Summary of a generated version of a chat, including its status and optional demo link.");
1107
- const versionSummaryListSchema = z.object({
1106
+ }).describe("Summary of a generated version of a chat, including its status and optional demo link.");
1107
+ const versionSummaryListSchema = z.strictObject({
1108
1108
  object: z.enum([
1109
1109
  "list"
1110
1110
  ]).describe("Fixed value identifying this as a list response."),
1111
- data: z.array(z.object({
1111
+ data: z.array(z.strictObject({
1112
1112
  id: z.string().describe("A unique identifier for the version."),
1113
1113
  object: z.enum([
1114
1114
  "version"
@@ -1122,77 +1122,77 @@ const versionSummaryListSchema = z.object({
1122
1122
  screenshotUrl: z.string().optional().describe("URL to retrieve a screenshot of this version."),
1123
1123
  createdAt: z.iso.datetime().describe("The date and time when the version was created, in ISO 8601 format."),
1124
1124
  updatedAt: z.iso.datetime().optional().describe("The date and time when the version was last updated, in ISO 8601 format.")
1125
- }).strict()).describe("Array of version summaries in this page of results."),
1126
- pagination: z.object({
1125
+ })).describe("Array of version summaries in this page of results."),
1126
+ pagination: z.strictObject({
1127
1127
  hasMore: z.boolean().describe("Indicates if there are more results available beyond this page."),
1128
1128
  nextCursor: z.string().optional().describe("Cursor for fetching the next page of results."),
1129
1129
  nextUrl: z.string().optional().describe("API URL for retrieving the next page of results.")
1130
- }).strict().describe("Pagination metadata for navigating through multiple pages of results.")
1131
- }).strict().describe("List response containing multiple version summaries with cursor-based pagination.");
1132
- const unauthorizedErrorSchema = z.object({
1133
- error: z.object({
1130
+ }).describe("Pagination metadata for navigating through multiple pages of results.")
1131
+ }).describe("List response containing multiple version summaries with cursor-based pagination.");
1132
+ const unauthorizedErrorSchema = z.strictObject({
1133
+ error: z.strictObject({
1134
1134
  message: z.string(),
1135
1135
  type: z.enum([
1136
1136
  "unauthorized_error"
1137
1137
  ])
1138
- }).strict()
1139
- }).strict();
1140
- const forbiddenErrorSchema = z.object({
1141
- error: z.object({
1138
+ })
1139
+ });
1140
+ const forbiddenErrorSchema = z.strictObject({
1141
+ error: z.strictObject({
1142
1142
  message: z.string(),
1143
1143
  type: z.enum([
1144
1144
  "forbidden_error"
1145
1145
  ])
1146
- }).strict()
1147
- }).strict();
1148
- const notFoundErrorSchema = z.object({
1149
- error: z.object({
1146
+ })
1147
+ });
1148
+ const notFoundErrorSchema = z.strictObject({
1149
+ error: z.strictObject({
1150
1150
  message: z.string(),
1151
1151
  type: z.enum([
1152
1152
  "not_found_error"
1153
1153
  ])
1154
- }).strict()
1155
- }).strict();
1156
- const conflictErrorSchema = z.object({
1157
- error: z.object({
1154
+ })
1155
+ });
1156
+ const conflictErrorSchema = z.strictObject({
1157
+ error: z.strictObject({
1158
1158
  message: z.string(),
1159
1159
  type: z.enum([
1160
1160
  "conflict_error"
1161
1161
  ])
1162
- }).strict()
1163
- }).strict();
1164
- const payloadTooLargeErrorSchema = z.object({
1165
- error: z.object({
1162
+ })
1163
+ });
1164
+ const payloadTooLargeErrorSchema = z.strictObject({
1165
+ error: z.strictObject({
1166
1166
  message: z.string(),
1167
1167
  type: z.enum([
1168
1168
  "payload_too_large_error"
1169
1169
  ])
1170
- }).strict()
1171
- }).strict();
1172
- const unprocessableEntityErrorSchema = z.object({
1173
- error: z.object({
1170
+ })
1171
+ });
1172
+ const unprocessableEntityErrorSchema = z.strictObject({
1173
+ error: z.strictObject({
1174
1174
  message: z.string(),
1175
1175
  type: z.enum([
1176
1176
  "unprocessable_entity_error"
1177
1177
  ])
1178
- }).strict()
1179
- }).strict();
1180
- const tooManyRequestsErrorSchema = z.object({
1181
- error: z.object({
1178
+ })
1179
+ });
1180
+ const tooManyRequestsErrorSchema = z.strictObject({
1181
+ error: z.strictObject({
1182
1182
  message: z.string(),
1183
1183
  type: z.enum([
1184
1184
  "too_many_requests_error"
1185
1185
  ])
1186
- }).strict()
1187
- }).strict();
1188
- const internalServerErrorSchema = z.object({
1189
- error: z.object({
1186
+ })
1187
+ });
1188
+ const internalServerErrorSchema = z.strictObject({
1189
+ error: z.strictObject({
1190
1190
  message: z.string(),
1191
1191
  type: z.enum([
1192
1192
  "internal_server_error"
1193
1193
  ])
1194
- }).strict()
1195
- }).strict();
1194
+ })
1195
+ });
1196
1196
  const chatsCreateStatus200Schema = z.unknown();
1197
1197
  const chatsCreateStatus401Schema = z.unknown();
1198
1198
  const chatsCreateStatus403Schema = z.unknown();