@appwrite.io/console 12.2.0 → 13.1.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 (72) hide show
  1. package/README.md +2 -2
  2. package/dist/cjs/sdk.js +1719 -1204
  3. package/dist/cjs/sdk.js.map +1 -1
  4. package/dist/esm/sdk.js +1717 -1205
  5. package/dist/esm/sdk.js.map +1 -1
  6. package/dist/iife/sdk.js +1736 -1221
  7. package/package.json +1 -1
  8. package/types/channel.d.ts +8 -3
  9. package/types/client.d.ts +1 -1
  10. package/types/enums/account-key-scopes.d.ts +5 -0
  11. package/types/enums/appwrite-migration-resource.d.ts +1 -0
  12. package/types/enums/backup-services.d.ts +1 -0
  13. package/types/enums/{resource-type.d.ts → block-resource-type.d.ts} +2 -6
  14. package/types/enums/{theme.d.ts → browser-theme.d.ts} +1 -1
  15. package/types/enums/cache-database.d.ts +5 -0
  16. package/types/enums/cache-target.d.ts +8 -0
  17. package/types/enums/{registration-type.d.ts → domain-registration-type.d.ts} +1 -1
  18. package/types/enums/{filter-type.d.ts → domain-suggestion-type.d.ts} +1 -1
  19. package/types/enums/{model.d.ts → embedding-model.d.ts} +1 -1
  20. package/types/enums/{runtime.d.ts → function-runtime.d.ts} +4 -2
  21. package/types/enums/function-template-use-case.d.ts +9 -0
  22. package/types/enums/{name.d.ts → health-queue-name.d.ts} +1 -1
  23. package/types/enums/{on-duplicate.d.ts → migration-on-duplicate.d.ts} +1 -1
  24. package/types/enums/o-auth-2-google-prompt.d.ts +5 -0
  25. package/types/enums/o-auth-provider.d.ts +1 -3
  26. package/types/enums/organization-addon.d.ts +4 -0
  27. package/types/enums/organization-key-scopes.d.ts +12 -0
  28. package/types/enums/{auth-method.d.ts → project-auth-method-id.d.ts} +1 -1
  29. package/types/enums/{email-template-type.d.ts → project-email-template-id.d.ts} +1 -1
  30. package/types/enums/{email-template-locale.d.ts → project-email-template-locale.d.ts} +1 -1
  31. package/types/enums/{scopes.d.ts → project-key-scopes.d.ts} +10 -8
  32. package/types/enums/project-o-auth-2-google-prompt.d.ts +5 -0
  33. package/types/enums/project-o-auth-provider-id.d.ts +45 -0
  34. package/types/enums/{project-policy.d.ts → project-policy-id.d.ts} +1 -1
  35. package/types/enums/{protocol-id.d.ts → project-protocol-id.d.ts} +1 -1
  36. package/types/enums/{service-id.d.ts → project-service-id.d.ts} +3 -2
  37. package/types/enums/project-smtp-secure.d.ts +4 -0
  38. package/types/enums/project-status.d.ts +3 -0
  39. package/types/enums/query-suggestion-resource.d.ts +10 -1
  40. package/types/enums/redirect-status-code.d.ts +6 -0
  41. package/types/enums/schedule-resource-type.d.ts +6 -0
  42. package/types/enums/{adapter.d.ts → site-adapter.d.ts} +1 -1
  43. package/types/enums/{runtimes.d.ts → site-build-runtime.d.ts} +4 -2
  44. package/types/enums/{framework.d.ts → site-framework.d.ts} +1 -1
  45. package/types/enums/{use-cases.d.ts → site-template-use-case.d.ts} +3 -8
  46. package/types/index.d.ts +36 -26
  47. package/types/models.d.ts +1186 -1185
  48. package/types/services/account.d.ts +9 -9
  49. package/types/services/avatars.d.ts +5 -5
  50. package/types/services/console.d.ts +31 -0
  51. package/types/services/documents-db.d.ts +1 -4
  52. package/types/services/domains.d.ts +216 -216
  53. package/types/services/functions.d.ts +36 -25
  54. package/types/services/health.d.ts +5 -5
  55. package/types/services/manager.d.ts +49 -9
  56. package/types/services/migrations.d.ts +13 -13
  57. package/types/services/organization.d.ts +234 -0
  58. package/types/services/organizations.d.ts +5 -131
  59. package/types/services/presences.d.ts +166 -0
  60. package/types/services/project.d.ts +226 -215
  61. package/types/services/projects.d.ts +10 -159
  62. package/types/services/proxy.d.ts +5 -5
  63. package/types/services/realtime.d.ts +45 -3
  64. package/types/services/sites.d.ts +43 -32
  65. package/types/services/usage.d.ts +50 -0
  66. package/types/services/vectors-db.d.ts +6 -9
  67. package/types/enums/addon.d.ts +0 -3
  68. package/types/enums/build-runtime.d.ts +0 -91
  69. package/types/enums/frameworks.d.ts +0 -17
  70. package/types/enums/secure.d.ts +0 -4
  71. package/types/enums/status-code.d.ts +0 -6
  72. package/types/enums/status.d.ts +0 -3
package/types/models.d.ts CHANGED
@@ -7,6 +7,10 @@ import { DetectionRuntimeType } from "./enums/detection-runtime-type";
7
7
  import { DeploymentStatus } from "./enums/deployment-status";
8
8
  import { ExecutionTrigger } from "./enums/execution-trigger";
9
9
  import { ExecutionStatus } from "./enums/execution-status";
10
+ import { ProjectAuthMethodId } from "./enums/project-auth-method-id";
11
+ import { ProjectServiceId } from "./enums/project-service-id";
12
+ import { ProjectProtocolId } from "./enums/project-protocol-id";
13
+ import { OAuth2GooglePrompt } from "./enums/o-auth-2-google-prompt";
10
14
  import { PlatformType } from "./enums/platform-type";
11
15
  import { HealthAntivirusStatus } from "./enums/health-antivirus-status";
12
16
  import { HealthCheckStatus } from "./enums/health-check-status";
@@ -47,6 +51,19 @@ export declare namespace Models {
47
51
  */
48
52
  documents: Document[];
49
53
  };
54
+ /**
55
+ * Presences List
56
+ */
57
+ export type PresenceList = {
58
+ /**
59
+ * Total number of presences that matched your query.
60
+ */
61
+ total: number;
62
+ /**
63
+ * List of presences.
64
+ */
65
+ presences: Presence[];
66
+ };
50
67
  /**
51
68
  * Tables List
52
69
  */
@@ -788,11 +805,11 @@ export declare namespace Models {
788
805
  /**
789
806
  * Database backup policies.
790
807
  */
791
- policies: Index[];
808
+ policies: BackupPolicy[];
792
809
  /**
793
810
  * Database backup archives.
794
811
  */
795
- archives: Collection[];
812
+ archives: BackupArchive[];
796
813
  };
797
814
  /**
798
815
  * Embedding
@@ -3069,6 +3086,47 @@ export declare namespace Models {
3069
3086
  [key: string]: any;
3070
3087
  [__default]: true;
3071
3088
  };
3089
+ /**
3090
+ * Presence
3091
+ */
3092
+ export type Presence = {
3093
+ /**
3094
+ * Presence ID.
3095
+ */
3096
+ $id: string;
3097
+ /**
3098
+ * Presence creation date in ISO 8601 format.
3099
+ */
3100
+ $createdAt: string;
3101
+ /**
3102
+ * Presence update date in ISO 8601 format.
3103
+ */
3104
+ $updatedAt: string;
3105
+ /**
3106
+ * Presence permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).
3107
+ */
3108
+ $permissions: string[];
3109
+ /**
3110
+ * User ID.
3111
+ */
3112
+ userId: string;
3113
+ /**
3114
+ * Presence status.
3115
+ */
3116
+ status?: string;
3117
+ /**
3118
+ * Presence source.
3119
+ */
3120
+ source: string;
3121
+ /**
3122
+ * Presence expiry date in ISO 8601 format.
3123
+ */
3124
+ expiresAt?: string;
3125
+ /**
3126
+ * Presence metadata.
3127
+ */
3128
+ metadata?: object;
3129
+ };
3072
3130
  /**
3073
3131
  * Log
3074
3132
  */
