@cloudfleet/sdk 0.0.1-ad0e55f → 0.0.1-af2f3f9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/README.md +26 -2
  2. package/dist/@tanstack/react-query.gen.d.ts +1159 -0
  3. package/dist/@tanstack/react-query.gen.d.ts.map +1 -0
  4. package/dist/@tanstack/react-query.gen.js +1175 -0
  5. package/dist/@tanstack/react-query.gen.js.map +1 -0
  6. package/dist/client/client.gen.d.ts.map +1 -1
  7. package/dist/client/client.gen.js +114 -102
  8. package/dist/client/client.gen.js.map +1 -1
  9. package/dist/client/index.d.ts +1 -1
  10. package/dist/client/index.d.ts.map +1 -1
  11. package/dist/client/index.js.map +1 -1
  12. package/dist/client/types.gen.d.ts +9 -13
  13. package/dist/client/types.gen.d.ts.map +1 -1
  14. package/dist/client/utils.gen.d.ts +8 -4
  15. package/dist/client/utils.gen.d.ts.map +1 -1
  16. package/dist/client/utils.gen.js +13 -15
  17. package/dist/client/utils.gen.js.map +1 -1
  18. package/dist/client.gen.d.ts.map +1 -1
  19. package/dist/client.gen.js +1 -3
  20. package/dist/client.gen.js.map +1 -1
  21. package/dist/core/auth.gen.d.ts.map +1 -1
  22. package/dist/core/auth.gen.js.map +1 -1
  23. package/dist/core/bodySerializer.gen.d.ts +16 -8
  24. package/dist/core/bodySerializer.gen.d.ts.map +1 -1
  25. package/dist/core/bodySerializer.gen.js +1 -1
  26. package/dist/core/bodySerializer.gen.js.map +1 -1
  27. package/dist/core/params.gen.d.ts +10 -0
  28. package/dist/core/params.gen.d.ts.map +1 -1
  29. package/dist/core/params.gen.js +22 -10
  30. package/dist/core/params.gen.js.map +1 -1
  31. package/dist/core/pathSerializer.gen.d.ts.map +1 -1
  32. package/dist/core/pathSerializer.gen.js +3 -11
  33. package/dist/core/pathSerializer.gen.js.map +1 -1
  34. package/dist/core/queryKeySerializer.gen.d.ts.map +1 -1
  35. package/dist/core/queryKeySerializer.gen.js +4 -11
  36. package/dist/core/queryKeySerializer.gen.js.map +1 -1
  37. package/dist/core/serverSentEvents.gen.d.ts +1 -1
  38. package/dist/core/serverSentEvents.gen.d.ts.map +1 -1
  39. package/dist/core/serverSentEvents.gen.js +6 -9
  40. package/dist/core/serverSentEvents.gen.js.map +1 -1
  41. package/dist/core/types.gen.d.ts +1 -1
  42. package/dist/core/types.gen.d.ts.map +1 -1
  43. package/dist/core/utils.gen.d.ts.map +1 -1
  44. package/dist/core/utils.gen.js +1 -1
  45. package/dist/core/utils.gen.js.map +1 -1
  46. package/dist/schemas.gen.d.ts +1601 -569
  47. package/dist/schemas.gen.d.ts.map +1 -1
  48. package/dist/schemas.gen.js +3024 -711
  49. package/dist/schemas.gen.js.map +1 -1
  50. package/dist/sdk.gen.d.ts +296 -164
  51. package/dist/sdk.gen.d.ts.map +1 -1
  52. package/dist/sdk.gen.js +429 -350
  53. package/dist/sdk.gen.js.map +1 -1
  54. package/dist/services/kubernetes/api.d.ts +8 -8
  55. package/dist/types.gen.d.ts +1781 -765
  56. package/dist/types.gen.d.ts.map +1 -1
  57. package/dist/zod.gen.d.ts +3511 -2559
  58. package/dist/zod.gen.d.ts.map +1 -1
  59. package/dist/zod.gen.js +1442 -1190
  60. package/dist/zod.gen.js.map +1 -1
  61. package/package.json +28 -8
package/dist/sdk.gen.js CHANGED
@@ -1,91 +1,275 @@
1
1
  // This file is auto-generated by @hey-api/openapi-ts
2
+ import { formDataBodySerializer } from './client';
2
3
  import { client } from './client.gen';
