@appwrite.io/console 1.2.1 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/.github/workflows/autoclose.yml +1 -1
  2. package/README.md +1 -1
  3. package/dist/cjs/sdk.js +4877 -3337
  4. package/dist/cjs/sdk.js.map +1 -1
  5. package/dist/esm/sdk.js +4876 -3338
  6. package/dist/esm/sdk.js.map +1 -1
  7. package/dist/iife/sdk.js +4877 -3337
  8. package/docs/examples/account/create-payment-method.md +11 -0
  9. package/docs/examples/account/delete-payment-method.md +13 -0
  10. package/docs/examples/account/get-billing-address.md +13 -0
  11. package/docs/examples/account/get-payment-method.md +13 -0
  12. package/docs/examples/account/list-billing-addresses.md +13 -0
  13. package/docs/examples/account/list-credits.md +14 -0
  14. package/docs/examples/account/list-invoices.md +13 -0
  15. package/docs/examples/account/list-payment-methods.md +13 -0
  16. package/docs/examples/account/update-payment-method-mandate-options.md +13 -0
  17. package/docs/examples/account/update-payment-method-provider.md +15 -0
  18. package/docs/examples/account/update-payment-method.md +15 -0
  19. package/docs/examples/backups/create-archive.md +14 -0
  20. package/docs/examples/backups/create-policy.md +19 -0
  21. package/docs/examples/backups/create-restoration.md +16 -0
  22. package/docs/examples/backups/delete-archive.md +13 -0
  23. package/docs/examples/backups/delete-policy.md +13 -0
  24. package/docs/examples/backups/get-archive.md +13 -0
  25. package/docs/examples/backups/get-policy.md +13 -0
  26. package/docs/examples/backups/get-restoration.md +13 -0
  27. package/docs/examples/backups/list-archives.md +13 -0
  28. package/docs/examples/backups/list-policies.md +13 -0
  29. package/docs/examples/backups/list-restorations.md +13 -0
  30. package/docs/examples/backups/update-policy.md +17 -0
  31. package/docs/examples/console/create-source.md +17 -0
  32. package/docs/examples/console/get-campaign.md +13 -0
  33. package/docs/examples/console/get-copon.md +13 -0
  34. package/docs/examples/console/plans.md +11 -0
  35. package/docs/examples/console/regions.md +11 -0
  36. package/docs/examples/health/get-queue-billing-aggregation.md +13 -0
  37. package/docs/examples/health/get-queue-priority-builds.md +13 -0
  38. package/docs/examples/organizations/add-credit.md +14 -0
  39. package/docs/examples/organizations/create-invoice-payment.md +15 -0
  40. package/docs/examples/organizations/create.md +17 -0
  41. package/docs/examples/organizations/delete-backup-payment-method.md +13 -0
  42. package/docs/examples/organizations/delete-billing-address.md +13 -0
  43. package/docs/examples/organizations/delete-default-payment-method.md +13 -0
  44. package/docs/examples/organizations/delete.md +13 -0
  45. package/docs/examples/organizations/get-aggregation.md +14 -0
  46. package/docs/examples/organizations/get-billing-address.md +14 -0
  47. package/docs/examples/organizations/get-credit.md +14 -0
  48. package/docs/examples/organizations/get-invoice-download.md +14 -0
  49. package/docs/examples/organizations/get-invoice-view.md +14 -0
  50. package/docs/examples/organizations/get-invoice.md +14 -0
  51. package/docs/examples/organizations/get-payment-method.md +14 -0
  52. package/docs/examples/organizations/get-plan.md +13 -0
  53. package/docs/examples/organizations/get-scopes.md +13 -0
  54. package/docs/examples/organizations/get-usage.md +15 -0
  55. package/docs/examples/organizations/list-aggregations.md +14 -0
  56. package/docs/examples/organizations/list-invoices.md +14 -0
  57. package/docs/examples/organizations/list.md +14 -0
  58. package/docs/examples/organizations/set-backup-payment-method.md +14 -0
  59. package/docs/examples/organizations/set-billing-address.md +14 -0
  60. package/docs/examples/organizations/set-billing-email.md +14 -0
  61. package/docs/examples/organizations/set-billing-tax-id.md +14 -0
  62. package/docs/examples/organizations/set-default-payment-method.md +14 -0
  63. package/docs/examples/organizations/update-budget.md +15 -0
  64. package/docs/examples/organizations/update-plan.md +16 -0
  65. package/package.json +1 -1
  66. package/src/client.ts +1 -1
  67. package/src/enums/billing-plan.ts +5 -0
  68. package/src/enums/runtime.ts +2 -5
  69. package/src/index.ts +3 -0
  70. package/src/models.ts +1120 -1
  71. package/src/services/account.ts +336 -0
  72. package/src/services/backups.ts +425 -0
  73. package/src/services/console.ts +148 -0
  74. package/src/services/health.ts +56 -0
  75. package/src/services/organizations.ts +924 -0
  76. package/types/enums/billing-plan.d.ts +5 -0
  77. package/types/enums/runtime.d.ts +2 -5
  78. package/types/index.d.ts +3 -0
  79. package/types/models.d.ts +1120 -1
  80. package/types/services/account.d.ts +103 -0
  81. package/types/services/backups.d.ts +128 -0
  82. package/types/services/console.d.ts +47 -0
  83. package/types/services/health.d.ts +18 -0
  84. package/types/services/organizations.d.ts +282 -0
  85. package/.travis.yml +0 -32
