v0-api 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/effect.mjs CHANGED
@@ -1,1310 +1,6 @@
1
1
  import { createEffectApi, createEffectByPath } from '@sferadev/openapi-utils/effect';
2
2
  export { ApiConfig, ApiError, NetworkError, ValidationError, makeApiLayer } from '@sferadev/openapi-utils/effect';
3
-
4
- function notEmpty(value) {
5
- return value !== null && value !== undefined;
6
- }
7
- function compactObject(obj) {
8
- return Object.fromEntries(Object.entries(obj).filter(([, value])=>notEmpty(value)));
9
- }
10
-
11
- async function client({ url, method, body, headers, queryParams, signal, token = null, baseUrl = "", fetchImpl = fetch }) {
12
- try {
13
- const requestHeaders = compactObject({
14
- "Content-Type": "application/json",
15
- Authorization: token ? `Bearer ${token}` : undefined,
16
- ...headers
17
- });
18
- /**
19
- * As the fetch API is being used, when multipart/form-data is specified
20
- * the Content-Type header must be deleted so that the browser can set
21
- * the correct boundary.
22
- * https://developer.mozilla.org/en-US/docs/Web/API/FormData/Using_FormData_Objects#sending_files_using_a_formdata_object
23
- */ if (requestHeaders["Content-Type"]?.toLowerCase().includes("multipart/form-data")) {
24
- delete requestHeaders["Content-Type"];
25
- }
26
- const payload = body instanceof FormData ? body : requestHeaders["Content-Type"] === "application/json" ? JSON.stringify(body) : body;
27
- const fullUrl = `${baseUrl}${resolveUrl(url, queryParams)}`;
28
- const response = await fetchImpl(fullUrl, {
29
- signal,
30
- method: method.toUpperCase(),
31
- body: payload,
32
- headers: requestHeaders
33
- });
34
- if (!response.ok) {
35
- let error;
36
- try {
37
- error = await response.json();
38
- } catch (e) {
39
- error = {
40
- status: "unknown",
41
- payload: e instanceof Error ? `Unexpected error (${e.message})` : "Unexpected error"
42
- };
43
- }
44
- throw error;
45
- }
46
- if (response.headers?.get("content-type")?.includes("json")) {
47
- return await response.json();
48
- } else {
49
- // if it is not a json response, assume it is a blob and cast it to TData
50
- return await response.text();
51
- }
52
- } catch (e) {
53
- const errorObject = {
54
- name: "unknown",
55
- message: e?.message ? `${e?.message}` : "Network error"
56
- };
57
- throw errorObject;
58
- }
59
- }
60
- const resolveUrl = (url, queryParams = {})=>{
61
- let query = new URLSearchParams(queryParams).toString();
62
- if (query) query = `?${query}`;
63
- return url + query;
64
- };
65
-
66
- /**
67
- * @summary Create Chat
68
- * @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.
69
- * @link /chats
70
- */ async function chatsCreate({ config } = {}) {
71
- const { client: request = client, ...requestConfig } = config ?? {};
72
- const data = await request({
73
- method: "POST",
74
- url: `/chats`,
75
- ...requestConfig,
76
- headers: {
77
- ...requestConfig.headers
78
- }
79
- });
80
- return data;
81
- }
82
- /**
83
- * @summary Find Chats
84
- * @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.
85
- * @link /chats
86
- */ async function chatsFind({ queryParams, config } = {}) {
87
- const { client: request = client, ...requestConfig } = config ?? {};
88
- const data = await request({
89
- method: "GET",
90
- url: `/chats`,
91
- queryParams,
92
- ...requestConfig,
93
- headers: {
94
- ...requestConfig.headers
95
- }
96
- });
97
- return data;
98
- }
99
- /**
100
- * @summary Initialize Chat
101
- * @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.
102
- * @link /chats/init
103
- */ async function chatsInit({ config } = {}) {
104
- const { client: request = client, ...requestConfig } = config ?? {};
105
- const data = await request({
106
- method: "POST",
107
- url: `/chats/init`,
108
- ...requestConfig,
109
- headers: {
110
- ...requestConfig.headers
111
- }
112
- });
113
- return data;
114
- }
115
- /**
116
- * @summary Delete Chat
117
- * @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.
118
- * @link /chats/{chatId}
119
- */ async function chatsDelete({ pathParams, config } = {}) {
120
- const { client: request = client, ...requestConfig } = config ?? {};
121
- if (!pathParams.chatId) {
122
- throw new Error(`Missing required path parameter: chatId`);
123
- }
124
- const data = await request({
125
- method: "DELETE",
126
- url: `/chats/${pathParams.chatId}`,
127
- ...requestConfig,
128
- headers: {
129
- ...requestConfig.headers
130
- }
131
- });
132
- return data;
133
- }
134
- /**
135
- * @summary Get Chat
136
- * @description Retrieves the full details of a specific chat using its `chatId`. Includes messages, metadata, and associated configuration.
137
- * @link /chats/{chatId}
138
- */ async function chatsGetById({ pathParams, config } = {}) {
139
- const { client: request = client, ...requestConfig } = config ?? {};
140
- if (!pathParams.chatId) {
141
- throw new Error(`Missing required path parameter: chatId`);
142
- }
143
- const data = await request({
144
- method: "GET",
145
- url: `/chats/${pathParams.chatId}`,
146
- ...requestConfig,
147
- headers: {
148
- ...requestConfig.headers
149
- }
150
- });
151
- return data;
152
- }
153
- /**
154
- * @summary Update Chat
155
- * @description Updates the metadata of an existing chat using its `chatId`. Supports changes to the chat name and privacy setting.
156
- * @link /chats/{chatId}
157
- */ async function chatsUpdate({ pathParams, config } = {}) {
158
- const { client: request = client, ...requestConfig } = config ?? {};
159
- if (!pathParams.chatId) {
160
- throw new Error(`Missing required path parameter: chatId`);
161
- }
162
- const data = await request({
163
- method: "PATCH",
164
- url: `/chats/${pathParams.chatId}`,
165
- ...requestConfig,
166
- headers: {
167
- ...requestConfig.headers
168
- }
169
- });
170
- return data;
171
- }
172
- /**
173
- * @summary Favorite Chat
174
- * @description Marks or unmarks a chat as a favorite using its `chatId`. This helps with organizing and quickly accessing important chats.
175
- * @link /chats/{chatId}/favorite
176
- */ async function chatsFavorite({ pathParams, config } = {}) {
177
- const { client: request = client, ...requestConfig } = config ?? {};
178
- if (!pathParams.chatId) {
179
- throw new Error(`Missing required path parameter: chatId`);
180
- }
181
- const data = await request({
182
- method: "PUT",
183
- url: `/chats/${pathParams.chatId}/favorite`,
184
- ...requestConfig,
185
- headers: {
186
- ...requestConfig.headers
187
- }
188
- });
189
- return data;
190
- }
191
- /**
192
- * @summary Fork Chat
193
- * @description Creates a new chat fork (duplicate) from a specific version within a chat created through Platform API v1. To duplicate chats created in v0 web or Platform API v2, use POST /v2/chats/{chatId}/duplicate.
194
- * @link /chats/{chatId}/fork
195
- */ async function chatsFork({ pathParams, config } = {}) {
196
- const { client: request = client, ...requestConfig } = config ?? {};
197
- if (!pathParams.chatId) {
198
- throw new Error(`Missing required path parameter: chatId`);
199
- }
200
- const data = await request({
201
- method: "POST",
202
- url: `/chats/${pathParams.chatId}/fork`,
203
- ...requestConfig,
204
- headers: {
205
- ...requestConfig.headers
206
- }
207
- });
208
- return data;
209
- }
210
- /**
211
- * @summary Get Project by Chat ID
212
- * @description Retrieves the v0 project associated with a given chat. Useful for determining the context or scope of a chat session.
213
- * @link /chats/{chatId}/project
214
- */ async function projectsGetByChatId({ pathParams, config } = {}) {
215
- const { client: request = client, ...requestConfig } = config ?? {};
216
- if (!pathParams.chatId) {
217
- throw new Error(`Missing required path parameter: chatId`);
218
- }
219
- const data = await request({
220
- method: "GET",
221
- url: `/chats/${pathParams.chatId}/project`,
222
- ...requestConfig,
223
- headers: {
224
- ...requestConfig.headers
225
- }
226
- });
227
- return data;
228
- }
229
- /**
230
- * @summary Find Chat Messages
231
- * @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.
232
- * @link /chats/{chatId}/messages
233
- */ async function chatsFindMessages({ pathParams, queryParams, config } = {}) {
234
- const { client: request = client, ...requestConfig } = config ?? {};
235
- if (!pathParams.chatId) {
236
- throw new Error(`Missing required path parameter: chatId`);
237
- }
238
- const data = await request({
239
- method: "GET",
240
- url: `/chats/${pathParams.chatId}/messages`,
241
- queryParams,
242
- ...requestConfig,
243
- headers: {
244
- ...requestConfig.headers
245
- }
246
- });
247
- return data;
248
- }
249
- /**
250
- * @summary Send Message
251
- * @description Creates a new message in an existing chat. Triggers a model response using the provided prompt, with optional attachments and configuration settings.
252
- * @link /chats/{chatId}/messages
253
- */ async function chatsSendMessage({ pathParams, config } = {}) {
254
- const { client: request = client, ...requestConfig } = config ?? {};
255
- if (!pathParams.chatId) {
256
- throw new Error(`Missing required path parameter: chatId`);
257
- }
258
- const data = await request({
259
- method: "POST",
260
- url: `/chats/${pathParams.chatId}/messages`,
261
- ...requestConfig,
262
- headers: {
263
- ...requestConfig.headers
264
- }
265
- });
266
- return data;
267
- }
268
- /**
269
- * @summary Get Chat Message
270
- * @description Retrieves detailed information about a specific message within a chat, including content, files, model configuration, and demo URLs.
271
- * @link /chats/{chatId}/messages/{messageId}
272
- */ async function chatsGetMessage({ pathParams, config } = {}) {
273
- const { client: request = client, ...requestConfig } = config ?? {};
274
- if (!pathParams.chatId) {
275
- throw new Error(`Missing required path parameter: chatId`);
276
- }
277
- if (!pathParams.messageId) {
278
- throw new Error(`Missing required path parameter: messageId`);
279
- }
280
- const data = await request({
281
- method: "GET",
282
- url: `/chats/${pathParams.chatId}/messages/${pathParams.messageId}`,
283
- ...requestConfig,
284
- headers: {
285
- ...requestConfig.headers
286
- }
287
- });
288
- return data;
289
- }
290
- /**
291
- * @summary Find Chat Versions
292
- * @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.
293
- * @link /chats/{chatId}/versions
294
- */ async function chatsFindVersions({ pathParams, queryParams, config } = {}) {
295
- const { client: request = client, ...requestConfig } = config ?? {};
296
- if (!pathParams.chatId) {
297
- throw new Error(`Missing required path parameter: chatId`);
298
- }
299
- const data = await request({
300
- method: "GET",
301
- url: `/chats/${pathParams.chatId}/versions`,
302
- queryParams,
303
- ...requestConfig,
304
- headers: {
305
- ...requestConfig.headers
306
- }
307
- });
308
- return data;
309
- }
310
- /**
311
- * @summary Get Chat Version
312
- * @description Retrieves detailed information about a specific version of a chat, including all files with their content and lock status.
313
- * @link /chats/{chatId}/versions/{versionId}
314
- */ async function chatsGetVersion({ pathParams, queryParams, config } = {}) {
315
- const { client: request = client, ...requestConfig } = config ?? {};
316
- if (!pathParams.chatId) {
317
- throw new Error(`Missing required path parameter: chatId`);
318
- }
319
- if (!pathParams.versionId) {
320
- throw new Error(`Missing required path parameter: versionId`);
321
- }
322
- const data = await request({
323
- method: "GET",
324
- url: `/chats/${pathParams.chatId}/versions/${pathParams.versionId}`,
325
- queryParams,
326
- ...requestConfig,
327
- headers: {
328
- ...requestConfig.headers
329
- }
330
- });
331
- return data;
332
- }
333
- /**
334
- * @summary Update Chat Version Files
335
- * @description Updates the source files of a specific chat version (block) manually. This allows editing generated files directly through the API.
336
- * @link /chats/{chatId}/versions/{versionId}
337
- */ async function chatsUpdateVersion({ pathParams, config } = {}) {
338
- const { client: request = client, ...requestConfig } = config ?? {};
339
- if (!pathParams.chatId) {
340
- throw new Error(`Missing required path parameter: chatId`);
341
- }
342
- if (!pathParams.versionId) {
343
- throw new Error(`Missing required path parameter: versionId`);
344
- }
345
- const data = await request({
346
- method: "PATCH",
347
- url: `/chats/${pathParams.chatId}/versions/${pathParams.versionId}`,
348
- ...requestConfig,
349
- headers: {
350
- ...requestConfig.headers
351
- }
352
- });
353
- return data;
354
- }
355
- /**
356
- * @summary Download version files
357
- * @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.
358
- * @link /chats/{chatId}/versions/{versionId}/download
359
- */ async function chatsDownloadVersion({ pathParams, queryParams, config } = {}) {
360
- const { client: request = client, ...requestConfig } = config ?? {};
361
- if (!pathParams.chatId) {
362
- throw new Error(`Missing required path parameter: chatId`);
363
- }
364
- if (!pathParams.versionId) {
365
- throw new Error(`Missing required path parameter: versionId`);
366
- }
367
- const data = await request({
368
- method: "GET",
369
- url: `/chats/${pathParams.chatId}/versions/${pathParams.versionId}/download`,
370
- queryParams,
371
- ...requestConfig,
372
- headers: {
373
- ...requestConfig.headers
374
- }
375
- });
376
- return data;
377
- }
378
- /**
379
- * @summary Delete Chat Version Files
380
- * @description Deletes source files from a specific chat version (block). Files are removed from the version and a new source version is created.
381
- * @link /chats/{chatId}/versions/{versionId}/files/delete
382
- */ async function chatsDeleteVersionFiles({ pathParams, config } = {}) {
383
- const { client: request = client, ...requestConfig } = config ?? {};
384
- if (!pathParams.chatId) {
385
- throw new Error(`Missing required path parameter: chatId`);
386
- }
387
- if (!pathParams.versionId) {
388
- throw new Error(`Missing required path parameter: versionId`);
389
- }
390
- const data = await request({
391
- method: "POST",
392
- url: `/chats/${pathParams.chatId}/versions/${pathParams.versionId}/files/delete`,
393
- ...requestConfig,
394
- headers: {
395
- ...requestConfig.headers
396
- }
397
- });
398
- return data;
399
- }
400
- /**
401
- * @summary Resume Message
402
- * @description Reconnects to an active assistant message stream and returns it as Server-Sent Events. This does not restart or continue a stopped generation.
403
- * @link /chats/{chatId}/messages/{messageId}/resume
404
- */ async function chatsResume({ pathParams, config } = {}) {
405
- const { client: request = client, ...requestConfig } = config ?? {};
406
- if (!pathParams.chatId) {
407
- throw new Error(`Missing required path parameter: chatId`);
408
- }
409
- if (!pathParams.messageId) {
410
- throw new Error(`Missing required path parameter: messageId`);
411
- }
412
- const data = await request({
413
- method: "POST",
414
- url: `/chats/${pathParams.chatId}/messages/${pathParams.messageId}/resume`,
415
- ...requestConfig,
416
- headers: {
417
- ...requestConfig.headers
418
- }
419
- });
420
- return data;
421
- }
422
- /**
423
- * @summary Stop Message
424
- * @description Stops an in-flight message generation in a chat. Useful for cancelling a streaming response that is still being generated.
425
- * @link /chats/{chatId}/messages/{messageId}/stop
426
- */ async function chatsStop({ pathParams, config } = {}) {
427
- const { client: request = client, ...requestConfig } = config ?? {};
428
- if (!pathParams.chatId) {
429
- throw new Error(`Missing required path parameter: chatId`);
430
- }
431
- if (!pathParams.messageId) {
432
- throw new Error(`Missing required path parameter: messageId`);
433
- }
434
- const data = await request({
435
- method: "POST",
436
- url: `/chats/${pathParams.chatId}/messages/${pathParams.messageId}/stop`,
437
- ...requestConfig,
438
- headers: {
439
- ...requestConfig.headers
440
- }
441
- });
442
- return data;
443
- }
444
- /**
445
- * @summary Resolve Task
446
- * @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).
447
- * @link /chats/{chatId}/tasks/resolve
448
- */ async function chatsResolveTask({ pathParams, config } = {}) {
449
- const { client: request = client, ...requestConfig } = config ?? {};
450
- if (!pathParams.chatId) {
451
- throw new Error(`Missing required path parameter: chatId`);
452
- }
453
- const data = await request({
454
- method: "POST",
455
- url: `/chats/${pathParams.chatId}/tasks/resolve`,
456
- ...requestConfig,
457
- headers: {
458
- ...requestConfig.headers
459
- }
460
- });
461
- return data;
462
- }
463
- /**
464
- * @summary Find Deployments
465
- * @description Find deployments by project and chat IDs. This will return a list of deployments for the given project and chat IDs.
466
- * @link /deployments
467
- */ async function deploymentsFind({ queryParams, config } = {}) {
468
- const { client: request = client, ...requestConfig } = config ?? {};
469
- const data = await request({
470
- method: "GET",
471
- url: `/deployments`,
472
- queryParams,
473
- ...requestConfig,
474
- headers: {
475
- ...requestConfig.headers
476
- }
477
- });
478
- return data;
479
- }
480
- /**
481
- * @summary Create Deployment
482
- * @description Create a new deployment for a specific chat and version. This will trigger a deployment to Vercel.
483
- * @link /deployments
484
- */ async function deploymentsCreate({ config } = {}) {
485
- const { client: request = client, ...requestConfig } = config ?? {};
486
- const data = await request({
487
- method: "POST",
488
- url: `/deployments`,
489
- ...requestConfig,
490
- headers: {
491
- ...requestConfig.headers
492
- }
493
- });
494
- return data;
495
- }
496
- /**
497
- * @summary Get Deployment
498
- * @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.
499
- * @link /deployments/{deploymentId}
500
- */ async function deploymentsGetById({ pathParams, config } = {}) {
501
- const { client: request = client, ...requestConfig } = config ?? {};
502
- if (!pathParams.deploymentId) {
503
- throw new Error(`Missing required path parameter: deploymentId`);
504
- }
505
- const data = await request({
506
- method: "GET",
507
- url: `/deployments/${pathParams.deploymentId}`,
508
- ...requestConfig,
509
- headers: {
510
- ...requestConfig.headers
511
- }
512
- });
513
- return data;
514
- }
515
- /**
516
- * @summary Delete Deployment
517
- * @description Delete a deployment by ID. This will delete the deployment from Vercel.
518
- * @link /deployments/{deploymentId}
519
- */ async function deploymentsDelete({ pathParams, config } = {}) {
520
- const { client: request = client, ...requestConfig } = config ?? {};
521
- if (!pathParams.deploymentId) {
522
- throw new Error(`Missing required path parameter: deploymentId`);
523
- }
524
- const data = await request({
525
- method: "DELETE",
526
- url: `/deployments/${pathParams.deploymentId}`,
527
- ...requestConfig,
528
- headers: {
529
- ...requestConfig.headers
530
- }
531
- });
532
- return data;
533
- }
534
- /**
535
- * @summary Find Deployment Logs
536
- * @description Retrieves logs for a specific deployment. Supports filtering by timestamp to fetch only recent logs.
537
- * @link /deployments/{deploymentId}/logs
538
- */ async function deploymentsFindLogs({ pathParams, queryParams, config } = {}) {
539
- const { client: request = client, ...requestConfig } = config ?? {};
540
- if (!pathParams.deploymentId) {
541
- throw new Error(`Missing required path parameter: deploymentId`);
542
- }
543
- const data = await request({
544
- method: "GET",
545
- url: `/deployments/${pathParams.deploymentId}/logs`,
546
- queryParams,
547
- ...requestConfig,
548
- headers: {
549
- ...requestConfig.headers
550
- }
551
- });
552
- return data;
553
- }
554
- /**
555
- * @summary Find Deployment Errors
556
- * @description Retrieves a list of errors that occurred during a specific deployment. Useful for diagnosing and debugging deployment issues.
557
- * @link /deployments/{deploymentId}/errors
558
- */ async function deploymentsFindErrors({ pathParams, config } = {}) {
559
- const { client: request = client, ...requestConfig } = config ?? {};
560
- if (!pathParams.deploymentId) {
561
- throw new Error(`Missing required path parameter: deploymentId`);
562
- }
563
- const data = await request({
564
- method: "GET",
565
- url: `/deployments/${pathParams.deploymentId}/errors`,
566
- ...requestConfig,
567
- headers: {
568
- ...requestConfig.headers
569
- }
570
- });
571
- return data;
572
- }
573
- /**
574
- * @summary Find Hooks
575
- * @description Retrieves a list of existing hooks in your workspace. Useful for managing active webhooks tied to chat events or deployments.
576
- * @link /hooks
577
- */ async function hooksFind({ config } = {}) {
578
- const { client: request = client, ...requestConfig } = config ?? {};
579
- const data = await request({
580
- method: "GET",
581
- url: `/hooks`,
582
- ...requestConfig,
583
- headers: {
584
- ...requestConfig.headers
585
- }
586
- });
587
- return data;
588
- }
589
- /**
590
- * @summary Create Hook
591
- * @description Creates a new webhook that listens for specific events. Supports optional association with a chat.
592
- * @link /hooks
593
- */ async function hooksCreate({ config } = {}) {
594
- const { client: request = client, ...requestConfig } = config ?? {};
595
- const data = await request({
596
- method: "POST",
597
- url: `/hooks`,
598
- ...requestConfig,
599
- headers: {
600
- ...requestConfig.headers
601
- }
602
- });
603
- return data;
604
- }
605
- /**
606
- * @summary Get Hook
607
- * @description Retrieves the details of a specific webhook using its ID.
608
- * @link /hooks/{hookId}
609
- */ async function hooksGetById({ pathParams, config } = {}) {
610
- const { client: request = client, ...requestConfig } = config ?? {};
611
- if (!pathParams.hookId) {
612
- throw new Error(`Missing required path parameter: hookId`);
613
- }
614
- const data = await request({
615
- method: "GET",
616
- url: `/hooks/${pathParams.hookId}`,
617
- ...requestConfig,
618
- headers: {
619
- ...requestConfig.headers
620
- }
621
- });
622
- return data;
623
- }
624
- /**
625
- * @summary Update Hook
626
- * @description Updates the configuration of an existing webhook, including its name, event subscriptions, or target URL.
627
- * @link /hooks/{hookId}
628
- */ async function hooksUpdate({ pathParams, config } = {}) {
629
- const { client: request = client, ...requestConfig } = config ?? {};
630
- if (!pathParams.hookId) {
631
- throw new Error(`Missing required path parameter: hookId`);
632
- }
633
- const data = await request({
634
- method: "PATCH",
635
- url: `/hooks/${pathParams.hookId}`,
636
- ...requestConfig,
637
- headers: {
638
- ...requestConfig.headers
639
- }
640
- });
641
- return data;
642
- }
643
- /**
644
- * @summary Delete Hook
645
- * @description Deletes a webhook based on its ID. This action is irreversible.
646
- * @link /hooks/{hookId}
647
- */ async function hooksDelete({ pathParams, config } = {}) {
648
- const { client: request = client, ...requestConfig } = config ?? {};
649
- if (!pathParams.hookId) {
650
- throw new Error(`Missing required path parameter: hookId`);
651
- }
652
- const data = await request({
653
- method: "DELETE",
654
- url: `/hooks/${pathParams.hookId}`,
655
- ...requestConfig,
656
- headers: {
657
- ...requestConfig.headers
658
- }
659
- });
660
- return data;
661
- }
662
- /**
663
- * @summary Find Vercel Projects
664
- * @description Retrieves a list of Vercel projects linked to your integration. Useful for associating chats, deployments, or hooks with specific Vercel projects.
665
- * @link /integrations/vercel/projects
666
- */ async function integrationsVercelProjectsFind({ config } = {}) {
667
- const { client: request = client, ...requestConfig } = config ?? {};
668
- const data = await request({
669
- method: "GET",
670
- url: `/integrations/vercel/projects`,
671
- ...requestConfig,
672
- headers: {
673
- ...requestConfig.headers
674
- }
675
- });
676
- return data;
677
- }
678
- /**
679
- * @summary Create Vercel Project
680
- * @description Links a Vercel project to an existing v0 project. Enables Vercel-related features and deployment integration within the v0 workspace.
681
- * @link /integrations/vercel/projects
682
- */ async function integrationsVercelProjectsCreate({ config } = {}) {
683
- const { client: request = client, ...requestConfig } = config ?? {};
684
- const data = await request({
685
- method: "POST",
686
- url: `/integrations/vercel/projects`,
687
- ...requestConfig,
688
- headers: {
689
- ...requestConfig.headers
690
- }
691
- });
692
- return data;
693
- }
694
- /**
695
- * @summary Find Projects
696
- * @description Returns a list of all v0 projects in your workspace. Useful for browsing or managing projects across different chats or use cases.
697
- * @link /projects
698
- */ async function projectsFind({ config } = {}) {
699
- const { client: request = client, ...requestConfig } = config ?? {};
700
- const data = await request({
701
- method: "GET",
702
- url: `/projects`,
703
- ...requestConfig,
704
- headers: {
705
- ...requestConfig.headers
706
- }
707
- });
708
- return data;
709
- }
710
- /**
711
- * @summary Create Project
712
- * @description Creates a new v0 project with an optional description, icon, environment variables, and instructions. Projects help organize chats and manage context.
713
- * @link /projects
714
- */ async function projectsCreate({ config } = {}) {
715
- const { client: request = client, ...requestConfig } = config ?? {};
716
- const data = await request({
717
- method: "POST",
718
- url: `/projects`,
719
- ...requestConfig,
720
- headers: {
721
- ...requestConfig.headers
722
- }
723
- });
724
- return data;
725
- }
726
- /**
727
- * @summary Get Project by ID
728
- * @description Retrieves the details of a specific v0 project by its ID.
729
- * @link /projects/{projectId}
730
- */ async function projectsGetById({ pathParams, config } = {}) {
731
- const { client: request = client, ...requestConfig } = config ?? {};
732
- if (!pathParams.projectId) {
733
- throw new Error(`Missing required path parameter: projectId`);
734
- }
735
- const data = await request({
736
- method: "GET",
737
- url: `/projects/${pathParams.projectId}`,
738
- ...requestConfig,
739
- headers: {
740
- ...requestConfig.headers
741
- }
742
- });
743
- return data;
744
- }
745
- /**
746
- * @summary Update Project
747
- * @description Updates the metadata of an existing project using its `projectId`. Supports changes to the project name and privacy setting.
748
- * @link /projects/{projectId}
749
- */ async function projectsUpdate({ pathParams, config } = {}) {
750
- const { client: request = client, ...requestConfig } = config ?? {};
751
- if (!pathParams.projectId) {
752
- throw new Error(`Missing required path parameter: projectId`);
753
- }
754
- const data = await request({
755
- method: "PATCH",
756
- url: `/projects/${pathParams.projectId}`,
757
- ...requestConfig,
758
- headers: {
759
- ...requestConfig.headers
760
- }
761
- });
762
- return data;
763
- }
764
- /**
765
- * @summary Delete Project
766
- * @description Deletes a specific project based on the provided projectId. This operation marks the project as deleted and is irreversible.
767
- * @link /projects/{projectId}
768
- */ async function projectsDelete({ pathParams, queryParams, config } = {}) {
769
- const { client: request = client, ...requestConfig } = config ?? {};
770
- if (!pathParams.projectId) {
771
- throw new Error(`Missing required path parameter: projectId`);
772
- }
773
- const data = await request({
774
- method: "DELETE",
775
- url: `/projects/${pathParams.projectId}`,
776
- queryParams,
777
- ...requestConfig,
778
- headers: {
779
- ...requestConfig.headers
780
- }
781
- });
782
- return data;
783
- }
784
- /**
785
- * @summary Assign Project to Chat
786
- * @description Links an existing v0 project to a specific chat. Helps group conversations under a shared project context.
787
- * @link /projects/{projectId}/assign
788
- */ async function projectsAssign({ pathParams, config } = {}) {
789
- const { client: request = client, ...requestConfig } = config ?? {};
790
- if (!pathParams.projectId) {
791
- throw new Error(`Missing required path parameter: projectId`);
792
- }
793
- const data = await request({
794
- method: "POST",
795
- url: `/projects/${pathParams.projectId}/assign`,
796
- ...requestConfig,
797
- headers: {
798
- ...requestConfig.headers
799
- }
800
- });
801
- return data;
802
- }
803
- /**
804
- * @summary Find Environment Variables
805
- * @description Retrieves all environment variables for a given project.
806
- * @link /projects/{projectId}/env-vars
807
- */ async function projectsFindEnvVars({ pathParams, queryParams, config } = {}) {
808
- const { client: request = client, ...requestConfig } = config ?? {};
809
- if (!pathParams.projectId) {
810
- throw new Error(`Missing required path parameter: projectId`);
811
- }
812
- const data = await request({
813
- method: "GET",
814
- url: `/projects/${pathParams.projectId}/env-vars`,
815
- queryParams,
816
- ...requestConfig,
817
- headers: {
818
- ...requestConfig.headers
819
- }
820
- });
821
- return data;
822
- }
823
- /**
824
- * @summary Create Environment Variables
825
- * @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.
826
- * @link /projects/{projectId}/env-vars
827
- */ async function projectsCreateEnvVars({ pathParams, queryParams, config } = {}) {
828
- const { client: request = client, ...requestConfig } = config ?? {};
829
- if (!pathParams.projectId) {
830
- throw new Error(`Missing required path parameter: projectId`);
831
- }
832
- const data = await request({
833
- method: "POST",
834
- url: `/projects/${pathParams.projectId}/env-vars`,
835
- queryParams,
836
- ...requestConfig,
837
- headers: {
838
- ...requestConfig.headers
839
- }
840
- });
841
- return data;
842
- }
843
- /**
844
- * @summary Update Environment Variables
845
- * @description Updates multiple environment variables for a given project. Only the value of each environment variable can be updated.
846
- * @link /projects/{projectId}/env-vars
847
- */ async function projectsUpdateEnvVars({ pathParams, queryParams, config } = {}) {
848
- const { client: request = client, ...requestConfig } = config ?? {};
849
- if (!pathParams.projectId) {
850
- throw new Error(`Missing required path parameter: projectId`);
851
- }
852
- const data = await request({
853
- method: "PATCH",
854
- url: `/projects/${pathParams.projectId}/env-vars`,
855
- queryParams,
856
- ...requestConfig,
857
- headers: {
858
- ...requestConfig.headers
859
- }
860
- });
861
- return data;
862
- }
863
- /**
864
- * @summary Delete Environment Variables
865
- * @description Deletes multiple environment variables for a given project by their IDs.
866
- * @link /projects/{projectId}/env-vars/delete
867
- */ async function projectsDeleteEnvVars({ pathParams, config } = {}) {
868
- const { client: request = client, ...requestConfig } = config ?? {};
869
- if (!pathParams.projectId) {
870
- throw new Error(`Missing required path parameter: projectId`);
871
- }
872
- const data = await request({
873
- method: "POST",
874
- url: `/projects/${pathParams.projectId}/env-vars/delete`,
875
- ...requestConfig,
876
- headers: {
877
- ...requestConfig.headers
878
- }
879
- });
880
- return data;
881
- }
882
- /**
883
- * @summary Get Environment Variable
884
- * @description Retrieves a specific environment variable for a given project by its ID, including its value.
885
- * @link /projects/{projectId}/env-vars/{environmentVariableId}
886
- */ async function projectsGetEnvVar({ pathParams, queryParams, config } = {}) {
887
- const { client: request = client, ...requestConfig } = config ?? {};
888
- if (!pathParams.projectId) {
889
- throw new Error(`Missing required path parameter: projectId`);
890
- }
891
- if (!pathParams.environmentVariableId) {
892
- throw new Error(`Missing required path parameter: environmentVariableId`);
893
- }
894
- const data = await request({
895
- method: "GET",
896
- url: `/projects/${pathParams.projectId}/env-vars/${pathParams.environmentVariableId}`,
897
- queryParams,
898
- ...requestConfig,
899
- headers: {
900
- ...requestConfig.headers
901
- }
902
- });
903
- return data;
904
- }
905
- /**
906
- * @summary Find Rate Limit
907
- * @description Retrieves rate limit information for a given scope. Useful for monitoring usage limits and avoiding throttling.
908
- * @link /rate-limits
909
- */ async function rateLimitsFind({ queryParams, config } = {}) {
910
- const { client: request = client, ...requestConfig } = config ?? {};
911
- const data = await request({
912
- method: "GET",
913
- url: `/rate-limits`,
914
- queryParams,
915
- ...requestConfig,
916
- headers: {
917
- ...requestConfig.headers
918
- }
919
- });
920
- return data;
921
- }
922
- /**
923
- * @summary Get User
924
- * @description Retrieves information about the authenticated user, including their ID, name, email, and account metadata.
925
- * @link /user
926
- */ async function userGet({ config } = {}) {
927
- const { client: request = client, ...requestConfig } = config ?? {};
928
- const data = await request({
929
- method: "GET",
930
- url: `/user`,
931
- ...requestConfig,
932
- headers: {
933
- ...requestConfig.headers
934
- }
935
- });
936
- return data;
937
- }
938
- /**
939
- * @summary Get Billing
940
- * @description Fetches billing usage and quota information for the authenticated user. Can be scoped to a specific context (e.g. project or namespace).
941
- * @link /user/billing
942
- */ async function userGetBilling({ queryParams, config } = {}) {
943
- const { client: request = client, ...requestConfig } = config ?? {};
944
- const data = await request({
945
- method: "GET",
946
- url: `/user/billing`,
947
- queryParams,
948
- ...requestConfig,
949
- headers: {
950
- ...requestConfig.headers
951
- }
952
- });
953
- return data;
954
- }
955
- /**
956
- * @summary Get Plan
957
- * @description Returns the current subscription plan for the authenticated user, including tier details and feature limits.
958
- * @link /user/plan
959
- */ async function userGetPlan({ config } = {}) {
960
- const { client: request = client, ...requestConfig } = config ?? {};
961
- const data = await request({
962
- method: "GET",
963
- url: `/user/plan`,
964
- ...requestConfig,
965
- headers: {
966
- ...requestConfig.headers
967
- }
968
- });
969
- return data;
970
- }
971
- /**
972
- * @summary Get User Scopes
973
- * @description Retrieves all accessible scopes for the authenticated user, such as personal workspaces or shared teams.
974
- * @link /user/scopes
975
- */ async function userGetScopes({ config } = {}) {
976
- const { client: request = client, ...requestConfig } = config ?? {};
977
- const data = await request({
978
- method: "GET",
979
- url: `/user/scopes`,
980
- ...requestConfig,
981
- headers: {
982
- ...requestConfig.headers
983
- }
984
- });
985
- return data;
986
- }
987
- /**
988
- * @summary Restore Block
989
- * @description Restores a block to a specific version.
990
- * @link /chats/{chatId}/versions/{versionId}/restore
991
- */ async function chatsRestore({ pathParams, config } = {}) {
992
- const { client: request = client, ...requestConfig } = config ?? {};
993
- if (!pathParams.chatId) {
994
- throw new Error(`Missing required path parameter: chatId`);
995
- }
996
- if (!pathParams.versionId) {
997
- throw new Error(`Missing required path parameter: versionId`);
998
- }
999
- const data = await request({
1000
- method: "POST",
1001
- url: `/chats/${pathParams.chatId}/versions/${pathParams.versionId}/restore`,
1002
- ...requestConfig,
1003
- headers: {
1004
- ...requestConfig.headers
1005
- }
1006
- });
1007
- return data;
1008
- }
1009
- /**
1010
- * @summary Get Usage Report
1011
- * @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.
1012
- * @link /reports/usage
1013
- */ async function reportsGetUsage({ queryParams, config } = {}) {
1014
- const { client: request = client, ...requestConfig } = config ?? {};
1015
- const data = await request({
1016
- method: "GET",
1017
- url: `/reports/usage`,
1018
- queryParams,
1019
- ...requestConfig,
1020
- headers: {
1021
- ...requestConfig.headers
1022
- }
1023
- });
1024
- return data;
1025
- }
1026
- /**
1027
- * @summary Get AI Usage Report
1028
- * @description Retrieves v0 AI usage events for the authenticated user or active team scope.
1029
- * @link /reports/usage/ai
1030
- */ async function reportsGetAIUsage({ queryParams, config } = {}) {
1031
- const { client: request = client, ...requestConfig } = config ?? {};
1032
- const data = await request({
1033
- method: "GET",
1034
- url: `/reports/usage/ai`,
1035
- queryParams,
1036
- ...requestConfig,
1037
- headers: {
1038
- ...requestConfig.headers
1039
- }
1040
- });
1041
- return data;
1042
- }
1043
- /**
1044
- * @summary Get User Activity Report
1045
- * @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.
1046
- * @link /reports/user-activity
1047
- */ async function reportsGetUserActivity({ queryParams, config } = {}) {
1048
- const { client: request = client, ...requestConfig } = config ?? {};
1049
- const data = await request({
1050
- method: "GET",
1051
- url: `/reports/user-activity`,
1052
- queryParams,
1053
- ...requestConfig,
1054
- headers: {
1055
- ...requestConfig.headers
1056
- }
1057
- });
1058
- return data;
1059
- }
1060
- /**
1061
- * @summary List MCP Servers
1062
- * @description Retrieves all MCP servers configured for the authenticated user.
1063
- * @link /mcp-servers
1064
- */ async function mcpServersFind({ config } = {}) {
1065
- const { client: request = client, ...requestConfig } = config ?? {};
1066
- const data = await request({
1067
- method: "GET",
1068
- url: `/mcp-servers`,
1069
- ...requestConfig,
1070
- headers: {
1071
- ...requestConfig.headers
1072
- }
1073
- });
1074
- return data;
1075
- }
1076
- /**
1077
- * @summary Create MCP Server
1078
- * @description Creates a new MCP server configuration for the authenticated user. Supports OAuth, bearer token, custom headers, and unauthenticated servers.
1079
- * @link /mcp-servers
1080
- */ async function mcpServersCreate({ config } = {}) {
1081
- const { client: request = client, ...requestConfig } = config ?? {};
1082
- const data = await request({
1083
- method: "POST",
1084
- url: `/mcp-servers`,
1085
- ...requestConfig,
1086
- headers: {
1087
- ...requestConfig.headers
1088
- }
1089
- });
1090
- return data;
1091
- }
1092
- /**
1093
- * @summary Get MCP Server
1094
- * @description Retrieves the details of a specific MCP server by its ID.
1095
- * @link /mcp-servers/{mcpServerId}
1096
- */ async function mcpServersGetById({ pathParams, config } = {}) {
1097
- const { client: request = client, ...requestConfig } = config ?? {};
1098
- if (!pathParams.mcpServerId) {
1099
- throw new Error(`Missing required path parameter: mcpServerId`);
1100
- }
1101
- const data = await request({
1102
- method: "GET",
1103
- url: `/mcp-servers/${pathParams.mcpServerId}`,
1104
- ...requestConfig,
1105
- headers: {
1106
- ...requestConfig.headers
1107
- }
1108
- });
1109
- return data;
1110
- }
1111
- /**
1112
- * @summary Update MCP Server
1113
- * @description Updates the configuration of an existing MCP server, including its name, URL, description, enabled status, and authentication settings.
1114
- * @link /mcp-servers/{mcpServerId}
1115
- */ async function mcpServersUpdate({ pathParams, config } = {}) {
1116
- const { client: request = client, ...requestConfig } = config ?? {};
1117
- if (!pathParams.mcpServerId) {
1118
- throw new Error(`Missing required path parameter: mcpServerId`);
1119
- }
1120
- const data = await request({
1121
- method: "PATCH",
1122
- url: `/mcp-servers/${pathParams.mcpServerId}`,
1123
- ...requestConfig,
1124
- headers: {
1125
- ...requestConfig.headers
1126
- }
1127
- });
1128
- return data;
1129
- }
1130
- /**
1131
- * @summary Delete MCP Server
1132
- * @description Deletes an MCP server based on its ID. This action is irreversible and will also remove any associated OAuth tokens.
1133
- * @link /mcp-servers/{mcpServerId}
1134
- */ async function mcpServersDelete({ pathParams, config } = {}) {
1135
- const { client: request = client, ...requestConfig } = config ?? {};
1136
- if (!pathParams.mcpServerId) {
1137
- throw new Error(`Missing required path parameter: mcpServerId`);
1138
- }
1139
- const data = await request({
1140
- method: "DELETE",
1141
- url: `/mcp-servers/${pathParams.mcpServerId}`,
1142
- ...requestConfig,
1143
- headers: {
1144
- ...requestConfig.headers
1145
- }
1146
- });
1147
- return data;
1148
- }
1149
- /**
1150
- * @summary Create MCP Server OAuth Authorization URL
1151
- * @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.
1152
- * @link /mcp-servers/{mcpServerId}/oauth/authorize
1153
- */ async function mcpServersCreateOAuthAuthorizationUrl({ pathParams, config } = {}) {
1154
- const { client: request = client, ...requestConfig } = config ?? {};
1155
- if (!pathParams.mcpServerId) {
1156
- throw new Error(`Missing required path parameter: mcpServerId`);
1157
- }
1158
- const data = await request({
1159
- method: "POST",
1160
- url: `/mcp-servers/${pathParams.mcpServerId}/oauth/authorize`,
1161
- ...requestConfig,
1162
- headers: {
1163
- ...requestConfig.headers
1164
- }
1165
- });
1166
- return data;
1167
- }
1168
- const operationsByPath = {
1169
- "POST /chats": chatsCreate,
1170
- "GET /chats": chatsFind,
1171
- "POST /chats/init": chatsInit,
1172
- "DELETE /chats/{chatId}": chatsDelete,
1173
- "GET /chats/{chatId}": chatsGetById,
1174
- "PATCH /chats/{chatId}": chatsUpdate,
1175
- "PUT /chats/{chatId}/favorite": chatsFavorite,
1176
- "POST /chats/{chatId}/fork": chatsFork,
1177
- "GET /chats/{chatId}/project": projectsGetByChatId,
1178
- "GET /chats/{chatId}/messages": chatsFindMessages,
1179
- "POST /chats/{chatId}/messages": chatsSendMessage,
1180
- "GET /chats/{chatId}/messages/{messageId}": chatsGetMessage,
1181
- "GET /chats/{chatId}/versions": chatsFindVersions,
1182
- "GET /chats/{chatId}/versions/{versionId}": chatsGetVersion,
1183
- "PATCH /chats/{chatId}/versions/{versionId}": chatsUpdateVersion,
1184
- "GET /chats/{chatId}/versions/{versionId}/download": chatsDownloadVersion,
1185
- "POST /chats/{chatId}/versions/{versionId}/files/delete": chatsDeleteVersionFiles,
1186
- "POST /chats/{chatId}/messages/{messageId}/resume": chatsResume,
1187
- "POST /chats/{chatId}/messages/{messageId}/stop": chatsStop,
1188
- "POST /chats/{chatId}/tasks/resolve": chatsResolveTask,
1189
- "GET /deployments": deploymentsFind,
1190
- "POST /deployments": deploymentsCreate,
1191
- "GET /deployments/{deploymentId}": deploymentsGetById,
1192
- "DELETE /deployments/{deploymentId}": deploymentsDelete,
1193
- "GET /deployments/{deploymentId}/logs": deploymentsFindLogs,
1194
- "GET /deployments/{deploymentId}/errors": deploymentsFindErrors,
1195
- "GET /hooks": hooksFind,
1196
- "POST /hooks": hooksCreate,
1197
- "GET /hooks/{hookId}": hooksGetById,
1198
- "PATCH /hooks/{hookId}": hooksUpdate,
1199
- "DELETE /hooks/{hookId}": hooksDelete,
1200
- "GET /integrations/vercel/projects": integrationsVercelProjectsFind,
1201
- "POST /integrations/vercel/projects": integrationsVercelProjectsCreate,
1202
- "GET /projects": projectsFind,
1203
- "POST /projects": projectsCreate,
1204
- "GET /projects/{projectId}": projectsGetById,
1205
- "PATCH /projects/{projectId}": projectsUpdate,
1206
- "DELETE /projects/{projectId}": projectsDelete,
1207
- "POST /projects/{projectId}/assign": projectsAssign,
1208
- "GET /projects/{projectId}/env-vars": projectsFindEnvVars,
1209
- "POST /projects/{projectId}/env-vars": projectsCreateEnvVars,
1210
- "PATCH /projects/{projectId}/env-vars": projectsUpdateEnvVars,
1211
- "POST /projects/{projectId}/env-vars/delete": projectsDeleteEnvVars,
1212
- "GET /projects/{projectId}/env-vars/{environmentVariableId}": projectsGetEnvVar,
1213
- "GET /rate-limits": rateLimitsFind,
1214
- "GET /user": userGet,
1215
- "GET /user/billing": userGetBilling,
1216
- "GET /user/plan": userGetPlan,
1217
- "GET /user/scopes": userGetScopes,
1218
- "POST /chats/{chatId}/versions/{versionId}/restore": chatsRestore,
1219
- "GET /reports/usage": reportsGetUsage,
1220
- "GET /reports/usage/ai": reportsGetAIUsage,
1221
- "GET /reports/user-activity": reportsGetUserActivity,
1222
- "GET /mcp-servers": mcpServersFind,
1223
- "POST /mcp-servers": mcpServersCreate,
1224
- "GET /mcp-servers/{mcpServerId}": mcpServersGetById,
1225
- "PATCH /mcp-servers/{mcpServerId}": mcpServersUpdate,
1226
- "DELETE /mcp-servers/{mcpServerId}": mcpServersDelete,
1227
- "POST /mcp-servers/{mcpServerId}/oauth/authorize": mcpServersCreateOAuthAuthorizationUrl
1228
- };
1229
- const operationsByTag = {
1230
- chats: {
1231
- chatsCreate,
1232
- chatsFind,
1233
- chatsInit,
1234
- chatsDelete,
1235
- chatsGetById,
1236
- chatsUpdate,
1237
- chatsFavorite,
1238
- chatsFork,
1239
- chatsFindMessages,
1240
- chatsSendMessage,
1241
- chatsGetMessage,
1242
- chatsFindVersions,
1243
- chatsGetVersion,
1244
- chatsUpdateVersion,
1245
- chatsDownloadVersion,
1246
- chatsDeleteVersionFiles,
1247
- chatsResume,
1248
- chatsStop,
1249
- chatsResolveTask,
1250
- chatsRestore
1251
- },
1252
- projects: {
1253
- projectsGetByChatId,
1254
- projectsFind,
1255
- projectsCreate,
1256
- projectsGetById,
1257
- projectsUpdate,
1258
- projectsDelete,
1259
- projectsAssign,
1260
- projectsFindEnvVars,
1261
- projectsCreateEnvVars,
1262
- projectsUpdateEnvVars,
1263
- projectsDeleteEnvVars,
1264
- projectsGetEnvVar
1265
- },
1266
- deployments: {
1267
- deploymentsFind,
1268
- deploymentsCreate,
1269
- deploymentsGetById,
1270
- deploymentsDelete,
1271
- deploymentsFindLogs,
1272
- deploymentsFindErrors
1273
- },
1274
- hooks: {
1275
- hooksFind,
1276
- hooksCreate,
1277
- hooksGetById,
1278
- hooksUpdate,
1279
- hooksDelete
1280
- },
1281
- integrations: {
1282
- integrationsVercelProjectsFind,
1283
- integrationsVercelProjectsCreate
1284
- },
1285
- ratelimits: {
1286
- rateLimitsFind
1287
- },
1288
- user: {
1289
- userGet,
1290
- userGetBilling,
1291
- userGetPlan,
1292
- userGetScopes
1293
- },
1294
- reports: {
1295
- reportsGetUsage,
1296
- reportsGetAIUsage,
1297
- reportsGetUserActivity
1298
- },
1299
- mcpservers: {
1300
- mcpServersFind,
1301
- mcpServersCreate,
1302
- mcpServersGetById,
1303
- mcpServersUpdate,
1304
- mcpServersDelete,
1305
- mcpServersCreateOAuthAuthorizationUrl
1306
- }
1307
- };
3
+ import { o as operationsByTag, a as operationsByPath } from './components-ja14lgg1.js';
1308
4
 
1309
5
  const ApiService = createEffectApi(operationsByTag);
1310
6
  const effectByPath = createEffectByPath(operationsByPath);