3
- export class BillingService {
4
+ export class UsersService {
4
5
  /**
5
- * Get billing usage information.
6
- * Returns aggregated usage information for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
6
+ * Get a list of organizations the user belongs to. Used during authentication process.
7
+ */
8
+ static listUserOrganizations(options) {
9
+ return (options.client ?? client).get({ url: '/users/organizations/{email}', ...options });
10
+ }
11
+ /**
12
+ * List users in organization.
13
+ *
14
+ * Returns a list of user details and their roles. For more information on identity access management, see [Users](https://cloudfleet.ai/docs/organization/users/) section of documentaiton.
15
+ *
16
+ * This endpoint is available to all users in the organization.
7
17
  *
8
18
  */
9
- static getUsage(options) {
10
- return (options?.client ?? client).get({
11
- url: '/billing/usage',
12
- ...options
13
- });
19
+ static listUsers(options) {
20
+ return (options?.client ?? client).get({ url: '/users', ...options });
14
21
  }
15
22
  /**
16
- * Get billing balance information.
17
- * Returns the current balance of the organization in USD as a floating-point number. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
23
+ * Create a new user.
24
+ *
25
+ * Create a new user in your Cloudfleet organization. Requires a valid invite code generated by the `invites create` command. The invite code is a unique string that can be used only once to create a new user. The invite code is generated by the `POST /invites` endpoint.
18
26
  *
19
27
  */
20
- static getBalance(options) {
21
- return (options?.client ?? client).get({
22
- url: '/billing/balance',
23
- ...options
28
+ static createUser(options) {
29
+ return (options.client ?? client).post({
30
+ url: '/users',
31
+ ...options,
32
+ headers: {
33
+ 'Content-Type': 'application/json',
34
+ ...options.headers
35
+ }
24
36
  });
25
37
  }
26
38
  /**
27
- * Get organization payment method information.
28
- * Returns the information about the payment card associated with the organization with sensitive information redacted. Payment details can be updated in the Cloudfleet console only, please visit https://console.cloudfleet.ai. This endpoint is available to all users in the organization.
39
+ * Delete user by id.
40
+ *
41
+ * Sets user status to `inactive`. Inactive users cannot log in and manage organization resources. This endpoint is available to administrators of the organization only.
42
+ *
43
+ */
44
+ static deleteUser(options) {
45
+ return (options.client ?? client).delete({ url: '/users/{user_id}', ...options });
46
+ }
47
+ /**
48
+ * Get user profile information by id.
49
+ *
50
+ * Returns user details including their roles. For more information on identity access management, see [Users](https://cloudfleet.ai/docs/organization/users/) section of documentaiton.
51
+ *
52
+ * This endpoint is available to all users in the organization.
53
+ *
54
+ */
55
+ static getUser(options) {
56
+ return (options.client ?? client).get({ url: '/users/{user_id}', ...options });
57
+ }
58
+ /**
59
+ * Update user profile information.
60
+ *
61
+ * Update user profile information: email, first name, last name, role. This endpoint can be accessed by administrators and the user itself. Role and status can be changed by administrators only.
29
62
  *
30
63
  */
31
- static getPaymentMethod(options) {
32
- return (options?.client ?? client).get({
33
- url: '/billing/payment-method',
34
- ...options
64
+ static updateUser(options) {
65
+ return (options.client ?? client).put({
66
+ url: '/users/{user_id}',
67
+ ...options,
68
+ headers: {
69
+ 'Content-Type': 'application/json',
70
+ ...options.headers
71
+ }
35
72
  });
36
73
  }
74
+ }
75
+ export class TokensService {
37
76
  /**
38
- * Get Stripe client secret.
39
- * Endpoint returns the Stripe secret key for the organization. This key is used to securely update the payment method in the Cloudfleet console only, please visit https://console.cloudfleet.ai. This endpoint is available to administrators of the organization only.
77
+ * List access tokens in organization.
78
+ *
79
+ * This endpoint allows you to get a list of all access tokens details in organization. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton. This endpoint is available to all users in the organization.
40
80
  *
41
81
  */
42
- static getPaymentMethodSecret(options) {
43
- return (options?.client ?? client).put({
44
- url: '/billing/payment-method',
45
- ...options
82
+ static listTokens(options) {
83
+ return (options?.client ?? client).get({ url: '/tokens', ...options });
84
+ }
85
+ /**
86
+ * Create a new access token.
87
+ *
88
+ * This endpoint allows you to create a new access token. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton.
89
+ *
90
+ * This endpoint is available to administrators of the organization only.
91
+ *
92
+ */
93
+ static createToken(options) {
94
+ return (options.client ?? client).post({
95
+ url: '/tokens',
96
+ ...options,
97
+ headers: {
98
+ 'Content-Type': 'application/json',
99
+ ...options.headers
100
+ }
46
101
  });
47
102
  }
48
103
  /**
49
- * List issued invoices.
50
- * Returns a list of invoices for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
104
+ * Permanently delete access token.
105
+ *
106
+ * This endpoint allows you to delete an access token. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton. This endpoint is available to administrators of the organization only.
51
107
  *
52
108
  */
53
- static listInvoices(options) {
54
- return (options.client ?? client).get({
55
- url: '/billing/invoices',
56
- ...options
109
+ static deleteToken(options) {
110
+ return (options.client ?? client).delete({ url: '/tokens/{token_id}', ...options });
111
+ }
112
+ /**
113
+ * Get access token information.
114
+ *
115
+ * This endpoint allows you to get access token details. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton. This endpoint is available to all users in the organization.
116
+ *
117
+ */
118
+ static getToken(options) {
119
+ return (options.client ?? client).get({ url: '/tokens/{token_id}', ...options });
120
+ }
121
+ /**
122
+ * Update access token information.
123
+ *
124
+ * This endpoint allows you to update access token details. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton.
125
+ *
126
+ * This endpoint is available to administrators of the organization only.
127
+ *
128
+ */
129
+ static updateToken(options) {
130
+ return (options.client ?? client).put({
131
+ url: '/tokens/{token_id}',
132
+ ...options,
133
+ headers: {
134
+ 'Content-Type': 'application/json',
135
+ ...options.headers
136
+ }
57
137
  });
58
138
  }
59
139
  /**
60
- * Get invoice information.
61
- * Returns a single Invoice as HTML referenced by id. This endpoint is available to all users in the organization.
140
+ * Regenerate access token secret key.
62
141
  *
142
+ * Generates a new access token secret. Old secret will not be valid anymore.
63
143
  */
64
- static getInvoice(options) {
65
- return (options.client ?? client).get({
66
- url: '/billing/invoices/{id}',
67
- ...options
144
+ static regenerateToken(options) {
145
+ return (options.client ?? client).put({ url: '/tokens/{token_id}/secret', ...options });
146
+ }
147
+ }
148
+ export class TicketsService {
149
+ /**
150
+ * List tickets for the current organization.
151
+ *
152
+ * Returns all tickets belonging to the caller's organization, newest first.
153
+ *
154
+ */
155
+ static listTickets(options) {
156
+ return (options?.client ?? client).get({ url: '/tickets', ...options });
157
+ }
158
+ /**
159
+ * Create a new support ticket.
160
+ *
161
+ * Creates a new support ticket with an initial customer message. The request is `multipart/form-data` with a JSON-encoded `payload` field carrying `category`, `body`, and optional `properties`, plus up to 3 `attachments` files (10 MB max each).
162
+ *
163
+ */
164
+ static createTicket(options) {
165
+ return (options.client ?? client).post({
166
+ ...formDataBodySerializer,
167
+ url: '/tickets',
168
+ ...options,
169
+ headers: {
170
+ 'Content-Type': null,
171
+ ...options.headers
172
+ }
68
173
  });
69
174
  }
70
175
  /**
71
- * Get organization contact and billing address information.
72
- * Returns the organization contact and billing address information. This endpoint is available to all users in the organization.
176
+ * Close a ticket (soft close).
177
+ *
178
+ * Marks the ticket as closed. Closed is a terminal state — users cannot reply to a closed ticket; a new ticket must be opened instead.
73
179
  *
74
180
  */
75
- static getContact(options) {
76
- return (options?.client ?? client).get({
77
- url: '/billing/contact',
78
- ...options
181
+ static closeTicket(options) {
182
+ return (options.client ?? client).delete({ url: '/tickets/{ticket_id}', ...options });
183
+ }
184
+ /**
185
+ * Get a ticket and its messages.
186
+ */
187
+ static getTicket(options) {
188
+ return (options.client ?? client).get({ url: '/tickets/{ticket_id}', ...options });
189
+ }
190
+ /**
191
+ * Append a customer reply to a ticket.
192
+ *
193
+ * Multipart form-data with a JSON-encoded `payload` field carrying `body`, plus up to 3 `attachments` files. Returns 409 if the ticket is closed.
194
+ *
195
+ */
196
+ static replyTicket(options) {
197
+ return (options.client ?? client).post({
198
+ ...formDataBodySerializer,
199
+ url: '/tickets/{ticket_id}/messages',
200
+ ...options,
201
+ headers: {
202
+ 'Content-Type': null,
203
+ ...options.headers
204
+ }
79
205
  });
80
206
  }
81
207
  /**
82
- * Update organization contact information and billing address.
83
- * This endpoint allows you to update organization details with its contact information. This endpoint is available to administrators of the organization only.
208
+ * Download a ticket attachment.
209
+ */
210
+ static getTicketAttachment(options) {
211
+ return (options.client ?? client).get({ url: '/tickets/{ticket_id}/attachments/{attachment_id}', ...options });
212
+ }
213
+ }
214
+ export class RegistryService {
215
+ /**
216
+ * List repositories
217
+ *
218
+ * Returns a list of repositories in the registry across all regions. This endpoint is available to all users in the organization.
84
219
  *
85
220
  */
86
- static updateContact(options) {
87
- return (options.client ?? client).put({
88
- url: '/billing/contact',
221
+ static listRepositories(options) {
222
+ return (options?.client ?? client).get({ url: '/registry', ...options });
223
+ }
224
+ /**
225
+ * List tags for a repository
226
+ *
227
+ * Returns a list of tags for a specific repository, including size and metadata for each tag. This endpoint is available to all users in the organization.
228
+ *
229
+ */
230
+ static listTags(options) {
231
+ return (options.client ?? client).get({ url: '/registry/{region}/{repository}', ...options });
232
+ }
233
+ /**
234
+ * Delete tag
235
+ *
236
+ * Permanently deletes a specific tag from a repository. This endpoint is available to administrators of the organization only.
237
+ *
238
+ */
239
+ static deleteTag(options) {
240
+ return (options.client ?? client).delete({ url: '/registry/{region}/{repository}/{tag}', ...options });
241
+ }
242
+ /**
243
+ * Get tag details
244
+ *
245
+ * Returns detailed information for a specific tag in a repository, including manifest details, size, and URI. This endpoint is available to all users in the organization.
246
+ *
247
+ */
248
+ static getTag(options) {
249
+ return (options.client ?? client).get({ url: '/registry/{region}/{repository}/{tag}', ...options });
250
+ }
251
+ }
252
+ export class OrganizationService {
253
+ /**
254
+ * Get organization information.
255
+ *
256
+ * Returns organization details including quota. For more information about quotas, see [Quotas and limits](https://cloudfleet.ai/docs/organization/quotas/) section of documentaiton.
257
+ *
258
+ * This endpoint is available to all users in the organization.
259
+ *
260
+ */
261
+ static getOrganization(options) {
262
+ return (options?.client ?? client).get({ url: '/organization', ...options });
263
+ }
264
+ /**
265
+ * Create a new organization / Cloudfleet account signup.
266
+ *
267
+ * This endpoint allows you to create a new Cloudfleet organization and an administrator user.
268
+ *
269
+ */
270
+ static createOrganization(options) {
271
+ return (options.client ?? client).post({
272
+ url: '/organization',
89
273
  ...options,
90
274
  headers: {
91
275
  'Content-Type': 'application/json',
@@ -93,25 +277,69 @@ export class BillingService {
93
277
  }
94
278
  });
95
279
  }
280
+ }
281
+ export class McpService {
96
282
  /**
97
- * Get applied promotional credits
98
- * Returns applied promotional credits for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
283
+ * MCP endpoint
99
284
  *
285
+ * MCP endpoint for handling Model Context Protocol JSON-RPC 2.0 messages.
100
286
  */
101
- static getCredits(options) {
102
- return (options?.client ?? client).get({
103
- url: '/billing/credits',
104
- ...options
287
+ static postMcp(options) {
288
+ return (options.client ?? client).post({
289
+ url: '/mcp',
290
+ ...options,
291
+ headers: {
292
+ 'Content-Type': 'application/json',
293
+ ...options.headers
294
+ }
105
295
  });
106
296
  }
297
+ }
298
+ export class ChartsMarketplaceService {
107
299
  /**
108
- * Redeem promotional credits code.
109
- * Applies promotional credits for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
300
+ * List chart listings available in the marketplace.
301
+ *
302
+ * Returns a list of available charts in the marketplace.
303
+ *
304
+ * This endpoint is available to all users in the organization.
110
305
  *
111
306
  */
112
- static redeemCredits(options) {
307
+ static listMarketplaceCharts(options) {
308
+ return (options?.client ?? client).get({ url: '/marketplace', ...options });
309
+ }
310
+ /**
311
+ * Get chart files for a specific version channel.
312
+ *
313
+ * Returns the Chart.yaml, values.yaml, and values.schema.json files for the latest version matching the specified version channel.
314
+ *
315
+ * Version channels use patterns like "1.31.x-cfke.x" to match the latest patch version, or "1.x.x-cfke.x" to match the latest minor version.
316
+ *
317
+ * This endpoint is available to all users in the organization.
318
+ *
319
+ */
320
+ static getMarketplaceChartFiles(options) {
321
+ return (options.client ?? client).get({ url: '/marketplace/{chart_name}/files/{version_channel}', ...options });
322
+ }
323
+ }
324
+ export class InvitesService {
325
+ /**
326
+ * List invites.
327
+ *
328
+ * Returns a list of pending (non-expired) invites under the current organization. This endpoint is available to administrators of the organization only.
329
+ *
330
+ */
331
+ static listInvites(options) {
332
+ return (options?.client ?? client).get({ url: '/invites', ...options });
333
+ }
334
+ /**
335
+ * Create a new invite.
336
+ *
337
+ * Invite a new user to your Cloudfleet organization. The user will receive an email with a link to create a new account. This endpoint is available to administrators of the organization only.
338
+ *
339
+ */
340
+ static createInvite(options) {
113
341
  return (options.client ?? client).post({
114
- url: '/billing/credits',
342
+ url: '/invites',
115
343
  ...options,
116
344
  headers: {
117
345
  'Content-Type': 'application/json',
@@ -119,31 +347,58 @@ export class BillingService {
119
347
  }
120
348
  });
121
349
  }
350
+ /**
351
+ * Get invite information.
352
+ *
353
+ * Validates an invitation code and returns the email address it was issued to (to pre-fill the signup form) and the organization it grants access to. This endpoint is unauthenticated, so no other invite details (such as the invited role) are disclosed.
354
+ *
355
+ */
356
+ static getInvite(options) {
357
+ return (options.client ?? client).get({ url: '/invites/{code}', ...options });
358
+ }
359
+ /**
360
+ * Permanently delete invite.
361
+ *
362
+ * Permanently deletes invite from the organization. This endpoint is available to administrators of the organization only.
363
+ *
364
+ */
365
+ static deleteInvite(options) {
366
+ return (options.client ?? client).delete({ url: '/invites/{email}', ...options });
367
+ }
122
368
  }
123
369
  export class ClustersService {
124
370
  /**
125
- * List charts.
126
- * Returns a list of charts in the cluster.
371
+ * Query Kubernetes cluster API
372
+ *
373
+ * An API endpoint for directly querying a Kubernetes cluster API without requiring kubectl or other tools. This endpoint is ideal for automation and scripting, as well as for internal use in fetching data for the Cloudfleet Console. It acts as a passthrough to the Kubernetes API, allowing access to any valid Kubernetes API endpoint, including those not exposed in the Cloudfleet Console. The endpoint is strictly read-only, ensuring no modifications to the cluster state. It is accessible to all users within the organization and uses the same authentication mechanisms as other Cloudfleet API endpoints.
374
+ */
375
+ static queryCluster(options) {
376
+ return (options.client ?? client).get({ url: '/clusters/{cluster_id}/query', ...options });
377
+ }
378
+ /**
379
+ * List fleets.
380
+ *
381
+ * Returns a list of fleets belonging to the cluster. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
127
382
  *
128
383
  * This endpoint is available to all users in the organization.
129
384
  *
130
385
  */
131
- static listCharts(options) {
132
- return (options.client ?? client).get({
133
- url: '/clusters/{cluster_id}/charts',
134
- ...options
135
- });
386
+ static listFleets(options) {
387
+ return (options.client ?? client).get({ url: '/clusters/{cluster_id}/fleets', ...options });
136
388
  }
137
389
  /**
138
- * Create a new chart.
139
- * Create a new chart deployment.
390
+ * Create a new fleet.
391
+ *
392
+ * Create a new fleet under the current organization. fleets allow you to to schedule workloads in cloud service provider accounts owned by you. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
393
+ *
394
+ * The cluster must be ready (status `deployed`) before a fleet can be added. Adding a fleet while the cluster is still provisioning returns `409`.
140
395
  *
141
396
  * This endpoint is available to administrators of the organization only.
142
397
  *
143
398
  */
144
- static createChart(options) {
399
+ static createFleet(options) {
145
400
  return (options.client ?? client).post({
146
- url: '/clusters/{cluster_id}/charts',
401
+ url: '/clusters/{cluster_id}/fleets',
147
402
  ...options,
148
403
  headers: {
149
404
  'Content-Type': 'application/json',
@@ -152,41 +407,44 @@ export class ClustersService {
152
407
  });
153
408
  }
154
409
  /**
155
- * Permanently delete the chart deployment from the cluster.
156
- * This endpoint will permanently delete chart. This operation cannot be undone.
410
+ * Permanently delete fleet.
411
+ *
412
+ * This endpoint will permanently delete fleet. This operation cannot be undone. Your subscription will end by the end of the current billing period and you will not be able to receive credit for unused time. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
413
+ *
414
+ * Deleting a fleet does not deprovision the cloud infrastructure it provisioned: nodes and other resources keep running. Scale the cluster down first, or remove the infrastructure manually, to avoid orphaned resources.
157
415
  *
158
416
  * This endpoint is available to administrators of the organization only.
159
417
  *
160
418
  */
161
- static deleteChart(options) {
162
- return (options.client ?? client).delete({
163
- url: '/clusters/{cluster_id}/charts/{chart_name}',
164
- ...options
165
- });
419
+ static deleteFleet(options) {
420
+ return (options.client ?? client).delete({ url: '/clusters/{cluster_id}/fleets/{fleet_name}', ...options });
166
421
  }
167
422
  /**
168
- * Get chart information.
169
- * Returns the details of the chart deployment.
423
+ * Get fleet information.
424
+ *
425
+ * Returns fleet details. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
170
426
  *
171
427
  * This endpoint is available to all users in the organization.
172
428
  *
173
429
  */
174
- static getChart(options) {
175
- return (options.client ?? client).get({
176
- url: '/clusters/{cluster_id}/charts/{chart_name}',
177
- ...options
178
- });
430
+ static getFleet(options) {
431
+ return (options.client ?? client).get({ url: '/clusters/{cluster_id}/fleets/{fleet_name}', ...options });
179
432
  }
180
433
  /**
181
- * Update chart information.
182
- * This endpoint allows you to update the values of a chart deployment.
434
+ * Update fleet information.
435
+ *
436
+ * This endpoint allows you to update fleet details.
437
+ *
438
+ * For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
439
+ *
440
+ * This is a full overwrite: any field omitted from the request is reset to its default rather than left unchanged. The Hetzner API key is the exception: it is kept when omitted (send a new value to rotate it).
183
441
  *
184
442
  * This endpoint is available to administrators of the organization only.
185
443
  *
186
444
  */
187
- static updateChart(options) {
445
+ static updateFleet(options) {
188
446
  return (options.client ?? client).put({
189
- url: '/clusters/{cluster_id}/charts/{chart_name}',
447
+ url: '/clusters/{cluster_id}/fleets/{fleet_name}',
190
448
  ...options,
191
449
  headers: {
192
450
  'Content-Type': 'application/json',
@@ -195,28 +453,27 @@ export class ClustersService {
195
453
  });
196
454
  }
197
455
  /**
198
- * List fleets.
199
- * Returns a list of fleets belonging to the cluster. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
456
+ * List charts.
457
+ *
458
+ * Returns a list of charts in the cluster.
200
459
  *
201
460
  * This endpoint is available to all users in the organization.
202
461
  *
203
462
  */
204
- static listFleets(options) {
205
- return (options.client ?? client).get({
206
- url: '/clusters/{cluster_id}/fleets',
207
- ...options
208
- });
463
+ static listCharts(options) {
464
+ return (options.client ?? client).get({ url: '/clusters/{cluster_id}/charts', ...options });
209
465
  }
210
466
  /**
211
- * Create a new fleet.
212
- * Create a new fleet under the current organization. fleets allow you to to schedule workloads in cloud service provider accounts owned by you. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
467
+ * Create a new chart.
468
+ *
469
+ * Create a new chart deployment.
213
470
  *
214
471
  * This endpoint is available to administrators of the organization only.
215
472
  *
216
473
  */
217
- static createFleet(options) {
474
+ static createChart(options) {
218
475
  return (options.client ?? client).post({
219
- url: '/clusters/{cluster_id}/fleets',
476
+ url: '/clusters/{cluster_id}/charts',
220
477
  ...options,
221
478
  headers: {
222
479
  'Content-Type': 'application/json',
@@ -225,45 +482,38 @@ export class ClustersService {
225
482
  });
226
483
  }
227
484
  /**
228
- * Permanently delete fleet.
229
- * This endpoint will permanently delete fleet. This operation cannot be undone. Your subscription will end by the end of the current billing period and you will not be able to receive credit for unused time. If you want to keep using the Fleet until the end of the billing period, set the status to `cancelling`. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
485
+ * Permanently delete the chart deployment from the cluster.
486
+ *
487
+ * This endpoint will permanently delete chart. This operation cannot be undone.
230
488
  *
231
489
  * This endpoint is available to administrators of the organization only.
232
490
  *
233
491
  */
234
- static deleteFleet(options) {
235
- return (options.client ?? client).delete({
236
- url: '/clusters/{cluster_id}/fleets/{fleet_name}',
237
- ...options
238
- });
492
+ static deleteChart(options) {
493
+ return (options.client ?? client).delete({ url: '/clusters/{cluster_id}/charts/{chart_name}', ...options });
239
494
  }
240
495
  /**
241
- * Get fleet information.
242
- * Returns fleet details. For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
496
+ * Get chart information.
497
+ *
498
+ * Returns the details of the chart deployment.
243
499
  *
244
500
  * This endpoint is available to all users in the organization.
245
501
  *
246
502
  */
247
- static getFleet(options) {
248
- return (options.client ?? client).get({
249
- url: '/clusters/{cluster_id}/fleets/{fleet_name}',
250
- ...options
251
- });
503
+ static getChart(options) {
504
+ return (options.client ?? client).get({ url: '/clusters/{cluster_id}/charts/{chart_name}', ...options });
252
505
  }
253
506
  /**
254
- * Update fleet information.
255
- * This endpoint allows you to update fleet details.
256
- *
257
- * Setting status to `deleted` will permanently delete fleet. This operation cannot be undone. Your subscription will end by the end of the current billing period and you will not be able to receive credit for unused time. If you want to keep using the Fleet until the end of the billing period, set the status to `cancelling`.
507
+ * Update chart information.
258
508
  *
259
- * For more information, see [Fleets](https://cloudfleet.ai/docs/cloud-infrastructure/fleets/) section of documentaiton.
509
+ * This endpoint allows you to update the values of a chart deployment.
260
510
  *
261
511
  * This endpoint is available to administrators of the organization only.
262
512
  *
263
513
  */
264
- static updateFleet(options) {
514
+ static updateChart(options) {
265
515
  return (options.client ?? client).put({
266
- url: '/clusters/{cluster_id}/fleets/{fleet_name}',
516
+ url: '/clusters/{cluster_id}/charts/{chart_name}',
267
517
  ...options,
268
518
  headers: {
269
519
  'Content-Type': 'application/json',
@@ -271,31 +521,20 @@ export class ClustersService {
271
521
  }
272
522
  });
273
523
  }
274
- /**
275
- * Query Kubernetes cluster API
276
- * An API endpoint for directly querying a Kubernetes cluster API without requiring kubectl or other tools. This endpoint is ideal for automation and scripting, as well as for internal use in fetching data for the Cloudfleet Console. It acts as a passthrough to the Kubernetes API, allowing access to any valid Kubernetes API endpoint, including those not exposed in the Cloudfleet Console. The endpoint is strictly read-only, ensuring no modifications to the cluster state. It is accessible to all users within the organization and uses the same authentication mechanisms as other Cloudfleet API endpoints.
277
- */
278
- static queryCluster(options) {
279
- return (options.client ?? client).get({
280
- url: '/clusters/{cluster_id}/query',
281
- ...options
282
- });
283
- }
284
524
  /**
285
525
  * List clusters.
286
- * Returns a list of clusters under the current organization, including quota. Quota is a set of filters defined by the admin of the organization that will be applied to all resources created in the cluster. Quota information returned here does not take into account quota set on organization or platform level. For calculated quota applied to this account, use /clusters/{cluster_id}/quota endpoint. For more information about quotas, see [Quotas and limits](https://cloudfleet.ai/docs/organization/quotas/) section of documentaiton.
526
+ *
527
+ * Returns a list of clusters under the current organization.
287
528
  *
288
529
  * This endpoint is available to all users in the organization.
289
530
  *
290
531
  */
291
532
  static listClusters(options) {
292
- return (options?.client ?? client).get({
293
- url: '/clusters',
294
- ...options
295
- });
533
+ return (options?.client ?? client).get({ url: '/clusters', ...options });
296
534
  }
297
535
  /**
298
536
  * Create a new cluster.
537
+ *
299
538
  * Create a new cluster under the current organization. Clusters allow you to group resources and you can create multiple clusters under the same organization, with billing delegated to the parent organization.
300
539
  *
301
540
  * This endpoint is available to administrators of the organization only.
@@ -313,33 +552,34 @@ export class ClustersService {
313
552
  }
314
553
  /**
315
554
  * Permanently delete cluster.
555
+ *
316
556
  * This endpoint will permanently delete the cluster. This operation cannot be undone.
317
557
  *
558
+ * Deleting a cluster also deletes its fleets. This does not deprovision the cloud infrastructure those fleets provisioned: nodes and other resources keep running. Scale the cluster down first, or remove the infrastructure manually, to avoid orphaned resources.
559
+ *
318
560
  * This endpoint is available to administrators of the organization only.
319
561
  *
320
562
  */
321
563
  static deleteCluster(options) {
322
- return (options.client ?? client).delete({
323
- url: '/clusters/{cluster_id}',
324
- ...options
325
- });
564
+ return (options.client ?? client).delete({ url: '/clusters/{cluster_id}', ...options });
326
565
  }
327
566
  /**
328
567
  * Get cluster information.
329
- * Returns cluster details including quota. Quota is a set of filters defined by the admin of the organization that will be applied to all resources created in the cluster. Quota information returned here does not take into account quota set on organization or platform level. For calculated quota applied to this account, use /clusters/{cluster_id}/quota endpoint. For more information about quotas, see [Quotas and limits](https://cloudfleet.ai/docs/organization/quotas/) section of documentaiton.
568
+ *
569
+ * Returns cluster details.
330
570
  *
331
571
  * This endpoint is available to all users in the organization.
332
572
  *
333
573
  */
334
574
  static getCluster(options) {
335
- return (options.client ?? client).get({
336
- url: '/clusters/{cluster_id}',
337
- ...options
338
- });
575
+ return (options.client ?? client).get({ url: '/clusters/{cluster_id}', ...options });
339
576
  }
340
577
  /**
341
578
  * Update cluster information.
342
- * This endpoint allows you to update cluster details, including quota and cluster status. For more information about clusters, see [Clusters](https://cloudfleet.ai/docs/cluster-management/cluster-types/) section of documentaiton.
579
+ *
580
+ * This endpoint allows you to update cluster details. For more information about clusters, see [Clusters](https://cloudfleet.ai/docs/cluster-management/cluster-types/) section of documentation.
581
+ *
582
+ * This is a full overwrite: any field omitted from the request is reset to its default rather than left unchanged.
343
583
  *
344
584
  * This endpoint is available to administrators of the organization only.
345
585
  *
@@ -356,185 +596,87 @@ export class ClustersService {
356
596
  }
357
597
  /**
358
598
  * Node join information for the cluster
599
+ *
359
600
  * Returns the join information for the cluster. This information is used to add a self-managed nodes to the CFKE cluster. This endpoint is available to only admins of the organization.
360
601
  *
361
602
  */
362
603
  static getJoinInformation(options) {
363
- return (options.client ?? client).post({
364
- url: '/clusters/{cluster_id}/join_information',
365
- ...options
366
- });
604
+ return (options.client ?? client).post({ url: '/clusters/{cluster_id}/join_information', ...options });
367
605
  }
368
606
  }
369
- export class InvitesService {
370
- /**
371
- * List invites.
372
- * Returns a list of invites under the current organization. This endpoint is available to all users in the organization.
373
- *
374
- */
375
- static listInvites(options) {
376
- return (options?.client ?? client).get({
377
- url: '/invites',
378
- ...options
379
- });
380
- }
381
- /**
382
- * Create a new invite.
383
- * Invite a new user to your Cloudfleet organization. The user will receive an email with a link to create a new account. This endpoint is available to administrators of the organization only.
384
- *
385
- */
386
- static createInvite(options) {
387
- return (options.client ?? client).post({
388
- url: '/invites',
389
- ...options,
390
- headers: {
391
- 'Content-Type': 'application/json',
392
- ...options.headers
393
- }
394
- });
395
- }
607
+ export class BillingService {
396
608
  /**
397
- * Get invite information.
398
- * Returns invite details.
609
+ * Get billing usage information.
399
610
  *
400
- */
401
- static getInvite(options) {
402
- return (options.client ?? client).get({
403
- url: '/invites/{code}',
404
- ...options
405
- });
406
- }
407
- /**
408
- * Permanently delete invite.
409
- * Permanently deletes invite from the organization. This endpoint is available to administrators of the organization only.
611
+ * Returns aggregated usage information for the organization with facets for filtering. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
410
612
  *
411
613
  */
412
- static deleteInvite(options) {
413
- return (options.client ?? client).delete({
414
- url: '/invites/{email}',
415
- ...options
416
- });
614
+ static getUsage(options) {
615
+ return (options?.client ?? client).get({ url: '/billing/usage', ...options });
417
616
  }
418
- }
419
- export class ChartsMarketplaceService {
420
617
  /**
421
- * List chart listings available in the marketplace.
422
- * Returns a list of available charts in the marketplace.
618
+ * Get Stripe client secret.
423
619
  *
424
- * This endpoint is available to all users in the organization.
620
+ * Endpoint returns the Stripe secret key for the organization. This key is used to securely update the payment method in the Cloudfleet console only, please visit https://console.cloudfleet.ai. This endpoint is available to administrators of the organization only.
425
621
  *
426
622
  */
427
- static listMarketplaceCharts(options) {
428
- return (options?.client ?? client).get({
429
- url: '/marketplace',
430
- ...options
431
- });
623
+ static getPaymentMethodSecret(options) {
624
+ return (options?.client ?? client).put({ url: '/billing/payment-method', ...options });
432
625
  }
433
626
  /**
434
- * Get chart listing details.
435
- * Returns details of the chart listing.
627
+ * List organization payment methods.
436
628
  *
437
- * This endpoint is available to all users in the organization.
629
+ * Returns all payment methods (cards and SEPA Direct Debit) attached to the organization, most recently added first, with the default flagged. This endpoint is available to all users in the organization.
438
630
  *
439
631
  */
440
- static getMarketplaceChart(options) {
441
- return (options.client ?? client).get({
442
- url: '/marketplace/{listing_id}',
443
- ...options
444
- });
632
+ static listPaymentMethods(options) {
633
+ return (options?.client ?? client).get({ url: '/billing/payment-methods', ...options });
445
634
  }
446
- }
447
- export class OrganizationService {
448
635
  /**
449
- * Get organization information.
450
- * Returns organization details including quota. For more information about quotas, see [Quotas and limits](https://cloudfleet.ai/docs/organization/quotas/) section of documentaiton.
636
+ * Set the default payment method.
451
637
  *
452
- * This endpoint is available to all users in the organization.
638
+ * Sets the given payment method as the default used for invoices and active subscriptions. Requires the Administrator role.
453
639
  *
454
640
  */
455
- static getOrganization(options) {
456
- return (options?.client ?? client).get({
457
- url: '/organization',
458
- ...options
459
- });
641
+ static setDefaultPaymentMethod(options) {
642
+ return (options.client ?? client).put({ url: '/billing/payment-methods/{paymentMethodId}/default', ...options });
460
643
  }
461
644
  /**
462
- * Create a new organization / Cloudfleet account signup.
463
- * This endpoint allows you to create a new Cloudfleet organization and an administrator user.
645
+ * Delete a payment method.
464
646
  *
465
- */
466
- static createOrganization(options) {
467
- return (options.client ?? client).post({
468
- url: '/organization',
469
- ...options,
470
- headers: {
471
- 'Content-Type': 'application/json',
472
- ...options.headers
473
- }
474
- });
475
- }
476
- }
477
- export class TokensService {
478
- /**
479
- * List access tokens in organization.
480
- * This endpoint allows you to get a list of all access tokens details in organization. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton. This endpoint is available to all users in the organization.
647
+ * Detaches the given payment method from the organization. Requires the Administrator role. An organization must keep at least one payment method, so deleting the only remaining method is rejected.
481
648
  *
482
649
  */
483
- static listTokens(options) {
484
- return (options?.client ?? client).get({
485
- url: '/tokens',
486
- ...options
487
- });
650
+ static deletePaymentMethod(options) {
651
+ return (options.client ?? client).delete({ url: '/billing/payment-methods/{paymentMethodId}', ...options });
488
652
  }
489
653
  /**
490
- * Create a new access token.
491
- * This endpoint allows you to create a new access token. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton.
654
+ * List issued invoices.
492
655
  *
493
- * This endpoint is available to administrators of the organization only.
656
+ * Returns a list of invoices for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
494
657
  *
495
658
  */
496
- static createToken(options) {
497
- return (options.client ?? client).post({
498
- url: '/tokens',
499
- ...options,
500
- headers: {
501
- 'Content-Type': 'application/json',
502
- ...options.headers
503
- }
504
- });
659
+ static listInvoices(options) {
660
+ return (options?.client ?? client).get({ url: '/billing/invoices', ...options });
505
661
  }
506
662
  /**
507
- * Permanently delete access token.
508
- * This endpoint allows you to delete an access token. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton. This endpoint is available to administrators of the organization only.
663
+ * Get organization contact and billing address information.
509
664
  *
510
- */
511
- static deleteToken(options) {
512
- return (options.client ?? client).delete({
513
- url: '/tokens/{token_id}',
514
- ...options
515
- });
516
- }
517
- /**
518
- * Get access token information.
519
- * This endpoint allows you to get access token details. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton. This endpoint is available to all users in the organization.
665
+ * Returns the organization contact and billing address information. This endpoint is available to all users in the organization.
520
666
  *
521
667
  */
522
- static getToken(options) {
523
- return (options.client ?? client).get({
524
- url: '/tokens/{token_id}',
525
- ...options
526
- });
668
+ static getContact(options) {
669
+ return (options?.client ?? client).get({ url: '/billing/contact', ...options });
527
670
  }
528
671
  /**
529
- * Update access token information.
530
- * This endpoint allows you to update access token details. For more information about identity access management and security, see [Service Accounts](https://cloudfleet.ai/docs/organization/api-tokens/) section of documentaiton.
672
+ * Update organization contact information and billing address.
531
673
  *
532
- * This endpoint is available to administrators of the organization only.
674
+ * This endpoint allows you to update organization details with its contact information. This endpoint is available to administrators of the organization only.
533
675
  *
534
676
  */
535
- static updateToken(options) {
677
+ static updateContact(options) {
536
678
  return (options.client ?? client).put({
537
- url: '/tokens/{token_id}',
679
+ url: '/billing/contact',
538
680
  ...options,
539
681
  headers: {
540
682
  'Content-Type': 'application/json',
@@ -543,86 +685,23 @@ export class TokensService {
543
685
  });
544
686
  }
545
687
  /**
546
- * Regenerate access token secret key.
547
- * Generates a new access token secret. Old secret will not be valid anymore.
548
- */
549
- static regenerateToken(options) {
550
- return (options.client ?? client).put({
551
- url: '/tokens/{token_id}/secret',
552
- ...options
553
- });
554
- }
555
- }
556
- export class UsersService {
557
- /**
558
- * Get a list of organizations the user belongs to. Used during authentication process.
559
- */
560
- static listUserOrganizations(options) {
561
- return (options.client ?? client).get({
562
- url: '/users/organizations/{email}',
563
- ...options
564
- });
565
- }
566
- /**
567
- * List users in organization.
568
- * Returns a list of user details and their roles. For more information on identity access management, see [Users](https://cloudfleet.ai/docs/organization/users/) section of documentaiton.
569
- *
570
- * This endpoint is available to all users in the organization.
571
- *
572
- */
573
- static listUsers(options) {
574
- return (options?.client ?? client).get({
575
- url: '/users',
576
- ...options
577
- });
578
- }
579
- /**
580
- * Create a new user.
581
- * Create a new user in your Cloudfleet organization. Requires a valid invite code generated by the `invites create` command. The invite code is a unique string that can be used only once to create a new user. The invite code is generated by the `POST /invites` endpoint.
688
+ * Get applied promotional credits
582
689
  *
583
- */
584
- static createUser(options) {
585
- return (options.client ?? client).post({
586
- url: '/users',
587
- ...options,
588
- headers: {
589
- 'Content-Type': 'application/json',
590
- ...options.headers
591
- }
592
- });
593
- }
594
- /**
595
- * Delete user by id.
596
- * Sets user status to `inactive`. Inactive users cannot log in and manage organization resources. This endpoint is available to administrators of the organization only.
690
+ * Returns applied promotional credits for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
597
691
  *
598
692
  */
599
- static deleteUser(options) {
600
- return (options.client ?? client).delete({
601
- url: '/users/{user_id}',
602
- ...options
603
- });
693
+ static getCredits(options) {
694
+ return (options?.client ?? client).get({ url: '/billing/credits', ...options });
604
695
  }
605
696
  /**
606
- * Get user profile information by id.
607
- * Returns user details including their roles. For more information on identity access management, see [Users](https://cloudfleet.ai/docs/organization/users/) section of documentaiton.
608
- *
609
- * This endpoint is available to all users in the organization.
697
+ * Redeem promotional credits code.
610
698
  *
611
- */
612
- static getUser(options) {
613
- return (options.client ?? client).get({
614
- url: '/users/{user_id}',
615
- ...options
616
- });
617
- }
618
- /**
619
- * Update user profile information.
620
- * Update user profile information: email, first name, last name, role. This endpoint can be accessed by administrators and the user itself. Role and status can be changed by administrators only.
699
+ * Applies promotional credits for the organization. For more information on billing and payments, see [Billing and pricing](https://cloudfleet.ai/docs/organization/billing/) section of documentaiton. This endpoint is available to all users in the organization.
621
700
  *
622
701
  */
623
- static updateUser(options) {
624
- return (options.client ?? client).put({
625
- url: '/users/{user_id}',
702
+ static redeemCredits(options) {
703
+ return (options.client ?? client).post({
704
+ url: '/billing/credits',
626
705
  ...options,
627
706
  headers: {
628
707
  'Content-Type': 'application/json',