@appwrite.io/console 8.2.0 → 8.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/README.md CHANGED
@@ -33,7 +33,7 @@ import { Client, Account } from "@appwrite.io/console";
33
33
  To install with a CDN (content delivery network) add the following scripts to the bottom of your <body> tag, but before you use any Appwrite services:
34
34
 
35
35
  ```html
36
- <script src="https://cdn.jsdelivr.net/npm/@appwrite.io/console@8.2.0"></script>
36
+ <script src="https://cdn.jsdelivr.net/npm/@appwrite.io/console@8.3.0"></script>
37
37
  ```
38
38
 
39
39
 
package/dist/cjs/sdk.js CHANGED
@@ -580,7 +580,7 @@ class Client {
580
580
  'x-sdk-name': 'Console',
581
581
  'x-sdk-platform': 'console',
582
582
  'x-sdk-language': 'web',
583
- 'x-sdk-version': '8.2.0',
583
+ 'x-sdk-version': '8.3.0',
584
584
  'X-Appwrite-Response-Format': '1.9.0',
585
585
  };
586
586
  this.realtime = {
@@ -15374,6 +15374,152 @@ class Organizations {
15374
15374
  };
15375
15375
  return this.client.call('delete', uri, apiHeaders, payload);
15376
15376
  }
15377
+ listAddons(paramsOrFirst) {
15378
+ let params;
15379
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
15380
+ params = (paramsOrFirst || {});
15381
+ }
15382
+ else {
15383
+ params = {
15384
+ organizationId: paramsOrFirst
15385
+ };
15386
+ }
15387
+ const organizationId = params.organizationId;
15388
+ if (typeof organizationId === 'undefined') {
15389
+ throw new AppwriteException('Missing required parameter: "organizationId"');
15390
+ }
15391
+ const apiPath = '/organizations/{organizationId}/addons'.replace('{organizationId}', organizationId);
15392
+ const payload = {};
15393
+ const uri = new URL(this.client.config.endpoint + apiPath);
15394
+ const apiHeaders = {};
15395
+ return this.client.call('get', uri, apiHeaders, payload);
15396
+ }
15397
+ createBaaAddon(paramsOrFirst) {
15398
+ let params;
15399
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
15400
+ params = (paramsOrFirst || {});
15401
+ }
15402
+ else {
15403
+ params = {
15404
+ organizationId: paramsOrFirst
15405
+ };
15406
+ }
15407
+ const organizationId = params.organizationId;
15408
+ if (typeof organizationId === 'undefined') {
15409
+ throw new AppwriteException('Missing required parameter: "organizationId"');
15410
+ }
15411
+ const apiPath = '/organizations/{organizationId}/addons/baa'.replace('{organizationId}', organizationId);
15412
+ const payload = {};
15413
+ const uri = new URL(this.client.config.endpoint + apiPath);
15414
+ const apiHeaders = {
15415
+ 'content-type': 'application/json',
15416
+ };
15417
+ return this.client.call('post', uri, apiHeaders, payload);
15418
+ }
15419
+ getAddon(paramsOrFirst, ...rest) {
15420
+ let params;
15421
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
15422
+ params = (paramsOrFirst || {});
15423
+ }
15424
+ else {
15425
+ params = {
15426
+ organizationId: paramsOrFirst,
15427
+ addonId: rest[0]
15428
+ };
15429
+ }
15430
+ const organizationId = params.organizationId;
15431
+ const addonId = params.addonId;
15432
+ if (typeof organizationId === 'undefined') {
15433
+ throw new AppwriteException('Missing required parameter: "organizationId"');
15434
+ }
15435
+ if (typeof addonId === 'undefined') {
15436
+ throw new AppwriteException('Missing required parameter: "addonId"');
15437
+ }
15438
+ const apiPath = '/organizations/{organizationId}/addons/{addonId}'.replace('{organizationId}', organizationId).replace('{addonId}', addonId);
15439
+ const payload = {};
15440
+ const uri = new URL(this.client.config.endpoint + apiPath);
15441
+ const apiHeaders = {};
15442
+ return this.client.call('get', uri, apiHeaders, payload);
15443
+ }
15444
+ deleteAddon(paramsOrFirst, ...rest) {
15445
+ let params;
15446
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
15447
+ params = (paramsOrFirst || {});
15448
+ }
15449
+ else {
15450
+ params = {
15451
+ organizationId: paramsOrFirst,
15452
+ addonId: rest[0]
15453
+ };
15454
+ }
15455
+ const organizationId = params.organizationId;
15456
+ const addonId = params.addonId;
15457
+ if (typeof organizationId === 'undefined') {
15458
+ throw new AppwriteException('Missing required parameter: "organizationId"');
15459
+ }
15460
+ if (typeof addonId === 'undefined') {
15461
+ throw new AppwriteException('Missing required parameter: "addonId"');
15462
+ }
15463
+ const apiPath = '/organizations/{organizationId}/addons/{addonId}'.replace('{organizationId}', organizationId).replace('{addonId}', addonId);
15464
+ const payload = {};
15465
+ const uri = new URL(this.client.config.endpoint + apiPath);
15466
+ const apiHeaders = {
15467
+ 'content-type': 'application/json',
15468
+ };
15469
+ return this.client.call('delete', uri, apiHeaders, payload);
15470
+ }
15471
+ confirmAddonPayment(paramsOrFirst, ...rest) {
15472
+ let params;
15473
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
15474
+ params = (paramsOrFirst || {});
15475
+ }
15476
+ else {
15477
+ params = {
15478
+ organizationId: paramsOrFirst,
15479
+ addonId: rest[0]
15480
+ };
15481
+ }
15482
+ const organizationId = params.organizationId;
15483
+ const addonId = params.addonId;
15484
+ if (typeof organizationId === 'undefined') {
15485
+ throw new AppwriteException('Missing required parameter: "organizationId"');
15486
+ }
15487
+ if (typeof addonId === 'undefined') {
15488
+ throw new AppwriteException('Missing required parameter: "addonId"');
15489
+ }
15490
+ const apiPath = '/organizations/{organizationId}/addons/{addonId}/confirmations'.replace('{organizationId}', organizationId).replace('{addonId}', addonId);
15491
+ const payload = {};
15492
+ const uri = new URL(this.client.config.endpoint + apiPath);
15493
+ const apiHeaders = {
15494
+ 'content-type': 'application/json',
15495
+ };
15496
+ return this.client.call('post', uri, apiHeaders, payload);
15497
+ }
15498
+ getAddonPrice(paramsOrFirst, ...rest) {
15499
+ let params;
15500
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
15501
+ params = (paramsOrFirst || {});
15502
+ }
15503
+ else {
15504
+ params = {
15505
+ organizationId: paramsOrFirst,
15506
+ addon: rest[0]
15507
+ };
15508
+ }
15509
+ const organizationId = params.organizationId;
15510
+ const addon = params.addon;
15511
+ if (typeof organizationId === 'undefined') {
15512
+ throw new AppwriteException('Missing required parameter: "organizationId"');
15513
+ }
15514
+ if (typeof addon === 'undefined') {
15515
+ throw new AppwriteException('Missing required parameter: "addon"');
15516
+ }
15517
+ const apiPath = '/organizations/{organizationId}/addons/{addon}/price'.replace('{organizationId}', organizationId).replace('{addon}', addon);
15518
+ const payload = {};
15519
+ const uri = new URL(this.client.config.endpoint + apiPath);
15520
+ const apiHeaders = {};
15521
+ return this.client.call('get', uri, apiHeaders, payload);
15522
+ }
15377
15523
  listAggregations(paramsOrFirst, ...rest) {
15378
15524
  let params;
15379
15525
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
@@ -29095,6 +29241,11 @@ exports.SupabaseMigrationResource = void 0;
29095
29241
  SupabaseMigrationResource["File"] = "file";
29096
29242
  })(exports.SupabaseMigrationResource || (exports.SupabaseMigrationResource = {}));
29097
29243
 
29244
+ exports.Addon = void 0;
29245
+ (function (Addon) {
29246
+ Addon["Baa"] = "baa";
29247
+ })(exports.Addon || (exports.Addon = {}));
29248
+
29098
29249
  exports.ProjectUsageRange = void 0;
29099
29250
  (function (ProjectUsageRange) {
29100
29251
  ProjectUsageRange["OneHour"] = "1h";