@appwrite.io/console 1.2.2 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/autoclose.yml +1 -1
- package/README.md +1 -1
- package/dist/cjs/sdk.js +4875 -3335
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +4874 -3336
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +4875 -3335
- package/docs/examples/account/create-payment-method.md +11 -0
- package/docs/examples/account/delete-payment-method.md +13 -0
- package/docs/examples/account/get-billing-address.md +13 -0
- package/docs/examples/account/get-payment-method.md +13 -0
- package/docs/examples/account/list-billing-addresses.md +13 -0
- package/docs/examples/account/list-credits.md +14 -0
- package/docs/examples/account/list-invoices.md +13 -0
- package/docs/examples/account/list-payment-methods.md +13 -0
- package/docs/examples/account/update-payment-method-mandate-options.md +13 -0
- package/docs/examples/account/update-payment-method-provider.md +15 -0
- package/docs/examples/account/update-payment-method.md +15 -0
- package/docs/examples/backups/create-archive.md +14 -0
- package/docs/examples/backups/create-policy.md +19 -0
- package/docs/examples/backups/create-restoration.md +16 -0
- package/docs/examples/backups/delete-archive.md +13 -0
- package/docs/examples/backups/delete-policy.md +13 -0
- package/docs/examples/backups/get-archive.md +13 -0
- package/docs/examples/backups/get-policy.md +13 -0
- package/docs/examples/backups/get-restoration.md +13 -0
- package/docs/examples/backups/list-archives.md +13 -0
- package/docs/examples/backups/list-policies.md +13 -0
- package/docs/examples/backups/list-restorations.md +13 -0
- package/docs/examples/backups/update-policy.md +17 -0
- package/docs/examples/console/create-source.md +17 -0
- package/docs/examples/console/get-campaign.md +13 -0
- package/docs/examples/console/get-copon.md +13 -0
- package/docs/examples/console/plans.md +11 -0
- package/docs/examples/console/regions.md +11 -0
- package/docs/examples/health/get-queue-billing-aggregation.md +13 -0
- package/docs/examples/health/get-queue-priority-builds.md +13 -0
- package/docs/examples/organizations/add-credit.md +14 -0
- package/docs/examples/organizations/create-invoice-payment.md +15 -0
- package/docs/examples/organizations/create.md +17 -0
- package/docs/examples/organizations/delete-backup-payment-method.md +13 -0
- package/docs/examples/organizations/delete-billing-address.md +13 -0
- package/docs/examples/organizations/delete-default-payment-method.md +13 -0
- package/docs/examples/organizations/delete.md +13 -0
- package/docs/examples/organizations/get-aggregation.md +14 -0
- package/docs/examples/organizations/get-billing-address.md +14 -0
- package/docs/examples/organizations/get-credit.md +14 -0
- package/docs/examples/organizations/get-invoice-download.md +14 -0
- package/docs/examples/organizations/get-invoice-view.md +14 -0
- package/docs/examples/organizations/get-invoice.md +14 -0
- package/docs/examples/organizations/get-payment-method.md +14 -0
- package/docs/examples/organizations/get-plan.md +13 -0
- package/docs/examples/organizations/get-scopes.md +13 -0
- package/docs/examples/organizations/get-usage.md +15 -0
- package/docs/examples/organizations/list-aggregations.md +14 -0
- package/docs/examples/organizations/list-invoices.md +14 -0
- package/docs/examples/organizations/list.md +14 -0
- package/docs/examples/organizations/set-backup-payment-method.md +14 -0
- package/docs/examples/organizations/set-billing-address.md +14 -0
- package/docs/examples/organizations/set-billing-email.md +14 -0
- package/docs/examples/organizations/set-billing-tax-id.md +14 -0
- package/docs/examples/organizations/set-default-payment-method.md +14 -0
- package/docs/examples/organizations/update-budget.md +15 -0
- package/docs/examples/organizations/update-plan.md +16 -0
- package/package.json +1 -1
- package/src/client.ts +1 -1
- package/src/enums/billing-plan.ts +5 -0
- package/src/enums/runtime.ts +0 -3
- package/src/index.ts +3 -0
- package/src/models.ts +1112 -1
- package/src/services/account.ts +336 -0
- package/src/services/backups.ts +425 -0
- package/src/services/console.ts +148 -0
- package/src/services/health.ts +56 -0
- package/src/services/organizations.ts +924 -0
- package/types/enums/billing-plan.d.ts +5 -0
- package/types/enums/runtime.d.ts +0 -3
- package/types/index.d.ts +3 -0
- package/types/models.d.ts +1112 -1
- package/types/services/account.d.ts +103 -0
- package/types/services/backups.d.ts +128 -0
- package/types/services/console.d.ts +47 -0
- package/types/services/health.d.ts +18 -0
- package/types/services/organizations.d.ts +282 -0
- package/.travis.yml +0 -32
|
@@ -37,6 +37,24 @@ export declare class Account {
|
|
|
37
37
|
* @returns {Promise<{}>}
|
|
38
38
|
*/
|
|
39
39
|
delete(): Promise<{}>;
|
|
40
|
+
/**
|
|
41
|
+
* List billing addresses
|
|
42
|
+
*
|
|
43
|
+
*
|
|
44
|
+
* @param {string[]} queries
|
|
45
|
+
* @throws {AppwriteException}
|
|
46
|
+
* @returns {Promise<Models.BillingAddress>}
|
|
47
|
+
*/
|
|
48
|
+
listBillingAddresses(queries?: string[]): Promise<Models.BillingAddress>;
|
|
49
|
+
/**
|
|
50
|
+
* Get billing address
|
|
51
|
+
*
|
|
52
|
+
*
|
|
53
|
+
* @param {string} billingAddressId
|
|
54
|
+
* @throws {AppwriteException}
|
|
55
|
+
* @returns {Promise<Models.BillingAddress>}
|
|
56
|
+
*/
|
|
57
|
+
getBillingAddress(billingAddressId: string): Promise<Models.BillingAddress>;
|
|
40
58
|
/**
|
|
41
59
|
* Update email
|
|
42
60
|
*
|
|
@@ -70,6 +88,15 @@ This endpoint can also be used to convert an anonymous account to a normal one,
|
|
|
70
88
|
* @returns {Promise<{}>}
|
|
71
89
|
*/
|
|
72
90
|
deleteIdentity(identityId: string): Promise<{}>;
|
|
91
|
+
/**
|
|
92
|
+
* List invoices
|
|
93
|
+
*
|
|
94
|
+
*
|
|
95
|
+
* @param {string[]} queries
|
|
96
|
+
* @throws {AppwriteException}
|
|
97
|
+
* @returns {Promise<Models.InvoiceList>}
|
|
98
|
+
*/
|
|
99
|
+
listInvoices(queries?: string[]): Promise<Models.InvoiceList>;
|
|
73
100
|
/**
|
|
74
101
|
* Create JWT
|
|
75
102
|
*
|
|
@@ -208,6 +235,72 @@ This endpoint can also be used to convert an anonymous account to a normal one,
|
|
|
208
235
|
* @returns {Promise<Models.User<Preferences>>}
|
|
209
236
|
*/
|
|
210
237
|
updatePassword<Preferences extends Models.Preferences>(password: string, oldPassword?: string): Promise<Models.User<Preferences>>;
|
|
238
|
+
/**
|
|
239
|
+
* List payment methods
|
|
240
|
+
*
|
|
241
|
+
*
|
|
242
|
+
* @param {string[]} queries
|
|
243
|
+
* @throws {AppwriteException}
|
|
244
|
+
* @returns {Promise<Models.PaymentMethodList>}
|
|
245
|
+
*/
|
|
246
|
+
listPaymentMethods(queries?: string[]): Promise<Models.PaymentMethodList>;
|
|
247
|
+
/**
|
|
248
|
+
* Create new payment method
|
|
249
|
+
*
|
|
250
|
+
*
|
|
251
|
+
* @throws {AppwriteException}
|
|
252
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
253
|
+
*/
|
|
254
|
+
createPaymentMethod(): Promise<Models.PaymentMethod>;
|
|
255
|
+
/**
|
|
256
|
+
* Get payment method
|
|
257
|
+
*
|
|
258
|
+
*
|
|
259
|
+
* @param {string} paymentMethodId
|
|
260
|
+
* @throws {AppwriteException}
|
|
261
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
262
|
+
*/
|
|
263
|
+
getPaymentMethod(paymentMethodId: string): Promise<Models.PaymentMethod>;
|
|
264
|
+
/**
|
|
265
|
+
* Update payment method
|
|
266
|
+
*
|
|
267
|
+
*
|
|
268
|
+
* @param {string} paymentMethodId
|
|
269
|
+
* @param {number} expiryMonth
|
|
270
|
+
* @param {number} expiryYear
|
|
271
|
+
* @throws {AppwriteException}
|
|
272
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
273
|
+
*/
|
|
274
|
+
updatePaymentMethod(paymentMethodId: string, expiryMonth: number, expiryYear: number): Promise<Models.PaymentMethod>;
|
|
275
|
+
/**
|
|
276
|
+
* Delete payment method
|
|
277
|
+
*
|
|
278
|
+
*
|
|
279
|
+
* @param {string} paymentMethodId
|
|
280
|
+
* @throws {AppwriteException}
|
|
281
|
+
* @returns {Promise<{}>}
|
|
282
|
+
*/
|
|
283
|
+
deletePaymentMethod(paymentMethodId: string): Promise<{}>;
|
|
284
|
+
/**
|
|
285
|
+
* Update payment method provider id
|
|
286
|
+
*
|
|
287
|
+
*
|
|
288
|
+
* @param {string} paymentMethodId
|
|
289
|
+
* @param {string} providerMethodId
|
|
290
|
+
* @param {string} name
|
|
291
|
+
* @throws {AppwriteException}
|
|
292
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
293
|
+
*/
|
|
294
|
+
updatePaymentMethodProvider(paymentMethodId: string, providerMethodId: string, name: string): Promise<Models.PaymentMethod>;
|
|
295
|
+
/**
|
|
296
|
+
* Update payment method with new setup with mandates for indian cards
|
|
297
|
+
*
|
|
298
|
+
*
|
|
299
|
+
* @param {string} paymentMethodId
|
|
300
|
+
* @throws {AppwriteException}
|
|
301
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
302
|
+
*/
|
|
303
|
+
updatePaymentMethodMandateOptions(paymentMethodId: string): Promise<Models.PaymentMethod>;
|
|
211
304
|
/**
|
|
212
305
|
* Update phone
|
|
213
306
|
*
|
|
@@ -527,4 +620,14 @@ Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/
|
|
|
527
620
|
* @returns {Promise<Models.Token>}
|
|
528
621
|
*/
|
|
529
622
|
updatePhoneVerification(userId: string, secret: string): Promise<Models.Token>;
|
|
623
|
+
/**
|
|
624
|
+
* List credits
|
|
625
|
+
*
|
|
626
|
+
*
|
|
627
|
+
* @param {string} organizationId
|
|
628
|
+
* @param {string[]} queries
|
|
629
|
+
* @throws {AppwriteException}
|
|
630
|
+
* @returns {Promise<Models.CreditList>}
|
|
631
|
+
*/
|
|
632
|
+
listCredits(organizationId: string, queries?: string[]): Promise<Models.CreditList>;
|
|
530
633
|
}
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
import { Client } from '../client';
|
|
2
|
+
import type { Models } from '../models';
|
|
3
|
+
export declare class Backups {
|
|
4
|
+
client: Client;
|
|
5
|
+
constructor(client: Client);
|
|
6
|
+
/**
|
|
7
|
+
* List archives
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* @param {string[]} queries
|
|
11
|
+
* @throws {AppwriteException}
|
|
12
|
+
* @returns {Promise<Models.BackupArchiveList>}
|
|
13
|
+
*/
|
|
14
|
+
listArchives(queries?: string[]): Promise<Models.BackupArchiveList>;
|
|
15
|
+
/**
|
|
16
|
+
* Create archive
|
|
17
|
+
*
|
|
18
|
+
*
|
|
19
|
+
* @param {string[]} services
|
|
20
|
+
* @param {string} resourceId
|
|
21
|
+
* @throws {AppwriteException}
|
|
22
|
+
* @returns {Promise<Models.BackupArchive>}
|
|
23
|
+
*/
|
|
24
|
+
createArchive(services: string[], resourceId?: string): Promise<Models.BackupArchive>;
|
|
25
|
+
/**
|
|
26
|
+
* Get backup archive
|
|
27
|
+
*
|
|
28
|
+
*
|
|
29
|
+
* @param {string} archiveId
|
|
30
|
+
* @throws {AppwriteException}
|
|
31
|
+
* @returns {Promise<Models.BackupArchive>}
|
|
32
|
+
*/
|
|
33
|
+
getArchive(archiveId: string): Promise<Models.BackupArchive>;
|
|
34
|
+
/**
|
|
35
|
+
* Delete archive
|
|
36
|
+
*
|
|
37
|
+
*
|
|
38
|
+
* @param {string} archiveId
|
|
39
|
+
* @throws {AppwriteException}
|
|
40
|
+
* @returns {Promise<{}>}
|
|
41
|
+
*/
|
|
42
|
+
deleteArchive(archiveId: string): Promise<{}>;
|
|
43
|
+
/**
|
|
44
|
+
* List backup policies
|
|
45
|
+
*
|
|
46
|
+
*
|
|
47
|
+
* @param {string[]} queries
|
|
48
|
+
* @throws {AppwriteException}
|
|
49
|
+
* @returns {Promise<Models.BackupPolicyList>}
|
|
50
|
+
*/
|
|
51
|
+
listPolicies(queries?: string[]): Promise<Models.BackupPolicyList>;
|
|
52
|
+
/**
|
|
53
|
+
* Create backup policy
|
|
54
|
+
*
|
|
55
|
+
*
|
|
56
|
+
* @param {string} policyId
|
|
57
|
+
* @param {string[]} services
|
|
58
|
+
* @param {number} retention
|
|
59
|
+
* @param {string} schedule
|
|
60
|
+
* @param {string} name
|
|
61
|
+
* @param {string} resourceId
|
|
62
|
+
* @param {boolean} enabled
|
|
63
|
+
* @throws {AppwriteException}
|
|
64
|
+
* @returns {Promise<Models.BackupPolicy>}
|
|
65
|
+
*/
|
|
66
|
+
createPolicy(policyId: string, services: string[], retention: number, schedule: string, name?: string, resourceId?: string, enabled?: boolean): Promise<Models.BackupPolicy>;
|
|
67
|
+
/**
|
|
68
|
+
* Get backup policy
|
|
69
|
+
*
|
|
70
|
+
*
|
|
71
|
+
* @param {string} policyId
|
|
72
|
+
* @throws {AppwriteException}
|
|
73
|
+
* @returns {Promise<Models.BackupPolicy>}
|
|
74
|
+
*/
|
|
75
|
+
getPolicy(policyId: string): Promise<Models.BackupPolicy>;
|
|
76
|
+
/**
|
|
77
|
+
* Update backup policy
|
|
78
|
+
*
|
|
79
|
+
*
|
|
80
|
+
* @param {string} policyId
|
|
81
|
+
* @param {string} name
|
|
82
|
+
* @param {number} retention
|
|
83
|
+
* @param {string} schedule
|
|
84
|
+
* @param {boolean} enabled
|
|
85
|
+
* @throws {AppwriteException}
|
|
86
|
+
* @returns {Promise<Models.BackupPolicy>}
|
|
87
|
+
*/
|
|
88
|
+
updatePolicy(policyId: string, name?: string, retention?: number, schedule?: string, enabled?: boolean): Promise<Models.BackupPolicy>;
|
|
89
|
+
/**
|
|
90
|
+
* Delete backup policy
|
|
91
|
+
*
|
|
92
|
+
*
|
|
93
|
+
* @param {string} policyId
|
|
94
|
+
* @throws {AppwriteException}
|
|
95
|
+
* @returns {Promise<{}>}
|
|
96
|
+
*/
|
|
97
|
+
deletePolicy(policyId: string): Promise<{}>;
|
|
98
|
+
/**
|
|
99
|
+
* Create restoration
|
|
100
|
+
*
|
|
101
|
+
*
|
|
102
|
+
* @param {string} archiveId
|
|
103
|
+
* @param {string[]} services
|
|
104
|
+
* @param {string} newResourceId
|
|
105
|
+
* @param {string} newResourceName
|
|
106
|
+
* @throws {AppwriteException}
|
|
107
|
+
* @returns {Promise<Models.BackupRestoration>}
|
|
108
|
+
*/
|
|
109
|
+
createRestoration(archiveId: string, services: string[], newResourceId?: string, newResourceName?: string): Promise<Models.BackupRestoration>;
|
|
110
|
+
/**
|
|
111
|
+
* List restorations
|
|
112
|
+
*
|
|
113
|
+
*
|
|
114
|
+
* @param {string[]} queries
|
|
115
|
+
* @throws {AppwriteException}
|
|
116
|
+
* @returns {Promise<Models.BackupRestorationList>}
|
|
117
|
+
*/
|
|
118
|
+
listRestorations(queries?: string[]): Promise<Models.BackupRestorationList>;
|
|
119
|
+
/**
|
|
120
|
+
* Get backup restoration
|
|
121
|
+
*
|
|
122
|
+
*
|
|
123
|
+
* @param {string} restorationId
|
|
124
|
+
* @throws {AppwriteException}
|
|
125
|
+
* @returns {Promise<Models.BackupArchive>}
|
|
126
|
+
*/
|
|
127
|
+
getRestoration(restorationId: string): Promise<Models.BackupArchive>;
|
|
128
|
+
}
|
|
@@ -3,6 +3,53 @@ import type { Models } from '../models';
|
|
|
3
3
|
export declare class Console {
|
|
4
4
|
client: Client;
|
|
5
5
|
constructor(client: Client);
|
|
6
|
+
/**
|
|
7
|
+
* Get campaign details
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* @param {string} campaignId
|
|
11
|
+
* @throws {AppwriteException}
|
|
12
|
+
* @returns {Promise<Models.Campaign>}
|
|
13
|
+
*/
|
|
14
|
+
getCampaign(campaignId: string): Promise<Models.Campaign>;
|
|
15
|
+
/**
|
|
16
|
+
* Get coupon details
|
|
17
|
+
*
|
|
18
|
+
*
|
|
19
|
+
* @param {string} couponId
|
|
20
|
+
* @throws {AppwriteException}
|
|
21
|
+
* @returns {Promise<Models.Coupon>}
|
|
22
|
+
*/
|
|
23
|
+
getCopon(couponId: string): Promise<Models.Coupon>;
|
|
24
|
+
/**
|
|
25
|
+
* Get plans
|
|
26
|
+
*
|
|
27
|
+
*
|
|
28
|
+
* @throws {AppwriteException}
|
|
29
|
+
* @returns {Promise<Models.BillingPlanList>}
|
|
30
|
+
*/
|
|
31
|
+
plans(): Promise<Models.BillingPlanList>;
|
|
32
|
+
/**
|
|
33
|
+
* Get Regions
|
|
34
|
+
*
|
|
35
|
+
*
|
|
36
|
+
* @throws {AppwriteException}
|
|
37
|
+
* @returns {Promise<Models.ConsoleRegionList>}
|
|
38
|
+
*/
|
|
39
|
+
regions(): Promise<Models.ConsoleRegionList>;
|
|
40
|
+
/**
|
|
41
|
+
* Create source
|
|
42
|
+
*
|
|
43
|
+
*
|
|
44
|
+
* @param {string} ref
|
|
45
|
+
* @param {string} referrer
|
|
46
|
+
* @param {string} utmSource
|
|
47
|
+
* @param {string} utmCampaign
|
|
48
|
+
* @param {string} utmMedium
|
|
49
|
+
* @throws {AppwriteException}
|
|
50
|
+
* @returns {Promise<{}>}
|
|
51
|
+
*/
|
|
52
|
+
createSource(ref?: string, referrer?: string, utmSource?: string, utmCampaign?: string, utmMedium?: string): Promise<{}>;
|
|
6
53
|
/**
|
|
7
54
|
* Get variables
|
|
8
55
|
*
|
|
@@ -68,6 +68,15 @@ export declare class Health {
|
|
|
68
68
|
* @returns {Promise<Models.HealthStatus>}
|
|
69
69
|
*/
|
|
70
70
|
getQueue(): Promise<Models.HealthStatus>;
|
|
71
|
+
/**
|
|
72
|
+
* Get billing aggregation queue
|
|
73
|
+
*
|
|
74
|
+
*
|
|
75
|
+
* @param {number} threshold
|
|
76
|
+
* @throws {AppwriteException}
|
|
77
|
+
* @returns {Promise<Models.HealthQueue>}
|
|
78
|
+
*/
|
|
79
|
+
getQueueBillingAggregation(threshold?: number): Promise<Models.HealthQueue>;
|
|
71
80
|
/**
|
|
72
81
|
* Get builds queue
|
|
73
82
|
*
|
|
@@ -78,6 +87,15 @@ export declare class Health {
|
|
|
78
87
|
* @returns {Promise<Models.HealthQueue>}
|
|
79
88
|
*/
|
|
80
89
|
getQueueBuilds(threshold?: number): Promise<Models.HealthQueue>;
|
|
90
|
+
/**
|
|
91
|
+
* Get billing aggregation queue
|
|
92
|
+
*
|
|
93
|
+
*
|
|
94
|
+
* @param {number} threshold
|
|
95
|
+
* @throws {AppwriteException}
|
|
96
|
+
* @returns {Promise<Models.HealthQueue>}
|
|
97
|
+
*/
|
|
98
|
+
getQueuePriorityBuilds(threshold?: number): Promise<Models.HealthQueue>;
|
|
81
99
|
/**
|
|
82
100
|
* Get certificates queue
|
|
83
101
|
*
|
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
import { Client } from '../client';
|
|
2
|
+
import type { Models } from '../models';
|
|
3
|
+
import { BillingPlan } from '../enums/billing-plan';
|
|
4
|
+
export declare class Organizations {
|
|
5
|
+
client: Client;
|
|
6
|
+
constructor(client: Client);
|
|
7
|
+
/**
|
|
8
|
+
* List Orgnizations
|
|
9
|
+
*
|
|
10
|
+
* 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
|
+
*
|
|
12
|
+
* @param {string[]} queries
|
|
13
|
+
* @param {string} search
|
|
14
|
+
* @throws {AppwriteException}
|
|
15
|
+
* @returns {Promise<Models.TeamList<Preferences>>}
|
|
16
|
+
*/
|
|
17
|
+
list<Preferences extends Models.Preferences>(queries?: string[], search?: string): Promise<Models.TeamList<Preferences>>;
|
|
18
|
+
/**
|
|
19
|
+
* Create Organization
|
|
20
|
+
*
|
|
21
|
+
* Create a new team. The user who creates the team will automatically be assigned as the owner of the team. Only the users with the owner role can invite new members, add new owners and delete or update the team.
|
|
22
|
+
*
|
|
23
|
+
* @param {string} organizationId
|
|
24
|
+
* @param {string} name
|
|
25
|
+
* @param {BillingPlan} billingPlan
|
|
26
|
+
* @param {string} paymentMethodId
|
|
27
|
+
* @param {string} billingAddressId
|
|
28
|
+
* @throws {AppwriteException}
|
|
29
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
30
|
+
*/
|
|
31
|
+
create<Preferences extends Models.Preferences>(organizationId: string, name: string, billingPlan: BillingPlan, paymentMethodId?: string, billingAddressId?: string): Promise<Models.Organization<Preferences>>;
|
|
32
|
+
/**
|
|
33
|
+
* Delete team
|
|
34
|
+
*
|
|
35
|
+
* Delete a team using its ID. Only team members with the owner role can delete the team.
|
|
36
|
+
*
|
|
37
|
+
* @param {string} organizationId
|
|
38
|
+
* @throws {AppwriteException}
|
|
39
|
+
* @returns {Promise<{}>}
|
|
40
|
+
*/
|
|
41
|
+
delete(organizationId: string): Promise<{}>;
|
|
42
|
+
/**
|
|
43
|
+
* List aggregations
|
|
44
|
+
*
|
|
45
|
+
*
|
|
46
|
+
* @param {string} organizationId
|
|
47
|
+
* @param {string[]} queries
|
|
48
|
+
* @throws {AppwriteException}
|
|
49
|
+
* @returns {Promise<Models.AggregationTeamList>}
|
|
50
|
+
*/
|
|
51
|
+
listAggregations(organizationId: string, queries?: string[]): Promise<Models.AggregationTeamList>;
|
|
52
|
+
/**
|
|
53
|
+
* Get invoice
|
|
54
|
+
*
|
|
55
|
+
*
|
|
56
|
+
* @param {string} organizationId
|
|
57
|
+
* @param {string} aggregationId
|
|
58
|
+
* @throws {AppwriteException}
|
|
59
|
+
* @returns {Promise<Models.Invoice>}
|
|
60
|
+
*/
|
|
61
|
+
getAggregation(organizationId: string, aggregationId: string): Promise<Models.Invoice>;
|
|
62
|
+
/**
|
|
63
|
+
* Set team's billing address
|
|
64
|
+
*
|
|
65
|
+
*
|
|
66
|
+
* @param {string} organizationId
|
|
67
|
+
* @param {string} billingAddressId
|
|
68
|
+
* @throws {AppwriteException}
|
|
69
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
70
|
+
*/
|
|
71
|
+
setBillingAddress<Preferences extends Models.Preferences>(organizationId: string, billingAddressId: string): Promise<Models.Organization<Preferences>>;
|
|
72
|
+
/**
|
|
73
|
+
* Delete team's billing address
|
|
74
|
+
*
|
|
75
|
+
*
|
|
76
|
+
* @param {string} organizationId
|
|
77
|
+
* @throws {AppwriteException}
|
|
78
|
+
* @returns {Promise<{}>}
|
|
79
|
+
*/
|
|
80
|
+
deleteBillingAddress(organizationId: string): Promise<{}>;
|
|
81
|
+
/**
|
|
82
|
+
* Get billing address
|
|
83
|
+
*
|
|
84
|
+
*
|
|
85
|
+
* @param {string} organizationId
|
|
86
|
+
* @param {string} billingAddressId
|
|
87
|
+
* @throws {AppwriteException}
|
|
88
|
+
* @returns {Promise<Models.BillingAddress>}
|
|
89
|
+
*/
|
|
90
|
+
getBillingAddress(organizationId: string, billingAddressId: string): Promise<Models.BillingAddress>;
|
|
91
|
+
/**
|
|
92
|
+
* Set team's billing email
|
|
93
|
+
*
|
|
94
|
+
*
|
|
95
|
+
* @param {string} organizationId
|
|
96
|
+
* @param {string} billingEmail
|
|
97
|
+
* @throws {AppwriteException}
|
|
98
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
99
|
+
*/
|
|
100
|
+
setBillingEmail<Preferences extends Models.Preferences>(organizationId: string, billingEmail: string): Promise<Models.Organization<Preferences>>;
|
|
101
|
+
/**
|
|
102
|
+
* Update organization budget
|
|
103
|
+
*
|
|
104
|
+
*
|
|
105
|
+
* @param {string} organizationId
|
|
106
|
+
* @param {number} budget
|
|
107
|
+
* @param {number[]} alerts
|
|
108
|
+
* @throws {AppwriteException}
|
|
109
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
110
|
+
*/
|
|
111
|
+
updateBudget<Preferences extends Models.Preferences>(organizationId: string, budget: number, alerts?: number[]): Promise<Models.Organization<Preferences>>;
|
|
112
|
+
/**
|
|
113
|
+
* Add credits from coupon
|
|
114
|
+
*
|
|
115
|
+
*
|
|
116
|
+
* @param {string} organizationId
|
|
117
|
+
* @param {string} couponId
|
|
118
|
+
* @throws {AppwriteException}
|
|
119
|
+
* @returns {Promise<Models.Credit>}
|
|
120
|
+
*/
|
|
121
|
+
addCredit(organizationId: string, couponId: string): Promise<Models.Credit>;
|
|
122
|
+
/**
|
|
123
|
+
* Get credit details
|
|
124
|
+
*
|
|
125
|
+
*
|
|
126
|
+
* @param {string} organizationId
|
|
127
|
+
* @param {string} creditId
|
|
128
|
+
* @throws {AppwriteException}
|
|
129
|
+
* @returns {Promise<Models.Credit>}
|
|
130
|
+
*/
|
|
131
|
+
getCredit(organizationId: string, creditId: string): Promise<Models.Credit>;
|
|
132
|
+
/**
|
|
133
|
+
* List invoices
|
|
134
|
+
*
|
|
135
|
+
*
|
|
136
|
+
* @param {string} organizationId
|
|
137
|
+
* @param {string[]} queries
|
|
138
|
+
* @throws {AppwriteException}
|
|
139
|
+
* @returns {Promise<Models.InvoiceList>}
|
|
140
|
+
*/
|
|
141
|
+
listInvoices(organizationId: string, queries?: string[]): Promise<Models.InvoiceList>;
|
|
142
|
+
/**
|
|
143
|
+
* Get invoice
|
|
144
|
+
*
|
|
145
|
+
*
|
|
146
|
+
* @param {string} organizationId
|
|
147
|
+
* @param {string} invoiceId
|
|
148
|
+
* @throws {AppwriteException}
|
|
149
|
+
* @returns {Promise<Models.Invoice>}
|
|
150
|
+
*/
|
|
151
|
+
getInvoice(organizationId: string, invoiceId: string): Promise<Models.Invoice>;
|
|
152
|
+
/**
|
|
153
|
+
* View invoice in PDF
|
|
154
|
+
*
|
|
155
|
+
*
|
|
156
|
+
* @param {string} organizationId
|
|
157
|
+
* @param {string} invoiceId
|
|
158
|
+
* @throws {AppwriteException}
|
|
159
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
160
|
+
*/
|
|
161
|
+
getInvoiceDownload(organizationId: string, invoiceId: string): Promise<Models.PaymentMethod>;
|
|
162
|
+
/**
|
|
163
|
+
* Initiate payment for failed invoice to pay live from console
|
|
164
|
+
*
|
|
165
|
+
*
|
|
166
|
+
* @param {string} organizationId
|
|
167
|
+
* @param {string} invoiceId
|
|
168
|
+
* @param {string} paymentMethodId
|
|
169
|
+
* @throws {AppwriteException}
|
|
170
|
+
* @returns {Promise<Models.Invoice>}
|
|
171
|
+
*/
|
|
172
|
+
createInvoicePayment(organizationId: string, invoiceId: string, paymentMethodId: string): Promise<Models.Invoice>;
|
|
173
|
+
/**
|
|
174
|
+
* View invoice in PDF
|
|
175
|
+
*
|
|
176
|
+
*
|
|
177
|
+
* @param {string} organizationId
|
|
178
|
+
* @param {string} invoiceId
|
|
179
|
+
* @throws {AppwriteException}
|
|
180
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
181
|
+
*/
|
|
182
|
+
getInvoiceView(organizationId: string, invoiceId: string): Promise<Models.PaymentMethod>;
|
|
183
|
+
/**
|
|
184
|
+
* Set team's payment method
|
|
185
|
+
*
|
|
186
|
+
*
|
|
187
|
+
* @param {string} organizationId
|
|
188
|
+
* @param {string} paymentMethodId
|
|
189
|
+
* @throws {AppwriteException}
|
|
190
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
191
|
+
*/
|
|
192
|
+
setDefaultPaymentMethod<Preferences extends Models.Preferences>(organizationId: string, paymentMethodId: string): Promise<Models.Organization<Preferences>>;
|
|
193
|
+
/**
|
|
194
|
+
* Delete team's default payment method
|
|
195
|
+
*
|
|
196
|
+
*
|
|
197
|
+
* @param {string} organizationId
|
|
198
|
+
* @throws {AppwriteException}
|
|
199
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
200
|
+
*/
|
|
201
|
+
deleteDefaultPaymentMethod<Preferences extends Models.Preferences>(organizationId: string): Promise<Models.Organization<Preferences>>;
|
|
202
|
+
/**
|
|
203
|
+
* Set team's backup payment method
|
|
204
|
+
*
|
|
205
|
+
*
|
|
206
|
+
* @param {string} organizationId
|
|
207
|
+
* @param {string} paymentMethodId
|
|
208
|
+
* @throws {AppwriteException}
|
|
209
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
210
|
+
*/
|
|
211
|
+
setBackupPaymentMethod<Preferences extends Models.Preferences>(organizationId: string, paymentMethodId: string): Promise<Models.Organization<Preferences>>;
|
|
212
|
+
/**
|
|
213
|
+
* Delete team's backup payment method
|
|
214
|
+
*
|
|
215
|
+
*
|
|
216
|
+
* @param {string} organizationId
|
|
217
|
+
* @throws {AppwriteException}
|
|
218
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
219
|
+
*/
|
|
220
|
+
deleteBackupPaymentMethod<Preferences extends Models.Preferences>(organizationId: string): Promise<Models.Organization<Preferences>>;
|
|
221
|
+
/**
|
|
222
|
+
* Get payment method
|
|
223
|
+
*
|
|
224
|
+
*
|
|
225
|
+
* @param {string} organizationId
|
|
226
|
+
* @param {string} paymentMethodId
|
|
227
|
+
* @throws {AppwriteException}
|
|
228
|
+
* @returns {Promise<Models.PaymentMethod>}
|
|
229
|
+
*/
|
|
230
|
+
getPaymentMethod(organizationId: string, paymentMethodId: string): Promise<Models.PaymentMethod>;
|
|
231
|
+
/**
|
|
232
|
+
* Get organization billing plan details
|
|
233
|
+
*
|
|
234
|
+
*
|
|
235
|
+
* @param {string} organizationId
|
|
236
|
+
* @throws {AppwriteException}
|
|
237
|
+
* @returns {Promise<Models.BillingPlan>}
|
|
238
|
+
*/
|
|
239
|
+
getPlan(organizationId: string): Promise<Models.BillingPlan>;
|
|
240
|
+
/**
|
|
241
|
+
* Update organization billing plan
|
|
242
|
+
*
|
|
243
|
+
*
|
|
244
|
+
* @param {string} organizationId
|
|
245
|
+
* @param {BillingPlan} billingPlan
|
|
246
|
+
* @param {string} paymentMethodId
|
|
247
|
+
* @param {string} billingAddressId
|
|
248
|
+
* @throws {AppwriteException}
|
|
249
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
250
|
+
*/
|
|
251
|
+
updatePlan<Preferences extends Models.Preferences>(organizationId: string, billingPlan: BillingPlan, paymentMethodId?: string, billingAddressId?: string): Promise<Models.Organization<Preferences>>;
|
|
252
|
+
/**
|
|
253
|
+
* Get Scopes
|
|
254
|
+
*
|
|
255
|
+
*
|
|
256
|
+
* @param {string} organizationId
|
|
257
|
+
* @throws {AppwriteException}
|
|
258
|
+
* @returns {Promise<Models.Roles>}
|
|
259
|
+
*/
|
|
260
|
+
getScopes(organizationId: string): Promise<Models.Roles>;
|
|
261
|
+
/**
|
|
262
|
+
* Set team's tax Id
|
|
263
|
+
*
|
|
264
|
+
*
|
|
265
|
+
* @param {string} organizationId
|
|
266
|
+
* @param {string} taxId
|
|
267
|
+
* @throws {AppwriteException}
|
|
268
|
+
* @returns {Promise<Models.Organization<Preferences>>}
|
|
269
|
+
*/
|
|
270
|
+
setBillingTaxId<Preferences extends Models.Preferences>(organizationId: string, taxId: string): Promise<Models.Organization<Preferences>>;
|
|
271
|
+
/**
|
|
272
|
+
* Get team's usage data
|
|
273
|
+
*
|
|
274
|
+
*
|
|
275
|
+
* @param {string} organizationId
|
|
276
|
+
* @param {string} startDate
|
|
277
|
+
* @param {string} endDate
|
|
278
|
+
* @throws {AppwriteException}
|
|
279
|
+
* @returns {Promise<Models.UsageOrganization>}
|
|
280
|
+
*/
|
|
281
|
+
getUsage(organizationId: string, startDate?: string, endDate?: string): Promise<Models.UsageOrganization>;
|
|
282
|
+
}
|
package/.travis.yml
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
language: node_js
|
|
2
|
-
node_js:
|
|
3
|
-
- "14.16"
|
|
4
|
-
|
|
5
|
-
jobs:
|
|
6
|
-
include:
|
|
7
|
-
- stage: NPM RC Release
|
|
8
|
-
if: tag =~ /-(rc|RC)/
|
|
9
|
-
node_js: "14.16"
|
|
10
|
-
script:
|
|
11
|
-
- npm install
|
|
12
|
-
- npm run build
|
|
13
|
-
- echo "Deploying RC to NPM..."
|
|
14
|
-
deploy:
|
|
15
|
-
provider: npm
|
|
16
|
-
email: $NPM_EMAIL
|
|
17
|
-
api_key: $NPM_API_KEY
|
|
18
|
-
tag: next
|
|
19
|
-
- stage: NPM Release
|
|
20
|
-
if: not tag =~ /-(rc|RC)/
|
|
21
|
-
node_js: "14.16"
|
|
22
|
-
script:
|
|
23
|
-
- npm install
|
|
24
|
-
- npm run build
|
|
25
|
-
- echo "Deploying to NPM..."
|
|
26
|
-
deploy:
|
|
27
|
-
provider: npm
|
|
28
|
-
email: $NPM_EMAIL
|
|
29
|
-
api_key: $NPM_API_KEY
|
|
30
|
-
skip_cleanup: true
|
|
31
|
-
on:
|
|
32
|
-
tags: true
|