@@ -3652,6 +3710,10 @@ export declare namespace Models {
3652
3710
  * File original size in bytes.
3653
3711
  */
3654
3712
  sizeOriginal: number;
3713
+ /**
3714
+ * File actual stored size in bytes after compression and/or encryption.
3715
+ */
3716
+ sizeActual: number;
3655
3717
  /**
3656
3718
  * Total number of chunks available
3657
3719
  */
@@ -3965,6 +4027,14 @@ export declare namespace Models {
3965
4027
  * Is VCS (Version Control System) connection is in silent mode? When in silence mode, no comments will be posted on the repository pull or merge requests
3966
4028
  */
3967
4029
  providerSilentMode: boolean;
4030
+ /**
4031
+ * List of branch name patterns that trigger automatic deployments. Supports glob wildcards. Empty list deploys on all branches.
4032
+ */
4033
+ providerBranches: string[];
4034
+ /**
4035
+ * List of file path patterns that trigger automatic deployments. Supports glob wildcards. Empty list deploys on all file changes.
4036
+ */
4037
+ providerPaths: string[];
3968
4038
  /**
3969
4039
  * Machine specification for deployment builds.
3970
4040
  */
@@ -4200,6 +4270,14 @@ export declare namespace Models {
4200
4270
  * Is VCS (Version Control System) connection is in silent mode? When in silence mode, no comments will be posted on the repository pull or merge requests
4201
4271
  */
4202
4272
  providerSilentMode: boolean;
4273
+ /**
4274
+ * List of branch name patterns that trigger automatic deployments. Supports glob wildcards. Empty list deploys on all branches.
4275
+ */
4276
+ providerBranches: string[];
4277
+ /**
4278
+ * List of file path patterns that trigger automatic deployments. Supports glob wildcards. Empty list deploys on all file changes.
4279
+ */
4280
+ providerPaths: string[];
4203
4281
  /**
4204
4282
  * Machine specification for deployment builds.
4205
4283
  */
@@ -4898,132 +4976,12 @@ export declare namespace Models {
4898
4976
  * Project name.
4899
4977
  */
4900
4978
  name: string;
4901
- /**
4902
- * Project description.
4903
- */
4904
- description: string;
4905
4979
  /**
4906
4980
  * Project team ID.
4907
4981
  */
4908
4982
  teamId: string;
4909
4983
  /**
4910
- * Project logo file ID.
4911
- */
4912
- logo: string;
4913
- /**
4914
- * Project website URL.
4915
- */
4916
- url: string;
4917
- /**
4918
- * Company legal name.
4919
- */
4920
- legalName: string;
4921
- /**
4922
- * Country code in [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1) two-character format.
4923
- */
4924
- legalCountry: string;
4925
- /**
4926
- * State name.
4927
- */
4928
- legalState: string;
4929
- /**
4930
- * City name.
4931
- */
4932
- legalCity: string;
4933
- /**
4934
- * Company Address.
4935
- */
4936
- legalAddress: string;
4937
- /**
4938
- * Company Tax ID.
4939
- */
4940
- legalTaxId: string;
4941
- /**
4942
- * Session duration in seconds.
4943
- */
4944
- authDuration: number;
4945
- /**
4946
- * Max users allowed. 0 is unlimited.
4947
- */
4948
- authLimit: number;
4949
- /**
4950
- * Max sessions allowed per user. 100 maximum.
4951
- */
4952
- authSessionsLimit: number;
4953
- /**
4954
- * Max allowed passwords in the history list per user. Max passwords limit allowed in history is 20. Use 0 for disabling password history.
4955
- */
4956
- authPasswordHistory: number;
4957
- /**
4958
- * Whether or not to check user's password against most commonly used passwords.
4959
- */
4960
- authPasswordDictionary: boolean;
4961
- /**
4962
- * Whether or not to check the user password for similarity with their personal data.
4963
- */
4964
- authPersonalDataCheck: boolean;
4965
- /**
4966
- * Whether or not to disallow disposable email addresses during signup and email updates.
4967
- */
4968
- authDisposableEmails: boolean;
4969
- /**
4970
- * Whether or not to require canonical email addresses during signup and email updates.
4971
- */
4972
- authCanonicalEmails: boolean;
4973
- /**
4974
- * Whether or not to disallow free email addresses during signup and email updates.
4975
- */
4976
- authFreeEmails: boolean;
4977
- /**
4978
- * An array of mock numbers and their corresponding verification codes (OTPs).
4979
- */
4980
- authMockNumbers: MockNumber[];
4981
- /**
4982
- * Whether or not to send session alert emails to users.
4983
- */
4984
- authSessionAlerts: boolean;
4985
- /**
4986
- * Whether or not to show user names in the teams membership response.
4987
- */
4988
- authMembershipsUserName: boolean;
4989
- /**
4990
- * Whether or not to show user emails in the teams membership response.
4991
- */
4992
- authMembershipsUserEmail: boolean;
4993
- /**
4994
- * Whether or not to show user MFA status in the teams membership response.
4995
- */
4996
- authMembershipsMfa: boolean;
4997
- /**
4998
- * Whether or not to show user IDs in the teams membership response.
4999
- */
5000
- authMembershipsUserId: boolean;
5001
- /**
5002
- * Whether or not to show user phone numbers in the teams membership response.
5003
- */
5004
- authMembershipsUserPhone: boolean;
5005
- /**
5006
- * Whether or not all existing sessions should be invalidated on password change
5007
- */
5008
- authInvalidateSessions: boolean;
5009
- /**
5010
- * List of Auth Providers.
5011
- */
5012
- oAuthProviders: AuthProvider[];
5013
- /**
5014
- * List of Platforms.
5015
- */
5016
- platforms: (Models.PlatformWeb | Models.PlatformApple | Models.PlatformAndroid | Models.PlatformWindows | Models.PlatformLinux)[];
5017
- /**
5018
- * List of Webhooks.
5019
- */
5020
- webhooks: Webhook[];
5021
- /**
5022
- * List of API Keys.
5023
- */
5024
- keys: Key[];
5025
- /**
5026
- * List of dev keys.
4984
+ * Deprecated since 1.9.5: List of dev keys.
5027
4985
  */
5028
4986
  devKeys: DevKey[];
5029
4987
  /**
@@ -5083,129 +5041,72 @@ export declare namespace Models {
5083
5041
  */
5084
5042
  status: string;
5085
5043
  /**
5086
- * Email/Password auth method status
5087
- */
5088
- authEmailPassword: boolean;
5089
- /**
5090
- * Magic URL auth method status
5091
- */
5092
- authUsersAuthMagicURL: boolean;
5093
- /**
5094
- * Email (OTP) auth method status
5095
- */
5096
- authEmailOtp: boolean;
5097
- /**
5098
- * Anonymous auth method status
5099
- */
5100
- authAnonymous: boolean;
5101
- /**
5102
- * Invites auth method status
5103
- */
5104
- authInvites: boolean;
5105
- /**
5106
- * JWT auth method status
5107
- */
5108
- authJWT: boolean;
5109
- /**
5110
- * Phone auth method status
5044
+ * List of auth methods.
5111
5045
  */
5112
- authPhone: boolean;
5046
+ authMethods: ProjectAuthMethod[];
5113
5047
  /**
5114
- * Account service status
5048
+ * List of services.
5115
5049
  */
5116
- serviceStatusForAccount: boolean;
5050
+ services: ProjectService[];
5117
5051
  /**
5118
- * Avatars service status
5052
+ * List of protocols.
5119
5053
  */
5120
- serviceStatusForAvatars: boolean;
5054
+ protocols: ProjectProtocol[];
5121
5055
  /**
5122
- * Databases (legacy) service status
5123
- */
5124
- serviceStatusForDatabases: boolean;
5125
- /**
5126
- * TablesDB service status
5127
- */
5128
- serviceStatusForTablesdb: boolean;
5129
- /**
5130
- * Locale service status
5131
- */
5132
- serviceStatusForLocale: boolean;
5133
- /**
5134
- * Health service status
5135
- */
5136
- serviceStatusForHealth: boolean;
5137
- /**
5138
- * Project service status
5139
- */
5140
- serviceStatusForProject: boolean;
5141
- /**
5142
- * Storage service status
5143
- */
5144
- serviceStatusForStorage: boolean;
5145
- /**
5146
- * Teams service status
5147
- */
5148
- serviceStatusForTeams: boolean;
5149
- /**
5150
- * Users service status
5151
- */
5152
- serviceStatusForUsers: boolean;
5153
- /**
5154
- * VCS service status
5155
- */
5156
- serviceStatusForVcs: boolean;
5157
- /**
5158
- * Sites service status
5159
- */
5160
- serviceStatusForSites: boolean;
5161
- /**
5162
- * Functions service status
5163
- */
5164
- serviceStatusForFunctions: boolean;
5165
- /**
5166
- * Proxy service status
5167
- */
5168
- serviceStatusForProxy: boolean;
5169
- /**
5170
- * GraphQL service status
5056
+ * Project region
5171
5057
  */
5172
- serviceStatusForGraphql: boolean;
5058
+ region: string;
5173
5059
  /**
5174
- * Migrations service status
5060
+ * Billing limits reached
5175
5061
  */
5176
- serviceStatusForMigrations: boolean;
5062
+ billingLimits?: BillingLimits;
5177
5063
  /**
5178
- * Messaging service status
5064
+ * Project blocks information
5179
5065
  */
5180
- serviceStatusForMessaging: boolean;
5066
+ blocks: Block[];
5181
5067
  /**
5182
- * REST protocol status
5068
+ * Last time the project was accessed via console. Used with plan's projectInactivityDays to determine if project is paused.
5183
5069
  */
5184
- protocolStatusForRest: boolean;
5070
+ consoleAccessedAt: string;
5071
+ };
5072
+ /**
5073
+ * ProjectAuthMethod
5074
+ */
5075
+ export type ProjectAuthMethod = {
5185
5076
  /**
5186
- * GraphQL protocol status
5077
+ * Auth method ID.
5187
5078
  */
5188
- protocolStatusForGraphql: boolean;
5079
+ $id: ProjectAuthMethodId;
5189
5080
  /**
5190
- * Websocket protocol status
5081
+ * Auth method status.
5191
5082
  */
5192
- protocolStatusForWebsocket: boolean;
5083
+ enabled: boolean;
5084
+ };
5085
+ /**
5086
+ * ProjectService
5087
+ */
5088
+ export type ProjectService = {
5193
5089
  /**
5194
- * Project region
5090
+ * Service ID.
5195
5091
  */
5196
- region: string;
5092
+ $id: ProjectServiceId;
5197
5093
  /**
5198
- * Billing limits reached
5094
+ * Service status.
5199
5095
  */
5200
- billingLimits: BillingLimits;
5096
+ enabled: boolean;
5097
+ };
5098
+ /**
5099
+ * ProjectProtocol
5100
+ */
5101
+ export type ProjectProtocol = {
5201
5102
  /**
5202
- * Project blocks information
5103
+ * Protocol ID.
5203
5104
  */
5204
- blocks: Block[];
5105
+ $id: ProjectProtocolId;
5205
5106
  /**
5206
- * Last time the project was accessed via console. Used with plan's projectInactivityDays to determine if project is paused.
5107
+ * Protocol status.
5207
5108
  */
5208
- consoleAccessedAt: string;
5109
+ enabled: boolean;
5209
5110
  };
5210
5111
  /**
5211
5112
  * Webhook
@@ -5613,6 +5514,10 @@ export declare namespace Models {
5613
5514
  * Google OAuth2 client secret.
5614
5515
  */
5615
5516
  clientSecret: string;
5517
+ /**
5518
+ * Google OAuth2 prompt values.
5519
+ */
5520
+ prompt: OAuth2GooglePrompt[];
5616
5521
  };
5617
5522
  /**
5618
5523
  * OAuth2Zoom
@@ -6450,31 +6355,6 @@ export declare namespace Models {
6450
6355
  */
6451
6356
  userMFA: boolean;
6452
6357
  };
6453
- /**
6454
- * AuthProvider
6455
- */
6456
- export type AuthProvider = {
6457
- /**
6458
- * Auth Provider.
6459
- */
6460
- key: string;
6461
- /**
6462
- * Auth Provider name.
6463
- */
6464
- name: string;
6465
- /**
6466
- * OAuth 2.0 application ID.
6467
- */
6468
- appId: string;
6469
- /**
6470
- * OAuth 2.0 application secret. Might be JSON string if provider requires extra configuration. This property is write-only and always returned empty.
6471
- */
6472
- secret: string;
6473
- /**
6474
- * Auth Provider is active and can be used to create session.
6475
- */
6476
- enabled: boolean;
6477
- };
6478
6358
  /**
6479
6359
  * Platform Web
6480
6360
  */
@@ -7079,6 +6959,23 @@ export declare namespace Models {
7079
6959
  */
7080
6960
  sessions: Metric[];
7081
6961
  };
6962
+ /**
6963
+ * UsagePresence
6964
+ */
6965
+ export type UsagePresence = {
6966
+ /**
6967
+ * Time range of the usage stats.
6968
+ */
6969
+ range: string;
6970
+ /**
6971
+ * Current total number of online users.
6972
+ */
6973
+ usersOnlineTotal: number;
6974
+ /**
6975
+ * Aggregated number of online users per period.
6976
+ */
6977
+ presences: Metric[];
6978
+ };
7082
6979
  /**
7083
6980
  * StorageUsage
7084
6981
  */
@@ -7606,7 +7503,7 @@ export declare namespace Models {
7606
7503
  outbound: Metric[];
7607
7504
  };
7608
7505
  /**
7609
- * UsageProject
7506
+ * Project
7610
7507
  */
7611
7508
  export type UsageProject = {
7612
7509
  /**
@@ -8692,6 +8589,10 @@ export declare namespace Models {
8692
8589
  * Number of functions to be migrated.
8693
8590
  */
8694
8591
  function: number;
8592
+ /**
8593
+ * Number of platforms to be migrated.
8594
+ */
8595
+ platform: number;
8695
8596
  /**
8696
8597
  * Number of sites to be migrated.
8697
8598
  */
@@ -8720,6 +8621,10 @@ export declare namespace Models {
8720
8621
  * Version of the Appwrite instance to be migrated.
8721
8622
  */
8722
8623
  version: string;
8624
+ /**
8625
+ * Number of backup policies to be migrated.
8626
+ */
8627
+ backuppolicy: number;
8723
8628
  };
8724
8629
  /**
8725
8630
  * ActivityEvent
@@ -8730,21 +8635,21 @@ export declare namespace Models {
8730
8635
  */
8731
8636
  $id: string;
8732
8637
  /**
8733
- * User type.
8638
+ * Actor type.
8734
8639
  */
8735
- userType: string;
8640
+ actorType: string;
8736
8641
  /**
8737
- * User ID.
8642
+ * Actor ID.
8738
8643
  */
8739
- userId: string;
8644
+ actorId: string;
8740
8645
  /**
8741
- * User Email.
8646
+ * Actor Email.
8742
8647
  */
8743
- userEmail: string;
8648
+ actorEmail: string;
8744
8649
  /**
8745
- * User Name.
8650
+ * Actor Name.
8746
8651
  */
8747
- userName: string;
8652
+ actorName: string;
8748
8653
  /**
8749
8654
  * Resource parent.
8750
8655
  */
@@ -8884,51 +8789,158 @@ export declare namespace Models {
8884
8789
  invoiceDesc: string;
8885
8790
  };
8886
8791
  /**
8887
- * AggregationTeam
8792
+ * Addon
8888
8793
  */
8889
- export type AggregationTeam = {
8794
+ export type Addon = {
8890
8795
  /**
8891
- * Aggregation ID.
8796
+ * Addon ID.
8892
8797
  */
8893
8798
  $id: string;
8894
8799
  /**
8895
- * Aggregation creation time in ISO 8601 format.
8800
+ * Addon creation time in ISO 8601 format.
8896
8801
  */
8897
8802
  $createdAt: string;
8898
8803
  /**
8899
- * Aggregation update date in ISO 8601 format.
8804
+ * Addon update date in ISO 8601 format.
8900
8805
  */
8901
8806
  $updatedAt: string;
8902
8807
  /**
8903
- * Aggregation permissions. [Learn more about permissions](/docs/permissions).
8808
+ * Addon permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).
8904
8809
  */
8905
8810
  $permissions: string[];
8906
8811
  /**
8907
- * Beginning date of the invoice
8812
+ * Addon key
8908
8813
  */
8909
- from: string;
8814
+ key: string;
8910
8815
  /**
8911
- * End date of the invoice
8816
+ * Resource type (organization or project)
8912
8817
  */
8913
- to: string;
8818
+ resourceType: string;
8914
8819
  /**
8915
- * Total storage usage
8820
+ * Resource ID
8916
8821
  */
8917
- usageStorage: number;
8822
+ resourceId: string;
8918
8823
  /**
8919
- * Total storage usage with builds storage
8824
+ * Payment status. Possible values: pending (awaiting payment confirmation e.g. 3DS), active (payment confirmed and addon is running).
8920
8825
  */
8921
- usageTotalStorage: number;
8826
+ status: string;
8922
8827
  /**
8923
- * Total files storage usage
8828
+ * Current value for this billing cycle. For toggle addons: 1 (on) or 0 (off). For numeric addons: the active quantity.
8924
8829
  */
8925
- usageFilesStorage: number;
8830
+ currentValue: number;
8926
8831
  /**
8927
- * Total deployments storage usage
8832
+ * Value to apply at the start of the next billing cycle. Null means no change is scheduled. For toggle addons, 0 means the addon will be removed at the next cycle.
8928
8833
  */
8929
- usageDeploymentsStorage: number;
8930
- /**
8931
- * Total builds storage usage
8834
+ nextValue?: number;
8835
+ };
8836
+ /**
8837
+ * AddonPrice
8838
+ */
8839
+ export type AddonPrice = {
8840
+ /**
8841
+ * Addon key.
8842
+ */
8843
+ addonKey: string;
8844
+ /**
8845
+ * Addon display name.
8846
+ */
8847
+ name: string;
8848
+ /**
8849
+ * Full monthly price of the addon.
8850
+ */
8851
+ monthlyPrice: number;
8852
+ /**
8853
+ * Calculated prorated amount for the current billing cycle.
8854
+ */
8855
+ proratedAmount: number;
8856
+ /**
8857
+ * Days remaining in the current billing cycle.
8858
+ */
8859
+ remainingDays: number;
8860
+ /**
8861
+ * Total days in the billing cycle.
8862
+ */
8863
+ totalCycleDays: number;
8864
+ /**
8865
+ * Currency code.
8866
+ */
8867
+ currency: string;
8868
+ /**
8869
+ * When the current billing cycle ends.
8870
+ */
8871
+ billingCycleEnd: string;
8872
+ };
8873
+ /**
8874
+ * Breakdown
8875
+ */
8876
+ export type AggregationBreakdown = {
8877
+ /**
8878
+ * Aggregation ID.
8879
+ */
8880
+ $id: string;
8881
+ /**
8882
+ * Project name
8883
+ */
8884
+ name: string;
8885
+ /**
8886
+ * Project region
8887
+ */
8888
+ region: string;
8889
+ /**
8890
+ * Aggregated amount
8891
+ */
8892
+ amount: number;
8893
+ /**
8894
+ *
8895
+ */
8896
+ resources: UsageResources[];
8897
+ };
8898
+ /**
8899
+ * Team
8900
+ */
8901
+ export type AggregationTeam = {
8902
+ /**
8903
+ * Aggregation ID.
8904
+ */
8905
+ $id: string;
8906
+ /**
8907
+ * Aggregation creation time in ISO 8601 format.
8908
+ */
8909
+ $createdAt: string;
8910
+ /**
8911
+ * Aggregation update date in ISO 8601 format.
8912
+ */
8913
+ $updatedAt: string;
8914
+ /**
8915
+ * Aggregation permissions. [Learn more about permissions](/docs/permissions).
8916
+ */
8917
+ $permissions: string[];
8918
+ /**
8919
+ * Beginning date of the invoice
8920
+ */
8921
+ from: string;
8922
+ /**
8923
+ * End date of the invoice
8924
+ */
8925
+ to: string;
8926
+ /**
8927
+ * Total storage usage
8928
+ */
8929
+ usageStorage: number;
8930
+ /**
8931
+ * Total storage usage with builds storage
8932
+ */
8933
+ usageTotalStorage: number;
8934
+ /**
8935
+ * Total files storage usage
8936
+ */
8937
+ usageFilesStorage: number;
8938
+ /**
8939
+ * Total deployments storage usage
8940
+ */
8941
+ usageDeploymentsStorage: number;
8942
+ /**
8943
+ * Total builds storage usage
8932
8944
  */
8933
8945
  usageBuildsStorage: number;
8934
8946
  /**
@@ -9004,31 +9016,6 @@ export declare namespace Models {
9004
9016
  */
9005
9017
  resources: UsageResources[];
9006
9018
  };
9007
- /**
9008
- * AggregationBreakdown
9009
- */
9010
- export type AggregationBreakdown = {
9011
- /**
9012
- * Aggregation ID.
9013
- */
9014
- $id: string;
9015
- /**
9016
- * Project name
9017
- */
9018
- name: string;
9019
- /**
9020
- * Project region
9021
- */
9022
- region: string;
9023
- /**
9024
- * Aggregated amount
9025
- */
9026
- amount: number;
9027
- /**
9028
- *
9029
- */
9030
- resources: UsageResources[];
9031
- };
9032
9019
  /**
9033
9020
  * Archive
9034
9021
  */
@@ -9083,7 +9070,7 @@ export declare namespace Models {
9083
9070
  resourceType?: string;
9084
9071
  };
9085
9072
  /**
9086
- * BillingAddress
9073
+ * Address
9087
9074
  */
9088
9075
  export type BillingAddress = {
9089
9076
  /**
@@ -9119,6 +9106,43 @@ export declare namespace Models {
9119
9106
  */
9120
9107
  postalCode: string;
9121
9108
  };
9109
+ /**
9110
+ * Limits
9111
+ */
9112
+ export type BillingLimits = {
9113
+ /**
9114
+ * Bandwidth limit
9115
+ */
9116
+ bandwidth?: number;
9117
+ /**
9118
+ * Storage limit
9119
+ */
9120
+ storage?: number;
9121
+ /**
9122
+ * Users limit
9123
+ */
9124
+ users?: number;
9125
+ /**
9126
+ * Executions limit
9127
+ */
9128
+ executions?: number;
9129
+ /**
9130
+ * GBHours limit
9131
+ */
9132
+ GBHours?: number;
9133
+ /**
9134
+ * Image transformations limit
9135
+ */
9136
+ imageTransformations?: number;
9137
+ /**
9138
+ * Auth phone limit
9139
+ */
9140
+ authPhone?: number;
9141
+ /**
9142
+ * Budget limit percentage
9143
+ */
9144
+ budgetLimit?: number;
9145
+ };
9122
9146
  /**
9123
9147
  * billingPlan
9124
9148
  */
@@ -9377,7 +9401,7 @@ export declare namespace Models {
9377
9401
  program?: Program;
9378
9402
  };
9379
9403
  /**
9380
- * BillingPlanAddon
9404
+ * Addon
9381
9405
  */
9382
9406
  export type BillingPlanAddon = {
9383
9407
  /**
@@ -9390,7 +9414,7 @@ export declare namespace Models {
9390
9414
  projects: BillingPlanAddonDetails;
9391
9415
  };
9392
9416
  /**
9393
- * BillingPlanAddonDetails
9417
+ * Details
9394
9418
  */
9395
9419
  export type BillingPlanAddonDetails = {
9396
9420
  /**
@@ -9427,7 +9451,7 @@ export declare namespace Models {
9427
9451
  invoiceDesc: string;
9428
9452
  };
9429
9453
  /**
9430
- * BillingPlanLimits
9454
+ * PlanLimits
9431
9455
  */
9432
9456
  export type BillingPlanLimits = {
9433
9457
  /**
@@ -9448,43 +9472,6 @@ export declare namespace Models {
9448
9472
  */
9449
9473
  baa: boolean;
9450
9474
  };
9451
- /**
9452
- * BillingLimits
9453
- */
9454
- export type BillingLimits = {
9455
- /**
9456
- * Bandwidth limit
9457
- */
9458
- bandwidth: number;
9459
- /**
9460
- * Storage limit
9461
- */
9462
- storage: number;
9463
- /**
9464
- * Users limit
9465
- */
9466
- users: number;
9467
- /**
9468
- * Executions limit
9469
- */
9470
- executions: number;
9471
- /**
9472
- * GBHours limit
9473
- */
9474
- GBHours: number;
9475
- /**
9476
- * Image transformations limit
9477
- */
9478
- imageTransformations: number;
9479
- /**
9480
- * Auth phone limit
9481
- */
9482
- authPhone: number;
9483
- /**
9484
- * Budget limit percentage
9485
- */
9486
- budgetLimit: number;
9487
- };
9488
9475
  /**
9489
9476
  * Block
9490
9477
  */
@@ -9596,47 +9583,6 @@ export declare namespace Models {
9596
9583
  */
9597
9584
  footer?: boolean;
9598
9585
  };
9599
- /**
9600
- * Program
9601
- */
9602
- export type Program = {
9603
- /**
9604
- * Program ID
9605
- */
9606
- $id: string;
9607
- /**
9608
- * Program title
9609
- */
9610
- title: string;
9611
- /**
9612
- * Program description
9613
- */
9614
- description: string;
9615
- /**
9616
- * Program tag for highlighting on console
9617
- */
9618
- tag: string;
9619
- /**
9620
- * Program icon for highlighting on console
9621
- */
9622
- icon: string;
9623
- /**
9624
- * URL for more information on this program
9625
- */
9626
- url: string;
9627
- /**
9628
- * Whether this program is active
9629
- */
9630
- active: boolean;
9631
- /**
9632
- * Whether this program is external
9633
- */
9634
- external: boolean;
9635
- /**
9636
- * Billing plan ID that this is program is associated with.
9637
- */
9638
- billingPlanId: string;
9639
- };
9640
9586
  /**
9641
9587
  * Coupon
9642
9588
  */
@@ -9750,1433 +9696,1449 @@ export declare namespace Models {
9750
9696
  available: number;
9751
9697
  };
9752
9698
  /**
9753
- * Downgrade Feedback
9699
+ * DNSRecord
9754
9700
  */
9755
- export type DowngradeFeedback = {
9701
+ export type DnsRecord = {
9756
9702
  /**
9757
- * Feedback ID.
9703
+ * DNS Record ID.
9758
9704
  */
9759
9705
  $id: string;
9760
9706
  /**
9761
- * Feedback creation date in ISO 8601 format.
9707
+ * DNS Record creation time in ISO 8601 format.
9762
9708
  */
9763
9709
  $createdAt: string;
9764
9710
  /**
9765
- * Feedback update date in ISO 8601 format.
9711
+ * DNS Record update date in ISO 8601 format.
9766
9712
  */
9767
9713
  $updatedAt: string;
9768
9714
  /**
9769
- * Feedback reason
9715
+ * DNS record type (e.g. A, CNAME, MX).
9770
9716
  */
9771
- title: string;
9717
+ type: string;
9772
9718
  /**
9773
- * Feedback message
9719
+ * Record name or subdomain.
9774
9720
  */
9775
- message: string;
9721
+ name: string;
9776
9722
  /**
9777
- * Plan ID downgrading from
9723
+ * Value of the record (IP address, domain, etc.).
9778
9724
  */
9779
- fromPlanId: string;
9725
+ value: string;
9780
9726
  /**
9781
- * Plan ID downgrading to
9727
+ * Time to live (in seconds).
9782
9728
  */
9783
- toPlanId: string;
9729
+ ttl: number;
9784
9730
  /**
9785
- * Organization ID
9731
+ * Record priority (commonly used for MX).
9786
9732
  */
9787
- teamId: string;
9733
+ priority: number;
9788
9734
  /**
9789
- * User ID who submitted feedback
9735
+ * Whether this record is locked (read-only).
9790
9736
  */
9791
- userId: string;
9737
+ lock: boolean;
9792
9738
  /**
9793
- * Console version
9739
+ * Record weight (used for SRV records).
9794
9740
  */
9795
- version: string;
9741
+ weight: number;
9742
+ /**
9743
+ * Target port (used for SRV records).
9744
+ */
9745
+ port: number;
9746
+ /**
9747
+ * Comment for the DNS record.
9748
+ */
9749
+ comment: string;
9796
9750
  };
9797
9751
  /**
9798
- * Invoice
9752
+ * Domain
9799
9753
  */
9800
- export type Invoice = {
9754
+ export type Domain = {
9801
9755
  /**
9802
- * Invoice ID.
9756
+ * Domain ID.
9803
9757
  */
9804
9758
  $id: string;
9805
9759
  /**
9806
- * Invoice creation time in ISO 8601 format.
9760
+ * Domain creation time in ISO 8601 format.
9807
9761
  */
9808
9762
  $createdAt: string;
9809
9763
  /**
9810
- * Invoice update date in ISO 8601 format.
9764
+ * Domain update date in ISO 8601 format.
9811
9765
  */
9812
9766
  $updatedAt: string;
9813
9767
  /**
9814
- * Invoice permissions. [Learn more about permissions](/docs/permissions).
9815
- */
9816
- $permissions: string[];
9817
- /**
9818
- * Project ID
9819
- */
9820
- teamId: string;
9821
- /**
9822
- * Aggregation ID
9823
- */
9824
- aggregationId: string;
9825
- /**
9826
- * Billing plan selected. Can be one of `tier-0`, `tier-1` or `tier-2`.
9827
- */
9828
- plan: string;
9829
- /**
9830
- * Usage breakdown per resource
9768
+ * Domain name.
9831
9769
  */
9832
- usage: UsageResources[];
9770
+ domain: string;
9833
9771
  /**
9834
- * Invoice Amount
9772
+ * Domain registrar (e.g. "appwrite" or "third_party").
9835
9773
  */
9836
- amount: number;
9774
+ registrar: string;
9837
9775
  /**
9838
- * Tax percentage
9776
+ * Nameservers setting. "Appwrite" or empty string.
9839
9777
  */
9840
- tax: number;
9778
+ nameservers: string;
9841
9779
  /**
9842
- * Tax amount
9780
+ * Domain expiry date in ISO 8601 format.
9843
9781
  */
9844
- taxAmount: number;
9782
+ expire: string;
9845
9783
  /**
9846
- * VAT percentage
9784
+ * Domain renewal date in ISO 8601 format.
9847
9785
  */
9848
- vat: number;
9786
+ renewal: string;
9849
9787
  /**
9850
- * VAT amount
9788
+ * If set to true, the domain will automatically renew.
9851
9789
  */
9852
- vatAmount: number;
9790
+ autoRenewal: boolean;
9853
9791
  /**
9854
- * Gross amount after vat, tax, and discounts applied.
9792
+ * Renewal price (in cents).
9855
9793
  */
9856
- grossAmount: number;
9794
+ renewalPrice: number;
9857
9795
  /**
9858
- * Credits used.
9796
+ * Transfer status for domains being transferred in.
9859
9797
  */
9860
- creditsUsed: number;
9798
+ transferStatus: DomainTransferStatusEnum;
9861
9799
  /**
9862
- * Currency the invoice is in
9800
+ * Team ID.
9863
9801
  */
9864
- currency: string;
9802
+ teamId: string;
9865
9803
  /**
9866
- * Client secret for processing failed payments in front-end
9804
+ * Dns records
9867
9805
  */
9868
- clientSecret: string;
9806
+ dnsRecords: DnsRecord[];
9807
+ };
9808
+ /**
9809
+ * DomainPrice
9810
+ */
9811
+ export type DomainPrice = {
9869
9812
  /**
9870
- * Invoice status
9813
+ * Domain name.
9871
9814
  */
9872
- status: string;
9815
+ domain: string;
9873
9816
  /**
9874
- * Invoice type. Can be one of `subscription`, `domain_purchase`, `domain_renewal`, `domain_transfer`, or `addon_*`.
9817
+ * Top-level domain for the requested domain.
9875
9818
  */
9876
- type: string;
9819
+ tld: string;
9877
9820
  /**
9878
- * Last payment error associated with the invoice
9821
+ * Whether the domain is currently available for registration.
9879
9822
  */
9880
- lastError: string;
9823
+ available: boolean;
9881
9824
  /**
9882
- * Invoice due date.
9825
+ * Domain registration price.
9883
9826
  */
9884
- dueAt: string;
9827
+ price: number;
9885
9828
  /**
9886
- * Beginning date of the invoice
9829
+ * Price period in years.
9887
9830
  */
9888
- from: string;
9831
+ periodYears: number;
9889
9832
  /**
9890
- * End date of the invoice
9833
+ * Whether the domain is a premium domain.
9891
9834
  */
9892
- to: string;
9835
+ premium: boolean;
9893
9836
  };
9894
9837
  /**
9895
- * Organization
9838
+ * DomainPurchase
9896
9839
  */
9897
- export type Organization<Preferences extends Models.Preferences = Models.DefaultPreferences> = {
9840
+ export type DomainPurchase = {
9898
9841
  /**
9899
- * Team ID.
9842
+ * Purchase/invoice ID.
9900
9843
  */
9901
9844
  $id: string;
9902
9845
  /**
9903
- * Team creation date in ISO 8601 format.
9846
+ * Purchase creation time in ISO 8601 format.
9904
9847
  */
9905
9848
  $createdAt: string;
9906
9849
  /**
9907
- * Team update date in ISO 8601 format.
9850
+ * Purchase update date in ISO 8601 format.
9908
9851
  */
9909
9852
  $updatedAt: string;
9910
9853
  /**
9911
- * Team name.
9912
- */
9913
- name: string;
9914
- /**
9915
- * Total number of team members.
9854
+ * Domain document ID.
9916
9855
  */
9917
- total: number;
9856
+ domainId: string;
9918
9857
  /**
9919
- * Team preferences as a key-value object
9858
+ * Domain name.
9920
9859
  */
9921
- prefs: Preferences;
9860
+ domain: string;
9922
9861
  /**
9923
- * Project budget limit
9862
+ * Team ID that owns the domain.
9924
9863
  */
9925
- billingBudget: number;
9864
+ organizationId: string;
9926
9865
  /**
9927
- * Project budget limit
9866
+ * Domain purchase status.
9928
9867
  */
9929
- budgetAlerts: number[];
9868
+ status: DomainPurchaseStatus;
9930
9869
  /**
9931
- * Organization's billing plan ID.
9870
+ * Stripe client secret for 3DS; empty when not applicable.
9932
9871
  */
9933
- billingPlan: string;
9872
+ clientSecret: string;
9934
9873
  /**
9935
- * Organization's billing plan ID.
9874
+ * Purchase amount.
9936
9875
  */
9937
- billingPlanId: string;
9876
+ amount: number;
9938
9877
  /**
9939
- * Organization's billing plan.
9878
+ * Currency code.
9940
9879
  */
9941
- billingPlanDetails: BillingPlan;
9880
+ currency: string;
9881
+ };
9882
+ /**
9883
+ * DomainSuggestion
9884
+ */
9885
+ export type DomainSuggestion = {
9942
9886
  /**
9943
- * Billing email set for the organization.
9887
+ * Domain suggestion.
9944
9888
  */
9945
- billingEmail: string;
9889
+ domain: string;
9946
9890
  /**
9947
- * Billing cycle start date.
9891
+ * Is the domain premium?
9948
9892
  */
9949
- billingStartDate: string;
9893
+ premium: boolean;
9950
9894
  /**
9951
- * Current invoice cycle start date.
9895
+ * Domain price.
9952
9896
  */
9953
- billingCurrentInvoiceDate: string;
9897
+ price?: number;
9954
9898
  /**
9955
- * Next invoice cycle start date.
9899
+ * Is the domain available?
9956
9900
  */
9957
- billingNextInvoiceDate: string;
9901
+ available: boolean;
9902
+ };
9903
+ /**
9904
+ * domainTransferOut
9905
+ */
9906
+ export type DomainTransferOut = {
9958
9907
  /**
9959
- * Start date of trial.
9908
+ * Domain transfer authorization code.
9960
9909
  */
9961
- billingTrialStartDate: string;
9910
+ authCode: string;
9911
+ };
9912
+ /**
9913
+ * domainTransferStatus
9914
+ */
9915
+ export type DomainTransferStatus = {
9962
9916
  /**
9963
- * Number of trial days.
9917
+ * Transfer status.
9964
9918
  */
9965
- billingTrialDays: number;
9919
+ status: DomainTransferStatusEnum;
9966
9920
  /**
9967
- * Current active aggregation id.
9921
+ * Additional transfer status information.
9968
9922
  */
9969
- billingAggregationId: string;
9923
+ reason: string;
9970
9924
  /**
9971
- * Current active aggregation id.
9925
+ * Transfer status timestamp in ISO 8601 format.
9972
9926
  */
9973
- billingInvoiceId: string;
9927
+ timestamp: string;
9928
+ };
9929
+ /**
9930
+ * Downgrade Feedback
9931
+ */
9932
+ export type DowngradeFeedback = {
9974
9933
  /**
9975
- * Default payment method.
9934
+ * Feedback ID.
9976
9935
  */
9977
- paymentMethodId: string;
9936
+ $id: string;
9978
9937
  /**
9979
- * Default payment method.
9938
+ * Feedback creation date in ISO 8601 format.
9980
9939
  */
9981
- billingAddressId: string;
9940
+ $createdAt: string;
9982
9941
  /**
9983
- * Backup payment method.
9942
+ * Feedback update date in ISO 8601 format.
9984
9943
  */
9985
- backupPaymentMethodId: string;
9944
+ $updatedAt: string;
9986
9945
  /**
9987
- * Team status.
9946
+ * Feedback reason
9988
9947
  */
9989
- status: string;
9948
+ title: string;
9990
9949
  /**
9991
- * Remarks on team status.
9950
+ * Feedback message
9992
9951
  */
9993
- remarks: string;
9952
+ message: string;
9994
9953
  /**
9995
- * Organization agreements
9954
+ * Plan ID downgrading from
9996
9955
  */
9997
- agreementBAA: string;
9956
+ fromPlanId: string;
9998
9957
  /**
9999
- * Program manager's name.
9958
+ * Plan ID downgrading to
10000
9959
  */
10001
- programManagerName: string;
9960
+ toPlanId: string;
10002
9961
  /**
10003
- * Program manager's calendar link.
9962
+ * Organization ID
10004
9963
  */
10005
- programManagerCalendar: string;
9964
+ teamId: string;
10006
9965
  /**
10007
- * Program's discord channel name.
9966
+ * User ID who submitted feedback
10008
9967
  */
10009
- programDiscordChannelName: string;
9968
+ userId: string;
10010
9969
  /**
10011
- * Program's discord channel URL.
9970
+ * Console version
10012
9971
  */
10013
- programDiscordChannelUrl: string;
9972
+ version: string;
9973
+ };
9974
+ /**
9975
+ * Estimation
9976
+ */
9977
+ export type Estimation = {
10014
9978
  /**
10015
- * Billing limits reached
9979
+ * Total amount
10016
9980
  */
10017
- billingLimits: BillingLimits;
9981
+ amount: number;
10018
9982
  /**
10019
- * Billing plan selected for downgrade.
9983
+ * Gross payable amount
10020
9984
  */
10021
- billingPlanDowngrade: string;
9985
+ grossAmount: number;
10022
9986
  /**
10023
- * Tax Id
9987
+ * Discount amount
10024
9988
  */
10025
- billingTaxId: string;
9989
+ discount: number;
10026
9990
  /**
10027
- * Marked for deletion
9991
+ * Credits amount
10028
9992
  */
10029
- markedForDeletion: boolean;
9993
+ credits: number;
10030
9994
  /**
10031
- * Product with which the organization is associated (appwrite or imagine)
9995
+ * Estimation items
10032
9996
  */
10033
- platform: string;
9997
+ items: EstimationItem[];
10034
9998
  /**
10035
- * Selected projects
9999
+ * Estimation discount items
10036
10000
  */
10037
- projects: string[];
10038
- };
10039
- /**
10040
- * PaymentAuthentication
10041
- */
10042
- export type PaymentAuthentication = {
10001
+ discounts: EstimationItem[];
10043
10002
  /**
10044
- * Message for the end user to show on Console.
10003
+ * Trial days
10045
10004
  */
10046
- message: string;
10005
+ trialDays: number;
10047
10006
  /**
10048
- * Stripe client secret to use for validation.
10007
+ * Trial end date
10049
10008
  */
10050
- clientSecret: string;
10009
+ trialEndDate?: string;
10010
+ };
10011
+ /**
10012
+ * DeleteOrganization
10013
+ */
10014
+ export type EstimationDeleteOrganization = {
10051
10015
  /**
10052
- * Organization ID for which the payment authentication is needed.
10016
+ * List of unpaid invoices
10053
10017
  */
10054
- organizationId: string;
10018
+ unpaidInvoices: Invoice[];
10019
+ };
10020
+ /**
10021
+ * Item
10022
+ */
10023
+ export type EstimationItem = {
10055
10024
  /**
10056
- * Invoice ID against which the payment needs to be validated.
10025
+ * Label
10057
10026
  */
10058
- invoiceId: string;
10027
+ label: string;
10059
10028
  /**
10060
- * Addon ID to use when calling the addon validate endpoint. Empty when authentication is not for an addon.
10029
+ * Gross payable amount
10061
10030
  */
10062
- addonId: string;
10031
+ value: number;
10063
10032
  };
10064
10033
  /**
10065
- * paymentMethod
10034
+ * EstimationPlanChange
10066
10035
  */
10067
- export type PaymentMethod = {
10036
+ export type EstimationPlanChange = {
10068
10037
  /**
10069
- * Payment Method ID.
10038
+ * Current billing plan ID
10070
10039
  */
10071
- $id: string;
10040
+ currentBillingPlanId: string;
10072
10041
  /**
10073
- * Payment method creation time in ISO 8601 format.
10042
+ * Target billing plan ID
10074
10043
  */
10075
- $createdAt: string;
10044
+ targetBillingPlanId: string;
10076
10045
  /**
10077
- * Payment method update date in ISO 8601 format.
10046
+ * Direction of plan change: upgrade, downgrade, or same
10078
10047
  */
10079
- $updatedAt: string;
10048
+ direction: string;
10080
10049
  /**
10081
- * Payment method permissions. [Learn more about permissions](/docs/permissions).
10050
+ * Cost estimation details
10082
10051
  */
10083
- $permissions: string[];
10052
+ estimation: PlanChangeEstimationDetails;
10084
10053
  /**
10085
- * Payment method ID from the payment provider
10054
+ * Plan limits and compliance information
10086
10055
  */
10087
- providerMethodId: string;
10056
+ limits: PlanChangeLimits;
10057
+ };
10058
+ /**
10059
+ * UpdatePlan
10060
+ */
10061
+ export type EstimationUpdatePlan = {
10088
10062
  /**
10089
- * Client secret hash for payment setup
10063
+ * Total amount
10090
10064
  */
10091
- clientSecret: string;
10065
+ amount: number;
10092
10066
  /**
10093
- * User ID from the payment provider.
10067
+ * Gross payable amount
10094
10068
  */
10095
- providerUserId: string;
10069
+ grossAmount: number;
10096
10070
  /**
10097
- * ID of the Team.
10071
+ * Discount amount
10098
10072
  */
10099
- userId: string;
10073
+ discount: number;
10100
10074
  /**
10101
- * Expiry month of the payment method.
10075
+ * Credits amount
10102
10076
  */
10103
- expiryMonth: number;
10077
+ credits: number;
10104
10078
  /**
10105
- * Expiry year of the payment method.
10079
+ * Estimation items
10106
10080
  */
10107
- expiryYear: number;
10081
+ items: EstimationItem[];
10108
10082
  /**
10109
- * Last 4 digit of the payment method
10083
+ * Estimation discount items
10110
10084
  */
10111
- last4: string;
10085
+ discounts: EstimationItem[];
10112
10086
  /**
10113
- * Payment method brand
10087
+ * Trial days
10114
10088
  */
10115
- brand: string;
10089
+ trialDays: number;
10116
10090
  /**
10117
- * Name of the owner
10091
+ * Trial end date
10118
10092
  */
10119
- name: string;
10093
+ trialEndDate?: string;
10120
10094
  /**
10121
- * Mandate ID of the payment method
10095
+ * Organization's existing credits
10122
10096
  */
10123
- mandateId: string;
10097
+ organizationCredits: number;
10098
+ };
10099
+ /**
10100
+ * Invoice
10101
+ */
10102
+ export type Invoice = {
10124
10103
  /**
10125
- * Country of the payment method
10104
+ * Invoice ID.
10126
10105
  */
10127
- country: string;
10106
+ $id: string;
10128
10107
  /**
10129
- * State of the payment method
10108
+ * Invoice creation time in ISO 8601 format.
10130
10109
  */
10131
- state: string;
10110
+ $createdAt: string;
10132
10111
  /**
10133
- * Last payment error associated with the payment method.
10112
+ * Invoice update date in ISO 8601 format.
10134
10113
  */
10135
- lastError: string;
10114
+ $updatedAt: string;
10136
10115
  /**
10137
- * True when it's the default payment method.
10116
+ * Invoice permissions. [Learn more about permissions](/docs/permissions).
10138
10117
  */
10139
- default: boolean;
10118
+ $permissions: string[];
10140
10119
  /**
10141
- * True when payment method has expired.
10120
+ * Project ID
10142
10121
  */
10143
- expired: boolean;
10122
+ teamId: string;
10144
10123
  /**
10145
- * True when payment method has failed to process multiple times.
10124
+ * Aggregation ID
10146
10125
  */
10147
- failed: boolean;
10148
- };
10149
- /**
10150
- * backup
10151
- */
10152
- export type BackupPolicy = {
10126
+ aggregationId: string;
10153
10127
  /**
10154
- * Backup policy ID.
10128
+ * Billing plan selected. Can be one of `tier-0`, `tier-1` or `tier-2`.
10155
10129
  */
10156
- $id: string;
10130
+ plan: string;
10157
10131
  /**
10158
- * Backup policy name.
10132
+ * Usage breakdown per resource
10159
10133
  */
10160
- name: string;
10134
+ usage: UsageResources[];
10161
10135
  /**
10162
- * Policy creation date in ISO 8601 format.
10136
+ * Invoice Amount
10163
10137
  */
10164
- $createdAt: string;
10138
+ amount: number;
10165
10139
  /**
10166
- * Policy update date in ISO 8601 format.
10140
+ * Tax percentage
10167
10141
  */
10168
- $updatedAt: string;
10142
+ tax: number;
10169
10143
  /**
10170
- * The services that are backed up by this policy.
10144
+ * Tax amount
10171
10145
  */
10172
- services: string[];
10146
+ taxAmount: number;
10173
10147
  /**
10174
- * The resources that are backed up by this policy.
10148
+ * VAT percentage
10175
10149
  */
10176
- resources: string[];
10150
+ vat: number;
10177
10151
  /**
10178
- * The resource ID to backup. Set only if this policy should backup a single resource.
10152
+ * VAT amount
10179
10153
  */
10180
- resourceId?: string;
10154
+ vatAmount: number;
10181
10155
  /**
10182
- * The resource type to backup. Set only if this policy should backup a single resource.
10156
+ * Gross amount after vat, tax, and discounts applied.
10183
10157
  */
10184
- resourceType?: string;
10158
+ grossAmount: number;
10185
10159
  /**
10186
- * How many days to keep the backup before it will be automatically deleted.
10160
+ * Credits used.
10187
10161
  */
10188
- retention: number;
10162
+ creditsUsed: number;
10189
10163
  /**
10190
- * Policy backup schedule in CRON format.
10164
+ * Currency the invoice is in
10191
10165
  */
10192
- schedule: string;
10166
+ currency: string;
10193
10167
  /**
10194
- * Is this policy enabled.
10168
+ * Client secret for processing failed payments in front-end
10195
10169
  */
10196
- enabled: boolean;
10197
- };
10198
- /**
10199
- * Region
10200
- */
10201
- export type ConsoleRegion = {
10170
+ clientSecret: string;
10202
10171
  /**
10203
- * Region ID
10172
+ * Invoice status
10204
10173
  */
10205
- $id: string;
10174
+ status: string;
10206
10175
  /**
10207
- * Region name
10176
+ * Invoice type. Can be one of `subscription`, `domain_purchase`, `domain_renewal`, `domain_transfer`, or `addon_*`.
10208
10177
  */
10209
- name: string;
10178
+ type: string;
10210
10179
  /**
10211
- * Does the organization have access to this region.
10180
+ * Last payment error associated with the invoice
10212
10181
  */
10213
- available: boolean;
10182
+ lastError: string;
10214
10183
  /**
10215
- * Does the backend support this region.
10184
+ * Invoice due date.
10216
10185
  */
10217
- disabled: boolean;
10186
+ dueAt: string;
10218
10187
  /**
10219
- * Is this the region default.
10188
+ * Beginning date of the invoice
10220
10189
  */
10221
- default: boolean;
10190
+ from: string;
10222
10191
  /**
10223
- * Region flag code.
10192
+ * End date of the invoice
10224
10193
  */
10225
- flag: string;
10194
+ to: string;
10226
10195
  };
10227
10196
  /**
10228
- * Restoration
10197
+ * Organization
10229
10198
  */
10230
- export type BackupRestoration = {
10199
+ export type Organization<Preferences extends Models.Preferences = Models.DefaultPreferences> = {
10231
10200
  /**
10232
- * Restoration ID.
10201
+ * Team ID.
10233
10202
  */
10234
10203
  $id: string;
10235
10204
  /**
10236
- * Restoration creation time in ISO 8601 format.
10205
+ * Team creation date in ISO 8601 format.
10237
10206
  */
10238
10207
  $createdAt: string;
10239
10208
  /**
10240
- * Restoration update date in ISO 8601 format.
10209
+ * Team update date in ISO 8601 format.
10241
10210
  */
10242
10211
  $updatedAt: string;
10243
10212
  /**
10244
- * Backup archive ID.
10213
+ * Team name.
10245
10214
  */
10246
- archiveId: string;
10215
+ name: string;
10247
10216
  /**
10248
- * Backup policy ID.
10217
+ * Total number of team members.
10249
10218
  */
10250
- policyId: string;
10219
+ total: number;
10251
10220
  /**
10252
- * The status of the restoration. Possible values: pending, downloading, processing, completed, failed.
10221
+ * Team preferences as a key-value object
10253
10222
  */
10254
- status: string;
10223
+ prefs: Preferences;
10255
10224
  /**
10256
- * The backup start time.
10257
- */
10258
- startedAt: string;
10259
- /**
10260
- * Migration ID.
10225
+ * Project budget limit
10261
10226
  */
10262
- migrationId: string;
10227
+ billingBudget: number;
10263
10228
  /**
10264
- * The services that are backed up by this policy.
10229
+ * Project budget limit
10265
10230
  */
10266
- services: string[];
10231
+ budgetAlerts: number[];
10267
10232
  /**
10268
- * The resources that are backed up by this policy.
10233
+ * Organization's billing plan ID.
10269
10234
  */
10270
- resources: string[];
10235
+ billingPlan: string;
10271
10236
  /**
10272
- * Optional data in key-value object.
10237
+ * Organization's billing plan ID.
10273
10238
  */
10274
- options: string;
10275
- };
10276
- /**
10277
- * Review
10278
- */
10279
- export type Review = {
10239
+ billingPlanId: string;
10280
10240
  /**
10281
- * Name of user
10241
+ * Organization's billing plan.
10282
10242
  */
10283
- name: string;
10243
+ billingPlanDetails: BillingPlan;
10284
10244
  /**
10285
- * Reviewer image
10245
+ * Billing email set for the organization.
10286
10246
  */
10287
- image: string;
10247
+ billingEmail: string;
10288
10248
  /**
10289
- * Reviewer description
10249
+ * Billing cycle start date.
10290
10250
  */
10291
- description: string;
10251
+ billingStartDate: string;
10292
10252
  /**
10293
- * Review
10253
+ * Current invoice cycle start date.
10294
10254
  */
10295
- review: string;
10296
- };
10297
- /**
10298
- * Roles
10299
- */
10300
- export type Roles = {
10255
+ billingCurrentInvoiceDate: string;
10301
10256
  /**
10302
- * Array of scopes accessible to current user.
10257
+ * Next invoice cycle start date.
10303
10258
  */
10304
- scopes: string[];
10259
+ billingNextInvoiceDate: string;
10305
10260
  /**
10306
- * Array of roles assigned to current user.
10261
+ * Start date of trial.
10307
10262
  */
10308
- roles: string[];
10309
- };
10310
- /**
10311
- * UsageOrganization
10312
- */
10313
- export type UsageOrganization = {
10263
+ billingTrialStartDate: string;
10314
10264
  /**
10315
- * Aggregated stats for number of requests.
10265
+ * Number of trial days.
10316
10266
  */
10317
- bandwidth: Metric[];
10267
+ billingTrialDays: number;
10318
10268
  /**
10319
- * Aggregated stats for consumed bandwidth.
10269
+ * Current active aggregation id.
10320
10270
  */
10321
- users: Metric[];
10271
+ billingAggregationId: string;
10322
10272
  /**
10323
- * Aggregated stats for function executions.
10273
+ * Current active aggregation id.
10324
10274
  */
10325
- executions: Metric[];
10275
+ billingInvoiceId: string;
10326
10276
  /**
10327
- * Aggregated stats for database reads.
10277
+ * Default payment method.
10328
10278
  */
10329
- databasesReads: Metric[];
10279
+ paymentMethodId: string;
10330
10280
  /**
10331
- * Aggregated stats for database writes.
10281
+ * Default payment method.
10332
10282
  */
10333
- databasesWrites: Metric[];
10283
+ billingAddressId: string;
10334
10284
  /**
10335
- * Aggregated stats for file transformations.
10285
+ * Backup payment method.
10336
10286
  */
10337
- imageTransformations: Metric[];
10287
+ backupPaymentMethodId: string;
10338
10288
  /**
10339
- * Aggregated stats for total file transformations.
10289
+ * Team status.
10340
10290
  */
10341
- imageTransformationsTotal: number;
10291
+ status: string;
10342
10292
  /**
10343
- * Aggregated stats for file transformations.
10293
+ * Remarks on team status.
10344
10294
  */
10345
- screenshotsGenerated: Metric[];
10295
+ remarks: string;
10346
10296
  /**
10347
- * Aggregated stats for total file transformations.
10297
+ * Organization agreements
10348
10298
  */
10349
- screenshotsGeneratedTotal: number;
10299
+ agreementBAA: string;
10350
10300
  /**
10351
- * Aggregated stats for imagine credits.
10301
+ * Program manager's name.
10352
10302
  */
10353
- imagineCredits: Metric[];
10303
+ programManagerName: string;
10354
10304
  /**
10355
- * Aggregated stats for total imagine credits.
10305
+ * Program manager's calendar link.
10356
10306
  */
10357
- imagineCreditsTotal: number;
10307
+ programManagerCalendar: string;
10358
10308
  /**
10359
- * Aggregated stats for total users.
10309
+ * Program's discord channel name.
10360
10310
  */
10361
- usersTotal: number;
10311
+ programDiscordChannelName: string;
10362
10312
  /**
10363
- * Aggregated stats for total executions.
10313
+ * Program's discord channel URL.
10364
10314
  */
10365
- executionsTotal: number;
10315
+ programDiscordChannelUrl: string;
10366
10316
  /**
10367
- * Aggregated stats for function executions in mb seconds.
10317
+ * Billing limits reached
10368
10318
  */
10369
- executionsMBSecondsTotal: number;
10319
+ billingLimits?: BillingLimits;
10370
10320
  /**
10371
- * Aggregated stats for function builds in mb seconds.
10321
+ * Billing plan selected for downgrade.
10372
10322
  */
10373
- buildsMBSecondsTotal: number;
10323
+ billingPlanDowngrade: string;
10374
10324
  /**
10375
- * Aggregated stats for total file storage.
10325
+ * Tax Id
10376
10326
  */
10377
- filesStorageTotal: number;
10327
+ billingTaxId: string;
10378
10328
  /**
10379
- * Aggregated stats for total builds storage.
10329
+ * Marked for deletion
10380
10330
  */
10381
- buildsStorageTotal: number;
10331
+ markedForDeletion: boolean;
10382
10332
  /**
10383
- * Aggregated stats for total deployments storage.
10333
+ * Product with which the organization is associated (appwrite or imagine)
10384
10334
  */
10385
- deploymentsStorageTotal: number;
10335
+ platform: string;
10386
10336
  /**
10387
- * Aggregated stats for total databases storage.
10337
+ * Selected projects
10388
10338
  */
10389
- databasesStorageTotal: number;
10339
+ projects: string[];
10340
+ };
10341
+ /**
10342
+ * PaymentAuthentication
10343
+ */
10344
+ export type PaymentAuthentication = {
10390
10345
  /**
10391
- * Aggregated stats for total databases reads.
10346
+ * Message for the end user to show on Console.
10392
10347
  */
10393
- databasesReadsTotal: number;
10348
+ message: string;
10394
10349
  /**
10395
- * Aggregated stats for total databases writes.
10350
+ * Stripe client secret to use for validation.
10396
10351
  */
10397
- databasesWritesTotal: number;
10352
+ clientSecret: string;
10398
10353
  /**
10399
- * Aggregated stats for total backups storage.
10354
+ * Organization ID for which the payment authentication is needed.
10400
10355
  */
10401
- backupsStorageTotal: number;
10356
+ organizationId: string;
10402
10357
  /**
10403
- * Aggregated stats for total storage.
10358
+ * Invoice ID against which the payment needs to be validated.
10404
10359
  */
10405
- storageTotal: number;
10360
+ invoiceId: string;
10406
10361
  /**
10407
- * Aggregated stats for total auth phone.
10362
+ * Addon ID to use when calling the addon validate endpoint. Empty when authentication is not for an addon.
10408
10363
  */
10409
- authPhoneTotal: number;
10364
+ addonId: string;
10365
+ };
10366
+ /**
10367
+ * paymentMethod
10368
+ */
10369
+ export type PaymentMethod = {
10410
10370
  /**
10411
- * Aggregated stats for total auth phone estimation.
10371
+ * Payment Method ID.
10412
10372
  */
10413
- authPhoneEstimate: number;
10373
+ $id: string;
10414
10374
  /**
10415
- * Aggregated stats for each projects.
10375
+ * Payment method creation time in ISO 8601 format.
10416
10376
  */
10417
- projects: UsageOrganizationProject[];
10377
+ $createdAt: string;
10418
10378
  /**
10419
- * Aggregated stats for realtime connections.
10379
+ * Payment method update date in ISO 8601 format.
10420
10380
  */
10421
- realtimeConnections: Metric[];
10381
+ $updatedAt: string;
10422
10382
  /**
10423
- * Aggregated stats for total realtime connections.
10383
+ * Payment method permissions. [Learn more about permissions](/docs/permissions).
10424
10384
  */
10425
- realtimeConnectionsTotal: number;
10385
+ $permissions: string[];
10426
10386
  /**
10427
- * Aggregated stats for realtime messages.
10387
+ * Payment method ID from the payment provider
10428
10388
  */
10429
- realtimeMessages: Metric[];
10389
+ providerMethodId: string;
10430
10390
  /**
10431
- * Aggregated stats for total realtime messages.
10391
+ * Client secret hash for payment setup
10432
10392
  */
10433
- realtimeMessagesTotal: number;
10393
+ clientSecret: string;
10434
10394
  /**
10435
- * Aggregated stats for realtime bandwidth.
10395
+ * User ID from the payment provider.
10436
10396
  */
10437
- realtimeBandwidth: Metric[];
10397
+ providerUserId: string;
10438
10398
  /**
10439
- * Aggregated stats for total realtime bandwidth.
10399
+ * ID of the Team.
10440
10400
  */
10441
- realtimeBandwidthTotal: number;
10442
- };
10443
- /**
10444
- * UsageOrganizationProject
10445
- */
10446
- export type UsageOrganizationProject = {
10401
+ userId: string;
10447
10402
  /**
10448
- * projectId
10403
+ * Expiry month of the payment method.
10449
10404
  */
10450
- projectId: string;
10405
+ expiryMonth: number;
10451
10406
  /**
10452
- * Aggregated stats for number of requests.
10407
+ * Expiry year of the payment method.
10453
10408
  */
10454
- bandwidth: Metric[];
10409
+ expiryYear: number;
10455
10410
  /**
10456
- * Aggregated stats for consumed bandwidth.
10411
+ * Last 4 digit of the payment method
10457
10412
  */
10458
- users: Metric[];
10413
+ last4: string;
10459
10414
  /**
10460
- * Aggregated stats for function executions.
10415
+ * Payment method brand
10461
10416
  */
10462
- executions: number;
10417
+ brand: string;
10463
10418
  /**
10464
- * Aggregated stats for database reads.
10419
+ * Name of the owner
10465
10420
  */
10466
- databasesReads: Metric[];
10421
+ name: string;
10467
10422
  /**
10468
- * Aggregated stats for database writes.
10423
+ * Mandate ID of the payment method
10469
10424
  */
10470
- databasesWrites: Metric[];
10425
+ mandateId: string;
10471
10426
  /**
10472
- * Aggregated stats for function executions in mb seconds.
10427
+ * Country of the payment method
10473
10428
  */
10474
- executionsMBSeconds: number;
10429
+ country: string;
10475
10430
  /**
10476
- * Aggregated stats for function builds in mb seconds.
10431
+ * State of the payment method
10477
10432
  */
10478
- buildsMBSeconds: number;
10433
+ state: string;
10479
10434
  /**
10480
- * Aggregated stats for number of documents.
10435
+ * Last payment error associated with the payment method.
10481
10436
  */
10482
- storage: number;
10437
+ lastError: string;
10483
10438
  /**
10484
- * Aggregated stats for phone authentication.
10439
+ * True when it's the default payment method.
10485
10440
  */
10486
- authPhoneTotal: number;
10441
+ default: boolean;
10487
10442
  /**
10488
- * Aggregated stats for phone authentication estimated cost.
10443
+ * True when payment method has expired.
10489
10444
  */
10490
- authPhoneEstimate: number;
10445
+ expired: boolean;
10491
10446
  /**
10492
- * Aggregated stats for total databases reads.
10447
+ * True when payment method has failed to process multiple times.
10493
10448
  */
10494
- databasesReadsTotal: number;
10449
+ failed: boolean;
10450
+ };
10451
+ /**
10452
+ * PlanChangeEstimationDetails
10453
+ */
10454
+ export type PlanChangeEstimationDetails = {
10495
10455
  /**
10496
- * Aggregated stats for total databases writes.
10456
+ * Currency code
10497
10457
  */
10498
- databasesWritesTotal: number;
10458
+ currency: string;
10499
10459
  /**
10500
- * Aggregated stats for file transformations.
10460
+ * Gross amount after all discounts and credits
10501
10461
  */
10502
- imageTransformations: Metric[];
10462
+ grossAmount: number;
10503
10463
  /**
10504
- * Aggregated stats for total file transformations.
10464
+ * Credits applied from coupon
10505
10465
  */
10506
- imageTransformationsTotal: number;
10466
+ credits: number;
10507
10467
  /**
10508
- * Aggregated stats for file transformations.
10468
+ * Organization's existing credits applied
10509
10469
  */
10510
- screenshotsGenerated: Metric[];
10470
+ organizationCredits: number;
10511
10471
  /**
10512
- * Aggregated stats for total file transformations.
10472
+ * Discount amount from prorated invoices
10513
10473
  */
10514
- screenshotsGeneratedTotal: number;
10474
+ discount: number;
10515
10475
  /**
10516
- * Aggregated stats for imagine credits.
10476
+ * Total amount before discounts and credits
10517
10477
  */
10518
- imagineCredits: number;
10478
+ amount: number;
10519
10479
  /**
10520
- * Aggregated stats for realtime connections.
10480
+ * Next invoice date
10521
10481
  */
10522
- realtimeConnections: number;
10482
+ nextInvoiceDate: string;
10523
10483
  /**
10524
- * Aggregated stats for realtime messages.
10484
+ * Line items breakdown
10525
10485
  */
10526
- realtimeMessages: number;
10486
+ items: object;
10527
10487
  /**
10528
- * Aggregated stats for realtime bandwidth.
10488
+ * Applied discounts breakdown
10529
10489
  */
10530
- realtimeBandwidth: number;
10490
+ discounts: object;
10531
10491
  };
10532
10492
  /**
10533
- * Domain
10493
+ * PlanChangeLimits
10534
10494
  */
10535
- export type Domain = {
10495
+ export type PlanChangeLimits = {
10536
10496
  /**
10537
- * Domain ID.
10497
+ * Total number of projects in the organization
10538
10498
  */
10539
- $id: string;
10499
+ totalProjects: number;
10540
10500
  /**
10541
- * Domain creation time in ISO 8601 format.
10501
+ * Number of projects exceeding target plan limits
10542
10502
  */
10543
- $createdAt: string;
10503
+ nonCompliantProjects: number;
10544
10504
  /**
10545
- * Domain update date in ISO 8601 format.
10505
+ * Whether the plan change is allowed
10546
10506
  */
10547
- $updatedAt: string;
10507
+ canChangePlan: boolean;
10508
+ /**
10509
+ * Project compliance details
10510
+ */
10511
+ projects: PlanChangeProjectCompliance[];
10512
+ /**
10513
+ * Active addon keys that the target plan does not support. When non-empty, `canChangePlan` is false.
10514
+ */
10515
+ unsupportedAddons: string[];
10516
+ };
10517
+ /**
10518
+ * PlanChangeProjectCompliance
10519
+ */
10520
+ export type PlanChangeProjectCompliance = {
10521
+ /**
10522
+ * Project ID
10523
+ */
10524
+ $id: string;
10548
10525
  /**
10549
- * Domain name.
10526
+ * Project name
10550
10527
  */
10551
- domain: string;
10528
+ name: string;
10552
10529
  /**
10553
- * Domain registrar (e.g. "appwrite" or "third_party").
10530
+ * Whether the project complies with target plan limits
10554
10531
  */
10555
- registrar: string;
10532
+ isCompliant: boolean;
10556
10533
  /**
10557
- * Nameservers setting. "Appwrite" or empty string.
10534
+ * Resource compliance details
10558
10535
  */
10559
- nameservers: string;
10536
+ resources: PlanChangeResourceCompliance[];
10560
10537
  /**
10561
- * Domain expiry date in ISO 8601 format.
10538
+ * Failure reason when compliance could not be evaluated. Present only when the project DB or Regions API was unreachable; in that case `isCompliant` is false (fail closed) and `resources` is empty.
10562
10539
  */
10563
- expire: string;
10540
+ error?: string;
10541
+ };
10542
+ /**
10543
+ * PlanChangeResourceCompliance
10544
+ */
10545
+ export type PlanChangeResourceCompliance = {
10564
10546
  /**
10565
- * Domain renewal date in ISO 8601 format.
10547
+ * Resource type
10566
10548
  */
10567
- renewal: string;
10549
+ type: string;
10568
10550
  /**
10569
- * If set to true, the domain will automatically renew.
10551
+ * Current usage count
10570
10552
  */
10571
- autoRenewal: boolean;
10553
+ currentUsage: number;
10572
10554
  /**
10573
- * Renewal price (in cents).
10555
+ * Allowed limit in target plan
10574
10556
  */
10575
- renewalPrice: number;
10557
+ limit: number;
10576
10558
  /**
10577
- * Transfer status for domains being transferred in.
10559
+ * Compliance status
10578
10560
  */
10579
- transferStatus: DomainTransferStatusEnum;
10561
+ status: string;
10580
10562
  /**
10581
- * Team ID.
10563
+ * Number of resources exceeding the limit
10582
10564
  */
10583
- teamId: string;
10565
+ excess: number;
10584
10566
  /**
10585
- * Dns records
10567
+ * Suggestion for resolving the compliance issue
10586
10568
  */
10587
- dnsRecords: DnsRecord[];
10569
+ resolutionHint: string;
10588
10570
  };
10589
10571
  /**
10590
- * DomainPurchase
10572
+ * backup
10591
10573
  */
10592
- export type DomainPurchase = {
10574
+ export type BackupPolicy = {
10593
10575
  /**
10594
- * Purchase/invoice ID.
10576
+ * Backup policy ID.
10595
10577
  */
10596
10578
  $id: string;
10597
10579
  /**
10598
- * Purchase creation time in ISO 8601 format.
10580
+ * Backup policy name.
10581
+ */
10582
+ name: string;
10583
+ /**
10584
+ * Policy creation date in ISO 8601 format.
10599
10585
  */
10600
10586
  $createdAt: string;
10601
10587
  /**
10602
- * Purchase update date in ISO 8601 format.
10588
+ * Policy update date in ISO 8601 format.
10603
10589
  */
10604
10590
  $updatedAt: string;
10605
10591
  /**
10606
- * Domain document ID.
10592
+ * The services that are backed up by this policy.
10607
10593
  */
10608
- domainId: string;
10594
+ services: string[];
10609
10595
  /**
10610
- * Domain name.
10596
+ * The resources that are backed up by this policy.
10611
10597
  */
10612
- domain: string;
10598
+ resources: string[];
10613
10599
  /**
10614
- * Team ID that owns the domain.
10600
+ * The resource ID to backup. Set only if this policy should backup a single resource.
10615
10601
  */
10616
- organizationId: string;
10602
+ resourceId?: string;
10617
10603
  /**
10618
- * Domain purchase status.
10604
+ * The resource type to backup. Set only if this policy should backup a single resource.
10619
10605
  */
10620
- status: DomainPurchaseStatus;
10606
+ resourceType?: string;
10621
10607
  /**
10622
- * Stripe client secret for 3DS; empty when not applicable.
10608
+ * How many days to keep the backup before it will be automatically deleted.
10623
10609
  */
10624
- clientSecret: string;
10610
+ retention: number;
10625
10611
  /**
10626
- * Purchase amount.
10612
+ * Policy backup schedule in CRON format.
10627
10613
  */
10628
- amount: number;
10614
+ schedule: string;
10629
10615
  /**
10630
- * Currency code.
10616
+ * Is this policy enabled.
10631
10617
  */
10632
- currency: string;
10618
+ enabled: boolean;
10633
10619
  };
10634
10620
  /**
10635
- * DNSRecord
10621
+ * Program
10636
10622
  */
10637
- export type DnsRecord = {
10623
+ export type Program = {
10638
10624
  /**
10639
- * DNS Record ID.
10625
+ * Program ID
10640
10626
  */
10641
10627
  $id: string;
10642
10628
  /**
10643
- * DNS Record creation time in ISO 8601 format.
10629
+ * Program title
10644
10630
  */
10645
- $createdAt: string;
10631
+ title: string;
10646
10632
  /**
10647
- * DNS Record update date in ISO 8601 format.
10633
+ * Program description
10648
10634
  */
10649
- $updatedAt: string;
10635
+ description: string;
10650
10636
  /**
10651
- * DNS record type (e.g. A, CNAME, MX).
10637
+ * Program tag for highlighting on console
10652
10638
  */
10653
- type: string;
10639
+ tag: string;
10654
10640
  /**
10655
- * Record name or subdomain.
10641
+ * Program icon for highlighting on console
10656
10642
  */
10657
- name: string;
10643
+ icon: string;
10658
10644
  /**
10659
- * Value of the record (IP address, domain, etc.).
10645
+ * URL for more information on this program
10660
10646
  */
10661
- value: string;
10647
+ url: string;
10662
10648
  /**
10663
- * Time to live (in seconds).
10649
+ * Whether this program is active
10664
10650
  */
10665
- ttl: number;
10651
+ active: boolean;
10666
10652
  /**
10667
- * Record priority (commonly used for MX).
10653
+ * Whether this program is external
10668
10654
  */
10669
- priority: number;
10655
+ external: boolean;
10670
10656
  /**
10671
- * Whether this record is locked (read-only).
10657
+ * Billing plan ID that this is program is associated with.
10672
10658
  */
10673
- lock: boolean;
10659
+ billingPlanId: string;
10660
+ };
10661
+ /**
10662
+ * Region
10663
+ */
10664
+ export type ConsoleRegion = {
10674
10665
  /**
10675
- * Record weight (used for SRV records).
10666
+ * Region ID
10676
10667
  */
10677
- weight: number;
10668
+ $id: string;
10678
10669
  /**
10679
- * Target port (used for SRV records).
10670
+ * Region name
10680
10671
  */
10681
- port: number;
10672
+ name: string;
10682
10673
  /**
10683
- * Comment for the DNS record.
10674
+ * Does the organization have access to this region.
10684
10675
  */
10685
- comment: string;
10676
+ available: boolean;
10677
+ /**
10678
+ * Does the backend support this region.
10679
+ */
10680
+ disabled: boolean;
10681
+ /**
10682
+ * Is this the region default.
10683
+ */
10684
+ default: boolean;
10685
+ /**
10686
+ * Region flag code.
10687
+ */
10688
+ flag: string;
10686
10689
  };
10687
10690
  /**
10688
- * UsageResource
10691
+ * Restoration
10689
10692
  */
10690
- export type UsageResources = {
10693
+ export type BackupRestoration = {
10691
10694
  /**
10692
- * Invoice name
10695
+ * Restoration ID.
10693
10696
  */
10694
- name: string;
10697
+ $id: string;
10695
10698
  /**
10696
- * Invoice value
10699
+ * Restoration creation time in ISO 8601 format.
10697
10700
  */
10698
- value: number;
10701
+ $createdAt: string;
10699
10702
  /**
10700
- * Invoice amount
10703
+ * Restoration update date in ISO 8601 format.
10701
10704
  */
10702
- amount: number;
10705
+ $updatedAt: string;
10703
10706
  /**
10704
- * Invoice rate
10707
+ * Backup archive ID.
10705
10708
  */
10706
- rate: number;
10709
+ archiveId: string;
10707
10710
  /**
10708
- * Invoice description
10711
+ * Backup policy ID.
10709
10712
  */
10710
- desc: string;
10713
+ policyId: string;
10711
10714
  /**
10712
- * Resource ID
10715
+ * The status of the restoration. Possible values: pending, downloading, processing, completed, failed.
10713
10716
  */
10714
- resourceId: string;
10715
- };
10716
- /**
10717
- * usageBillingPlan
10718
- */
10719
- export type UsageBillingPlan = {
10717
+ status: string;
10720
10718
  /**
10721
- * Bandwidth additional resources
10719
+ * The backup start time.
10722
10720
  */
10723
- bandwidth: AdditionalResource;
10721
+ startedAt: string;
10724
10722
  /**
10725
- * Executions additional resources
10723
+ * Migration ID.
10726
10724
  */
10727
- executions: AdditionalResource;
10725
+ migrationId: string;
10728
10726
  /**
10729
- * Member additional resources
10727
+ * The services that are backed up by this policy.
10730
10728
  */
10731
- member: AdditionalResource;
10729
+ services: string[];
10732
10730
  /**
10733
- * Realtime additional resources
10731
+ * The resources that are backed up by this policy.
10734
10732
  */
10735
- realtime: AdditionalResource;
10733
+ resources: string[];
10736
10734
  /**
10737
- * Realtime messages additional resources
10735
+ * Optional data in key-value object.
10738
10736
  */
10739
- realtimeMessages: AdditionalResource;
10737
+ options: string;
10738
+ };
10739
+ /**
10740
+ * Review
10741
+ */
10742
+ export type Review = {
10740
10743
  /**
10741
- * Realtime bandwidth additional resources
10744
+ * Name of user
10742
10745
  */
10743
- realtimeBandwidth: AdditionalResource;
10746
+ name: string;
10744
10747
  /**
10745
- * Storage additional resources
10748
+ * Reviewer image
10746
10749
  */
10747
- storage: AdditionalResource;
10750
+ image: string;
10748
10751
  /**
10749
- * User additional resources
10752
+ * Reviewer description
10750
10753
  */
10751
- users: AdditionalResource;
10754
+ description: string;
10752
10755
  /**
10753
- * GBHour additional resources
10756
+ * Review
10754
10757
  */
10755
- GBHours: AdditionalResource;
10758
+ review: string;
10759
+ };
10760
+ /**
10761
+ * Roles
10762
+ */
10763
+ export type Roles = {
10756
10764
  /**
10757
- * Image transformation additional resources
10765
+ * Array of scopes accessible to current user.
10758
10766
  */
10759
- imageTransformations: AdditionalResource;
10767
+ scopes: string[];
10760
10768
  /**
10761
- * Credits additional resources
10769
+ * Array of roles assigned to current user.
10762
10770
  */
10763
- credits: AdditionalResource;
10771
+ roles: string[];
10764
10772
  };
10765
10773
  /**
10766
- * Estimation
10774
+ * usageBillingPlan
10767
10775
  */
10768
- export type Estimation = {
10769
- /**
10770
- * Total amount
10771
- */
10772
- amount: number;
10776
+ export type UsageBillingPlan = {
10773
10777
  /**
10774
- * Gross payable amount
10778
+ * Bandwidth additional resources
10775
10779
  */
10776
- grossAmount: number;
10780
+ bandwidth: AdditionalResource;
10777
10781
  /**
10778
- * Discount amount
10782
+ * Executions additional resources
10779
10783
  */
10780
- discount: number;
10784
+ executions: AdditionalResource;
10781
10785
  /**
10782
- * Credits amount
10786
+ * Member additional resources
10783
10787
  */
10784
- credits: number;
10788
+ member: AdditionalResource;
10785
10789
  /**
10786
- * Estimation items
10790
+ * Realtime additional resources
10787
10791
  */
10788
- items: EstimationItem[];
10792
+ realtime: AdditionalResource;
10789
10793
  /**
10790
- * Estimation discount items
10794
+ * Realtime messages additional resources
10791
10795
  */
10792
- discounts: EstimationItem[];
10796
+ realtimeMessages: AdditionalResource;
10793
10797
  /**
10794
- * Trial days
10798
+ * Realtime bandwidth additional resources
10795
10799
  */
10796
- trialDays: number;
10800
+ realtimeBandwidth: AdditionalResource;
10797
10801
  /**
10798
- * Trial end date
10802
+ * Storage additional resources
10799
10803
  */
10800
- trialEndDate?: string;
10801
- };
10802
- /**
10803
- * EstimationUpdatePlan
10804
- */
10805
- export type EstimationUpdatePlan = {
10804
+ storage: AdditionalResource;
10806
10805
  /**
10807
- * Total amount
10806
+ * User additional resources
10808
10807
  */
10809
- amount: number;
10808
+ users: AdditionalResource;
10810
10809
  /**
10811
- * Gross payable amount
10810
+ * GBHour additional resources
10812
10811
  */
10813
- grossAmount: number;
10812
+ GBHours: AdditionalResource;
10814
10813
  /**
10815
- * Discount amount
10814
+ * Image transformation additional resources
10816
10815
  */
10817
- discount: number;
10816
+ imageTransformations: AdditionalResource;
10818
10817
  /**
10819
- * Credits amount
10818
+ * Credits additional resources
10820
10819
  */
10821
- credits: number;
10820
+ credits: AdditionalResource;
10821
+ };
10822
+ /**
10823
+ * usageEvent
10824
+ */
10825
+ export type UsageEvent = {
10822
10826
  /**
10823
- * Estimation items
10827
+ * The metric key.
10824
10828
  */
10825
- items: EstimationItem[];
10829
+ metric: string;
10826
10830
  /**
10827
- * Estimation discount items
10831
+ * The metric value.
10828
10832
  */
10829
- discounts: EstimationItem[];
10833
+ value: number;
10830
10834
  /**
10831
- * Trial days
10835
+ * The event timestamp.
10832
10836
  */
10833
- trialDays: number;
10837
+ time: string;
10834
10838
  /**
10835
- * Trial end date
10839
+ * The API endpoint path.
10836
10840
  */
10837
- trialEndDate?: string;
10841
+ path: string;
10838
10842
  /**
10839
- * Organization's existing credits
10843
+ * The HTTP method.
10840
10844
  */
10841
- organizationCredits: number;
10842
- };
10843
- /**
10844
- * EstimationPlanChange
10845
- */
10846
- export type EstimationPlanChange = {
10845
+ method: string;
10847
10846
  /**
10848
- * Current billing plan ID
10847
+ * HTTP status code. Stored as string to preserve unset state (empty string = not available).
10849
10848
  */
10850
- currentBillingPlanId: string;
10849
+ status: string;
10851
10850
  /**
10852
- * Target billing plan ID
10851
+ * The resource type.
10853
10852
  */
10854
- targetBillingPlanId: string;
10853
+ resourceType: string;
10855
10854
  /**
10856
- * Direction of plan change: upgrade, downgrade, or same
10855
+ * The resource ID.
10857
10856
  */
10858
- direction: string;
10857
+ resourceId: string;
10859
10858
  /**
10860
- * Cost estimation details
10859
+ * Country code in [ISO 3166-1](http://en.wikipedia.org/wiki/ISO_3166-1) two-character format.
10861
10860
  */
10862
- estimation: PlanChangeEstimationDetails;
10861
+ countryCode: string;
10863
10862
  /**
10864
- * Plan limits and compliance information
10863
+ * The user agent string.
10865
10864
  */
10866
- limits: PlanChangeLimits;
10865
+ userAgent: string;
10867
10866
  };
10868
10867
  /**
10869
- * PlanChangeEstimationDetails
10868
+ * usageGauge
10870
10869
  */
10871
- export type PlanChangeEstimationDetails = {
10872
- /**
10873
- * Currency code
10874
- */
10875
- currency: string;
10870
+ export type UsageGauge = {
10876
10871
  /**
10877
- * Gross amount after all discounts and credits
10872
+ * The metric key.
10878
10873
  */
10879
- grossAmount: number;
10874
+ metric: string;
10880
10875
  /**
10881
- * Credits applied from coupon
10876
+ * The current snapshot value.
10882
10877
  */
10883
- credits: number;
10878
+ value: number;
10884
10879
  /**
10885
- * Organization's existing credits applied
10880
+ * The snapshot timestamp.
10886
10881
  */
10887
- organizationCredits: number;
10882
+ time: string;
10888
10883
  /**
10889
- * Discount amount from prorated invoices
10884
+ * The resource type.
10890
10885
  */
10891
- discount: number;
10886
+ resourceType: string;
10892
10887
  /**
10893
- * Total amount before discounts and credits
10888
+ * The resource ID.
10894
10889
  */
10895
- amount: number;
10890
+ resourceId: string;
10891
+ };
10892
+ /**
10893
+ * Organization
10894
+ */
10895
+ export type UsageOrganization = {
10896
10896
  /**
10897
- * Next invoice date
10897
+ * Aggregated stats for number of requests.
10898
10898
  */
10899
- nextInvoiceDate: string;
10899
+ bandwidth: Metric[];
10900
10900
  /**
10901
- * Line items breakdown
10901
+ * Aggregated stats for consumed bandwidth.
10902
10902
  */
10903
- items: object;
10903
+ users: Metric[];
10904
10904
  /**
10905
- * Applied discounts breakdown
10905
+ * Aggregated stats for function executions.
10906
10906
  */
10907
- discounts: object;
10908
- };
10909
- /**
10910
- * PlanChangeLimits
10911
- */
10912
- export type PlanChangeLimits = {
10907
+ executions: Metric[];
10913
10908
  /**
10914
- * Total number of projects in the organization
10909
+ * Aggregated stats for database reads.
10915
10910
  */
10916
- totalProjects: number;
10911
+ databasesReads: Metric[];
10917
10912
  /**
10918
- * Number of projects exceeding target plan limits
10913
+ * Aggregated stats for database writes.
10919
10914
  */
10920
- nonCompliantProjects: number;
10915
+ databasesWrites: Metric[];
10921
10916
  /**
10922
- * Whether the plan change is allowed
10917
+ * Aggregated stats for file transformations.
10923
10918
  */
10924
- canChangePlan: boolean;
10919
+ imageTransformations: Metric[];
10925
10920
  /**
10926
- * Project compliance details
10921
+ * Aggregated stats for total file transformations.
10927
10922
  */
10928
- projects: PlanChangeProjectCompliance[];
10923
+ imageTransformationsTotal: number;
10929
10924
  /**
10930
- * Active addon keys that the target plan does not support. When non-empty, `canChangePlan` is false.
10925
+ * Aggregated stats for file transformations.
10931
10926
  */
10932
- unsupportedAddons: string[];
10933
- };
10934
- /**
10935
- * PlanChangeProjectCompliance
10936
- */
10937
- export type PlanChangeProjectCompliance = {
10927
+ screenshotsGenerated: Metric[];
10938
10928
  /**
10939
- * Project ID
10929
+ * Aggregated stats for total file transformations.
10940
10930
  */
10941
- $id: string;
10931
+ screenshotsGeneratedTotal: number;
10942
10932
  /**
10943
- * Project name
10933
+ * Aggregated stats for imagine credits.
10944
10934
  */
10945
- name: string;
10935
+ imagineCredits: Metric[];
10946
10936
  /**
10947
- * Whether the project complies with target plan limits
10937
+ * Aggregated stats for total imagine credits.
10948
10938
  */
10949
- isCompliant: boolean;
10939
+ imagineCreditsTotal: number;
10950
10940
  /**
10951
- * Resource compliance details
10941
+ * Aggregated stats for total users.
10952
10942
  */
10953
- resources: PlanChangeResourceCompliance[];
10943
+ usersTotal: number;
10954
10944
  /**
10955
- * Failure reason when compliance could not be evaluated. Present only when the project DB or Regions API was unreachable; in that case `isCompliant` is false (fail closed) and `resources` is empty.
10945
+ * Aggregated stats for total executions.
10956
10946
  */
10957
- error?: string;
10958
- };
10959
- /**
10960
- * PlanChangeResourceCompliance
10961
- */
10962
- export type PlanChangeResourceCompliance = {
10947
+ executionsTotal: number;
10963
10948
  /**
10964
- * Resource type
10949
+ * Aggregated stats for function executions in mb seconds.
10965
10950
  */
10966
- type: string;
10951
+ executionsMBSecondsTotal: number;
10967
10952
  /**
10968
- * Current usage count
10953
+ * Aggregated stats for function builds in mb seconds.
10969
10954
  */
10970
- currentUsage: number;
10955
+ buildsMBSecondsTotal: number;
10971
10956
  /**
10972
- * Allowed limit in target plan
10957
+ * Aggregated stats for total file storage.
10973
10958
  */
10974
- limit: number;
10959
+ filesStorageTotal: number;
10975
10960
  /**
10976
- * Compliance status
10961
+ * Aggregated stats for total builds storage.
10977
10962
  */
10978
- status: string;
10963
+ buildsStorageTotal: number;
10979
10964
  /**
10980
- * Number of resources exceeding the limit
10965
+ * Aggregated stats for total deployments storage.
10981
10966
  */
10982
- excess: number;
10967
+ deploymentsStorageTotal: number;
10983
10968
  /**
10984
- * Suggestion for resolving the compliance issue
10969
+ * Aggregated stats for total databases storage.
10985
10970
  */
10986
- resolutionHint: string;
10987
- };
10988
- /**
10989
- * EstimationDeleteOrganization
10990
- */
10991
- export type EstimationDeleteOrganization = {
10971
+ databasesStorageTotal: number;
10992
10972
  /**
10993
- * List of unpaid invoices
10973
+ * Aggregated stats for total databases reads.
10994
10974
  */
10995
- unpaidInvoices: Invoice[];
10996
- };
10997
- /**
10998
- * EstimationItem
10999
- */
11000
- export type EstimationItem = {
10975
+ databasesReadsTotal: number;
11001
10976
  /**
11002
- * Label
10977
+ * Aggregated stats for total databases writes.
11003
10978
  */
11004
- label: string;
10979
+ databasesWritesTotal: number;
11005
10980
  /**
11006
- * Gross payable amount
10981
+ * Aggregated stats for total backups storage.
11007
10982
  */
11008
- value: number;
11009
- };
11010
- /**
11011
- * DomainPrice
11012
- */
11013
- export type DomainPrice = {
10983
+ backupsStorageTotal: number;
11014
10984
  /**
11015
- * Domain name.
10985
+ * Aggregated stats for total storage.
11016
10986
  */
11017
- domain: string;
10987
+ storageTotal: number;
11018
10988
  /**
11019
- * Top-level domain for the requested domain.
10989
+ * Aggregated stats for total auth phone.
11020
10990
  */
11021
- tld: string;
10991
+ authPhoneTotal: number;
11022
10992
  /**
11023
- * Whether the domain is currently available for registration.
10993
+ * Aggregated stats for total auth phone estimation.
11024
10994
  */
11025
- available: boolean;
10995
+ authPhoneEstimate: number;
11026
10996
  /**
11027
- * Domain registration price.
10997
+ * Aggregated stats for each projects.
11028
10998
  */
11029
- price: number;
10999
+ projects: UsageOrganizationProject[];
11030
11000
  /**
11031
- * Price period in years.
11001
+ * Aggregated stats for realtime connections.
11032
11002
  */
11033
- periodYears: number;
11003
+ realtimeConnections: Metric[];
11034
11004
  /**
11035
- * Whether the domain is a premium domain.
11005
+ * Aggregated stats for total realtime connections.
11036
11006
  */
11037
- premium: boolean;
11038
- };
11039
- /**
11040
- * DomainSuggestion
11041
- */
11042
- export type DomainSuggestion = {
11007
+ realtimeConnectionsTotal: number;
11043
11008
  /**
11044
- * Domain suggestion.
11009
+ * Aggregated stats for realtime messages.
11045
11010
  */
11046
- domain: string;
11011
+ realtimeMessages: Metric[];
11047
11012
  /**
11048
- * Is the domain premium?
11013
+ * Aggregated stats for total realtime messages.
11049
11014
  */
11050
- premium: boolean;
11015
+ realtimeMessagesTotal: number;
11051
11016
  /**
11052
- * Domain price.
11017
+ * Aggregated stats for realtime bandwidth.
11053
11018
  */
11054
- price?: number;
11019
+ realtimeBandwidth: Metric[];
11055
11020
  /**
11056
- * Is the domain available?
11021
+ * Aggregated stats for total realtime bandwidth.
11057
11022
  */
11058
- available: boolean;
11023
+ realtimeBandwidthTotal: number;
11059
11024
  };
11060
11025
  /**
11061
- * Addon
11026
+ * OrganizationProject
11062
11027
  */
11063
- export type Addon = {
11028
+ export type UsageOrganizationProject = {
11064
11029
  /**
11065
- * Addon ID.
11030
+ * projectId
11066
11031
  */
11067
- $id: string;
11032
+ projectId: string;
11068
11033
  /**
11069
- * Addon creation time in ISO 8601 format.
11034
+ * Aggregated stats for number of requests.
11070
11035
  */
11071
- $createdAt: string;
11036
+ bandwidth: Metric[];
11072
11037
  /**
11073
- * Addon update date in ISO 8601 format.
11038
+ * Aggregated stats for consumed bandwidth.
11074
11039
  */
11075
- $updatedAt: string;
11040
+ users: Metric[];
11076
11041
  /**
11077
- * Addon permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).
11042
+ * Aggregated stats for function executions.
11078
11043
  */
11079
- $permissions: string[];
11044
+ executions: number;
11080
11045
  /**
11081
- * Addon key
11046
+ * Aggregated stats for database reads.
11082
11047
  */
11083
- key: string;
11048
+ databasesReads: Metric[];
11084
11049
  /**
11085
- * Resource type (organization or project)
11050
+ * Aggregated stats for database writes.
11086
11051
  */
11087
- resourceType: string;
11052
+ databasesWrites: Metric[];
11088
11053
  /**
11089
- * Resource ID
11054
+ * Aggregated stats for function executions in mb seconds.
11090
11055
  */
11091
- resourceId: string;
11056
+ executionsMBSeconds: number;
11092
11057
  /**
11093
- * Payment status. Possible values: pending (awaiting payment confirmation e.g. 3DS), active (payment confirmed and addon is running).
11058
+ * Aggregated stats for function builds in mb seconds.
11094
11059
  */
11095
- status: string;
11060
+ buildsMBSeconds: number;
11096
11061
  /**
11097
- * Current value for this billing cycle. For toggle addons: 1 (on) or 0 (off). For numeric addons: the active quantity.
11062
+ * Aggregated stats for number of documents.
11098
11063
  */
11099
- currentValue: number;
11064
+ storage: number;
11100
11065
  /**
11101
- * Value to apply at the start of the next billing cycle. Null means no change is scheduled. For toggle addons, 0 means the addon will be removed at the next cycle.
11066
+ * Aggregated stats for phone authentication.
11102
11067
  */
11103
- nextValue?: number;
11104
- };
11105
- /**
11106
- * AddonPrice
11107
- */
11108
- export type AddonPrice = {
11068
+ authPhoneTotal: number;
11109
11069
  /**
11110
- * Addon key.
11070
+ * Aggregated stats for phone authentication estimated cost.
11111
11071
  */
11112
- addonKey: string;
11072
+ authPhoneEstimate: number;
11113
11073
  /**
11114
- * Addon display name.
11074
+ * Aggregated stats for total databases reads.
11115
11075
  */
11116
- name: string;
11076
+ databasesReadsTotal: number;
11117
11077
  /**
11118
- * Full monthly price of the addon.
11078
+ * Aggregated stats for total databases writes.
11119
11079
  */
11120
- monthlyPrice: number;
11080
+ databasesWritesTotal: number;
11121
11081
  /**
11122
- * Calculated prorated amount for the current billing cycle.
11082
+ * Aggregated stats for file transformations.
11123
11083
  */
11124
- proratedAmount: number;
11084
+ imageTransformations: Metric[];
11125
11085
  /**
11126
- * Days remaining in the current billing cycle.
11086
+ * Aggregated stats for total file transformations.
11127
11087
  */
11128
- remainingDays: number;
11088
+ imageTransformationsTotal: number;
11129
11089
  /**
11130
- * Total days in the billing cycle.
11090
+ * Aggregated stats for file transformations.
11131
11091
  */
11132
- totalCycleDays: number;
11092
+ screenshotsGenerated: Metric[];
11133
11093
  /**
11134
- * Currency code.
11094
+ * Aggregated stats for total file transformations.
11135
11095
  */
11136
- currency: string;
11096
+ screenshotsGeneratedTotal: number;
11137
11097
  /**
11138
- * When the current billing cycle ends.
11098
+ * Aggregated stats for imagine credits.
11139
11099
  */
11140
- billingCycleEnd: string;
11141
- };
11142
- /**
11143
- * domainTransferOut
11144
- */
11145
- export type DomainTransferOut = {
11100
+ imagineCredits: number;
11146
11101
  /**
11147
- * Domain transfer authorization code.
11102
+ * Aggregated stats for realtime connections.
11148
11103
  */
11149
- authCode: string;
11104
+ realtimeConnections: number;
11105
+ /**
11106
+ * Aggregated stats for realtime messages.
11107
+ */
11108
+ realtimeMessages: number;
11109
+ /**
11110
+ * Aggregated stats for realtime bandwidth.
11111
+ */
11112
+ realtimeBandwidth: number;
11150
11113
  };
11151
11114
  /**
11152
- * domainTransferStatus
11115
+ * Resource
11153
11116
  */
11154
- export type DomainTransferStatus = {
11117
+ export type UsageResources = {
11155
11118
  /**
11156
- * Transfer status.
11119
+ * Invoice name
11157
11120
  */
11158
- status: DomainTransferStatusEnum;
11121
+ name: string;
11159
11122
  /**
11160
- * Additional transfer status information.
11123
+ * Invoice value
11161
11124
  */
11162
- reason: string;
11125
+ value: number;
11163
11126
  /**
11164
- * Transfer status timestamp in ISO 8601 format.
11127
+ * Invoice amount
11165
11128
  */
11166
- timestamp: string;
11167
- };
11168
- /**
11169
- * Addons list
11170
- */
11171
- export type AddonList = {
11129
+ amount: number;
11172
11130
  /**
11173
- * Total number of addons that matched your query.
11131
+ * Invoice rate
11174
11132
  */
11175
- total: number;
11133
+ rate: number;
11176
11134
  /**
11177
- * List of addons.
11135
+ * Invoice description
11178
11136
  */
11179
- addons: Addon[];
11137
+ desc: string;
11138
+ /**
11139
+ * Resource ID
11140
+ */
11141
+ resourceId: string;
11180
11142
  };
11181
11143
  /**
11182
11144
  * Activity event list
@@ -11191,6 +11153,19 @@ export declare namespace Models {
11191
11153
  */
11192
11154
  events: ActivityEvent[];
11193
11155
  };
11156
+ /**
11157
+ * Addons list
11158
+ */
11159
+ export type AddonList = {
11160
+ /**
11161
+ * Total number of addons that matched your query.
11162
+ */
11163
+ total: number;
11164
+ /**
11165
+ * List of addons.
11166
+ */
11167
+ addons: Addon[];
11168
+ };
11194
11169
  /**
11195
11170
  * Aggregation team list
11196
11171
  */
@@ -11244,30 +11219,30 @@ export declare namespace Models {
11244
11219
  restorations: BackupRestoration[];
11245
11220
  };
11246
11221
  /**
11247
- * Billing invoices list
11222
+ * Billing address list
11248
11223
  */
11249
- export type InvoiceList = {
11224
+ export type BillingAddressList = {
11250
11225
  /**
11251
- * Total number of invoices that matched your query.
11226
+ * Total number of billingAddresses that matched your query.
11252
11227
  */
11253
11228
  total: number;
11254
11229
  /**
11255
- * List of invoices.
11230
+ * List of billingAddresses.
11256
11231
  */
11257
- invoices: Invoice[];
11232
+ billingAddresses: BillingAddress[];
11258
11233
  };
11259
11234
  /**
11260
- * Billing address list
11235
+ * Billing invoices list
11261
11236
  */
11262
- export type BillingAddressList = {
11237
+ export type InvoiceList = {
11263
11238
  /**
11264
- * Total number of billingAddresses that matched your query.
11239
+ * Total number of invoices that matched your query.
11265
11240
  */
11266
11241
  total: number;
11267
11242
  /**
11268
- * List of billingAddresses.
11243
+ * List of invoices.
11269
11244
  */
11270
- billingAddresses: BillingAddress[];
11245
+ invoices: Invoice[];
11271
11246
  };
11272
11247
  /**
11273
11248
  * Billing plan list
@@ -11283,95 +11258,121 @@ export declare namespace Models {
11283
11258
  plans: BillingPlan[];
11284
11259
  };
11285
11260
  /**
11286
- * Organizations list
11261
+ * Blocks list
11287
11262
  */
11288
- export type OrganizationList<Preferences extends Models.Preferences = Models.DefaultPreferences> = {
11263
+ export type BlockList = {
11289
11264
  /**
11290
- * Total number of teams that matched your query.
11265
+ * Total number of blocks that matched your query.
11291
11266
  */
11292
11267
  total: number;
11293
11268
  /**
11294
- * List of teams.
11269
+ * List of blocks.
11295
11270
  */
11296
- teams: Organization<Preferences>[];
11271
+ blocks: Block[];
11297
11272
  };
11298
11273
  /**
11299
- * Payment methods list
11274
+ * DNS records list
11300
11275
  */
11301
- export type PaymentMethodList = {
11276
+ export type DnsRecordsList = {
11302
11277
  /**
11303
- * Total number of paymentMethods that matched your query.
11278
+ * Total number of dnsRecords that matched your query.
11304
11279
  */
11305
11280
  total: number;
11306
11281
  /**
11307
- * List of paymentMethods.
11282
+ * List of dnsRecords.
11308
11283
  */
11309
- paymentMethods: PaymentMethod[];
11284
+ dnsRecords: DnsRecord[];
11310
11285
  };
11311
11286
  /**
11312
- * Blocks list
11287
+ * Domain suggestions list
11313
11288
  */
11314
- export type BlockList = {
11289
+ export type DomainSuggestionsList = {
11315
11290
  /**
11316
- * Total number of blocks that matched your query.
11291
+ * Total number of suggestions that matched your query.
11317
11292
  */
11318
11293
  total: number;
11319
11294
  /**
11320
- * List of blocks.
11295
+ * List of suggestions.
11321
11296
  */
11322
- blocks: Block[];
11297
+ suggestions: DomainSuggestion[];
11323
11298
  };
11324
11299
  /**
11325
- * Regions list
11300
+ * Domains list
11326
11301
  */
11327
- export type ConsoleRegionList = {
11302
+ export type DomainsList = {
11328
11303
  /**
11329
- * Total number of regions that matched your query.
11304
+ * Total number of domains that matched your query.
11330
11305
  */
11331
11306
  total: number;
11332
11307
  /**
11333
- * List of regions.
11308
+ * List of domains.
11334
11309
  */
11335
- regions: ConsoleRegion[];
11310
+ domains: Domain[];
11336
11311
  };
11337
11312
  /**
11338
- * Domains list
11313
+ * Organizations list
11339
11314
  */
11340
- export type DomainsList = {
11315
+ export type OrganizationList<Preferences extends Models.Preferences = Models.DefaultPreferences> = {
11341
11316
  /**
11342
- * Total number of domains that matched your query.
11317
+ * Total number of teams that matched your query.
11343
11318
  */
11344
11319
  total: number;
11345
11320
  /**
11346
- * List of domains.
11321
+ * List of teams.
11347
11322
  */
11348
- domains: Domain[];
11323
+ teams: Organization<Preferences>[];
11349
11324
  };
11350
11325
  /**
11351
- * DNS records list
11326
+ * Payment methods list
11352
11327
  */
11353
- export type DnsRecordsList = {
11328
+ export type PaymentMethodList = {
11354
11329
  /**
11355
- * Total number of dnsRecords that matched your query.
11330
+ * Total number of paymentMethods that matched your query.
11356
11331
  */
11357
11332
  total: number;
11358
11333
  /**
11359
- * List of dnsRecords.
11334
+ * List of paymentMethods.
11360
11335
  */
11361
- dnsRecords: DnsRecord[];
11336
+ paymentMethods: PaymentMethod[];
11362
11337
  };
11363
11338
  /**
11364
- * Domain suggestions list
11339
+ * Regions list
11365
11340
  */
11366
- export type DomainSuggestionsList = {
11341
+ export type ConsoleRegionList = {
11367
11342
  /**
11368
- * Total number of suggestions that matched your query.
11343
+ * Total number of regions that matched your query.
11369
11344
  */
11370
11345
  total: number;
11371
11346
  /**
11372
- * List of suggestions.
11347
+ * List of regions.
11373
11348
  */
11374
- suggestions: DomainSuggestion[];
11349
+ regions: ConsoleRegion[];
11350
+ };
11351
+ /**
11352
+ * Usage events list
11353
+ */
11354
+ export type UsageEventList = {
11355
+ /**
11356
+ * Total number of events that matched your query.
11357
+ */
11358
+ total: number;
11359
+ /**
11360
+ * List of events.
11361
+ */
11362
+ events: UsageEvent[];
11363
+ };
11364
+ /**
11365
+ * Usage gauges list
11366
+ */
11367
+ export type UsageGaugeList = {
11368
+ /**
11369
+ * Total number of gauges that matched your query.
11370
+ */
11371
+ total: number;
11372
+ /**
11373
+ * List of gauges.
11374
+ */
11375
+ gauges: UsageGauge[];
11375
11376
  };
11376
11377
  export {};
11377
11378
  }