v0-api 0.0.4 → 0.1.3

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 (44) hide show
  1. package/dist/components.cjs +1498 -0
  2. package/dist/components.d.cts +1011 -0
  3. package/dist/components.d.cts.map +1 -0
  4. package/dist/components.d.mts +1011 -0
  5. package/dist/components.d.mts.map +1 -0
  6. package/dist/components.mjs +1435 -0
  7. package/dist/effect.cjs +1334 -0
  8. package/dist/effect.d.cts +970 -0
  9. package/dist/effect.d.cts.map +1 -0
  10. package/dist/effect.d.mts +970 -0
  11. package/dist/effect.d.mts.map +1 -0
  12. package/dist/effect.mjs +1312 -0
  13. package/dist/index.cjs +5111 -527
  14. package/dist/index.d.cts +10838 -3847
  15. package/dist/index.d.cts.map +1 -0
  16. package/dist/index.d.mts +10838 -3847
  17. package/dist/index.d.mts.map +1 -0
  18. package/dist/index.d.ts +10838 -3847
  19. package/dist/index.d.ts.map +1 -0
  20. package/dist/index.mjs +4292 -524
  21. package/dist/schemas.cjs +3229 -0
  22. package/dist/schemas.d.cts +1856 -0
  23. package/dist/schemas.d.cts.map +1 -0
  24. package/dist/schemas.d.mts +1856 -0
  25. package/dist/schemas.d.mts.map +1 -0
  26. package/dist/schemas.mjs +2488 -0
  27. package/dist/types.cjs +420 -0
  28. package/dist/types.d.cts +8429 -0
  29. package/dist/types.d.cts.map +1 -0
  30. package/dist/types.d.mts +8429 -0
  31. package/dist/types.d.mts.map +1 -0
  32. package/dist/types.mjs +343 -0
  33. package/package.json +70 -26
  34. package/README.md +0 -3
  35. package/dist/mcp.cjs +0 -519
  36. package/dist/mcp.d.cts +0 -5
  37. package/dist/mcp.d.mts +0 -5
  38. package/dist/mcp.d.ts +0 -5
  39. package/dist/mcp.mjs +0 -517
  40. package/dist/shared/v0-api.B8nEbJhM.d.cts +0 -36
  41. package/dist/shared/v0-api.B8nEbJhM.d.mts +0 -36
  42. package/dist/shared/v0-api.B8nEbJhM.d.ts +0 -36
  43. package/dist/shared/v0-api.D3CFh7k4.cjs +0 -833
  44. package/dist/shared/v0-api.mzMaOyDB.mjs +0 -814