package/types/models.d.ts CHANGED
@@ -559,6 +559,14 @@ export declare namespace Models {
559
559
  * If database is enabled. Can be 'enabled' or 'disabled'. When disabled, the database is inaccessible to users, but remains accessible to Server SDKs using API keys.
560
560
  */
561
561
  enabled: boolean;
562
+ /**
563
+ * Database backup policies.
564
+ */
565
+ policies: Index[];
566
+ /**
567
+ * Database backup archives.
568
+ */
569
+ archives: Collection[];
562
570
  };
563
571
  /**
564
572
  * Collection
@@ -2593,6 +2601,14 @@ export declare namespace Models {
2593
2601
  * SMTP server secure protocol
2594
2602
  */
2595
2603
  smtpSecure: string;
2604
+ /**
2605
+ * Number of times the ping was received for this project.
2606
+ */
2607
+ pingCount: number;
2608
+ /**
2609
+ * Last ping datetime in ISO 8601 format.
2610
+ */
2611
+ pingedAt: string;
2596
2612
  /**
2597
2613
  * Email/Password auth method status
2598
2614
  */
@@ -2665,6 +2681,10 @@ export declare namespace Models {
2665
2681
  * Messaging service status
2666
2682
  */
2667
2683
  serviceStatusForMessaging: boolean;
2684
+ /**
2685
+ * Project region
2686
+ */
2687
+ region: number;
2668
2688
  };
2669
2689
  /**
2670
2690
  * Webhook
@@ -3969,7 +3989,7 @@ export declare namespace Models {
3969
3989
  */
3970
3990
  $id: string;
3971
3991
  /**
3972
- * Variable creation date in ISO 8601 format.
3992
+ * Migration creation date in ISO 8601 format.
3973
3993
  */
3974
3994
  $createdAt: string;
3975
3995
  /**
@@ -4059,4 +4079,1103 @@ export declare namespace Models {
4059
4079
  */
4060
4080
  displayName: string;
4061
4081
  };
