@appwrite.io/console 1.5.2 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/cjs/sdk.js +7673 -9723
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +7673 -9723
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +7673 -9723
- package/docs/examples/organizations/validate-invoice.md +14 -0
- package/package.json +1 -1
- package/src/client.ts +21 -4
- package/src/enums/o-auth-provider.ts +1 -0
- package/src/models.ts +118 -6
- package/src/services/account.ts +126 -430
- package/src/services/assistant.ts +2 -7
- package/src/services/avatars.ts +7 -21
- package/src/services/backups.ts +24 -84
- package/src/services/console.ts +14 -49
- package/src/services/databases.ts +96 -336
- package/src/services/functions.ts +55 -192
- package/src/services/graphql.ts +4 -14
- package/src/services/health.ts +50 -175
- package/src/services/locale.ts +16 -56
- package/src/services/messaging.ts +92 -322
- package/src/services/migrations.ts +24 -84
- package/src/services/organizations.ts +86 -196
- package/src/services/project.ts +12 -42
- package/src/services/projects.ts +92 -322
- package/src/services/proxy.ts +10 -35
- package/src/services/storage.ts +27 -93
- package/src/services/teams.ts +28 -98
- package/src/services/users.ts +86 -301
- package/src/services/vcs.ts +20 -70
- package/types/enums/o-auth-provider.d.ts +1 -0
- package/types/models.d.ts +118 -6
- package/types/services/account.d.ts +4 -128
- package/types/services/assistant.d.ts +0 -2
- package/types/services/avatars.d.ts +0 -14
- package/types/services/backups.d.ts +0 -24
- package/types/services/console.d.ts +0 -14
- package/types/services/databases.d.ts +0 -96
- package/types/services/functions.d.ts +0 -56
- package/types/services/graphql.d.ts +0 -4
- package/types/services/health.d.ts +0 -50
- package/types/services/locale.d.ts +0 -16
- package/types/services/messaging.d.ts +0 -92
- package/types/services/migrations.d.ts +0 -24
- package/types/services/organizations.d.ts +11 -58
- package/types/services/project.d.ts +0 -12
- package/types/services/projects.d.ts +0 -92
- package/types/services/proxy.d.ts +0 -10
- package/types/services/storage.d.ts +0 -30
- package/types/services/teams.d.ts +0 -28
- package/types/services/users.d.ts +0 -86
- package/types/services/vcs.d.ts +0 -20
|
@@ -5,8 +5,6 @@ export declare class Organizations {
|
|
|
5
5
|
client: Client;
|
|
6
6
|
constructor(client: Client);
|
|
7
7
|
/**
|
|
8
|
-
* List Orgnizations
|
|
9
|
-
*
|
|
10
8
|
* Get a list of all the teams in which the current user is a member. You can use the parameters to filter your results.
|
|
11
9
|
*
|
|
12
10
|
* @param {string[]} queries
|
|
@@ -16,8 +14,6 @@ export declare class Organizations {
|
|
|
16
14
|
*/
|
|
17
15
|
list<Preferences extends Models.Preferences>(queries?: string[], search?: string): Promise<Models.OrganizationList<Preferences>>;
|
|
18
16
|
/**
|
|
19
|
-
* Create Organization
|
|
20
|
-
*
|
|
21
17
|
* Create a new organization.
|
|
22
18
|
|
|
23
19
|
*
|
|
@@ -35,8 +31,6 @@ export declare class Organizations {
|
|
|
35
31
|
*/
|
|
36
32
|
create<Preferences extends Models.Preferences>(organizationId: string, name: string, billingPlan: BillingPlan, paymentMethodId?: string, billingAddressId?: string, invites?: string[], couponId?: string, taxId?: string, budget?: number): Promise<Models.Organization<Preferences>>;
|
|
37
33
|
/**
|
|
38
|
-
* Delete team
|
|
39
|
-
*
|
|
40
34
|
* Delete an organization.
|
|
41
35
|
*
|
|
42
36
|
* @param {string} organizationId
|
|
@@ -45,8 +39,6 @@ export declare class Organizations {
|
|
|
45
39
|
*/
|
|
46
40
|
delete(organizationId: string): Promise<{}>;
|
|
47
41
|
/**
|
|
48
|
-
* List aggregations
|
|
49
|
-
*
|
|
50
42
|
* Get a list of all aggregations for an organization.
|
|
51
43
|
*
|
|
52
44
|
* @param {string} organizationId
|
|
@@ -56,19 +48,15 @@ export declare class Organizations {
|
|
|
56
48
|
*/
|
|
57
49
|
listAggregations(organizationId: string, queries?: string[]): Promise<Models.AggregationTeamList>;
|
|
58
50
|
/**
|
|
59
|
-
* Get invoice
|
|
60
|
-
*
|
|
61
51
|
* Get a specific aggregation using it's aggregation ID.
|
|
62
52
|
*
|
|
63
53
|
* @param {string} organizationId
|
|
64
54
|
* @param {string} aggregationId
|
|
65
55
|
* @throws {AppwriteException}
|
|
66
|
-
* @returns {Promise<Models.
|
|
56
|
+
* @returns {Promise<Models.AggregationTeam>}
|
|
67
57
|
*/
|
|
68
|
-
getAggregation(organizationId: string, aggregationId: string): Promise<Models.
|
|
58
|
+
getAggregation(organizationId: string, aggregationId: string): Promise<Models.AggregationTeam>;
|
|
69
59
|
/**
|
|
70
|
-
* Set team's billing address
|
|
71
|
-
*
|
|
72
60
|
* Set a billing address for an organization.
|
|
73
61
|
*
|
|
74
62
|
* @param {string} organizationId
|
|
@@ -78,8 +66,6 @@ export declare class Organizations {
|
|
|
78
66
|
*/
|
|
79
67
|
setBillingAddress<Preferences extends Models.Preferences>(organizationId: string, billingAddressId: string): Promise<Models.Organization<Preferences>>;
|
|
80
68
|
/**
|
|
81
|
-
* Delete team's billing address
|
|
82
|
-
*
|
|
83
69
|
* Delete a team's billing address.
|
|
84
70
|
*
|
|
85
71
|
* @param {string} organizationId
|
|
@@ -88,8 +74,6 @@ export declare class Organizations {
|
|
|
88
74
|
*/
|
|
89
75
|
deleteBillingAddress(organizationId: string): Promise<{}>;
|
|
90
76
|
/**
|
|
91
|
-
* Get billing address
|
|
92
|
-
*
|
|
93
77
|
* Get a billing address using it's ID.
|
|
94
78
|
*
|
|
95
79
|
* @param {string} organizationId
|
|
@@ -99,8 +83,6 @@ export declare class Organizations {
|
|
|
99
83
|
*/
|
|
100
84
|
getBillingAddress(organizationId: string, billingAddressId: string): Promise<Models.BillingAddress>;
|
|
101
85
|
/**
|
|
102
|
-
* Set team's billing email
|
|
103
|
-
*
|
|
104
86
|
* Set the current billing email for the organization.
|
|
105
87
|
*
|
|
106
88
|
* @param {string} organizationId
|
|
@@ -110,8 +92,6 @@ export declare class Organizations {
|
|
|
110
92
|
*/
|
|
111
93
|
setBillingEmail<Preferences extends Models.Preferences>(organizationId: string, billingEmail: string): Promise<Models.Organization<Preferences>>;
|
|
112
94
|
/**
|
|
113
|
-
* Update organization budget
|
|
114
|
-
*
|
|
115
95
|
* Update the budget limit for an organization.
|
|
116
96
|
*
|
|
117
97
|
* @param {string} organizationId
|
|
@@ -120,10 +100,8 @@ export declare class Organizations {
|
|
|
120
100
|
* @throws {AppwriteException}
|
|
121
101
|
* @returns {Promise<Models.Organization<Preferences>>}
|
|
122
102
|
*/
|
|
123
|
-
updateBudget<Preferences extends Models.Preferences>(organizationId: string, budget
|
|
103
|
+
updateBudget<Preferences extends Models.Preferences>(organizationId: string, budget?: number, alerts?: number[]): Promise<Models.Organization<Preferences>>;
|
|
124
104
|
/**
|
|
125
|
-
* List credits
|
|
126
|
-
*
|
|
127
105
|
* List all credits for an organization.
|
|
128
106
|
|
|
129
107
|
*
|
|
@@ -134,8 +112,6 @@ export declare class Organizations {
|
|
|
134
112
|
*/
|
|
135
113
|
listCredits(organizationId: string, queries?: string[]): Promise<Models.CreditList>;
|
|
136
114
|
/**
|
|
137
|
-
* Add credits from coupon
|
|
138
|
-
*
|
|
139
115
|
* Add credit to an organization using a coupon.
|
|
140
116
|
*
|
|
141
117
|
* @param {string} organizationId
|
|
@@ -145,8 +121,6 @@ export declare class Organizations {
|
|
|
145
121
|
*/
|
|
146
122
|
addCredit(organizationId: string, couponId: string): Promise<Models.Credit>;
|
|
147
123
|
/**
|
|
148
|
-
* Get credit details
|
|
149
|
-
*
|
|
150
124
|
* Get credit details.
|
|
151
125
|
*
|
|
152
126
|
* @param {string} organizationId
|
|
@@ -156,8 +130,6 @@ export declare class Organizations {
|
|
|
156
130
|
*/
|
|
157
131
|
getCredit(organizationId: string, creditId: string): Promise<Models.Credit>;
|
|
158
132
|
/**
|
|
159
|
-
* List invoices
|
|
160
|
-
*
|
|
161
133
|
* List all invoices for an organization.
|
|
162
134
|
*
|
|
163
135
|
* @param {string} organizationId
|
|
@@ -167,8 +139,6 @@ export declare class Organizations {
|
|
|
167
139
|
*/
|
|
168
140
|
listInvoices(organizationId: string, queries?: string[]): Promise<Models.InvoiceList>;
|
|
169
141
|
/**
|
|
170
|
-
* Get invoice
|
|
171
|
-
*
|
|
172
142
|
* Get an invoice by its unique ID.
|
|
173
143
|
*
|
|
174
144
|
* @param {string} organizationId
|
|
@@ -178,8 +148,6 @@ export declare class Organizations {
|
|
|
178
148
|
*/
|
|
179
149
|
getInvoice(organizationId: string, invoiceId: string): Promise<Models.Invoice>;
|
|
180
150
|
/**
|
|
181
|
-
* Download invoice in PDF
|
|
182
|
-
*
|
|
183
151
|
* Download invoice in PDF
|
|
184
152
|
*
|
|
185
153
|
* @param {string} organizationId
|
|
@@ -189,8 +157,6 @@ export declare class Organizations {
|
|
|
189
157
|
*/
|
|
190
158
|
getInvoiceDownload(organizationId: string, invoiceId: string): Promise<Models.PaymentMethod>;
|
|
191
159
|
/**
|
|
192
|
-
* Initiate payment for failed invoice to pay live from console
|
|
193
|
-
*
|
|
194
160
|
* Initiate payment for failed invoice to pay live from console
|
|
195
161
|
*
|
|
196
162
|
* @param {string} organizationId
|
|
@@ -201,8 +167,15 @@ export declare class Organizations {
|
|
|
201
167
|
*/
|
|
202
168
|
createInvoicePayment(organizationId: string, invoiceId: string, paymentMethodId: string): Promise<Models.Invoice>;
|
|
203
169
|
/**
|
|
204
|
-
*
|
|
170
|
+
* Validates the payment linked with the invoice and updates the invoice status if the payment status is changed.
|
|
205
171
|
*
|
|
172
|
+
* @param {string} organizationId
|
|
173
|
+
* @param {string} invoiceId
|
|
174
|
+
* @throws {AppwriteException}
|
|
175
|
+
* @returns {Promise<Models.Invoice>}
|
|
176
|
+
*/
|
|
177
|
+
validateInvoice(organizationId: string, invoiceId: string): Promise<Models.Invoice>;
|
|
178
|
+
/**
|
|
206
179
|
* View invoice in PDF
|
|
207
180
|
*
|
|
208
181
|
* @param {string} organizationId
|
|
@@ -212,8 +185,6 @@ export declare class Organizations {
|
|
|
212
185
|
*/
|
|
213
186
|
getInvoiceView(organizationId: string, invoiceId: string): Promise<Models.PaymentMethod>;
|
|
214
187
|
/**
|
|
215
|
-
* Set team's payment method
|
|
216
|
-
*
|
|
217
188
|
* Set a organization's default payment method.
|
|
218
189
|
*
|
|
219
190
|
* @param {string} organizationId
|
|
@@ -223,8 +194,6 @@ export declare class Organizations {
|
|
|
223
194
|
*/
|
|
224
195
|
setDefaultPaymentMethod<Preferences extends Models.Preferences>(organizationId: string, paymentMethodId: string): Promise<Models.Organization<Preferences>>;
|
|
225
196
|
/**
|
|
226
|
-
* Delete team's default payment method
|
|
227
|
-
*
|
|
228
197
|
* Delete the default payment method for an organization.
|
|
229
198
|
*
|
|
230
199
|
* @param {string} organizationId
|
|
@@ -233,8 +202,6 @@ export declare class Organizations {
|
|
|
233
202
|
*/
|
|
234
203
|
deleteDefaultPaymentMethod<Preferences extends Models.Preferences>(organizationId: string): Promise<Models.Organization<Preferences>>;
|
|
235
204
|
/**
|
|
236
|
-
* Set team's backup payment method
|
|
237
|
-
*
|
|
238
205
|
* Set an organization's backup payment method.
|
|
239
206
|
|
|
240
207
|
*
|
|
@@ -245,8 +212,6 @@ export declare class Organizations {
|
|
|
245
212
|
*/
|
|
246
213
|
setBackupPaymentMethod<Preferences extends Models.Preferences>(organizationId: string, paymentMethodId: string): Promise<Models.Organization<Preferences>>;
|
|
247
214
|
/**
|
|
248
|
-
* Delete team's backup payment method
|
|
249
|
-
*
|
|
250
215
|
* Delete a backup payment method for an organization.
|
|
251
216
|
*
|
|
252
217
|
* @param {string} organizationId
|
|
@@ -255,8 +220,6 @@ export declare class Organizations {
|
|
|
255
220
|
*/
|
|
256
221
|
deleteBackupPaymentMethod<Preferences extends Models.Preferences>(organizationId: string): Promise<Models.Organization<Preferences>>;
|
|
257
222
|
/**
|
|
258
|
-
* Get payment method
|
|
259
|
-
*
|
|
260
223
|
* Get an organization's payment method using it's payment method ID.
|
|
261
224
|
*
|
|
262
225
|
* @param {string} organizationId
|
|
@@ -266,8 +229,6 @@ export declare class Organizations {
|
|
|
266
229
|
*/
|
|
267
230
|
getPaymentMethod(organizationId: string, paymentMethodId: string): Promise<Models.PaymentMethod>;
|
|
268
231
|
/**
|
|
269
|
-
* Get organization billing plan details
|
|
270
|
-
*
|
|
271
232
|
* Get the details of the current billing plan for an organization.
|
|
272
233
|
*
|
|
273
234
|
* @param {string} organizationId
|
|
@@ -276,8 +237,6 @@ export declare class Organizations {
|
|
|
276
237
|
*/
|
|
277
238
|
getPlan(organizationId: string): Promise<Models.BillingPlan>;
|
|
278
239
|
/**
|
|
279
|
-
* Update organization billing plan
|
|
280
|
-
*
|
|
281
240
|
* Update the billing plan for an organization.
|
|
282
241
|
*
|
|
283
242
|
* @param {string} organizationId
|
|
@@ -293,8 +252,6 @@ export declare class Organizations {
|
|
|
293
252
|
*/
|
|
294
253
|
updatePlan<Preferences extends Models.Preferences>(organizationId: string, billingPlan: BillingPlan, paymentMethodId?: string, billingAddressId?: string, invites?: string[], couponId?: string, taxId?: string, budget?: number): Promise<Models.Organization<Preferences>>;
|
|
295
254
|
/**
|
|
296
|
-
* Get Scopes
|
|
297
|
-
*
|
|
298
255
|
* Get Scopes
|
|
299
256
|
*
|
|
300
257
|
* @param {string} organizationId
|
|
@@ -303,8 +260,6 @@ export declare class Organizations {
|
|
|
303
260
|
*/
|
|
304
261
|
getScopes(organizationId: string): Promise<Models.Roles>;
|
|
305
262
|
/**
|
|
306
|
-
* Set team's tax Id
|
|
307
|
-
*
|
|
308
263
|
* Set an organization's billing tax ID.
|
|
309
264
|
*
|
|
310
265
|
* @param {string} organizationId
|
|
@@ -314,8 +269,6 @@ export declare class Organizations {
|
|
|
314
269
|
*/
|
|
315
270
|
setBillingTaxId<Preferences extends Models.Preferences>(organizationId: string, taxId: string): Promise<Models.Organization<Preferences>>;
|
|
316
271
|
/**
|
|
317
|
-
* Get team's usage data
|
|
318
|
-
*
|
|
319
272
|
* Get the usage data for an organization.
|
|
320
273
|
*
|
|
321
274
|
* @param {string} organizationId
|
|
@@ -5,8 +5,6 @@ export declare class Project {
|
|
|
5
5
|
client: Client;
|
|
6
6
|
constructor(client: Client);
|
|
7
7
|
/**
|
|
8
|
-
* Get project usage stats
|
|
9
|
-
*
|
|
10
8
|
* Get comprehensive usage statistics for your project. View metrics including network requests, bandwidth, storage, function executions, database usage, and user activity. Specify a time range with startDate and endDate, and optionally set the data granularity with period (1h or 1d). The response includes both total counts and detailed breakdowns by resource, along with historical data over the specified period.
|
|
11
9
|
*
|
|
12
10
|
* @param {string} startDate
|
|
@@ -17,8 +15,6 @@ export declare class Project {
|
|
|
17
15
|
*/
|
|
18
16
|
getUsage(startDate: string, endDate: string, period?: ProjectUsageRange): Promise<Models.UsageProject>;
|
|
19
17
|
/**
|
|
20
|
-
* List variables
|
|
21
|
-
*
|
|
22
18
|
* Get a list of all project variables. These variables will be accessible in all Appwrite Functions at runtime.
|
|
23
19
|
*
|
|
24
20
|
* @throws {AppwriteException}
|
|
@@ -26,8 +22,6 @@ export declare class Project {
|
|
|
26
22
|
*/
|
|
27
23
|
listVariables(): Promise<Models.VariableList>;
|
|
28
24
|
/**
|
|
29
|
-
* Create variable
|
|
30
|
-
*
|
|
31
25
|
* Create a new project variable. This variable will be accessible in all Appwrite Functions at runtime.
|
|
32
26
|
*
|
|
33
27
|
* @param {string} key
|
|
@@ -37,8 +31,6 @@ export declare class Project {
|
|
|
37
31
|
*/
|
|
38
32
|
createVariable(key: string, value: string): Promise<Models.Variable>;
|
|
39
33
|
/**
|
|
40
|
-
* Get variable
|
|
41
|
-
*
|
|
42
34
|
* Get a project variable by its unique ID.
|
|
43
35
|
*
|
|
44
36
|
* @param {string} variableId
|
|
@@ -47,8 +39,6 @@ export declare class Project {
|
|
|
47
39
|
*/
|
|
48
40
|
getVariable(variableId: string): Promise<Models.Variable>;
|
|
49
41
|
/**
|
|
50
|
-
* Update variable
|
|
51
|
-
*
|
|
52
42
|
* Update project variable by its unique ID. This variable will be accessible in all Appwrite Functions at runtime.
|
|
53
43
|
*
|
|
54
44
|
* @param {string} variableId
|
|
@@ -59,8 +49,6 @@ export declare class Project {
|
|
|
59
49
|
*/
|
|
60
50
|
updateVariable(variableId: string, key: string, value?: string): Promise<Models.Variable>;
|
|
61
51
|
/**
|
|
62
|
-
* Delete variable
|
|
63
|
-
*
|
|
64
52
|
* Delete a project variable by its unique ID.
|
|
65
53
|
*
|
|
66
54
|
* @param {string} variableId
|