berget 0.0.3 → 0.0.4

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.
@@ -0,0 +1,2037 @@
1
+ /**
2
+ * This file was auto-generated by openapi-typescript.
3
+ * Do not make direct changes to the file.
4
+ */
5
+
6
+
7
+ /** OneOf type helpers */
8
+ type Without<T, U> = { [P in Exclude<keyof T, keyof U>]?: never };
9
+ type XOR<T, U> = (T | U) extends object ? (Without<T, U> & U) | (Without<U, T> & T) : T | U;
10
+ type OneOf<T extends any[]> = T extends [infer Only] ? Only : T extends [infer A, infer B, ...infer Rest] ? OneOf<[XOR<A, B>, ...Rest]> : never;
11
+
12
+ export interface paths {
13
+ "/v1/api-keys": {
14
+ /**
15
+ * List all API keys
16
+ * @description Lists all API keys for the authenticated user's organization.
17
+ */
18
+ get: {
19
+ responses: {
20
+ /** @description List of API keys */
21
+ 200: {
22
+ content: {
23
+ "application/json": components["schemas"]["ApiKeyListResponse"];
24
+ };
25
+ };
26
+ /** @description Unauthorized */
27
+ 401: {
28
+ content: never;
29
+ };
30
+ /** @description Server error */
31
+ 500: {
32
+ content: never;
33
+ };
34
+ };
35
+ };
36
+ /**
37
+ * Create a new API key
38
+ * @description Creates a new API key for the authenticated user's organization. The full API key is only returned once at creation time.
39
+ */
40
+ post: {
41
+ requestBody: {
42
+ content: {
43
+ "application/json": components["schemas"]["CreateApiKey"];
44
+ };
45
+ };
46
+ responses: {
47
+ /** @description API key created successfully */
48
+ 201: {
49
+ content: {
50
+ "application/json": components["schemas"]["CreateApiKeyResponse"];
51
+ };
52
+ };
53
+ /** @description Unauthorized */
54
+ 401: {
55
+ content: never;
56
+ };
57
+ /** @description Server error */
58
+ 500: {
59
+ content: never;
60
+ };
61
+ };
62
+ };
63
+ };
64
+ "/v1/api-keys/{id}": {
65
+ /**
66
+ * Delete an API key
67
+ * @description Permanently deletes an API key
68
+ */
69
+ delete: {
70
+ parameters: {
71
+ path: {
72
+ /** @description API key ID */
73
+ id: string;
74
+ };
75
+ };
76
+ responses: {
77
+ /** @description API key deleted successfully */
78
+ 204: {
79
+ content: never;
80
+ };
81
+ /** @description Unauthorized */
82
+ 401: {
83
+ content: never;
84
+ };
85
+ /** @description API key not found */
86
+ 404: {
87
+ content: never;
88
+ };
89
+ /** @description Server error */
90
+ 500: {
91
+ content: never;
92
+ };
93
+ };
94
+ };
95
+ };
96
+ "/v1/api-keys/{id}/rotate": {
97
+ /**
98
+ * Rotate an API key
99
+ * @description Rotates an API key by invalidating the old key and generating a new one. The new key is returned in the response and is only shown once.
100
+ */
101
+ put: {
102
+ parameters: {
103
+ path: {
104
+ /** @description API key ID */
105
+ id: string;
106
+ };
107
+ };
108
+ responses: {
109
+ /** @description API key rotated successfully */
110
+ 200: {
111
+ content: {
112
+ "application/json": components["schemas"]["CreateApiKeyResponse"];
113
+ };
114
+ };
115
+ /** @description Unauthorized */
116
+ 401: {
117
+ content: never;
118
+ };
119
+ /** @description API key not found */
120
+ 404: {
121
+ content: never;
122
+ };
123
+ /** @description Server error */
124
+ 500: {
125
+ content: never;
126
+ };
127
+ };
128
+ };
129
+ };
130
+ "/v1/api-keys/{id}/usage": {
131
+ /**
132
+ * Get API key usage statistics
133
+ * @description Returns usage statistics for a specific API key including request count, daily breakdown, model-specific usage, and token consumption.
134
+ */
135
+ get: {
136
+ parameters: {
137
+ query?: {
138
+ /** @description Start date in YYYY-MM-DD format */
139
+ start_date?: string;
140
+ /** @description End date in YYYY-MM-DD format */
141
+ end_date?: string;
142
+ };
143
+ path: {
144
+ /** @description API key ID */
145
+ id: string;
146
+ };
147
+ };
148
+ responses: {
149
+ /** @description API key usage statistics */
150
+ 200: {
151
+ content: {
152
+ "application/json": components["schemas"]["ApiKeyUsageResponse"];
153
+ };
154
+ };
155
+ /** @description Unauthorized */
156
+ 401: {
157
+ content: never;
158
+ };
159
+ /** @description API key not found */
160
+ 404: {
161
+ content: never;
162
+ };
163
+ /** @description Server error */
164
+ 500: {
165
+ content: never;
166
+ };
167
+ };
168
+ };
169
+ };
170
+ "/v1/apps/templates": {
171
+ /**
172
+ * List app templates
173
+ * @description Retrieves a list of all available application templates that can be installed in your cluster
174
+ */
175
+ get: {
176
+ responses: {
177
+ /** @description List of app templates */
178
+ 200: {
179
+ content: {
180
+ "application/json": components["schemas"]["AppTemplateList"];
181
+ };
182
+ };
183
+ /** @description Unauthorized */
184
+ 401: {
185
+ content: never;
186
+ };
187
+ /** @description Server error */
188
+ 500: {
189
+ content: never;
190
+ };
191
+ };
192
+ };
193
+ };
194
+ "/v1/apps/templates/{appId}": {
195
+ /**
196
+ * Get app template details
197
+ * @description Retrieves detailed information about a specific app template
198
+ */
199
+ get: {
200
+ parameters: {
201
+ path: {
202
+ /** @description App template ID */
203
+ appId: string;
204
+ };
205
+ };
206
+ responses: {
207
+ /** @description App template details */
208
+ 200: {
209
+ content: {
210
+ "application/json": components["schemas"]["AppTemplate"];
211
+ };
212
+ };
213
+ /** @description Unauthorized */
214
+ 401: {
215
+ content: never;
216
+ };
217
+ /** @description App template not found */
218
+ 404: {
219
+ content: never;
220
+ };
221
+ /** @description Server error */
222
+ 500: {
223
+ content: never;
224
+ };
225
+ };
226
+ };
227
+ };
228
+ "/v1/apps/installations": {
229
+ /**
230
+ * List app installations
231
+ * @description Retrieves a list of all installed applications in your clusters
232
+ */
233
+ get: {
234
+ responses: {
235
+ /** @description List of app installations */
236
+ 200: {
237
+ content: {
238
+ "application/json": components["schemas"]["AppInstallationList"];
239
+ };
240
+ };
241
+ /** @description Unauthorized */
242
+ 401: {
243
+ content: never;
244
+ };
245
+ /** @description Server error */
246
+ 500: {
247
+ content: never;
248
+ };
249
+ };
250
+ };
251
+ /**
252
+ * Install an app
253
+ * @description Installs an application from a template into your cluster
254
+ */
255
+ post: {
256
+ requestBody: {
257
+ content: {
258
+ "application/json": components["schemas"]["AppInstallRequest"];
259
+ };
260
+ };
261
+ responses: {
262
+ /** @description App installation initiated */
263
+ 201: {
264
+ content: {
265
+ "application/json": components["schemas"]["AppInstallation"];
266
+ };
267
+ };
268
+ /** @description Invalid request */
269
+ 400: {
270
+ content: never;
271
+ };
272
+ /** @description Unauthorized */
273
+ 401: {
274
+ content: never;
275
+ };
276
+ /** @description App template not found */
277
+ 404: {
278
+ content: never;
279
+ };
280
+ /** @description Server error */
281
+ 500: {
282
+ content: never;
283
+ };
284
+ };
285
+ };
286
+ };
287
+ "/v1/apps/installations/{installationId}": {
288
+ /**
289
+ * Get installation details
290
+ * @description Retrieves detailed information about a specific app installation
291
+ */
292
+ get: {
293
+ parameters: {
294
+ path: {
295
+ /** @description Installation ID */
296
+ installationId: string;
297
+ };
298
+ };
299
+ responses: {
300
+ /** @description Installation details */
301
+ 200: {
302
+ content: {
303
+ "application/json": components["schemas"]["AppInstallation"];
304
+ };
305
+ };
306
+ /** @description Unauthorized */
307
+ 401: {
308
+ content: never;
309
+ };
310
+ /** @description Installation not found */
311
+ 404: {
312
+ content: never;
313
+ };
314
+ /** @description Server error */
315
+ 500: {
316
+ content: never;
317
+ };
318
+ };
319
+ };
320
+ /**
321
+ * Uninstall an app
322
+ * @description Removes an installed application from your cluster
323
+ */
324
+ delete: {
325
+ parameters: {
326
+ path: {
327
+ /** @description Installation ID */
328
+ installationId: string;
329
+ };
330
+ };
331
+ responses: {
332
+ /** @description App uninstallation initiated */
333
+ 204: {
334
+ content: never;
335
+ };
336
+ /** @description Unauthorized */
337
+ 401: {
338
+ content: never;
339
+ };
340
+ /** @description Installation not found */
341
+ 404: {
342
+ content: never;
343
+ };
344
+ /** @description Server error */
345
+ 500: {
346
+ content: never;
347
+ };
348
+ };
349
+ };
350
+ };
351
+ "/v1/auth/login": {
352
+ /**
353
+ * OAuth login
354
+ * @description Initiates OAuth flow for user authentication.
355
+ *
356
+ * If you don't have an account yet, you can create one during the login process
357
+ * by clicking on the "Register" link on the login page.
358
+ *
359
+ * This is the recommended way to authenticate with the Berget AI API.
360
+ */
361
+ get: {
362
+ responses: {
363
+ /** @description Redirects to authentication provider */
364
+ 302: {
365
+ content: never;
366
+ };
367
+ };
368
+ };
369
+ };
370
+ "/v1/auth/callback": {
371
+ /**
372
+ * OAuth callback
373
+ * @description Handles the callback from OAuth authentication. After successful authentication, you'll receive an access token to use for API requests.
374
+ */
375
+ get: {
376
+ parameters: {
377
+ query?: {
378
+ /** @description Authorization code */
379
+ code?: string;
380
+ /** @description State parameter for CSRF protection */
381
+ state?: string;
382
+ };
383
+ };
384
+ responses: {
385
+ /** @description Redirects to frontend with token */
386
+ 302: {
387
+ content: never;
388
+ };
389
+ /** @description Invalid request */
390
+ 400: {
391
+ content: never;
392
+ };
393
+ /** @description Authentication failed */
394
+ 401: {
395
+ content: never;
396
+ };
397
+ };
398
+ };
399
+ };
400
+ "/v1/auth/keycloak": {
401
+ /**
402
+ * Authenticate with OAuth tokens
403
+ * @description Exchange OAuth tokens for our system token
404
+ */
405
+ post: {
406
+ requestBody: {
407
+ content: {
408
+ "application/json": {
409
+ /** @description Subject identifier from authentication provider */
410
+ sub: string;
411
+ /**
412
+ * Format: email
413
+ * @description User's email address
414
+ */
415
+ email: string;
416
+ /** @description User's full name */
417
+ name?: string;
418
+ /** @description User's preferred username */
419
+ preferred_username?: string;
420
+ /** @description OAuth access token */
421
+ access_token: string;
422
+ /** @description OAuth refresh token */
423
+ refresh_token?: string;
424
+ /** @description OAuth ID token */
425
+ id_token?: string;
426
+ };
427
+ };
428
+ };
429
+ responses: {
430
+ /** @description Authentication successful */
431
+ 200: {
432
+ content: {
433
+ "application/json": {
434
+ /** @description JWT token for our system */
435
+ token?: string;
436
+ /** @description User information */
437
+ user?: Record<string, never>;
438
+ };
439
+ };
440
+ };
441
+ /** @description Invalid request */
442
+ 400: {
443
+ content: never;
444
+ };
445
+ /** @description Authentication failed */
446
+ 401: {
447
+ content: never;
448
+ };
449
+ };
450
+ };
451
+ };
452
+ "/v1/auth/register-url": {
453
+ /**
454
+ * Get registration URL
455
+ * @description Returns the URL where users can register a new account.
456
+ * This is the recommended way for new users to create accounts.
457
+ */
458
+ get: {
459
+ responses: {
460
+ /** @description Registration URL */
461
+ 200: {
462
+ content: {
463
+ "application/json": {
464
+ /** @description URL to registration page */
465
+ url?: string;
466
+ };
467
+ };
468
+ };
469
+ };
470
+ };
471
+ };
472
+ "/v1/auth/device": {
473
+ /**
474
+ * Initiate device authorization flow
475
+ * @description Initiates a device authorization flow for CLI tools.
476
+ * Returns a verification URL and device code for the user to complete authentication.
477
+ */
478
+ post: {
479
+ responses: {
480
+ /** @description Device authorization initiated */
481
+ 200: {
482
+ content: {
483
+ "application/json": {
484
+ /** @description URL where the user should go to authenticate */
485
+ verification_url?: string;
486
+ /** @description Code the user should enter on the verification page */
487
+ user_code?: string;
488
+ /** @description Code used by the device to poll for authentication status */
489
+ device_code?: string;
490
+ /** @description Seconds until the device code expires */
491
+ expires_in?: number;
492
+ /** @description Polling interval in seconds */
493
+ interval?: number;
494
+ };
495
+ };
496
+ };
497
+ };
498
+ };
499
+ };
500
+ "/v1/auth/device/token": {
501
+ /**
502
+ * Poll for device authorization token
503
+ * @description Polls for the completion of a device authorization flow.
504
+ * The CLI tool should call this endpoint repeatedly until authentication is complete.
505
+ */
506
+ post: {
507
+ requestBody: {
508
+ content: {
509
+ "application/json": {
510
+ /** @description Device code received from the /device endpoint */
511
+ device_code: string;
512
+ };
513
+ };
514
+ };
515
+ responses: {
516
+ /** @description Authentication successful */
517
+ 200: {
518
+ content: {
519
+ "application/json": {
520
+ /** @description JWT token for API access */
521
+ token?: string;
522
+ /** @description User information */
523
+ user?: Record<string, never>;
524
+ };
525
+ };
526
+ };
527
+ /** @description Invalid request */
528
+ 400: {
529
+ content: never;
530
+ };
531
+ /** @description Authentication pending or failed */
532
+ 401: {
533
+ content: never;
534
+ };
535
+ };
536
+ };
537
+ };
538
+ "/v1/auth/logout": {
539
+ /**
540
+ * Logout
541
+ * @description Redirects to logout endpoint to properly terminate the session.
542
+ * Optionally accepts a redirect_uri query parameter to specify where to redirect after logout.
543
+ */
544
+ get: {
545
+ parameters: {
546
+ query?: {
547
+ /** @description URL to redirect to after logout */
548
+ redirect_uri?: string;
549
+ };
550
+ };
551
+ responses: {
552
+ /** @description Redirects to logout page */
553
+ 302: {
554
+ content: never;
555
+ };
556
+ };
557
+ };
558
+ };
559
+ "/v1/billing/usage": {
560
+ /**
561
+ * Get current usage
562
+ * @description Retrieves current billing period usage metrics and costs. Shows detailed breakdown of API calls, compute resources, and other billable items. This helps you understand your current billing status.
563
+ */
564
+ get: {
565
+ responses: {
566
+ /** @description Current usage metrics */
567
+ 200: {
568
+ content: {
569
+ "application/json": components["schemas"]["Usage"];
570
+ };
571
+ };
572
+ };
573
+ };
574
+ };
575
+ "/v1/billing/invoices": {
576
+ /**
577
+ * List invoices
578
+ * @description Retrieves all invoices for the authenticated user
579
+ */
580
+ get: {
581
+ responses: {
582
+ /** @description List of invoices */
583
+ 200: {
584
+ content: {
585
+ "application/json": {
586
+ invoices?: components["schemas"]["Invoice"][];
587
+ };
588
+ };
589
+ };
590
+ };
591
+ };
592
+ };
593
+ "/v1/billing/invoices/{id}": {
594
+ /**
595
+ * Get invoice details
596
+ * @description Retrieves details for a specific invoice
597
+ */
598
+ get: {
599
+ parameters: {
600
+ path: {
601
+ id: string;
602
+ };
603
+ };
604
+ responses: {
605
+ /** @description Invoice details */
606
+ 200: {
607
+ content: {
608
+ "application/json": components["schemas"]["Invoice"];
609
+ };
610
+ };
611
+ };
612
+ };
613
+ };
614
+ "/v1/billing/payment-methods": {
615
+ /**
616
+ * List payment methods
617
+ * @description Retrieves all payment methods for the authenticated user
618
+ */
619
+ get: {
620
+ responses: {
621
+ /** @description List of payment methods */
622
+ 200: {
623
+ content: {
624
+ "application/json": {
625
+ paymentMethods?: components["schemas"]["PaymentMethod"][];
626
+ };
627
+ };
628
+ };
629
+ };
630
+ };
631
+ /**
632
+ * Add payment method
633
+ * @description Adds a new payment method for the authenticated user
634
+ */
635
+ post: {
636
+ requestBody: {
637
+ content: {
638
+ "application/json": components["schemas"]["CreatePaymentMethod"];
639
+ };
640
+ };
641
+ responses: {
642
+ /** @description Payment method added */
643
+ 201: {
644
+ content: {
645
+ "application/json": components["schemas"]["PaymentMethod"];
646
+ };
647
+ };
648
+ };
649
+ };
650
+ };
651
+ "/v1/billing/payment-methods/{id}": {
652
+ /**
653
+ * Remove payment method
654
+ * @description Removes a payment method for the authenticated user
655
+ */
656
+ delete: {
657
+ parameters: {
658
+ path: {
659
+ id: string;
660
+ };
661
+ };
662
+ responses: {
663
+ /** @description Payment method removed */
664
+ 204: {
665
+ content: never;
666
+ };
667
+ };
668
+ };
669
+ };
670
+ "/v1/billing/subscription": {
671
+ /**
672
+ * Update subscription
673
+ * @description Updates the subscription plan for the authenticated user
674
+ */
675
+ put: {
676
+ requestBody: {
677
+ content: {
678
+ "application/json": components["schemas"]["UpdateSubscription"];
679
+ };
680
+ };
681
+ responses: {
682
+ /** @description Subscription updated */
683
+ 200: {
684
+ content: never;
685
+ };
686
+ };
687
+ };
688
+ };
689
+ "/v1/chat/completions": {
690
+ /**
691
+ * Create a chat completion
692
+ * @description Creates a model response for the given chat conversation.
693
+ *
694
+ * This endpoint is compatible with OpenAI's chat completions API, making it easy to switch between providers.
695
+ *
696
+ * ## Quick Start
697
+ *
698
+ * 1. Get an API key from the dashboard or `/v1/api-keys` endpoint
699
+ * 2. Make a request with your messages:
700
+ *
701
+ * ```json
702
+ * {
703
+ * "model": "berget-70b-instruct",
704
+ * "messages": [
705
+ * {"role": "system", "content": "You are a helpful assistant."},
706
+ * {"role": "user", "content": "Hello!"}
707
+ * ],
708
+ * "temperature": 0.7
709
+ * }
710
+ * ```
711
+ *
712
+ * 3. Process the response which contains the assistant's reply
713
+ *
714
+ * ## Streaming
715
+ *
716
+ * To receive a streaming response, set `stream: true` in your request:
717
+ *
718
+ * ```json
719
+ * {
720
+ * "model": "berget-70b-instruct",
721
+ * "messages": [
722
+ * {"role": "system", "content": "You are a helpful assistant."},
723
+ * {"role": "user", "content": "Write a short story."}
724
+ * ],
725
+ * "stream": true
726
+ * }
727
+ * ```
728
+ *
729
+ * The response will be a stream of server-sent events (SSE), with each event containing a chunk of the response.
730
+ */
731
+ post: {
732
+ requestBody: {
733
+ content: {
734
+ "application/json": components["schemas"]["ChatCompletionRequest"];
735
+ };
736
+ };
737
+ responses: {
738
+ /** @description Successful completion */
739
+ 200: {
740
+ content: {
741
+ "application/json": components["schemas"]["ChatCompletionResponse"];
742
+ };
743
+ };
744
+ /** @description Invalid request */
745
+ 400: {
746
+ content: never;
747
+ };
748
+ /** @description Unauthorized */
749
+ 401: {
750
+ content: never;
751
+ };
752
+ };
753
+ };
754
+ };
755
+ "/v1/clusters": {
756
+ /**
757
+ * List all clusters
758
+ * @description Retrieves a list of all Kubernetes clusters in the customer's namespace
759
+ */
760
+ get: {
761
+ responses: {
762
+ /** @description List of clusters */
763
+ 200: {
764
+ content: {
765
+ "application/json": components["schemas"]["ClusterList"];
766
+ };
767
+ };
768
+ /** @description Unauthorized */
769
+ 401: {
770
+ content: never;
771
+ };
772
+ /** @description Server error */
773
+ 500: {
774
+ content: never;
775
+ };
776
+ };
777
+ };
778
+ };
779
+ "/v1/clusters/usage": {
780
+ /**
781
+ * Get cluster usage
782
+ * @description Retrieves resource usage and cost data across all Kubernetes clusters for the current billing period
783
+ */
784
+ get: {
785
+ responses: {
786
+ /** @description Cluster usage data */
787
+ 200: {
788
+ content: {
789
+ "application/json": components["schemas"]["ClustersUsageResponse"];
790
+ };
791
+ };
792
+ /** @description Unauthorized */
793
+ 401: {
794
+ content: never;
795
+ };
796
+ /** @description Server error */
797
+ 500: {
798
+ content: never;
799
+ };
800
+ };
801
+ };
802
+ };
803
+ "/v1/clusters/{clusterId}/usage": {
804
+ /**
805
+ * Get detailed usage for a specific cluster
806
+ * @description Retrieves detailed resource usage and cost data for a specific Kubernetes cluster
807
+ */
808
+ get: {
809
+ parameters: {
810
+ path: {
811
+ /** @description The cluster identifier */
812
+ clusterId: string;
813
+ };
814
+ };
815
+ responses: {
816
+ /** @description Detailed cluster usage data */
817
+ 200: {
818
+ content: {
819
+ "application/json": components["schemas"]["ClusterDetailedUsage"];
820
+ };
821
+ };
822
+ /** @description Unauthorized */
823
+ 401: {
824
+ content: never;
825
+ };
826
+ /** @description Cluster not found */
827
+ 404: {
828
+ content: never;
829
+ };
830
+ /** @description Server error */
831
+ 500: {
832
+ content: never;
833
+ };
834
+ };
835
+ };
836
+ };
837
+ "/v1/models": {
838
+ /**
839
+ * List available models
840
+ * @description Retrieves a list of all available AI models with their specifications, capabilities, and pricing information. Use this endpoint to discover which models are available for your chat completion API calls.
841
+ */
842
+ get: {
843
+ responses: {
844
+ /** @description List of available models */
845
+ 200: {
846
+ content: {
847
+ "application/json": components["schemas"]["ModelList"];
848
+ };
849
+ };
850
+ /** @description Server error */
851
+ 500: {
852
+ content: never;
853
+ };
854
+ };
855
+ };
856
+ };
857
+ "/v1/models/{modelId}": {
858
+ /**
859
+ * Retrieve model information
860
+ * @description Get detailed information about a specific model
861
+ */
862
+ get: {
863
+ parameters: {
864
+ path: {
865
+ modelId: string;
866
+ };
867
+ };
868
+ responses: {
869
+ /** @description Model details */
870
+ 200: {
871
+ content: {
872
+ "application/json": components["schemas"]["Model"];
873
+ };
874
+ };
875
+ /** @description Model not found */
876
+ 404: {
877
+ content: never;
878
+ };
879
+ /** @description Server error */
880
+ 500: {
881
+ content: never;
882
+ };
883
+ };
884
+ };
885
+ };
886
+ "/v1/usage/tokens": {
887
+ /**
888
+ * Get token usage
889
+ * @description Retrieves token usage data across all models for the current billing period. This helps you track your API usage and associated costs.
890
+ */
891
+ get: {
892
+ responses: {
893
+ /** @description Token usage data */
894
+ 200: {
895
+ content: {
896
+ "application/json": components["schemas"]["TokenUsageResponse"];
897
+ };
898
+ };
899
+ /** @description Unauthorized */
900
+ 401: {
901
+ content: never;
902
+ };
903
+ /** @description Server error */
904
+ 500: {
905
+ content: never;
906
+ };
907
+ };
908
+ };
909
+ };
910
+ "/v1/usage/tokens/{modelId}": {
911
+ /**
912
+ * Get token usage for a specific model
913
+ * @description Retrieves token usage data for a specific model in the current billing period
914
+ */
915
+ get: {
916
+ parameters: {
917
+ path: {
918
+ /** @description The model identifier */
919
+ modelId: string;
920
+ };
921
+ };
922
+ responses: {
923
+ /** @description Model token usage data */
924
+ 200: {
925
+ content: {
926
+ "application/json": components["schemas"]["ModelTokenUsageResponse"];
927
+ };
928
+ };
929
+ /** @description Unauthorized */
930
+ 401: {
931
+ content: never;
932
+ };
933
+ /** @description Model not found */
934
+ 404: {
935
+ content: never;
936
+ };
937
+ /** @description Server error */
938
+ 500: {
939
+ content: never;
940
+ };
941
+ };
942
+ };
943
+ };
944
+ "/v1/users": {
945
+ /**
946
+ * List team members
947
+ * @description Retrieves a list of all users in your organization
948
+ */
949
+ get: {
950
+ responses: {
951
+ /** @description List of team members */
952
+ 200: {
953
+ content: {
954
+ "application/json": components["schemas"]["UserProfile"][];
955
+ };
956
+ };
957
+ /** @description Unauthorized */
958
+ 401: {
959
+ content: {
960
+ "application/json": components["schemas"]["ErrorResponse"];
961
+ };
962
+ };
963
+ /** @description Server error */
964
+ 500: {
965
+ content: {
966
+ "application/json": components["schemas"]["ErrorResponse"];
967
+ };
968
+ };
969
+ };
970
+ };
971
+ };
972
+ "/v1/users/{id}": {
973
+ /**
974
+ * Get user details
975
+ * @description Retrieves details for a specific user
976
+ */
977
+ get: {
978
+ parameters: {
979
+ path: {
980
+ id: string;
981
+ };
982
+ };
983
+ responses: {
984
+ /** @description User details */
985
+ 200: {
986
+ content: {
987
+ "application/json": components["schemas"]["UserProfile"];
988
+ };
989
+ };
990
+ /** @description Unauthorized */
991
+ 401: {
992
+ content: {
993
+ "application/json": components["schemas"]["ErrorResponse"];
994
+ };
995
+ };
996
+ /** @description User not found */
997
+ 404: {
998
+ content: {
999
+ "application/json": components["schemas"]["ErrorResponse"];
1000
+ };
1001
+ };
1002
+ };
1003
+ };
1004
+ /**
1005
+ * Update user
1006
+ * @description Updates an existing user
1007
+ */
1008
+ put: {
1009
+ parameters: {
1010
+ path: {
1011
+ id: string;
1012
+ };
1013
+ };
1014
+ requestBody: {
1015
+ content: {
1016
+ "application/json": components["schemas"]["UpdateUser"];
1017
+ };
1018
+ };
1019
+ responses: {
1020
+ /** @description User updated */
1021
+ 200: {
1022
+ content: {
1023
+ "application/json": components["schemas"]["UserProfile"];
1024
+ };
1025
+ };
1026
+ /** @description Invalid request */
1027
+ 400: {
1028
+ content: {
1029
+ "application/json": components["schemas"]["ErrorResponse"];
1030
+ };
1031
+ };
1032
+ /** @description Unauthorized */
1033
+ 401: {
1034
+ content: {
1035
+ "application/json": components["schemas"]["ErrorResponse"];
1036
+ };
1037
+ };
1038
+ /** @description Forbidden */
1039
+ 403: {
1040
+ content: {
1041
+ "application/json": components["schemas"]["ErrorResponse"];
1042
+ };
1043
+ };
1044
+ };
1045
+ };
1046
+ /**
1047
+ * Delete user
1048
+ * @description Deletes your own user account
1049
+ */
1050
+ delete: {
1051
+ parameters: {
1052
+ path: {
1053
+ id: string;
1054
+ };
1055
+ };
1056
+ responses: {
1057
+ /** @description User deleted */
1058
+ 204: {
1059
+ content: never;
1060
+ };
1061
+ /** @description Unauthorized */
1062
+ 401: {
1063
+ content: {
1064
+ "application/json": components["schemas"]["ErrorResponse"];
1065
+ };
1066
+ };
1067
+ /** @description Cannot delete other users */
1068
+ 403: {
1069
+ content: {
1070
+ "application/json": components["schemas"]["ErrorResponse"];
1071
+ };
1072
+ };
1073
+ };
1074
+ };
1075
+ };
1076
+ "/v1/users/me": {
1077
+ /**
1078
+ * Get current user profile
1079
+ * @description Retrieves the profile of the currently authenticated user
1080
+ */
1081
+ get: {
1082
+ responses: {
1083
+ /** @description User profile */
1084
+ 200: {
1085
+ content: {
1086
+ "application/json": components["schemas"]["UserProfile"];
1087
+ };
1088
+ };
1089
+ /** @description Unauthorized */
1090
+ 401: {
1091
+ content: {
1092
+ "application/json": components["schemas"]["ErrorResponse"];
1093
+ };
1094
+ };
1095
+ };
1096
+ };
1097
+ };
1098
+ "/v1/users/invite": {
1099
+ /**
1100
+ * Invite team member
1101
+ * @description Invites a new team member to join your organization. They will receive an email with instructions to set up their account.
1102
+ */
1103
+ post: {
1104
+ requestBody: {
1105
+ content: {
1106
+ "application/json": components["schemas"]["InviteUser"];
1107
+ };
1108
+ };
1109
+ responses: {
1110
+ /** @description Invitation sent successfully */
1111
+ 200: {
1112
+ content: never;
1113
+ };
1114
+ /** @description Unauthorized */
1115
+ 401: {
1116
+ content: never;
1117
+ };
1118
+ /** @description Forbidden - insufficient permissions */
1119
+ 403: {
1120
+ content: never;
1121
+ };
1122
+ };
1123
+ };
1124
+ };
1125
+ }
1126
+
1127
+ export type webhooks = Record<string, never>;
1128
+
1129
+ export interface components {
1130
+ schemas: {
1131
+ ApiKey: {
1132
+ /** @description Unique identifier for the API key */
1133
+ id: number;
1134
+ /** @description Name of the API key */
1135
+ name: string;
1136
+ /** @description Description of the API key */
1137
+ description: string | null;
1138
+ /** @description Whether the API key is active */
1139
+ active: boolean;
1140
+ /**
1141
+ * Format: date-time
1142
+ * @description Creation timestamp
1143
+ */
1144
+ created: string;
1145
+ /**
1146
+ * Format: date-time
1147
+ * @description Last modification timestamp
1148
+ */
1149
+ modified: string;
1150
+ /**
1151
+ * Format: date-time
1152
+ * @description Last usage timestamp
1153
+ */
1154
+ lastUsed: string | null;
1155
+ /** @description API key prefix (for display purposes) */
1156
+ prefix: string;
1157
+ };
1158
+ ApiKeyResponse: {
1159
+ /** @description Unique identifier for the API key */
1160
+ id: number;
1161
+ /** @description Name of the API key */
1162
+ name: string;
1163
+ /** @description Description of the API key */
1164
+ description: string | null;
1165
+ /** @description Whether the API key is active */
1166
+ active: boolean;
1167
+ /**
1168
+ * Format: date-time
1169
+ * @description Creation timestamp
1170
+ */
1171
+ created: string;
1172
+ /**
1173
+ * Format: date-time
1174
+ * @description Last modification timestamp
1175
+ */
1176
+ modified: string;
1177
+ /**
1178
+ * Format: date-time
1179
+ * @description Last usage timestamp
1180
+ */
1181
+ lastUsed: string | null;
1182
+ /** @description API key prefix (for display purposes) */
1183
+ prefix: string;
1184
+ };
1185
+ CreateApiKey: {
1186
+ /** @description Name of the API key */
1187
+ name: string;
1188
+ /** @description Description of the API key */
1189
+ description?: string;
1190
+ };
1191
+ CreateApiKeyResponse: {
1192
+ /** @description Unique identifier for the API key */
1193
+ id: number;
1194
+ /** @description Name of the API key */
1195
+ name: string;
1196
+ /** @description Description of the API key */
1197
+ description: string | null;
1198
+ /** @description The API key - only returned once at creation */
1199
+ key: string;
1200
+ /**
1201
+ * Format: date-time
1202
+ * @description Creation timestamp
1203
+ */
1204
+ created: string;
1205
+ };
1206
+ ApiKeyUsageEntry: {
1207
+ /** @description Date in YYYY-MM-DD format */
1208
+ date: string;
1209
+ /** @description Number of requests on this date */
1210
+ count: number;
1211
+ };
1212
+ ApiKeyModelUsage: {
1213
+ /** @description Model identifier */
1214
+ id: string;
1215
+ /** @description Model display name */
1216
+ name: string;
1217
+ /** @description Total number of requests to this model */
1218
+ requests: number;
1219
+ /** @description Token usage statistics */
1220
+ tokens: {
1221
+ /** @description Total input tokens */
1222
+ input: number;
1223
+ /** @description Total output tokens */
1224
+ output: number;
1225
+ /** @description Total tokens (input + output) */
1226
+ total: number;
1227
+ };
1228
+ };
1229
+ ApiKeyUsageResponse: {
1230
+ /** @description API key ID */
1231
+ id: number;
1232
+ /** @description API key name */
1233
+ name: string;
1234
+ /** @description Request statistics */
1235
+ requests: {
1236
+ /** @description Total number of requests */
1237
+ total: number;
1238
+ /** @description Daily request counts */
1239
+ daily: components["schemas"]["ApiKeyUsageEntry"][];
1240
+ };
1241
+ /** @description Usage statistics per model */
1242
+ models: components["schemas"]["ApiKeyModelUsage"][];
1243
+ /** @description Time period for the usage data */
1244
+ period: {
1245
+ /** @description Start date of the period (YYYY-MM-DD) */
1246
+ start: string;
1247
+ /** @description End date of the period (YYYY-MM-DD) */
1248
+ end: string;
1249
+ };
1250
+ };
1251
+ ApiKeyListResponse: components["schemas"]["ApiKey"][];
1252
+ AppTemplate: {
1253
+ /** @description Unique identifier for the app */
1254
+ id: string;
1255
+ /** @description Display name of the app */
1256
+ name: string;
1257
+ /** @description Category the app belongs to */
1258
+ category: string;
1259
+ /** @description Short description of the app */
1260
+ description: string;
1261
+ /** @description Number of installations */
1262
+ installs: string;
1263
+ /** @description User rating */
1264
+ rating: number;
1265
+ /** @description Icon identifier */
1266
+ icon: string;
1267
+ /** @description List of key features */
1268
+ features: string[];
1269
+ /** @description Resource requirements */
1270
+ requirements: {
1271
+ /** @description Required CPU cores */
1272
+ cpu: number;
1273
+ /** @description Required memory in GB */
1274
+ memory: number;
1275
+ /** @description Required storage in GB */
1276
+ storage: number;
1277
+ };
1278
+ /** @description Configuration options */
1279
+ configuration: OneOf<[{
1280
+ /** @description Configuration field name */
1281
+ name: string;
1282
+ /**
1283
+ * @description String input type
1284
+ * @enum {string}
1285
+ */
1286
+ type: "string";
1287
+ /** @description Whether this field is required */
1288
+ required: boolean;
1289
+ /** @description Default value if any */
1290
+ default?: string;
1291
+ }, {
1292
+ /** @description Configuration field name */
1293
+ name: string;
1294
+ /**
1295
+ * @description Number input type
1296
+ * @enum {string}
1297
+ */
1298
+ type: "number";
1299
+ /** @description Whether this field is required */
1300
+ required: boolean;
1301
+ /** @description Default value if any */
1302
+ default?: number;
1303
+ }, {
1304
+ /** @description Configuration field name */
1305
+ name: string;
1306
+ /**
1307
+ * @description Boolean toggle type
1308
+ * @enum {string}
1309
+ */
1310
+ type: "boolean";
1311
+ /** @description Whether this field is required */
1312
+ required: boolean;
1313
+ /** @description Default value if any */
1314
+ default?: boolean;
1315
+ }, {
1316
+ /** @description Configuration field name */
1317
+ name: string;
1318
+ /**
1319
+ * @description Dropdown select type
1320
+ * @enum {string}
1321
+ */
1322
+ type: "select";
1323
+ /** @description Whether this field is required */
1324
+ required: boolean;
1325
+ /** @description Default selected option */
1326
+ default?: string;
1327
+ /** @description Available options to select from */
1328
+ options: string[];
1329
+ }, {
1330
+ /** @description Configuration field name */
1331
+ name: string;
1332
+ /**
1333
+ * @description Password input type
1334
+ * @enum {string}
1335
+ */
1336
+ type: "password";
1337
+ /** @description Whether this field is required */
1338
+ required: boolean;
1339
+ /** @description Default value if any */
1340
+ default?: string;
1341
+ }]>[];
1342
+ /** @description Ingress configuration if applicable */
1343
+ ingress?: {
1344
+ /** @description Whether ingress is enabled for this app */
1345
+ enabled: boolean;
1346
+ /** @description Hostname pattern for the ingress */
1347
+ hostname: string;
1348
+ /** @description Path for the ingress */
1349
+ path: string;
1350
+ /** @description Whether TLS is enabled */
1351
+ tls: boolean;
1352
+ };
1353
+ };
1354
+ AppTemplateList: {
1355
+ data: {
1356
+ /** @description Unique identifier for the app */
1357
+ id: string;
1358
+ /** @description Display name of the app */
1359
+ name: string;
1360
+ /** @description Category the app belongs to */
1361
+ category: string;
1362
+ /** @description Short description of the app */
1363
+ description: string;
1364
+ /** @description Number of installations */
1365
+ installs: string;
1366
+ /** @description User rating */
1367
+ rating: number;
1368
+ /** @description Icon identifier */
1369
+ icon: string;
1370
+ /** @description List of key features */
1371
+ features: string[];
1372
+ /** @description Resource requirements */
1373
+ requirements: {
1374
+ /** @description Required CPU cores */
1375
+ cpu: number;
1376
+ /** @description Required memory in GB */
1377
+ memory: number;
1378
+ /** @description Required storage in GB */
1379
+ storage: number;
1380
+ };
1381
+ /** @description Configuration options */
1382
+ configuration: OneOf<[{
1383
+ /** @description Configuration field name */
1384
+ name: string;
1385
+ /**
1386
+ * @description String input type
1387
+ * @enum {string}
1388
+ */
1389
+ type: "string";
1390
+ /** @description Whether this field is required */
1391
+ required: boolean;
1392
+ /** @description Default value if any */
1393
+ default?: string;
1394
+ }, {
1395
+ /** @description Configuration field name */
1396
+ name: string;
1397
+ /**
1398
+ * @description Number input type
1399
+ * @enum {string}
1400
+ */
1401
+ type: "number";
1402
+ /** @description Whether this field is required */
1403
+ required: boolean;
1404
+ /** @description Default value if any */
1405
+ default?: number;
1406
+ }, {
1407
+ /** @description Configuration field name */
1408
+ name: string;
1409
+ /**
1410
+ * @description Boolean toggle type
1411
+ * @enum {string}
1412
+ */
1413
+ type: "boolean";
1414
+ /** @description Whether this field is required */
1415
+ required: boolean;
1416
+ /** @description Default value if any */
1417
+ default?: boolean;
1418
+ }, {
1419
+ /** @description Configuration field name */
1420
+ name: string;
1421
+ /**
1422
+ * @description Dropdown select type
1423
+ * @enum {string}
1424
+ */
1425
+ type: "select";
1426
+ /** @description Whether this field is required */
1427
+ required: boolean;
1428
+ /** @description Default selected option */
1429
+ default?: string;
1430
+ /** @description Available options to select from */
1431
+ options: string[];
1432
+ }, {
1433
+ /** @description Configuration field name */
1434
+ name: string;
1435
+ /**
1436
+ * @description Password input type
1437
+ * @enum {string}
1438
+ */
1439
+ type: "password";
1440
+ /** @description Whether this field is required */
1441
+ required: boolean;
1442
+ /** @description Default value if any */
1443
+ default?: string;
1444
+ }]>[];
1445
+ /** @description Ingress configuration if applicable */
1446
+ ingress?: {
1447
+ /** @description Whether ingress is enabled for this app */
1448
+ enabled: boolean;
1449
+ /** @description Hostname pattern for the ingress */
1450
+ hostname: string;
1451
+ /** @description Path for the ingress */
1452
+ path: string;
1453
+ /** @description Whether TLS is enabled */
1454
+ tls: boolean;
1455
+ };
1456
+ }[];
1457
+ /** @enum {string} */
1458
+ object: "list";
1459
+ };
1460
+ AppInstallRequest: {
1461
+ /** @description ID of the app to install */
1462
+ appId: string;
1463
+ /** @description Kubernetes namespace to install into */
1464
+ namespace: string;
1465
+ /** @description Configuration values */
1466
+ configuration: {
1467
+ [key: string]: string | number | boolean;
1468
+ };
1469
+ };
1470
+ AppInstallation: {
1471
+ /** @description Installation ID */
1472
+ id: string;
1473
+ /** @description App template ID */
1474
+ appId: string;
1475
+ /** @description App name */
1476
+ name: string;
1477
+ /** @description Kubernetes namespace */
1478
+ namespace: string;
1479
+ /**
1480
+ * @description Installation status
1481
+ * @enum {string}
1482
+ */
1483
+ status: "pending" | "installing" | "running" | "failed";
1484
+ /** @description Creation timestamp */
1485
+ created: string;
1486
+ /** @description Status message or error */
1487
+ message?: string;
1488
+ /** @description Access URL if available */
1489
+ url?: string;
1490
+ /** @description Applied configuration */
1491
+ configuration: {
1492
+ [key: string]: string | number | boolean;
1493
+ };
1494
+ };
1495
+ AppInstallationList: {
1496
+ data: ({
1497
+ /** @description Installation ID */
1498
+ id: string;
1499
+ /** @description App template ID */
1500
+ appId: string;
1501
+ /** @description App name */
1502
+ name: string;
1503
+ /** @description Kubernetes namespace */
1504
+ namespace: string;
1505
+ /**
1506
+ * @description Installation status
1507
+ * @enum {string}
1508
+ */
1509
+ status: "pending" | "installing" | "running" | "failed";
1510
+ /** @description Creation timestamp */
1511
+ created: string;
1512
+ /** @description Status message or error */
1513
+ message?: string;
1514
+ /** @description Access URL if available */
1515
+ url?: string;
1516
+ /** @description Applied configuration */
1517
+ configuration: {
1518
+ [key: string]: string | number | boolean;
1519
+ };
1520
+ })[];
1521
+ /** @enum {string} */
1522
+ object: "list";
1523
+ };
1524
+ AuthToken: {
1525
+ accessToken: string;
1526
+ /** @enum {string} */
1527
+ tokenType: "Bearer";
1528
+ expiresIn: number;
1529
+ user?: {
1530
+ id: string;
1531
+ name: string;
1532
+ /** Format: email */
1533
+ email: string;
1534
+ };
1535
+ };
1536
+ User: {
1537
+ id: string;
1538
+ login: string;
1539
+ name: string | null;
1540
+ /** Format: email */
1541
+ email: string | null;
1542
+ /** Format: uri */
1543
+ avatarUrl: string;
1544
+ };
1545
+ Usage: {
1546
+ current_period: {
1547
+ /** Format: date-time */
1548
+ start_date: string;
1549
+ /** Format: date-time */
1550
+ end_date: string;
1551
+ };
1552
+ metrics: {
1553
+ name: string;
1554
+ value: number;
1555
+ unit: string;
1556
+ cost: number;
1557
+ currency: string;
1558
+ }[];
1559
+ total: {
1560
+ amount: number;
1561
+ currency: string;
1562
+ };
1563
+ };
1564
+ Invoice: {
1565
+ id: string;
1566
+ number: string;
1567
+ /** Format: date-time */
1568
+ issuingDate: string;
1569
+ /** @enum {string} */
1570
+ paymentStatus: "pending" | "succeeded" | "failed";
1571
+ amount: number;
1572
+ currency: string;
1573
+ customerId: string;
1574
+ customer: {
1575
+ id: string;
1576
+ name: string;
1577
+ /** Format: email */
1578
+ email: string;
1579
+ /** Format: date-time */
1580
+ createdAt: string;
1581
+ };
1582
+ };
1583
+ PaymentMethod: {
1584
+ id: string;
1585
+ /** @enum {string} */
1586
+ type: "card" | "sepa";
1587
+ last4: string;
1588
+ expMonth?: number;
1589
+ expYear?: number;
1590
+ brand?: string;
1591
+ isDefault: boolean;
1592
+ };
1593
+ CreatePaymentMethod: {
1594
+ /** @enum {string} */
1595
+ type: "card" | "sepa";
1596
+ token: string;
1597
+ setDefault?: boolean;
1598
+ };
1599
+ UpdateSubscription: {
1600
+ planId: string;
1601
+ quantity?: number;
1602
+ };
1603
+ ChatMessage: {
1604
+ /**
1605
+ * @default user
1606
+ * @enum {string}
1607
+ */
1608
+ role?: "system" | "user" | "assistant";
1609
+ content: string;
1610
+ };
1611
+ ChatCompletionRequest: {
1612
+ model: string;
1613
+ messages: components["schemas"]["ChatMessage"][];
1614
+ temperature?: number;
1615
+ /** @default 4096 */
1616
+ max_tokens?: number;
1617
+ /** @default false */
1618
+ stream?: boolean;
1619
+ /** @default 1 */
1620
+ top_p?: number;
1621
+ };
1622
+ ChatCompletionResponse: {
1623
+ /** @description Unique identifier for this completion */
1624
+ id: string;
1625
+ /** @enum {string} */
1626
+ object: "chat.completion";
1627
+ /** @description Unix timestamp of when the completion was created */
1628
+ created: number;
1629
+ /** @description The model used for completion */
1630
+ model: string;
1631
+ choices: ({
1632
+ message: {
1633
+ /** @enum {string} */
1634
+ role: "assistant";
1635
+ /** @description The model's response */
1636
+ content: string;
1637
+ };
1638
+ /** @enum {string} */
1639
+ finish_reason: "stop" | "length" | "content_filter";
1640
+ index: number;
1641
+ })[];
1642
+ usage: {
1643
+ prompt_tokens: number;
1644
+ completion_tokens: number;
1645
+ total_tokens: number;
1646
+ };
1647
+ };
1648
+ Cluster: {
1649
+ /** @description Unique identifier for the cluster */
1650
+ id: string;
1651
+ /** @description Display name of the cluster */
1652
+ name: string;
1653
+ /** @description Cloud provider (AWS, GCP, Azure, etc.) */
1654
+ provider: string;
1655
+ /** @description Cloud region where the cluster is deployed */
1656
+ region: string;
1657
+ /** @description Kubernetes version */
1658
+ version: string;
1659
+ /** @description Number of nodes in the cluster */
1660
+ nodes: number;
1661
+ /**
1662
+ * @description Current status of the cluster
1663
+ * @enum {string}
1664
+ */
1665
+ status: "healthy" | "degraded" | "unhealthy" | "unknown";
1666
+ /**
1667
+ * Format: date-time
1668
+ * @description Creation timestamp
1669
+ */
1670
+ created: string;
1671
+ };
1672
+ ClusterList: {
1673
+ data: components["schemas"]["Cluster"][];
1674
+ /** @enum {string} */
1675
+ object: "list";
1676
+ };
1677
+ ResourceMetric: {
1678
+ /** @description Total allocated resources */
1679
+ allocated: number;
1680
+ /** @description Currently used resources */
1681
+ used: number;
1682
+ /** @description Available resources */
1683
+ available: number;
1684
+ /** @description Unit of measurement (e.g., cores, GB) */
1685
+ unit: string;
1686
+ };
1687
+ /** @description Cost breakdown */
1688
+ ClusterCost: {
1689
+ /** @description Cost for CPU resources */
1690
+ cpu: number;
1691
+ /** @description Cost for memory resources */
1692
+ memory: number;
1693
+ /** @description Cost for storage resources */
1694
+ storage: number;
1695
+ /** @description Cost for network resources */
1696
+ network: number;
1697
+ /** @description Total cost */
1698
+ total: number;
1699
+ /** @description Currency code (e.g., USD, EUR) */
1700
+ currency: string;
1701
+ };
1702
+ ClusterUsage: {
1703
+ /** @description Unique cluster identifier */
1704
+ id: string;
1705
+ /** @description Cluster name */
1706
+ name: string;
1707
+ /** @description Resource usage metrics */
1708
+ resources: {
1709
+ cpu: components["schemas"]["ResourceMetric"];
1710
+ memory: components["schemas"]["ResourceMetric"];
1711
+ storage: components["schemas"]["ResourceMetric"];
1712
+ };
1713
+ cost: components["schemas"]["ClusterCost"];
1714
+ /** @description Number of nodes in the cluster */
1715
+ nodes: number;
1716
+ /** @description Current cluster status */
1717
+ status: string;
1718
+ };
1719
+ ResourceMetricWithTrend: components["schemas"]["ResourceMetric"] & {
1720
+ /** @description Historical usage trend data */
1721
+ usage_trend: {
1722
+ /** @description Date in YYYY-MM-DD format */
1723
+ date: string;
1724
+ /** @description Resource usage value for this date */
1725
+ value: number;
1726
+ }[];
1727
+ };
1728
+ DailyCost: {
1729
+ /** @description Date in YYYY-MM-DD format */
1730
+ date: string;
1731
+ /** @description CPU cost for this day */
1732
+ cpu: number;
1733
+ /** @description Memory cost for this day */
1734
+ memory: number;
1735
+ /** @description Storage cost for this day */
1736
+ storage: number;
1737
+ /** @description Network cost for this day */
1738
+ network: number;
1739
+ /** @description Total cost for this day */
1740
+ total: number;
1741
+ };
1742
+ /** @description Detailed cost breakdown with daily data */
1743
+ ClusterCostWithDaily: components["schemas"]["ClusterCost"] & {
1744
+ /** @description Daily cost breakdown */
1745
+ daily: components["schemas"]["DailyCost"][];
1746
+ };
1747
+ ClusterDetailedUsage: {
1748
+ /** @description Unique cluster identifier */
1749
+ id: string;
1750
+ /** @description Cluster name */
1751
+ name: string;
1752
+ /** @description Detailed resource usage metrics with trends */
1753
+ resources: {
1754
+ cpu: components["schemas"]["ResourceMetricWithTrend"];
1755
+ memory: components["schemas"]["ResourceMetricWithTrend"];
1756
+ storage: components["schemas"]["ResourceMetricWithTrend"];
1757
+ };
1758
+ cost: components["schemas"]["ClusterCostWithDaily"];
1759
+ /** @description Number of nodes in the cluster */
1760
+ nodes: number;
1761
+ /** @description Current cluster status */
1762
+ status: string;
1763
+ /** @description Time period for the usage data */
1764
+ period: {
1765
+ /** @description Start date of the period (YYYY-MM-DD) */
1766
+ start: string;
1767
+ /** @description End date of the period (YYYY-MM-DD) */
1768
+ end: string;
1769
+ };
1770
+ };
1771
+ ClustersUsageResponse: {
1772
+ /** @description List of clusters with usage data */
1773
+ clusters: components["schemas"]["ClusterUsage"][];
1774
+ /** @description Time period for the usage data */
1775
+ period: {
1776
+ /** @description Start date of the period (YYYY-MM-DD) */
1777
+ start: string;
1778
+ /** @description End date of the period (YYYY-MM-DD) */
1779
+ end: string;
1780
+ };
1781
+ /** @description Aggregated totals */
1782
+ total: {
1783
+ /** @description Total cost breakdown across all clusters */
1784
+ cost: {
1785
+ /** @description Total CPU cost across all clusters */
1786
+ cpu: number;
1787
+ /** @description Total memory cost across all clusters */
1788
+ memory: number;
1789
+ /** @description Total storage cost across all clusters */
1790
+ storage: number;
1791
+ /** @description Total network cost across all clusters */
1792
+ network: number;
1793
+ /** @description Total cost across all clusters */
1794
+ total: number;
1795
+ /** @description Currency code (e.g., USD, EUR) */
1796
+ currency: string;
1797
+ };
1798
+ };
1799
+ };
1800
+ /** @description Pricing information for the model */
1801
+ ModelPricing: {
1802
+ /** @description Cost per token for input in the specified currency */
1803
+ input: number;
1804
+ /** @description Cost per token for output in the specified currency */
1805
+ output: number;
1806
+ /** @description The unit of pricing (e.g., "token") */
1807
+ unit: string;
1808
+ /** @description The currency of the pricing (e.g., "USD") */
1809
+ currency: string;
1810
+ };
1811
+ /** @description Model capabilities */
1812
+ ModelCapabilities: {
1813
+ /** @description Whether the model supports vision/image input */
1814
+ vision: boolean;
1815
+ /** @description Whether the model supports function calling */
1816
+ function_calling: boolean;
1817
+ /** @description Whether the model supports JSON mode */
1818
+ json_mode: boolean;
1819
+ };
1820
+ Model: {
1821
+ /** @description Unique identifier for the model */
1822
+ id: string;
1823
+ /**
1824
+ * @description Object type
1825
+ * @enum {string}
1826
+ */
1827
+ object: "model";
1828
+ /** @description Unix timestamp of when the model was created */
1829
+ created: number;
1830
+ /** @description Organization that owns the model */
1831
+ owned_by: string;
1832
+ pricing: components["schemas"]["ModelPricing"];
1833
+ capabilities: components["schemas"]["ModelCapabilities"];
1834
+ };
1835
+ ModelList: {
1836
+ data: components["schemas"]["Model"][];
1837
+ /** @enum {string} */
1838
+ object: "list";
1839
+ };
1840
+ /** @description Cost information for this usage */
1841
+ TokenCost: {
1842
+ /** @description Cost amount */
1843
+ amount: number;
1844
+ /** @description Currency code (e.g., USD, EUR) */
1845
+ currency: string;
1846
+ };
1847
+ DailyTokenUsage: {
1848
+ /** @description Usage date in YYYY-MM-DD format */
1849
+ date: string;
1850
+ /** @description Model identifier */
1851
+ model?: string;
1852
+ /** @description Number of input tokens used */
1853
+ input_tokens: number;
1854
+ /** @description Number of output tokens generated */
1855
+ output_tokens: number;
1856
+ /** @description Total tokens (input + output) */
1857
+ total_tokens: number;
1858
+ cost: components["schemas"]["TokenCost"];
1859
+ };
1860
+ /** @description Aggregated usage totals */
1861
+ TokenUsageTotal: {
1862
+ /** @description Total input tokens for the period */
1863
+ input_tokens: number;
1864
+ /** @description Total output tokens for the period */
1865
+ output_tokens: number;
1866
+ /** @description Total tokens for the period */
1867
+ total_tokens: number;
1868
+ cost: components["schemas"]["TokenCost"];
1869
+ };
1870
+ /** @description Time period for the usage data */
1871
+ TokenUsagePeriod: {
1872
+ /** @description Start date of the period (YYYY-MM-DD) */
1873
+ start: string;
1874
+ /** @description End date of the period (YYYY-MM-DD) */
1875
+ end: string;
1876
+ };
1877
+ TokenUsageResponse: {
1878
+ /** @description Daily token usage data */
1879
+ usage: components["schemas"]["DailyTokenUsage"][];
1880
+ total: components["schemas"]["TokenUsageTotal"];
1881
+ period: components["schemas"]["TokenUsagePeriod"];
1882
+ };
1883
+ ModelTokenUsageResponse: {
1884
+ /** @description Model identifier */
1885
+ model: string;
1886
+ /** @description Daily token usage data */
1887
+ usage: components["schemas"]["DailyTokenUsage"][];
1888
+ total: components["schemas"]["TokenUsageTotal"];
1889
+ period: components["schemas"]["TokenUsagePeriod"];
1890
+ };
1891
+ /** @description Complete user profile including company details */
1892
+ UserProfile: {
1893
+ /** @description Unique identifier for the user */
1894
+ id: string;
1895
+ /**
1896
+ * Format: email
1897
+ * @description User's email address
1898
+ */
1899
+ email: string;
1900
+ /** @description Full name of the user */
1901
+ name: string;
1902
+ /** @description Contact phone number */
1903
+ phone: string | null;
1904
+ /** @description ID of the company the user belongs to */
1905
+ company_id: number;
1906
+ /** @description Username for login */
1907
+ login: string;
1908
+ /**
1909
+ * @description User role determining permissions
1910
+ * @enum {string}
1911
+ */
1912
+ role: "admin" | "member";
1913
+ /** @description Whether the user account is active */
1914
+ active: boolean | null;
1915
+ /**
1916
+ * Format: date-time
1917
+ * @description When the user was created
1918
+ */
1919
+ createdAt: string | null;
1920
+ /**
1921
+ * Format: date-time
1922
+ * @description Last update timestamp
1923
+ */
1924
+ updatedAt: string | null;
1925
+ /** @description User preferences and settings */
1926
+ settings?: {
1927
+ /** @description Email notification preferences */
1928
+ notifications: boolean;
1929
+ /** @description User's preferred timezone */
1930
+ timezone: string;
1931
+ /** @description Preferred interface language */
1932
+ language?: string;
1933
+ /**
1934
+ * @description UI theme preference
1935
+ * @enum {string}
1936
+ */
1937
+ theme?: "light" | "dark" | "system";
1938
+ };
1939
+ /** @description Associated company details */
1940
+ company?: {
1941
+ /** @description Company unique identifier */
1942
+ id: number;
1943
+ /** @description Legal company name */
1944
+ name: string;
1945
+ /** @description VAT identification number */
1946
+ vat: string;
1947
+ /**
1948
+ * Format: email
1949
+ * @description Company email address
1950
+ */
1951
+ email: string;
1952
+ /** @description Company phone number */
1953
+ phone: string | null;
1954
+ /** @description Street address */
1955
+ street: string | null;
1956
+ /** @description City */
1957
+ city: string | null;
1958
+ /** @description Company country information */
1959
+ country: {
1960
+ /** @description Country ID */
1961
+ id: number;
1962
+ /** @description Country name */
1963
+ name: string;
1964
+ /** @description ISO country code */
1965
+ code: string;
1966
+ } | null;
1967
+ };
1968
+ };
1969
+ CreateUser: {
1970
+ name: string;
1971
+ /** Format: email */
1972
+ email: string;
1973
+ phone: string | null;
1974
+ company_id: number;
1975
+ /** @enum {string} */
1976
+ role: "admin" | "member";
1977
+ settings?: {
1978
+ notifications: boolean;
1979
+ timezone: string;
1980
+ language?: string;
1981
+ /** @enum {string} */
1982
+ theme?: "light" | "dark" | "system";
1983
+ };
1984
+ };
1985
+ UpdateUser: {
1986
+ name?: string;
1987
+ /** Format: email */
1988
+ email?: string;
1989
+ phone?: string | null;
1990
+ settings?: {
1991
+ notifications: boolean;
1992
+ timezone: string;
1993
+ language?: string;
1994
+ /** @enum {string} */
1995
+ theme?: "light" | "dark" | "system";
1996
+ };
1997
+ };
1998
+ InviteUser: {
1999
+ /**
2000
+ * Format: email
2001
+ * @description Email address of the person to invite
2002
+ */
2003
+ email: string;
2004
+ /**
2005
+ * @description Role to assign to the new team member
2006
+ * @enum {string}
2007
+ */
2008
+ role: "admin" | "member";
2009
+ /** @description Company ID to invite the user to (defaults to current user's company) */
2010
+ companyId?: number;
2011
+ };
2012
+ ErrorResponse: {
2013
+ error: string;
2014
+ code?: string;
2015
+ details?: unknown;
2016
+ };
2017
+ HealthCheck: {
2018
+ status: string;
2019
+ timestamp: string;
2020
+ version: string;
2021
+ npmVersion: string;
2022
+ environment: string;
2023
+ };
2024
+ };
2025
+ responses: never;
2026
+ parameters: {
2027
+ };
2028
+ requestBodies: never;
2029
+ headers: never;
2030
+ pathItems: never;
2031
+ }
2032
+
2033
+ export type $defs = Record<string, never>;
2034
+
2035
+ export type external = Record<string, never>;
2036
+
2037
+ export type operations = Record<string, never>;