4082
+ /**
4083
+ * AdditionalResource
4084
+ */
4085
+ type AdditionalResource = {
4086
+ /**
4087
+ * Resource unit
4088
+ */
4089
+ unit: string;
4090
+ /**
4091
+ * Price currency
4092
+ */
4093
+ currency: string;
4094
+ /**
4095
+ * Price
4096
+ */
4097
+ price: number;
4098
+ /**
4099
+ * Resource value
4100
+ */
4101
+ value: number;
4102
+ };
4103
+ /**
4104
+ * AggregationTeam
4105
+ */
4106
+ type AggregationTeam = {
4107
+ /**
4108
+ * Aggregation ID.
4109
+ */
4110
+ $id: string;
4111
+ /**
4112
+ * Aggregation creation time in ISO 8601 format.
4113
+ */
4114
+ $createdAt: string;
4115
+ /**
4116
+ * Aggregation update date in ISO 8601 format.
4117
+ */
4118
+ $updatedAt: string;
4119
+ /**
4120
+ * Aggregation permissions. [Learn more about permissions](/docs/permissions).
4121
+ */
4122
+ $permissions: string[];
4123
+ /**
4124
+ * Beginning date of the invoice
4125
+ */
4126
+ from: string;
4127
+ /**
4128
+ * End date of the invoice
4129
+ */
4130
+ to: string;
4131
+ /**
4132
+ * Total storage usage
4133
+ */
4134
+ usageStorage: number;
4135
+ /**
4136
+ * Total storage usage with builds storage
4137
+ */
4138
+ usageTotalStorage: number;
4139
+ /**
4140
+ * Total files storage usage
4141
+ */
4142
+ usageFilesStorage: number;
4143
+ /**
4144
+ * Total deployments storage usage
4145
+ */
4146
+ usageDeploymentsStorage: number;
4147
+ /**
4148
+ * Total builds storage usage
4149
+ */
4150
+ usageBuildsStorage: number;
4151
+ /**
4152
+ * Total databases storage usage
4153
+ */
4154
+ usageDatabasesStorage: number;
4155
+ /**
4156
+ * Total active users for the billing period
4157
+ */
4158
+ usageUsers: number;
4159
+ /**
4160
+ * Total number of executions for the billing period
4161
+ */
4162
+ usageExecutions: number;
4163
+ /**
4164
+ * Total bandwidth usage for the billing period
4165
+ */
4166
+ usageBandwidth: number;
4167
+ /**
4168
+ * Total realtime usage for the billing period
4169
+ */
4170
+ usageRealtime: number;
4171
+ /**
4172
+ * Additional members
4173
+ */
4174
+ additionalMembers: number;
4175
+ /**
4176
+ * Additional members cost
4177
+ */
4178
+ additionalMemberAmount: number;
4179
+ /**
4180
+ * Additional storage usage cost
4181
+ */
4182
+ additionalStorageAmount: number;
4183
+ /**
4184
+ * Additional users usage cost.
4185
+ */
4186
+ additionalUsersAmount: number;
4187
+ /**
4188
+ * Additional executions usage cost
4189
+ */
4190
+ additionalExecutionsAmount: number;
4191
+ /**
4192
+ * Additional bandwidth usage cost
4193
+ */
4194
+ additionalBandwidthAmount: number;
4195
+ /**
4196
+ * Additional realtime usage cost
4197
+ */
4198
+ additionalRealtimeAmount: number;
4199
+ /**
4200
+ * Aggregated amount
4201
+ */
4202
+ amount: number;
4203
+ };
4204
+ /**
4205
+ * Archive
4206
+ */
4207
+ type BackupArchive = {
4208
+ /**
4209
+ * Archive ID.
4210
+ */
4211
+ $id: string;
4212
+ /**
4213
+ * Archive creation time in ISO 8601 format.
4214
+ */
4215
+ $createdAt: string;
4216
+ /**
4217
+ * Archive update date in ISO 8601 format.
4218
+ */
4219
+ $updatedAt: string;
4220
+ /**
4221
+ * Archive policy ID.
4222
+ */
4223
+ policyId: string;
4224
+ /**
4225
+ * Archive size in bytes.
4226
+ */
4227
+ size: number;
4228
+ /**
4229
+ * The status of the archive creation. Possible values: pending, processing, uploading, completed, failed.
4230
+ */
4231
+ status: string;
4232
+ /**
4233
+ * The backup start time.
4234
+ */
4235
+ startedAt: string;
4236
+ /**
4237
+ * Migration ID.
4238
+ */
4239
+ migrationId: string;
4240
+ /**
4241
+ * The services that are backed up by this archive.
4242
+ */
4243
+ services: string[];
4244
+ /**
4245
+ * The resources that are backed up by this archive.
4246
+ */
4247
+ resources: string[];
4248
+ /**
4249
+ * The resource ID to backup. Set only if this archive should backup a single resource.
4250
+ */
4251
+ resourceId?: string;
4252
+ /**
4253
+ * The resource type to backup. Set only if this archive should backup a single resource.
4254
+ */
4255
+ resourceType?: string;
4256
+ };
4257
+ /**
4258
+ * BillingAddress
4259
+ */
4260
+ type BillingAddress = {
4261
+ /**
4262
+ * Region ID
4263
+ */
4264
+ $id: string;
4265
+ /**
4266
+ * Street address
4267
+ */
4268
+ streetAddress: string;
4269
+ /**
4270
+ * Address line 2
4271
+ */
4272
+ addressLine2: string;
4273
+ /**
4274
+ * Address country
4275
+ */
4276
+ country: string;
4277
+ /**
4278
+ * city
4279
+ */
4280
+ city: string;
4281
+ /**
4282
+ * state
4283
+ */
4284
+ state: string;
4285
+ /**
4286
+ * postal code
4287
+ */
4288
+ postalCode: string;
4289
+ };
4290
+ /**
4291
+ * billingPlan
4292
+ */
4293
+ type BillingPlan = {
4294
+ /**
4295
+ * Plan ID.
4296
+ */
4297
+ $id: string;
4298
+ /**
4299
+ * Plan name
4300
+ */
4301
+ name: string;
4302
+ /**
4303
+ * Price
4304
+ */
4305
+ price: number;
4306
+ /**
4307
+ * Trial days
4308
+ */
4309
+ trial: number;
4310
+ /**
4311
+ * Bandwidth
4312
+ */
4313
+ bandwidth: number;
4314
+ /**
4315
+ * Storage
4316
+ */
4317
+ storage: number;
4318
+ /**
4319
+ * Members
4320
+ */
4321
+ members: number;
4322
+ /**
4323
+ * Webhooks
4324
+ */
4325
+ webhooks: number;
4326
+ /**
4327
+ * Platofrms
4328
+ */
4329
+ platforms: number;
4330
+ /**
4331
+ * Users
4332
+ */
4333
+ users: number;
4334
+ /**
4335
+ * Teams
4336
+ */
4337
+ teams: number;
4338
+ /**
4339
+ * Databases
4340
+ */
4341
+ databases: number;
4342
+ /**
4343
+ * Buckets
4344
+ */
4345
+ buckets: number;
4346
+ /**
4347
+ * File size
4348
+ */
4349
+ fileSize: number;
4350
+ /**
4351
+ * Functions
4352
+ */
4353
+ functions: number;
4354
+ /**
4355
+ * Function executions
4356
+ */
4357
+ executions: number;
4358
+ /**
4359
+ * Realtime connections
4360
+ */
4361
+ realtime: number;
4362
+ /**
4363
+ * Log days
4364
+ */
4365
+ logs: number;
4366
+ /**
4367
+ * Additional resources
4368
+ */
4369
+ addons: AdditionalResource[];
4370
+ /**
4371
+ * Custom SMTP
4372
+ */
4373
+ customSmtp: boolean;
4374
+ /**
4375
+ * Appwrite branding in email
4376
+ */
4377
+ emailBranding: boolean;
4378
+ /**
4379
+ * Does plan require payment method
4380
+ */
4381
+ requiresPaymentMethod: boolean;
4382
+ /**
4383
+ * Does plan require billing address
4384
+ */
4385
+ requiresBillingAddress: boolean;
4386
+ /**
4387
+ * Is the billing plan available
4388
+ */
4389
+ isAvailable: boolean;
4390
+ /**
4391
+ * Can user change the plan themselves
4392
+ */
4393
+ selfService: boolean;
4394
+ };
4395
+ /**
4396
+ * Campaign
4397
+ */
4398
+ type Campaign = {
4399
+ /**
4400
+ * Campaign ID
4401
+ */
4402
+ $id: string;
4403
+ /**
4404
+ * Campaign template
4405
+ */
4406
+ template: string;
4407
+ /**
4408
+ * Campaign title
4409
+ */
4410
+ title: string;
4411
+ /**
4412
+ * Campaign description
4413
+ */
4414
+ description: string;
4415
+ /**
4416
+ * Billing plan campaign is associated with
4417
+ */
4418
+ plan?: string;
4419
+ /**
4420
+ * Campaign CTA
4421
+ */
4422
+ cta?: string;
4423
+ /**
4424
+ * Campaign info when claimed
4425
+ */
4426
+ claimed?: string;
4427
+ /**
4428
+ * Campaign infor when unclaimed
4429
+ */
4430
+ unclaimed?: string;
4431
+ /**
4432
+ * Campaign images
4433
+ */
4434
+ image?: object;
4435
+ /**
4436
+ * Campaign reviews
4437
+ */
4438
+ reviews?: Review[];
4439
+ /**
4440
+ * Campaign valid only for new orgs.
4441
+ */
4442
+ onlyNewOrgs?: boolean;
4443
+ /**
4444
+ * Is footer
4445
+ */
4446
+ footer?: boolean;
4447
+ };
4448
+ /**
4449
+ * Coupon
4450
+ */
4451
+ type Coupon = {
4452
+ /**
4453
+ * coupon ID
4454
+ */
4455
+ $id: string;
4456
+ /**
4457
+ * coupon ID
4458
+ */
4459
+ code: string;
4460
+ /**
4461
+ * Provided credit amount
4462
+ */
4463
+ credits: number;
4464
+ /**
4465
+ * Coupon expiration time in ISO 8601 format.
4466
+ */
4467
+ expiration: string;
4468
+ /**
4469
+ * Credit validity in days.
4470
+ */
4471
+ validity: number;
4472
+ /**
4473
+ * Campaign the coupon is associated with`.
4474
+ */
4475
+ campaign: string;
4476
+ /**
4477
+ * Status of the coupon. Can be one of `disabled`, `active` or `expired`.
4478
+ */
4479
+ status: string;
4480
+ };
4481
+ /**
4482
+ * Credit
4483
+ */
4484
+ type Credit = {
4485
+ /**
4486
+ * Credit ID.
4487
+ */
4488
+ $id: string;
4489
+ /**
4490
+ * Credit creation time in ISO 8601 format.
4491
+ */
4492
+ $createdAt: string;
4493
+ /**
4494
+ * Credit update date in ISO 8601 format.
4495
+ */
4496
+ $updatedAt: string;
4497
+ /**
4498
+ * Credit permissions. [Learn more about permissions](/docs/permissions).
4499
+ */
4500
+ $permissions: string[];
4501
+ /**
4502
+ * coupon ID
4503
+ */
4504
+ couponId: string;
4505
+ /**
4506
+ * ID of the User.
4507
+ */
4508
+ userId: string;
4509
+ /**
4510
+ * ID of the Team.
4511
+ */
4512
+ teamId: string;
4513
+ /**
4514
+ * Provided credit amount
4515
+ */
4516
+ credits: number;
4517
+ /**
4518
+ * Provided credit amount
4519
+ */
4520
+ total: number;
4521
+ /**
4522
+ * Credit expiration time in ISO 8601 format.
4523
+ */
4524
+ expiration: string;
4525
+ /**
4526
+ * Status of the credit. Can be one of `disabled`, `active` or `expired`.
4527
+ */
4528
+ status: string;
4529
+ };
4530
+ /**
4531
+ * CreditList
4532
+ */
4533
+ type CreditList = {
4534
+ /**
4535
+ * Credits
4536
+ */
4537
+ credits: Credit[];
4538
+ /**
4539
+ * Total number of credits
4540
+ */
4541
+ total: number;
4542
+ /**
4543
+ * Total available credit balance in USD
4544
+ */
4545
+ available: number;
4546
+ };
4547
+ /**
4548
+ * Invoice
4549
+ */
4550
+ type Invoice = {
4551
+ /**
4552
+ * Invoice ID.
4553
+ */
4554
+ $id: string;
4555
+ /**
4556
+ * Invoice creation time in ISO 8601 format.
4557
+ */
4558
+ $createdAt: string;
4559
+ /**
4560
+ * Invoice update date in ISO 8601 format.
4561
+ */
4562
+ $updatedAt: string;
4563
+ /**
4564
+ * Invoice permissions. [Learn more about permissions](/docs/permissions).
4565
+ */
4566
+ $permissions: string[];
4567
+ /**
4568
+ * Project ID
4569
+ */
4570
+ teamId: string;
4571
+ /**
4572
+ * Aggregation ID
4573
+ */
4574
+ aggregationId: string;
4575
+ /**
4576
+ * Billing plan selected. Can be one of `tier-0`, `tier-1` or `tier-2`.
4577
+ */
4578
+ plan: string;
4579
+ /**
4580
+ * Usage breakdown per resource
4581
+ */
4582
+ usage: object;
4583
+ /**
4584
+ * Invoice Amount
4585
+ */
4586
+ amount: number;
4587
+ /**
4588
+ * Tax percentage
4589
+ */
4590
+ tax: number;
4591
+ /**
4592
+ * Tax amount
4593
+ */
4594
+ taxAmount: number;
4595
+ /**
4596
+ * VAT percentage
4597
+ */
4598
+ vat: number;
4599
+ /**
4600
+ * VAT amount
4601
+ */
4602
+ vatAmount: number;
4603
+ /**
4604
+ * Gross amount after vat, tax, and discounts applied.
4605
+ */
4606
+ grossAmount: number;
4607
+ /**
4608
+ * Credits used.
4609
+ */
4610
+ creditsUsed: number;
4611
+ /**
4612
+ * Currency the invoice is in
4613
+ */
4614
+ currency: string;
4615
+ /**
4616
+ * Client secret for processing failed payments in front-end
4617
+ */
4618
+ clientSecret: string;
4619
+ /**
4620
+ * Invoice status
4621
+ */
4622
+ status: string;
4623
+ /**
4624
+ * Last payment error associated with the invoice
4625
+ */
4626
+ lastError: string;
4627
+ /**
4628
+ * Invoice due date.
4629
+ */
4630
+ dueAt: string;
4631
+ /**
4632
+ * Beginning date of the invoice
4633
+ */
4634
+ from: string;
4635
+ /**
4636
+ * End date of the invoice
4637
+ */
4638
+ to: string;
4639
+ };
4640
+ /**
4641
+ * Organization
4642
+ */
4643
+ type Organization<Preferences extends Models.Preferences> = {
4644
+ /**
4645
+ * Team ID.
4646
+ */
4647
+ $id: string;
4648
+ /**
4649
+ * Team creation date in ISO 8601 format.
4650
+ */
4651
+ $createdAt: string;
4652
+ /**
4653
+ * Team update date in ISO 8601 format.
4654
+ */
4655
+ $updatedAt: string;
4656
+ /**
4657
+ * Team name.
4658
+ */
4659
+ name: string;
4660
+ /**
4661
+ * Total number of team members.
4662
+ */
4663
+ total: number;
4664
+ /**
4665
+ * Team preferences as a key-value object
4666
+ */
4667
+ prefs: Preferences;
4668
+ /**
4669
+ * Project budget limit
4670
+ */
4671
+ billingBudget: number;
4672
+ /**
4673
+ * Project budget limit
4674
+ */
4675
+ budgetAlerts: string[];
4676
+ /**
4677
+ * Billing plan selected. Can be one of `tier-0`, `tier-1` or `tier-2`.
4678
+ */
4679
+ billingPlan: string;
4680
+ /**
4681
+ * Billing email set for the organization.
4682
+ */
4683
+ billingEmail: string;
4684
+ /**
4685
+ * Billing cycle start date.
4686
+ */
4687
+ billingStartDate: string;
4688
+ /**
4689
+ * Current invoice cycle start date.
4690
+ */
4691
+ billingCurrentInvoiceDate: string;
4692
+ /**
4693
+ * Next invoice cycle start date.
4694
+ */
4695
+ billingNextInvoiceDate: string;
4696
+ /**
4697
+ * Start date of trial.
4698
+ */
4699
+ billingTrialStartDate: string;
4700
+ /**
4701
+ * Number of trial days.
4702
+ */
4703
+ billingTrialDays: number;
4704
+ /**
4705
+ * Current active aggregation id.
4706
+ */
4707
+ billingAggregationId: string;
4708
+ /**
4709
+ * Default payment method.
4710
+ */
4711
+ paymentMethodId: string;
4712
+ /**
4713
+ * Default payment method.
4714
+ */
4715
+ billingAddressId: string;
4716
+ /**
4717
+ * Backup payment method.
4718
+ */
4719
+ backupPaymentMethodId: string;
4720
+ /**
4721
+ * Organization agreements
4722
+ */
4723
+ agreementBAA: string;
4724
+ /**
4725
+ * Program manager&#039;s name.
4726
+ */
4727
+ programManagerName: string;
4728
+ /**
4729
+ * Program manager&#039;s calendar link.
4730
+ */
4731
+ programManagerCalendar: string;
4732
+ /**
4733
+ * Program&#039;s discord channel name.
4734
+ */
4735
+ programDiscordChannelName: string;
4736
+ /**
4737
+ * Program&#039;s discord channel URL.
4738
+ */
4739
+ programDiscordChannelUrl: string;
4740
+ /**
4741
+ * Billing limits reached
4742
+ */
4743
+ billingLimits: object;
4744
+ /**
4745
+ * Billing plan downgrade
4746
+ */
4747
+ billingPlanDowngrade: object;
4748
+ /**
4749
+ * Tax Id
4750
+ */
4751
+ billingTaxId: string;
4752
+ /**
4753
+ * Marked for deletion
4754
+ */
4755
+ markedForDeletion: boolean;
4756
+ };
4757
+ /**
4758
+ * paymentMethod
4759
+ */
4760
+ type PaymentMethod = {
4761
+ /**
4762
+ * Payment Method ID.
4763
+ */
4764
+ $id: string;
4765
+ /**
4766
+ * Payment method creation time in ISO 8601 format.
4767
+ */
4768
+ $createdAt: string;
4769
+ /**
4770
+ * Payment method update date in ISO 8601 format.
4771
+ */
4772
+ $updatedAt: string;
4773
+ /**
4774
+ * Payment method permissions. [Learn more about permissions](/docs/permissions).
4775
+ */
4776
+ $permissions: string[];
4777
+ /**
4778
+ * Payment method ID from the payment provider
4779
+ */
4780
+ providerMethodId: string;
4781
+ /**
4782
+ * Client secret hash for payment setup
4783
+ */
4784
+ clientSecret: string;
4785
+ /**
4786
+ * User ID from the payment provider.
4787
+ */
4788
+ providerUserId: string;
4789
+ /**
4790
+ * ID of the Team.
4791
+ */
4792
+ userId: string;
4793
+ /**
4794
+ * Expiry month of the payment method.
4795
+ */
4796
+ expiryMonth: number;
4797
+ /**
4798
+ * Expiry year of the payment method.
4799
+ */
4800
+ expiryYear: number;
4801
+ /**
4802
+ * Last 4 digit of the payment method
4803
+ */
4804
+ last4: string;
4805
+ /**
4806
+ * Payment method brand
4807
+ */
4808
+ brand: string;
4809
+ /**
4810
+ * Name of the owner
4811
+ */
4812
+ name: string;
4813
+ /**
4814
+ * Last payment error associated with the payment method.
4815
+ */
4816
+ lastError: string;
4817
+ /**
4818
+ * True when it&#039;s the default payment method.
4819
+ */
4820
+ default: boolean;
4821
+ /**
4822
+ * True when payment method has expired.
4823
+ */
4824
+ expired: boolean;
4825
+ /**
4826
+ * True when payment method has failed to process multiple times.
4827
+ */
4828
+ failed: boolean;
4829
+ };
4830
+ /**
4831
+ * backup
4832
+ */
4833
+ type BackupPolicy = {
4834
+ /**
4835
+ * Backup policy ID.
4836
+ */
4837
+ $id: string;
4838
+ /**
4839
+ * Backup policy name.
4840
+ */
4841
+ name: string;
4842
+ /**
4843
+ * Policy creation date in ISO 8601 format.
4844
+ */
4845
+ $createdAt: string;
4846
+ /**
4847
+ * Policy update date in ISO 8601 format.
4848
+ */
4849
+ $updatedAt: string;
4850
+ /**
4851
+ * The services that are backed up by this policy.
4852
+ */
4853
+ services: string[];
4854
+ /**
4855
+ * The resources that are backed up by this policy.
4856
+ */
4857
+ resources: string[];
4858
+ /**
4859
+ * The resource ID to backup. Set only if this policy should backup a single resource.
4860
+ */
4861
+ resourceId?: string;
4862
+ /**
4863
+ * The resource type to backup. Set only if this policy should backup a single resource.
4864
+ */
4865
+ resourceType?: string;
4866
+ /**
4867
+ * How many days to keep the backup before it will be automatically deleted.
4868
+ */
4869
+ retention: number;
4870
+ /**
4871
+ * Policy backup schedule in CRON format.
4872
+ */
4873
+ schedule: string;
4874
+ /**
4875
+ * Is this policy enabled.
4876
+ */
4877
+ enabled: boolean;
4878
+ };
4879
+ /**
4880
+ * Region
4881
+ */
4882
+ type ConsoleRegion = {
4883
+ /**
4884
+ * Region ID
4885
+ */
4886
+ $id: string;
4887
+ /**
4888
+ * Region name
4889
+ */
4890
+ name: string;
4891
+ /**
4892
+ * Is the region disabled.
4893
+ */
4894
+ disabled: boolean;
4895
+ /**
4896
+ * Is this the region default.
4897
+ */
4898
+ default: boolean;
4899
+ /**
4900
+ * Region flag code.
4901
+ */
4902
+ flag: string;
4903
+ };
4904
+ /**
4905
+ * Restoration
4906
+ */
4907
+ type BackupRestoration = {
4908
+ /**
4909
+ * Restoration ID.
4910
+ */
4911
+ $id: string;
4912
+ /**
4913
+ * Restoration creation time in ISO 8601 format.
4914
+ */
4915
+ $createdAt: string;
4916
+ /**
4917
+ * Restoration update date in ISO 8601 format.
4918
+ */
4919
+ $updatedAt: string;
4920
+ /**
4921
+ * Backup archive ID.
4922
+ */
4923
+ archiveId: string;
4924
+ /**
4925
+ * Backup policy ID.
4926
+ */
4927
+ policyId: string;
4928
+ /**
4929
+ * The status of the restoration. Possible values: pending, downloading, processing, completed, failed.
4930
+ */
4931
+ status: string;
4932
+ /**
4933
+ * The backup start time.
4934
+ */
4935
+ startedAt: string;
4936
+ /**
4937
+ * Migration ID.
4938
+ */
4939
+ migrationId: string;
4940
+ /**
4941
+ * The services that are backed up by this policy.
4942
+ */
4943
+ services: string[];
4944
+ /**
4945
+ * The resources that are backed up by this policy.
4946
+ */
4947
+ resources: string[];
4948
+ /**
4949
+ * Optional data in key-value object.
4950
+ */
4951
+ options: string;
4952
+ };
4953
+ /**
4954
+ * Review
4955
+ */
4956
+ type Review = {
4957
+ /**
4958
+ * Name of user
4959
+ */
4960
+ name: string;
4961
+ /**
4962
+ * Reviewer image
4963
+ */
4964
+ image: string;
4965
+ /**
4966
+ * Reviewer description
4967
+ */
4968
+ description: string;
4969
+ /**
4970
+ * Review
4971
+ */
4972
+ review: string;
4973
+ };
4974
+ /**
4975
+ * Roles
4976
+ */
4977
+ type Roles = {
4978
+ /**
4979
+ * Array of scopes accessible to current user.
4980
+ */
4981
+ scopes: string[];
4982
+ /**
4983
+ * Array of roles assigned to current user.
4984
+ */
4985
+ roles: string[];
4986
+ };
4987
+ /**
4988
+ * UsageOrganization
4989
+ */
4990
+ type UsageOrganization = {
4991
+ /**
4992
+ * Aggregated stats for number of requests.
4993
+ */
4994
+ bandwidth: Metric[];
4995
+ /**
4996
+ * Aggregated stats for consumed bandwidth.
4997
+ */
4998
+ users: Metric[];
4999
+ /**
5000
+ * Aggregated stats for function executions.
5001
+ */
5002
+ executions: Metric[];
5003
+ /**
5004
+ * Aggregated stats for total users.
5005
+ */
5006
+ usersTotal: number;
5007
+ /**
5008
+ * Aggregated stats for total executions.
5009
+ */
5010
+ executionsTotal: number;
5011
+ /**
5012
+ * Aggregated stats for function executions in mb seconds.
5013
+ */
5014
+ executionsMBSecondsTotal: number;
5015
+ /**
5016
+ * Aggregated stats for function builds in mb seconds.
5017
+ */
5018
+ buildsMBSecondsTotal: number;
5019
+ /**
5020
+ * Aggregated stats for total file storage.
5021
+ */
5022
+ filesStorageTotal: number;
5023
+ /**
5024
+ * Aggregated stats for total builds storage.
5025
+ */
5026
+ buildsStorageTotal: number;
5027
+ /**
5028
+ * Aggregated stats for total deployments storage.
5029
+ */
5030
+ deploymentsStorageTotal: number;
5031
+ /**
5032
+ * Aggregated stats for total databases storage.
5033
+ */
5034
+ databasesStorageTotal: number;
5035
+ /**
5036
+ * Aggregated stats for total storage.
5037
+ */
5038
+ storageTotal: number;
5039
+ /**
5040
+ * Aggregated stats for each projects.
5041
+ */
5042
+ projects: UsageOrganizationProject[];
5043
+ };
5044
+ /**
5045
+ * UsageOrganizationProject
5046
+ */
5047
+ type UsageOrganizationProject = {
5048
+ /**
5049
+ * projectId
5050
+ */
5051
+ projectId: string;
5052
+ /**
5053
+ * Aggregated stats for number of requests.
5054
+ */
5055
+ bandwidth: Metric[];
5056
+ /**
5057
+ * Aggregated stats for consumed bandwidth.
5058
+ */
5059
+ users: Metric[];
5060
+ /**
5061
+ * Aggregated stats for function executions.
5062
+ */
5063
+ executions: number;
5064
+ /**
5065
+ * Aggregated stats for function executions in mb seconds.
5066
+ */
5067
+ executionsMBSeconds: number;
5068
+ /**
5069
+ * Aggregated stats for function builds in mb seconds.
5070
+ */
5071
+ buildsMBSeconds: number;
5072
+ /**
5073
+ * Aggregated stats for number of documents.
5074
+ */
5075
+ storage: number;
5076
+ };
5077
+ /**
5078
+ * Aggregation team list
5079
+ */
5080
+ type AggregationTeamList = {
5081
+ /**
5082
+ * Total number of aggregations documents that matched your query.
5083
+ */
5084
+ total: number;
5085
+ /**
5086
+ * List of aggregations.
5087
+ */
5088
+ aggregations: AggregationTeam[];
5089
+ };
5090
+ /**
5091
+ * Backup archive list
5092
+ */
5093
+ type BackupArchiveList = {
5094
+ /**
5095
+ * Total number of archives documents that matched your query.
5096
+ */
5097
+ total: number;
5098
+ /**
5099
+ * List of archives.
5100
+ */
5101
+ archives: BackupArchive[];
5102
+ };
5103
+ /**
5104
+ * Backup policy list
5105
+ */
5106
+ type BackupPolicyList = {
5107
+ /**
5108
+ * Total number of policies documents that matched your query.
5109
+ */
5110
+ total: number;
5111
+ /**
5112
+ * List of policies.
5113
+ */
5114
+ policies: BackupPolicy[];
5115
+ };
5116
+ /**
5117
+ * Backup restoration list
5118
+ */
5119
+ type BackupRestorationList = {
5120
+ /**
5121
+ * Total number of restorations documents that matched your query.
5122
+ */
5123
+ total: number;
5124
+ /**
5125
+ * List of restorations.
5126
+ */
5127
+ restorations: BackupRestoration[];
5128
+ };
5129
+ /**
5130
+ * Billing Invoices List
5131
+ */
5132
+ type InvoiceList = {
5133
+ /**
5134
+ * Total number of invoices documents that matched your query.
5135
+ */
5136
+ total: number;
5137
+ /**
5138
+ * List of invoices.
5139
+ */
5140
+ invoices: Invoice[];
5141
+ };
5142
+ /**
5143
+ * Billing plan list
5144
+ */
5145
+ type BillingPlanList = {
5146
+ /**
5147
+ * Total number of plans documents that matched your query.
5148
+ */
5149
+ total: number;
5150
+ /**
5151
+ * List of plans.
5152
+ */
5153
+ plans: BillingPlan[];
5154
+ };
5155
+ /**
5156
+ * Payment Methods List
5157
+ */
5158
+ type PaymentMethodList = {
5159
+ /**
5160
+ * Total number of paymentMethods documents that matched your query.
5161
+ */
5162
+ total: number;
5163
+ /**
5164
+ * List of paymentMethods.
5165
+ */
5166
+ paymentMethods: PaymentMethod[];
5167
+ };
5168
+ /**
5169
+ * Regions list
5170
+ */
5171
+ type ConsoleRegionList = {
5172
+ /**
5173
+ * Total number of regions documents that matched your query.
5174
+ */
5175
+ total: number;
5176
+ /**
5177
+ * List of regions.
5178
+ */
5179
+ regions: ConsoleRegion[];
5180
+ };
4062
5181
  }