@@ -0,0 +1,1011 @@
1
+ type RequestInit = {
2
+ body?: string | FormData | undefined;
3
+ headers?: Record<string, string> | undefined;
4
+ method?: string | undefined;
5
+ signal?: any | undefined;
6
+ };
7
+ type Response = {
8
+ ok: boolean;
9
+ status: number;
10
+ url: string;
11
+ json(): Promise<any>;
12
+ text(): Promise<string>;
13
+ headers?: {
14
+ get(name: string): string | null;
15
+ } | undefined;
16
+ };
17
+ type FetchImpl = (url: string, init?: RequestInit) => Promise<Response>;
18
+
19
+ type FetcherConfig = {
20
+ baseUrl?: string;
21
+ token?: string | null;
22
+ fetchImpl?: FetchImpl;
23
+ headers?: Record<string, any>;
24
+ };
25
+ type FetcherOptions<TBody, THeaders, TQueryParams, TPathParams> = {
26
+ url: string;
27
+ method: string;
28
+ body?: TBody | undefined;
29
+ headers?: THeaders | undefined;
30
+ queryParams?: TQueryParams | undefined;
31
+ pathParams?: TPathParams | undefined;
32
+ signal?: AbortSignal | undefined;
33
+ } & FetcherConfig;
34
+ declare function client<TData, TError, TBody, THeaders, TQueryParams, TPathParams>({ url, method, body, headers, queryParams, signal, token, baseUrl, fetchImpl, }: FetcherOptions<TBody, THeaders, TQueryParams, TPathParams>): Promise<TData>;
35
+
36
+ /**
37
+ * Generated by Kubb (https://kubb.dev/).
38
+ * Do not edit manually.
39
+ */
40
+
41
+ /**
42
+ * @summary Create Chat
43
+ * @description Creates a new chat using a user message, optional system context, and model configuration. Useful for prompting the model within the scope of a specific project.
44
+ * @link /chats
45
+ */
46
+ declare function chatsCreate({ config }?: {
47
+ config?: Partial<FetcherConfig> & {
48
+ client?: typeof client;
49
+ };
50
+ }): Promise<unknown>;
51
+ /**
52
+ * @summary Find Chats
53
+ * @description Retrieves a list of existing chats, with support for pagination and filtering by favorite status, Vercel project, or Git branch. Helps manage and navigate chat history.
54
+ * @link /chats
55
+ */
56
+ declare function chatsFind({ queryParams, config }?: {
57
+ queryParams?: {
58
+ "limit"?: number;
59
+ "offset"?: number;
60
+ "isFavorite"?: "true" | "false";
61
+ "vercelProjectId"?: string;
62
+ "branch"?: string;
63
+ };
64
+ config?: Partial<FetcherConfig> & {
65
+ client?: typeof client;
66
+ };
67
+ }): Promise<unknown>;
68
+ /**
69
+ * @summary Initialize Chat
70
+ * @description Initializes a new chat from source content such as files, repositories, registries, or zip archives. Enables context-rich conversations based on code or assets.
71
+ * @link /chats/init
72
+ */
73
+ declare function chatsInit({ config }?: {
74
+ config?: Partial<FetcherConfig> & {
75
+ client?: typeof client;
76
+ };
77
+ }): Promise<unknown>;
78
+ /**
79
+ * @summary Delete Chat
80
+ * @description Deletes a specific chat based on the provided chatId. The chat and its contents are moved to trash and stop being retrievable immediately, then retained for 30 days before being permanently removed.
81
+ * @link /chats/{chatId}
82
+ */
83
+ declare function chatsDelete({ pathParams, config }?: {
84
+ pathParams: {
85
+ "chatId": string;
86
+ };
87
+ config?: Partial<FetcherConfig> & {
88
+ client?: typeof client;
89
+ };
90
+ }): Promise<unknown>;
91
+ /**
92
+ * @summary Get Chat
93
+ * @description Retrieves the full details of a specific chat using its `chatId`. Includes messages, metadata, and associated configuration.
94
+ * @link /chats/{chatId}
95
+ */
96
+ declare function chatsGetById({ pathParams, config }?: {
97
+ pathParams: {
98
+ "chatId": string;
99
+ };
100
+ config?: Partial<FetcherConfig> & {
101
+ client?: typeof client;
102
+ };
103
+ }): Promise<unknown>;
104
+ /**
105
+ * @summary Update Chat
106
+ * @description Updates the metadata of an existing chat using its `chatId`. Supports changes to the chat name and privacy setting.
107
+ * @link /chats/{chatId}
108
+ */
109
+ declare function chatsUpdate({ pathParams, config }?: {
110
+ pathParams: {
111
+ "chatId": string;
112
+ };
113
+ config?: Partial<FetcherConfig> & {
114
+ client?: typeof client;
115
+ };
116
+ }): Promise<unknown>;
117
+ /**
118
+ * @summary Favorite Chat
119
+ * @description Marks or unmarks a chat as a favorite using its `chatId`. This helps with organizing and quickly accessing important chats.
120
+ * @link /chats/{chatId}/favorite
121
+ */
122
+ declare function chatsFavorite({ pathParams, config }?: {
123
+ pathParams: {
124
+ "chatId": string;
125
+ };
126
+ config?: Partial<FetcherConfig> & {
127
+ client?: typeof client;
128
+ };
129
+ }): Promise<unknown>;
130
+ /**
131
+ * @summary Fork Chat
132
+ * @description Creates a new chat fork (duplicate) from a specific version within an existing chat. Useful for branching off alternate directions without modifying the original conversation.
133
+ * @link /chats/{chatId}/fork
134
+ */
135
+ declare function chatsFork({ pathParams, config }?: {
136
+ pathParams: {
137
+ "chatId": string;
138
+ };
139
+ config?: Partial<FetcherConfig> & {
140
+ client?: typeof client;
141
+ };
142
+ }): Promise<unknown>;
143
+ /**
144
+ * @summary Get Project by Chat ID
145
+ * @description Retrieves the v0 project associated with a given chat. Useful for determining the context or scope of a chat session.
146
+ * @link /chats/{chatId}/project
147
+ */
148
+ declare function projectsGetByChatId({ pathParams, config }?: {
149
+ pathParams: {
150
+ "chatId": string;
151
+ };
152
+ config?: Partial<FetcherConfig> & {
153
+ client?: typeof client;
154
+ };
155
+ }): Promise<unknown>;
156
+ /**
157
+ * @summary Find Chat Messages
158
+ * @description Retrieves a list of all messages for a specific chat, ordered by creation date (newest first). Supports cursor-based pagination and includes message content, role, and type information.
159
+ * @link /chats/{chatId}/messages
160
+ */
161
+ declare function chatsFindMessages({ pathParams, queryParams, config }?: {
162
+ pathParams: {
163
+ "chatId": string;
164
+ };
165
+ queryParams?: {
166
+ "limit"?: number;
167
+ "cursor"?: string;
168
+ };
169
+ config?: Partial<FetcherConfig> & {
170
+ client?: typeof client;
171
+ };
172
+ }): Promise<unknown>;
173
+ /**
174
+ * @summary Send Message
175
+ * @description Creates a new message in an existing chat. Triggers a model response using the provided prompt, with optional attachments and configuration settings.
176
+ * @link /chats/{chatId}/messages
177
+ */
178
+ declare function chatsSendMessage({ pathParams, config }?: {
179
+ pathParams: {
180
+ "chatId": string;
181
+ };
182
+ config?: Partial<FetcherConfig> & {
183
+ client?: typeof client;
184
+ };
185
+ }): Promise<unknown>;
186
+ /**
187
+ * @summary Get Chat Message
188
+ * @description Retrieves detailed information about a specific message within a chat, including content, files, model configuration, and demo URLs.
189
+ * @link /chats/{chatId}/messages/{messageId}
190
+ */
191
+ declare function chatsGetMessage({ pathParams, config }?: {
192
+ pathParams: {
193
+ "chatId": string;
194
+ "messageId": string;
195
+ };
196
+ config?: Partial<FetcherConfig> & {
197
+ client?: typeof client;
198
+ };
199
+ }): Promise<unknown>;
200
+ /**
201
+ * @summary Find Chat Versions
202
+ * @description Retrieves a list of all versions (iterations) for a specific chat, ordered by creation date (newest first). Supports cursor-based pagination and includes version status and demo URLs.
203
+ * @link /chats/{chatId}/versions
204
+ */
205
+ declare function chatsFindVersions({ pathParams, queryParams, config }?: {
206
+ pathParams: {
207
+ "chatId": string;
208
+ };
209
+ queryParams?: {
210
+ "limit"?: number;
211
+ "cursor"?: string;
212
+ };
213
+ config?: Partial<FetcherConfig> & {
214
+ client?: typeof client;
215
+ };
216
+ }): Promise<unknown>;
217
+ /**
218
+ * @summary Get Chat Version
219
+ * @description Retrieves detailed information about a specific version of a chat, including all files with their content and lock status.
220
+ * @link /chats/{chatId}/versions/{versionId}
221
+ */
222
+ declare function chatsGetVersion({ pathParams, queryParams, config }?: {
223
+ pathParams: {
224
+ "chatId": string;
225
+ "versionId": string;
226
+ };
227
+ queryParams?: {
228
+ "includeDefaultFiles"?: "true" | "false";
229
+ };
230
+ config?: Partial<FetcherConfig> & {
231
+ client?: typeof client;
232
+ };
233
+ }): Promise<unknown>;
234
+ /**
235
+ * @summary Update Chat Version Files
236
+ * @description Updates the source files of a specific chat version (block) manually. This allows editing generated files directly through the API.
237
+ * @link /chats/{chatId}/versions/{versionId}
238
+ */
239
+ declare function chatsUpdateVersion({ pathParams, config }?: {
240
+ pathParams: {
241
+ "chatId": string;
242
+ "versionId": string;
243
+ };
244
+ config?: Partial<FetcherConfig> & {
245
+ client?: typeof client;
246
+ };
247
+ }): Promise<unknown>;
248
+ /**
249
+ * @summary Download version files
250
+ * @description Download all files for a specific chat version as a zip or tarball archive. Use includeDefaultFiles=true to include all deployment files (package.json, configuration files, etc.) or false/omitted to return only the generated source files.
251
+ * @link /chats/{chatId}/versions/{versionId}/download
252
+ */
253
+ declare function chatsDownloadVersion({ pathParams, queryParams, config }?: {
254
+ pathParams: {
255
+ "chatId": string;
256
+ "versionId": string;
257
+ };
258
+ queryParams?: {
259
+ "format"?: "zip" | "tarball";
260
+ "includeDefaultFiles"?: "true" | "false";
261
+ };
262
+ config?: Partial<FetcherConfig> & {
263
+ client?: typeof client;
264
+ };
265
+ }): Promise<unknown>;
266
+ /**
267
+ * @summary Delete Chat Version Files
268
+ * @description Deletes source files from a specific chat version (block). Files are removed from the version and a new source version is created.
269
+ * @link /chats/{chatId}/versions/{versionId}/files/delete
270
+ */
271
+ declare function chatsDeleteVersionFiles({ pathParams, config }?: {
272
+ pathParams: {
273
+ "chatId": string;
274
+ "versionId": string;
275
+ };
276
+ config?: Partial<FetcherConfig> & {
277
+ client?: typeof client;
278
+ };
279
+ }): Promise<unknown>;
280
+ /**
281
+ * @summary Resume Message
282
+ * @description Reconnects to an active assistant message stream and returns it as Server-Sent Events. This does not restart or continue a stopped generation.
283
+ * @link /chats/{chatId}/messages/{messageId}/resume
284
+ */
285
+ declare function chatsResume({ pathParams, config }?: {
286
+ pathParams: {
287
+ "chatId": string;
288
+ "messageId": string;
289
+ };
290
+ config?: Partial<FetcherConfig> & {
291
+ client?: typeof client;
292
+ };
293
+ }): Promise<unknown>;
294
+ /**
295
+ * @summary Stop Message
296
+ * @description Stops an in-flight message generation in a chat. Useful for cancelling a streaming response that is still being generated.
297
+ * @link /chats/{chatId}/messages/{messageId}/stop
298
+ */
299
+ declare function chatsStop({ pathParams, config }?: {
300
+ pathParams: {
301
+ "chatId": string;
302
+ "messageId": string;
303
+ };
304
+ config?: Partial<FetcherConfig> & {
305
+ client?: typeof client;
306
+ };
307
+ }): Promise<unknown>;
308
+ /**
309
+ * @summary Resolve Task
310
+ * @description Resolves a pending task in a chat, continuing the conversation. The latest message in the active chat fork must be an assistant message currently blocked on a matching task (integration setup, plan approval, question answers, or permission grants).
311
+ * @link /chats/{chatId}/tasks/resolve
312
+ */
313
+ declare function chatsResolveTask({ pathParams, config }?: {
314
+ pathParams: {
315
+ "chatId": string;
316
+ };
317
+ config?: Partial<FetcherConfig> & {
318
+ client?: typeof client;
319
+ };
320
+ }): Promise<unknown>;
321
+ /**
322
+ * @summary Find Deployments
323
+ * @description Find deployments by project and chat IDs. This will return a list of deployments for the given project and chat IDs.
324
+ * @link /deployments
325
+ */
326
+ declare function deploymentsFind({ queryParams, config }?: {
327
+ queryParams?: {
328
+ "projectId"?: string;
329
+ "chatId"?: string;
330
+ "versionId"?: string;
331
+ };
332
+ config?: Partial<FetcherConfig> & {
333
+ client?: typeof client;
334
+ };
335
+ }): Promise<unknown>;
336
+ /**
337
+ * @summary Create Deployment
338
+ * @description Create a new deployment for a specific chat and version. This will trigger a deployment to Vercel.
339
+ * @link /deployments
340
+ */
341
+ declare function deploymentsCreate({ config }?: {
342
+ config?: Partial<FetcherConfig> & {
343
+ client?: typeof client;
344
+ };
345
+ }): Promise<unknown>;
346
+ /**
347
+ * @summary Get Deployment
348
+ * @description Get a deployment by ID. This will return the details of the deployment, including the inspector URL, chat ID, project ID, version ID, API URL, and web URL.
349
+ * @link /deployments/{deploymentId}
350
+ */
351
+ declare function deploymentsGetById({ pathParams, config }?: {
352
+ pathParams: {
353
+ "deploymentId": string;
354
+ };
355
+ config?: Partial<FetcherConfig> & {
356
+ client?: typeof client;
357
+ };
358
+ }): Promise<unknown>;
359
+ /**
360
+ * @summary Delete Deployment
361
+ * @description Delete a deployment by ID. This will delete the deployment from Vercel.
362
+ * @link /deployments/{deploymentId}
363
+ */
364
+ declare function deploymentsDelete({ pathParams, config }?: {
365
+ pathParams: {
366
+ "deploymentId": string;
367
+ };
368
+ config?: Partial<FetcherConfig> & {
369
+ client?: typeof client;
370
+ };
371
+ }): Promise<unknown>;
372
+ /**
373
+ * @summary Find Deployment Logs
374
+ * @description Retrieves logs for a specific deployment. Supports filtering by timestamp to fetch only recent logs.
375
+ * @link /deployments/{deploymentId}/logs
376
+ */
377
+ declare function deploymentsFindLogs({ pathParams, queryParams, config }?: {
378
+ pathParams: {
379
+ "deploymentId": string;
380
+ };
381
+ queryParams?: {
382
+ "since"?: number;
383
+ };
384
+ config?: Partial<FetcherConfig> & {
385
+ client?: typeof client;
386
+ };
387
+ }): Promise<unknown>;
388
+ /**
389
+ * @summary Find Deployment Errors
390
+ * @description Retrieves a list of errors that occurred during a specific deployment. Useful for diagnosing and debugging deployment issues.
391
+ * @link /deployments/{deploymentId}/errors
392
+ */
393
+ declare function deploymentsFindErrors({ pathParams, config }?: {
394
+ pathParams: {
395
+ "deploymentId": string;
396
+ };
397
+ config?: Partial<FetcherConfig> & {
398
+ client?: typeof client;
399
+ };
400
+ }): Promise<unknown>;
401
+ /**
402
+ * @summary Find Hooks
403
+ * @description Retrieves a list of existing hooks in your workspace. Useful for managing active webhooks tied to chat events or deployments.
404
+ * @link /hooks
405
+ */
406
+ declare function hooksFind({ config }?: {
407
+ config?: Partial<FetcherConfig> & {
408
+ client?: typeof client;
409
+ };
410
+ }): Promise<unknown>;
411
+ /**
412
+ * @summary Create Hook
413
+ * @description Creates a new webhook that listens for specific events. Supports optional association with a chat.
414
+ * @link /hooks
415
+ */
416
+ declare function hooksCreate({ config }?: {
417
+ config?: Partial<FetcherConfig> & {
418
+ client?: typeof client;
419
+ };
420
+ }): Promise<unknown>;
421
+ /**
422
+ * @summary Get Hook
423
+ * @description Retrieves the details of a specific webhook using its ID.
424
+ * @link /hooks/{hookId}
425
+ */
426
+ declare function hooksGetById({ pathParams, config }?: {
427
+ pathParams: {
428
+ "hookId": string;
429
+ };
430
+ config?: Partial<FetcherConfig> & {
431
+ client?: typeof client;
432
+ };
433
+ }): Promise<unknown>;
434
+ /**
435
+ * @summary Update Hook
436
+ * @description Updates the configuration of an existing webhook, including its name, event subscriptions, or target URL.
437
+ * @link /hooks/{hookId}
438
+ */
439
+ declare function hooksUpdate({ pathParams, config }?: {
440
+ pathParams: {
441
+ "hookId": string;
442
+ };
443
+ config?: Partial<FetcherConfig> & {
444
+ client?: typeof client;
445
+ };
446
+ }): Promise<unknown>;
447
+ /**
448
+ * @summary Delete Hook
449
+ * @description Deletes a webhook based on its ID. This action is irreversible.
450
+ * @link /hooks/{hookId}
451
+ */
452
+ declare function hooksDelete({ pathParams, config }?: {
453
+ pathParams: {
454
+ "hookId": string;
455
+ };
456
+ config?: Partial<FetcherConfig> & {
457
+ client?: typeof client;
458
+ };
459
+ }): Promise<unknown>;
460
+ /**
461
+ * @summary Find Vercel Projects
462
+ * @description Retrieves a list of Vercel projects linked to your integration. Useful for associating chats, deployments, or hooks with specific Vercel projects.
463
+ * @link /integrations/vercel/projects
464
+ */
465
+ declare function integrationsVercelProjectsFind({ config }?: {
466
+ config?: Partial<FetcherConfig> & {
467
+ client?: typeof client;
468
+ };
469
+ }): Promise<unknown>;
470
+ /**
471
+ * @summary Create Vercel Project
472
+ * @description Links a Vercel project to an existing v0 project. Enables Vercel-related features and deployment integration within the v0 workspace.
473
+ * @link /integrations/vercel/projects
474
+ */
475
+ declare function integrationsVercelProjectsCreate({ config }?: {
476
+ config?: Partial<FetcherConfig> & {
477
+ client?: typeof client;
478
+ };
479
+ }): Promise<unknown>;
480
+ /**
481
+ * @summary Find Projects
482
+ * @description Returns a list of all v0 projects in your workspace. Useful for browsing or managing projects across different chats or use cases.
483
+ * @link /projects
484
+ */
485
+ declare function projectsFind({ config }?: {
486
+ config?: Partial<FetcherConfig> & {
487
+ client?: typeof client;
488
+ };
489
+ }): Promise<unknown>;
490
+ /**
491
+ * @summary Create Project
492
+ * @description Creates a new v0 project with an optional description, icon, environment variables, and instructions. Projects help organize chats and manage context.
493
+ * @link /projects
494
+ */
495
+ declare function projectsCreate({ config }?: {
496
+ config?: Partial<FetcherConfig> & {
497
+ client?: typeof client;
498
+ };
499
+ }): Promise<unknown>;
500
+ /**
501
+ * @summary Get Project by ID
502
+ * @description Retrieves the details of a specific v0 project by its ID.
503
+ * @link /projects/{projectId}
504
+ */
505
+ declare function projectsGetById({ pathParams, config }?: {
506
+ pathParams: {
507
+ "projectId": string;
508
+ };
509
+ config?: Partial<FetcherConfig> & {
510
+ client?: typeof client;
511
+ };
512
+ }): Promise<unknown>;
513
+ /**
514
+ * @summary Update Project
515
+ * @description Updates the metadata of an existing project using its `projectId`. Supports changes to the project name and privacy setting.
516
+ * @link /projects/{projectId}
517
+ */
518
+ declare function projectsUpdate({ pathParams, config }?: {
519
+ pathParams: {
520
+ "projectId": string;
521
+ };
522
+ config?: Partial<FetcherConfig> & {
523
+ client?: typeof client;
524
+ };
525
+ }): Promise<unknown>;
526
+ /**
527
+ * @summary Delete Project
528
+ * @description Deletes a specific project based on the provided projectId. This operation marks the project as deleted and is irreversible.
529
+ * @link /projects/{projectId}
530
+ */
531
+ declare function projectsDelete({ pathParams, queryParams, config }?: {
532
+ pathParams: {
533
+ "projectId": string;
534
+ };
535
+ queryParams?: {
536
+ "deleteAllChats"?: "true" | "false";
537
+ };
538
+ config?: Partial<FetcherConfig> & {
539
+ client?: typeof client;
540
+ };
541
+ }): Promise<unknown>;
542
+ /**
543
+ * @summary Assign Project to Chat
544
+ * @description Links an existing v0 project to a specific chat. Helps group conversations under a shared project context.
545
+ * @link /projects/{projectId}/assign
546
+ */
547
+ declare function projectsAssign({ pathParams, config }?: {
548
+ pathParams: {
549
+ "projectId": string;
550
+ };
551
+ config?: Partial<FetcherConfig> & {
552
+ client?: typeof client;
553
+ };
554
+ }): Promise<unknown>;
555
+ /**
556
+ * @summary Find Environment Variables
557
+ * @description Retrieves all environment variables for a given project.
558
+ * @link /projects/{projectId}/env-vars
559
+ */
560
+ declare function projectsFindEnvVars({ pathParams, queryParams, config }?: {
561
+ pathParams: {
562
+ "projectId": string;
563
+ };
564
+ queryParams?: {
565
+ "decrypted"?: "true" | "false";
566
+ };
567
+ config?: Partial<FetcherConfig> & {
568
+ client?: typeof client;
569
+ };
570
+ }): Promise<unknown>;
571
+ /**
572
+ * @summary Create Environment Variables
573
+ * @description Creates new environment variables for a given project. This endpoint will fail if any of the specified environment variable keys already exist, unless upsert is set to true.
574
+ * @link /projects/{projectId}/env-vars
575
+ */
576
+ declare function projectsCreateEnvVars({ pathParams, queryParams, config }?: {
577
+ pathParams: {
578
+ "projectId": string;
579
+ };
580
+ queryParams?: {
581
+ "decrypted"?: "true" | "false";
582
+ };
583
+ config?: Partial<FetcherConfig> & {
584
+ client?: typeof client;
585
+ };
586
+ }): Promise<unknown>;
587
+ /**
588
+ * @summary Update Environment Variables
589
+ * @description Updates multiple environment variables for a given project. Only the value of each environment variable can be updated.
590
+ * @link /projects/{projectId}/env-vars
591
+ */
592
+ declare function projectsUpdateEnvVars({ pathParams, queryParams, config }?: {
593
+ pathParams: {
594
+ "projectId": string;
595
+ };
596
+ queryParams?: {
597
+ "decrypted"?: "true" | "false";
598
+ };
599
+ config?: Partial<FetcherConfig> & {
600
+ client?: typeof client;
601
+ };
602
+ }): Promise<unknown>;
603
+ /**
604
+ * @summary Delete Environment Variables
605
+ * @description Deletes multiple environment variables for a given project by their IDs.
606
+ * @link /projects/{projectId}/env-vars/delete
607
+ */
608
+ declare function projectsDeleteEnvVars({ pathParams, config }?: {
609
+ pathParams: {
610
+ "projectId": string;
611
+ };
612
+ config?: Partial<FetcherConfig> & {
613
+ client?: typeof client;
614
+ };
615
+ }): Promise<unknown>;
616
+ /**
617
+ * @summary Get Environment Variable
618
+ * @description Retrieves a specific environment variable for a given project by its ID, including its value.
619
+ * @link /projects/{projectId}/env-vars/{environmentVariableId}
620
+ */
621
+ declare function projectsGetEnvVar({ pathParams, queryParams, config }?: {
622
+ pathParams: {
623
+ "projectId": string;
624
+ "environmentVariableId": string;
625
+ };
626
+ queryParams?: {
627
+ "decrypted"?: "true" | "false";
628
+ };
629
+ config?: Partial<FetcherConfig> & {
630
+ client?: typeof client;
631
+ };
632
+ }): Promise<unknown>;
633
+ /**
634
+ * @summary Find Rate Limit
635
+ * @description Retrieves rate limit information for a given scope. Useful for monitoring usage limits and avoiding throttling.
636
+ * @link /rate-limits
637
+ */
638
+ declare function rateLimitsFind({ queryParams, config }?: {
639
+ queryParams?: {
640
+ "scope"?: string;
641
+ };
642
+ config?: Partial<FetcherConfig> & {
643
+ client?: typeof client;
644
+ };
645
+ }): Promise<unknown>;
646
+ /**
647
+ * @summary Get User
648
+ * @description Retrieves information about the authenticated user, including their ID, name, email, and account metadata.
649
+ * @link /user
650
+ */
651
+ declare function userGet({ config }?: {
652
+ config?: Partial<FetcherConfig> & {
653
+ client?: typeof client;
654
+ };
655
+ }): Promise<unknown>;
656
+ /**
657
+ * @summary Get Billing
658
+ * @description Fetches billing usage and quota information for the authenticated user. Can be scoped to a specific context (e.g. project or namespace).
659
+ * @link /user/billing
660
+ */
661
+ declare function userGetBilling({ queryParams, config }?: {
662
+ queryParams?: {
663
+ "scope"?: string;
664
+ };
665
+ config?: Partial<FetcherConfig> & {
666
+ client?: typeof client;
667
+ };
668
+ }): Promise<unknown>;
669
+ /**
670
+ * @summary Get Plan
671
+ * @description Returns the current subscription plan for the authenticated user, including tier details and feature limits.
672
+ * @link /user/plan
673
+ */
674
+ declare function userGetPlan({ config }?: {
675
+ config?: Partial<FetcherConfig> & {
676
+ client?: typeof client;
677
+ };
678
+ }): Promise<unknown>;
679
+ /**
680
+ * @summary Get User Scopes
681
+ * @description Retrieves all accessible scopes for the authenticated user, such as personal workspaces or shared teams.
682
+ * @link /user/scopes
683
+ */
684
+ declare function userGetScopes({ config }?: {
685
+ config?: Partial<FetcherConfig> & {
686
+ client?: typeof client;
687
+ };
688
+ }): Promise<unknown>;
689
+ /**
690
+ * @summary Restore Block
691
+ * @description Restores a block to a specific version.
692
+ * @link /chats/{chatId}/versions/{versionId}/restore
693
+ */
694
+ declare function chatsRestore({ pathParams, config }?: {
695
+ pathParams: {
696
+ "chatId": string;
697
+ "versionId": string;
698
+ };
699
+ config?: Partial<FetcherConfig> & {
700
+ client?: typeof client;
701
+ };
702
+ }): Promise<unknown>;
703
+ /**
704
+ * @summary Get Usage Report
705
+ * @description Retrieves detailed usage events for the authenticated user or team, including costs, event types, models used, and metadata. Shows the same data as displayed in the usage dashboard. Can be filtered by chatId to show usage for a specific chat, or by userId to show usage for a specific user.
706
+ * @link /reports/usage
707
+ */
708
+ declare function reportsGetUsage({ queryParams, config }?: {
709
+ queryParams?: {
710
+ "startDate"?: string;
711
+ "endDate"?: string;
712
+ "chatId"?: string;
713
+ "messageId"?: string;
714
+ "userId"?: string;
715
+ "limit"?: number;
716
+ "cursor"?: string;
717
+ };
718
+ config?: Partial<FetcherConfig> & {
719
+ client?: typeof client;
720
+ };
721
+ }): Promise<unknown>;
722
+ /**
723
+ * @summary Get AI Usage Report
724
+ * @description Retrieves v0 AI usage events for the authenticated user or active team scope.
725
+ * @link /reports/usage/ai
726
+ */
727
+ declare function reportsGetAIUsage({ queryParams, config }?: {
728
+ queryParams?: {
729
+ "start"?: string;
730
+ "end"?: string;
731
+ "cursor"?: string;
732
+ "limit"?: number;
733
+ };
734
+ config?: Partial<FetcherConfig> & {
735
+ client?: typeof client;
736
+ };
737
+ }): Promise<unknown>;
738
+ /**
739
+ * @summary Get User Activity Report
740
+ * @description Retrieves aggregated user activity data for team members, including chat counts, message counts, and activity timestamps. Only available for Enterprise teams with OWNER or BILLING role. Shows the same data as displayed in the Usage settings for Enterprise teams.
741
+ * @link /reports/user-activity
742
+ */
743
+ declare function reportsGetUserActivity({ queryParams, config }?: {
744
+ queryParams?: {
745
+ "startDate"?: string;
746
+ "endDate"?: string;
747
+ };
748
+ config?: Partial<FetcherConfig> & {
749
+ client?: typeof client;
750
+ };
751
+ }): Promise<unknown>;
752
+ /**
753
+ * @summary List MCP Servers
754
+ * @description Retrieves all MCP servers configured for the authenticated user.
755
+ * @link /mcp-servers
756
+ */
757
+ declare function mcpServersFind({ config }?: {
758
+ config?: Partial<FetcherConfig> & {
759
+ client?: typeof client;
760
+ };
761
+ }): Promise<unknown>;
762
+ /**
763
+ * @summary Create MCP Server
764
+ * @description Creates a new MCP server configuration for the authenticated user. Supports OAuth, bearer token, custom headers, and unauthenticated servers.
765
+ * @link /mcp-servers
766
+ */
767
+ declare function mcpServersCreate({ config }?: {
768
+ config?: Partial<FetcherConfig> & {
769
+ client?: typeof client;
770
+ };
771
+ }): Promise<unknown>;
772
+ /**
773
+ * @summary Get MCP Server
774
+ * @description Retrieves the details of a specific MCP server by its ID.
775
+ * @link /mcp-servers/{mcpServerId}
776
+ */
777
+ declare function mcpServersGetById({ pathParams, config }?: {
778
+ pathParams: {
779
+ "mcpServerId": string;
780
+ };
781
+ config?: Partial<FetcherConfig> & {
782
+ client?: typeof client;
783
+ };
784
+ }): Promise<unknown>;
785
+ /**
786
+ * @summary Update MCP Server
787
+ * @description Updates the configuration of an existing MCP server, including its name, URL, description, enabled status, and authentication settings.
788
+ * @link /mcp-servers/{mcpServerId}
789
+ */
790
+ declare function mcpServersUpdate({ pathParams, config }?: {
791
+ pathParams: {
792
+ "mcpServerId": string;
793
+ };
794
+ config?: Partial<FetcherConfig> & {
795
+ client?: typeof client;
796
+ };
797
+ }): Promise<unknown>;
798
+ /**
799
+ * @summary Delete MCP Server
800
+ * @description Deletes an MCP server based on its ID. This action is irreversible and will also remove any associated OAuth tokens.
801
+ * @link /mcp-servers/{mcpServerId}
802
+ */
803
+ declare function mcpServersDelete({ pathParams, config }?: {
804
+ pathParams: {
805
+ "mcpServerId": string;
806
+ };
807
+ config?: Partial<FetcherConfig> & {
808
+ client?: typeof client;
809
+ };
810
+ }): Promise<unknown>;
811
+ /**
812
+ * @summary Create MCP Server OAuth Authorization URL
813
+ * @description Creates an OAuth authorization URL for an OAuth MCP server. Redirect the user to the returned URL, and the Platform API OAuth callback will store the resulting tokens before redirecting to your returnUrl.
814
+ * @link /mcp-servers/{mcpServerId}/oauth/authorize
815
+ */
816
+ declare function mcpServersCreateOAuthAuthorizationUrl({ pathParams, config }?: {
817
+ pathParams: {
818
+ "mcpServerId": string;
819
+ };
820
+ config?: Partial<FetcherConfig> & {
821
+ client?: typeof client;
822
+ };
823
+ }): Promise<unknown>;
824
+ declare const operationsByPath: {
825
+ "POST /chats": typeof chatsCreate;
826
+ "GET /chats": typeof chatsFind;
827
+ "POST /chats/init": typeof chatsInit;
828
+ "DELETE /chats/{chatId}": typeof chatsDelete;
829
+ "GET /chats/{chatId}": typeof chatsGetById;
830
+ "PATCH /chats/{chatId}": typeof chatsUpdate;
831
+ "PUT /chats/{chatId}/favorite": typeof chatsFavorite;
832
+ "POST /chats/{chatId}/fork": typeof chatsFork;
833
+ "GET /chats/{chatId}/project": typeof projectsGetByChatId;
834
+ "GET /chats/{chatId}/messages": typeof chatsFindMessages;
835
+ "POST /chats/{chatId}/messages": typeof chatsSendMessage;
836
+ "GET /chats/{chatId}/messages/{messageId}": typeof chatsGetMessage;
837
+ "GET /chats/{chatId}/versions": typeof chatsFindVersions;
838
+ "GET /chats/{chatId}/versions/{versionId}": typeof chatsGetVersion;
839
+ "PATCH /chats/{chatId}/versions/{versionId}": typeof chatsUpdateVersion;
840
+ "GET /chats/{chatId}/versions/{versionId}/download": typeof chatsDownloadVersion;
841
+ "POST /chats/{chatId}/versions/{versionId}/files/delete": typeof chatsDeleteVersionFiles;
842
+ "POST /chats/{chatId}/messages/{messageId}/resume": typeof chatsResume;
843
+ "POST /chats/{chatId}/messages/{messageId}/stop": typeof chatsStop;
844
+ "POST /chats/{chatId}/tasks/resolve": typeof chatsResolveTask;
845
+ "GET /deployments": typeof deploymentsFind;
846
+ "POST /deployments": typeof deploymentsCreate;
847
+ "GET /deployments/{deploymentId}": typeof deploymentsGetById;
848
+ "DELETE /deployments/{deploymentId}": typeof deploymentsDelete;
849
+ "GET /deployments/{deploymentId}/logs": typeof deploymentsFindLogs;
850
+ "GET /deployments/{deploymentId}/errors": typeof deploymentsFindErrors;
851
+ "GET /hooks": typeof hooksFind;
852
+ "POST /hooks": typeof hooksCreate;
853
+ "GET /hooks/{hookId}": typeof hooksGetById;
854
+ "PATCH /hooks/{hookId}": typeof hooksUpdate;
855
+ "DELETE /hooks/{hookId}": typeof hooksDelete;
856
+ "GET /integrations/vercel/projects": typeof integrationsVercelProjectsFind;
857
+ "POST /integrations/vercel/projects": typeof integrationsVercelProjectsCreate;
858
+ "GET /projects": typeof projectsFind;
859
+ "POST /projects": typeof projectsCreate;
860
+ "GET /projects/{projectId}": typeof projectsGetById;
861
+ "PATCH /projects/{projectId}": typeof projectsUpdate;
862
+ "DELETE /projects/{projectId}": typeof projectsDelete;
863
+ "POST /projects/{projectId}/assign": typeof projectsAssign;
864
+ "GET /projects/{projectId}/env-vars": typeof projectsFindEnvVars;
865
+ "POST /projects/{projectId}/env-vars": typeof projectsCreateEnvVars;
866
+ "PATCH /projects/{projectId}/env-vars": typeof projectsUpdateEnvVars;
867
+ "POST /projects/{projectId}/env-vars/delete": typeof projectsDeleteEnvVars;
868
+ "GET /projects/{projectId}/env-vars/{environmentVariableId}": typeof projectsGetEnvVar;
869
+ "GET /rate-limits": typeof rateLimitsFind;
870
+ "GET /user": typeof userGet;
871
+ "GET /user/billing": typeof userGetBilling;
872
+ "GET /user/plan": typeof userGetPlan;
873
+ "GET /user/scopes": typeof userGetScopes;
874
+ "POST /chats/{chatId}/versions/{versionId}/restore": typeof chatsRestore;
875
+ "GET /reports/usage": typeof reportsGetUsage;
876
+ "GET /reports/usage/ai": typeof reportsGetAIUsage;
877
+ "GET /reports/user-activity": typeof reportsGetUserActivity;
878
+ "GET /mcp-servers": typeof mcpServersFind;
879
+ "POST /mcp-servers": typeof mcpServersCreate;
880
+ "GET /mcp-servers/{mcpServerId}": typeof mcpServersGetById;
881
+ "PATCH /mcp-servers/{mcpServerId}": typeof mcpServersUpdate;
882
+ "DELETE /mcp-servers/{mcpServerId}": typeof mcpServersDelete;
883
+ "POST /mcp-servers/{mcpServerId}/oauth/authorize": typeof mcpServersCreateOAuthAuthorizationUrl;
884
+ };
885
+ declare const operationsByTag: {
886
+ chats: {
887
+ chatsCreate: typeof chatsCreate;
888
+ chatsFind: typeof chatsFind;
889
+ chatsInit: typeof chatsInit;
890
+ chatsDelete: typeof chatsDelete;
891
+ chatsGetById: typeof chatsGetById;
892
+ chatsUpdate: typeof chatsUpdate;
893
+ chatsFavorite: typeof chatsFavorite;
894
+ chatsFork: typeof chatsFork;
895
+ chatsFindMessages: typeof chatsFindMessages;
896
+ chatsSendMessage: typeof chatsSendMessage;
897
+ chatsGetMessage: typeof chatsGetMessage;
898
+ chatsFindVersions: typeof chatsFindVersions;
899
+ chatsGetVersion: typeof chatsGetVersion;
900
+ chatsUpdateVersion: typeof chatsUpdateVersion;
901
+ chatsDownloadVersion: typeof chatsDownloadVersion;
902
+ chatsDeleteVersionFiles: typeof chatsDeleteVersionFiles;
903
+ chatsResume: typeof chatsResume;
904
+ chatsStop: typeof chatsStop;
905
+ chatsResolveTask: typeof chatsResolveTask;
906
+ chatsRestore: typeof chatsRestore;
907
+ };
908
+ projects: {
909
+ projectsGetByChatId: typeof projectsGetByChatId;
910
+ projectsFind: typeof projectsFind;
911
+ projectsCreate: typeof projectsCreate;
912
+ projectsGetById: typeof projectsGetById;
913
+ projectsUpdate: typeof projectsUpdate;
914
+ projectsDelete: typeof projectsDelete;
915
+ projectsAssign: typeof projectsAssign;
916
+ projectsFindEnvVars: typeof projectsFindEnvVars;
917
+ projectsCreateEnvVars: typeof projectsCreateEnvVars;
918
+ projectsUpdateEnvVars: typeof projectsUpdateEnvVars;
919
+ projectsDeleteEnvVars: typeof projectsDeleteEnvVars;
920
+ projectsGetEnvVar: typeof projectsGetEnvVar;
921
+ };
922
+ deployments: {
923
+ deploymentsFind: typeof deploymentsFind;
924
+ deploymentsCreate: typeof deploymentsCreate;
925
+ deploymentsGetById: typeof deploymentsGetById;
926
+ deploymentsDelete: typeof deploymentsDelete;
927
+ deploymentsFindLogs: typeof deploymentsFindLogs;
928
+ deploymentsFindErrors: typeof deploymentsFindErrors;
929
+ };
930
+ hooks: {
931
+ hooksFind: typeof hooksFind;
932
+ hooksCreate: typeof hooksCreate;
933
+ hooksGetById: typeof hooksGetById;
934
+ hooksUpdate: typeof hooksUpdate;
935
+ hooksDelete: typeof hooksDelete;
936
+ };
937
+ integrations: {
938
+ integrationsVercelProjectsFind: typeof integrationsVercelProjectsFind;
939
+ integrationsVercelProjectsCreate: typeof integrationsVercelProjectsCreate;
940
+ };
941
+ ratelimits: {
942
+ rateLimitsFind: typeof rateLimitsFind;
943
+ };
944
+ user: {
945
+ userGet: typeof userGet;
946
+ userGetBilling: typeof userGetBilling;
947
+ userGetPlan: typeof userGetPlan;
948
+ userGetScopes: typeof userGetScopes;
949
+ };
950
+ reports: {
951
+ reportsGetUsage: typeof reportsGetUsage;
952
+ reportsGetAIUsage: typeof reportsGetAIUsage;
953
+ reportsGetUserActivity: typeof reportsGetUserActivity;
954
+ };
955
+ mcpservers: {
956
+ mcpServersFind: typeof mcpServersFind;
957
+ mcpServersCreate: typeof mcpServersCreate;
958
+ mcpServersGetById: typeof mcpServersGetById;
959
+ mcpServersUpdate: typeof mcpServersUpdate;
960
+ mcpServersDelete: typeof mcpServersDelete;
961
+ mcpServersCreateOAuthAuthorizationUrl: typeof mcpServersCreateOAuthAuthorizationUrl;
962
+ };
963
+ };
964
+ declare const tagDictionary: {
965
+ readonly chats: {
966
+ readonly POST: readonly ["chatsCreate", "chatsInit", "chatsFork", "chatsSendMessage", "chatsDeleteVersionFiles", "chatsResume", "chatsStop", "chatsResolveTask", "chatsRestore"];
967
+ readonly GET: readonly ["chatsFind", "chatsGetById", "chatsFindMessages", "chatsGetMessage", "chatsFindVersions", "chatsGetVersion", "chatsDownloadVersion"];
968
+ readonly DELETE: readonly ["chatsDelete"];
969
+ readonly PATCH: readonly ["chatsUpdate", "chatsUpdateVersion"];
970
+ readonly PUT: readonly ["chatsFavorite"];
971
+ };
972
+ readonly projects: {
973
+ readonly GET: readonly ["projectsGetByChatId", "projectsFind", "projectsGetById", "projectsFindEnvVars", "projectsGetEnvVar"];
974
+ readonly POST: readonly ["projectsCreate", "projectsAssign", "projectsCreateEnvVars", "projectsDeleteEnvVars"];
975
+ readonly PATCH: readonly ["projectsUpdate", "projectsUpdateEnvVars"];
976
+ readonly DELETE: readonly ["projectsDelete"];
977
+ };
978
+ readonly deployments: {
979
+ readonly GET: readonly ["deploymentsFind", "deploymentsGetById", "deploymentsFindLogs", "deploymentsFindErrors"];
980
+ readonly POST: readonly ["deploymentsCreate"];
981
+ readonly DELETE: readonly ["deploymentsDelete"];
982
+ };
983
+ readonly hooks: {
984
+ readonly GET: readonly ["hooksFind", "hooksGetById"];
985
+ readonly POST: readonly ["hooksCreate"];
986
+ readonly PATCH: readonly ["hooksUpdate"];
987
+ readonly DELETE: readonly ["hooksDelete"];
988
+ };
989
+ readonly integrations: {
990
+ readonly GET: readonly ["integrationsVercelProjectsFind"];
991
+ readonly POST: readonly ["integrationsVercelProjectsCreate"];
992
+ };
993
+ readonly ratelimits: {
994
+ readonly GET: readonly ["rateLimitsFind"];
995
+ };
996
+ readonly user: {
997
+ readonly GET: readonly ["userGet", "userGetBilling", "userGetPlan", "userGetScopes"];
998
+ };
999
+ readonly reports: {
1000
+ readonly GET: readonly ["reportsGetUsage", "reportsGetAIUsage", "reportsGetUserActivity"];
1001
+ };
1002
+ readonly mcpservers: {
1003
+ readonly GET: readonly ["mcpServersFind", "mcpServersGetById"];
1004
+ readonly POST: readonly ["mcpServersCreate", "mcpServersCreateOAuthAuthorizationUrl"];
1005
+ readonly PATCH: readonly ["mcpServersUpdate"];
1006
+ readonly DELETE: readonly ["mcpServersDelete"];
1007
+ };
1008
+ };
1009
+
1010
+ export { chatsCreate, chatsDelete, chatsDeleteVersionFiles, chatsDownloadVersion, chatsFavorite, chatsFind, chatsFindMessages, chatsFindVersions, chatsFork, chatsGetById, chatsGetMessage, chatsGetVersion, chatsInit, chatsResolveTask, chatsRestore, chatsResume, chatsSendMessage, chatsStop, chatsUpdate, chatsUpdateVersion, deploymentsCreate, deploymentsDelete, deploymentsFind, deploymentsFindErrors, deploymentsFindLogs, deploymentsGetById, hooksCreate, hooksDelete, hooksFind, hooksGetById, hooksUpdate, integrationsVercelProjectsCreate, integrationsVercelProjectsFind, mcpServersCreate, mcpServersCreateOAuthAuthorizationUrl, mcpServersDelete, mcpServersFind, mcpServersGetById, mcpServersUpdate, operationsByPath, operationsByTag, projectsAssign, projectsCreate, projectsCreateEnvVars, projectsDelete, projectsDeleteEnvVars, projectsFind, projectsFindEnvVars, projectsGetByChatId, projectsGetById, projectsGetEnvVar, projectsUpdate, projectsUpdateEnvVars, rateLimitsFind, reportsGetAIUsage, reportsGetUsage, reportsGetUserActivity, tagDictionary, userGet, userGetBilling, userGetPlan, userGetScopes };
1011
+ //# sourceMappingURL=components.d.cts.map