@appwrite.io/console 8.3.0 → 9.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.
package/dist/iife/sdk.js CHANGED
@@ -4378,8 +4378,8 @@
4378
4378
  'x-sdk-name': 'Console',
4379
4379
  'x-sdk-platform': 'console',
4380
4380
  'x-sdk-language': 'web',
4381
- 'x-sdk-version': '8.3.0',
4382
- 'X-Appwrite-Response-Format': '1.9.0',
4381
+ 'x-sdk-version': '9.1.0',
4382
+ 'X-Appwrite-Response-Format': '1.9.1',
4383
4383
  };
4384
4384
  this.realtime = {
4385
4385
  socket: undefined,
@@ -8653,7 +8653,8 @@
8653
8653
  name: rest[1],
8654
8654
  permissions: rest[2],
8655
8655
  documentSecurity: rest[3],
8656
- enabled: rest[4]
8656
+ enabled: rest[4],
8657
+ purge: rest[5]
8657
8658
  };
8658
8659
  }
8659
8660
  const databaseId = params.databaseId;
@@ -8662,6 +8663,7 @@
8662
8663
  const permissions = params.permissions;
8663
8664
  const documentSecurity = params.documentSecurity;
8664
8665
  const enabled = params.enabled;
8666
+ const purge = params.purge;
8665
8667
  if (typeof databaseId === 'undefined') {
8666
8668
  throw new AppwriteException('Missing required parameter: "databaseId"');
8667
8669
  }
@@ -8682,6 +8684,9 @@
8682
8684
  if (typeof enabled !== 'undefined') {
8683
8685
  payload['enabled'] = enabled;
8684
8686
  }
8687
+ if (typeof purge !== 'undefined') {
8688
+ payload['purge'] = purge;
8689
+ }
8685
8690
  const uri = new URL(this.client.config.endpoint + apiPath);
8686
8691
  const apiHeaders = {
8687
8692
  'content-type': 'application/json',
@@ -20435,43 +20440,82 @@
20435
20440
  constructor(client) {
20436
20441
  this.client = client;
20437
20442
  }
20438
- getUsage(paramsOrFirst, ...rest) {
20443
+ updateCanonicalEmails(paramsOrFirst) {
20439
20444
  let params;
20440
20445
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20441
20446
  params = (paramsOrFirst || {});
20442
20447
  }
20443
20448
  else {
20444
20449
  params = {
20445
- startDate: paramsOrFirst,
20446
- endDate: rest[0],
20447
- period: rest[1]
20450
+ enabled: paramsOrFirst
20448
20451
  };
20449
20452
  }
20450
- const startDate = params.startDate;
20451
- const endDate = params.endDate;
20452
- const period = params.period;
20453
- if (typeof startDate === 'undefined') {
20454
- throw new AppwriteException('Missing required parameter: "startDate"');
20453
+ const enabled = params.enabled;
20454
+ if (typeof enabled === 'undefined') {
20455
+ throw new AppwriteException('Missing required parameter: "enabled"');
20455
20456
  }
20456
- if (typeof endDate === 'undefined') {
20457
- throw new AppwriteException('Missing required parameter: "endDate"');
20457
+ const apiPath = '/project/auth/canonical-emails';
20458
+ const payload = {};
20459
+ if (typeof enabled !== 'undefined') {
20460
+ payload['enabled'] = enabled;
20458
20461
  }
20459
- const apiPath = '/project/usage';
20462
+ const uri = new URL(this.client.config.endpoint + apiPath);
20463
+ const apiHeaders = {
20464
+ 'content-type': 'application/json',
20465
+ };
20466
+ return this.client.call('patch', uri, apiHeaders, payload);
20467
+ }
20468
+ updateDisposableEmails(paramsOrFirst) {
20469
+ let params;
20470
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20471
+ params = (paramsOrFirst || {});
20472
+ }
20473
+ else {
20474
+ params = {
20475
+ enabled: paramsOrFirst
20476
+ };
20477
+ }
20478
+ const enabled = params.enabled;
20479
+ if (typeof enabled === 'undefined') {
20480
+ throw new AppwriteException('Missing required parameter: "enabled"');
20481
+ }
20482
+ const apiPath = '/project/auth/disposable-emails';
20460
20483
  const payload = {};
20461
- if (typeof startDate !== 'undefined') {
20462
- payload['startDate'] = startDate;
20484
+ if (typeof enabled !== 'undefined') {
20485
+ payload['enabled'] = enabled;
20463
20486
  }
20464
- if (typeof endDate !== 'undefined') {
20465
- payload['endDate'] = endDate;
20487
+ const uri = new URL(this.client.config.endpoint + apiPath);
20488
+ const apiHeaders = {
20489
+ 'content-type': 'application/json',
20490
+ };
20491
+ return this.client.call('patch', uri, apiHeaders, payload);
20492
+ }
20493
+ updateFreeEmails(paramsOrFirst) {
20494
+ let params;
20495
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20496
+ params = (paramsOrFirst || {});
20466
20497
  }
20467
- if (typeof period !== 'undefined') {
20468
- payload['period'] = period;
20498
+ else {
20499
+ params = {
20500
+ enabled: paramsOrFirst
20501
+ };
20502
+ }
20503
+ const enabled = params.enabled;
20504
+ if (typeof enabled === 'undefined') {
20505
+ throw new AppwriteException('Missing required parameter: "enabled"');
20506
+ }
20507
+ const apiPath = '/project/auth/free-emails';
20508
+ const payload = {};
20509
+ if (typeof enabled !== 'undefined') {
20510
+ payload['enabled'] = enabled;
20469
20511
  }
20470
20512
  const uri = new URL(this.client.config.endpoint + apiPath);
20471
- const apiHeaders = {};
20472
- return this.client.call('get', uri, apiHeaders, payload);
20513
+ const apiHeaders = {
20514
+ 'content-type': 'application/json',
20515
+ };
20516
+ return this.client.call('patch', uri, apiHeaders, payload);
20473
20517
  }
20474
- listVariables(paramsOrFirst, ...rest) {
20518
+ listKeys(paramsOrFirst, ...rest) {
20475
20519
  let params;
20476
20520
  if (!paramsOrFirst || (paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20477
20521
  params = (paramsOrFirst || {});
@@ -20484,7 +20528,7 @@
20484
20528
  }
20485
20529
  const queries = params.queries;
20486
20530
  const total = params.total;
20487
- const apiPath = '/project/variables';
20531
+ const apiPath = '/project/keys';
20488
20532
  const payload = {};
20489
20533
  if (typeof queries !== 'undefined') {
20490
20534
  payload['queries'] = queries;
@@ -20496,45 +20540,45 @@
20496
20540
  const apiHeaders = {};
20497
20541
  return this.client.call('get', uri, apiHeaders, payload);
20498
20542
  }
20499
- createVariable(paramsOrFirst, ...rest) {
20543
+ createKey(paramsOrFirst, ...rest) {
20500
20544
  let params;
20501
20545
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20502
20546
  params = (paramsOrFirst || {});
20503
20547
  }
20504
20548
  else {
20505
20549
  params = {
20506
- variableId: paramsOrFirst,
20507
- key: rest[0],
20508
- value: rest[1],
20509
- secret: rest[2]
20550
+ keyId: paramsOrFirst,
20551
+ name: rest[0],
20552
+ scopes: rest[1],
20553
+ expire: rest[2]
20510
20554
  };
20511
20555
  }
20512
- const variableId = params.variableId;
20513
- const key = params.key;
20514
- const value = params.value;
20515
- const secret = params.secret;
20516
- if (typeof variableId === 'undefined') {
20517
- throw new AppwriteException('Missing required parameter: "variableId"');
20556
+ const keyId = params.keyId;
20557
+ const name = params.name;
20558
+ const scopes = params.scopes;
20559
+ const expire = params.expire;
20560
+ if (typeof keyId === 'undefined') {
20561
+ throw new AppwriteException('Missing required parameter: "keyId"');
20518
20562
  }
20519
- if (typeof key === 'undefined') {
20520
- throw new AppwriteException('Missing required parameter: "key"');
20563
+ if (typeof name === 'undefined') {
20564
+ throw new AppwriteException('Missing required parameter: "name"');
20521
20565
  }
20522
- if (typeof value === 'undefined') {
20523
- throw new AppwriteException('Missing required parameter: "value"');
20566
+ if (typeof scopes === 'undefined') {
20567
+ throw new AppwriteException('Missing required parameter: "scopes"');
20524
20568
  }
20525
- const apiPath = '/project/variables';
20569
+ const apiPath = '/project/keys';
20526
20570
  const payload = {};
20527
- if (typeof variableId !== 'undefined') {
20528
- payload['variableId'] = variableId;
20571
+ if (typeof keyId !== 'undefined') {
20572
+ payload['keyId'] = keyId;
20529
20573
  }
20530
- if (typeof key !== 'undefined') {
20531
- payload['key'] = key;
20574
+ if (typeof name !== 'undefined') {
20575
+ payload['name'] = name;
20532
20576
  }
20533
- if (typeof value !== 'undefined') {
20534
- payload['value'] = value;
20577
+ if (typeof scopes !== 'undefined') {
20578
+ payload['scopes'] = scopes;
20535
20579
  }
20536
- if (typeof secret !== 'undefined') {
20537
- payload['secret'] = secret;
20580
+ if (typeof expire !== 'undefined') {
20581
+ payload['expire'] = expire;
20538
20582
  }
20539
20583
  const uri = new URL(this.client.config.endpoint + apiPath);
20540
20584
  const apiHeaders = {
@@ -20542,56 +20586,62 @@
20542
20586
  };
20543
20587
  return this.client.call('post', uri, apiHeaders, payload);
20544
20588
  }
20545
- getVariable(paramsOrFirst) {
20589
+ getKey(paramsOrFirst) {
20546
20590
  let params;
20547
20591
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20548
20592
  params = (paramsOrFirst || {});
20549
20593
  }
20550
20594
  else {
20551
20595
  params = {
20552
- variableId: paramsOrFirst
20596
+ keyId: paramsOrFirst
20553
20597
  };
20554
20598
  }
20555
- const variableId = params.variableId;
20556
- if (typeof variableId === 'undefined') {
20557
- throw new AppwriteException('Missing required parameter: "variableId"');
20599
+ const keyId = params.keyId;
20600
+ if (typeof keyId === 'undefined') {
20601
+ throw new AppwriteException('Missing required parameter: "keyId"');
20558
20602
  }
20559
- const apiPath = '/project/variables/{variableId}'.replace('{variableId}', variableId);
20603
+ const apiPath = '/project/keys/{keyId}'.replace('{keyId}', keyId);
20560
20604
  const payload = {};
20561
20605
  const uri = new URL(this.client.config.endpoint + apiPath);
20562
20606
  const apiHeaders = {};
20563
20607
  return this.client.call('get', uri, apiHeaders, payload);
20564
20608
  }
20565
- updateVariable(paramsOrFirst, ...rest) {
20609
+ updateKey(paramsOrFirst, ...rest) {
20566
20610
  let params;
20567
20611
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20568
20612
  params = (paramsOrFirst || {});
20569
20613
  }
20570
20614
  else {
20571
20615
  params = {
20572
- variableId: paramsOrFirst,
20573
- key: rest[0],
20574
- value: rest[1],
20575
- secret: rest[2]
20616
+ keyId: paramsOrFirst,
20617
+ name: rest[0],
20618
+ scopes: rest[1],
20619
+ expire: rest[2]
20576
20620
  };
20577
20621
  }
20578
- const variableId = params.variableId;
20579
- const key = params.key;
20580
- const value = params.value;
20581
- const secret = params.secret;
20582
- if (typeof variableId === 'undefined') {
20583
- throw new AppwriteException('Missing required parameter: "variableId"');
20622
+ const keyId = params.keyId;
20623
+ const name = params.name;
20624
+ const scopes = params.scopes;
20625
+ const expire = params.expire;
20626
+ if (typeof keyId === 'undefined') {
20627
+ throw new AppwriteException('Missing required parameter: "keyId"');
20584
20628
  }
20585
- const apiPath = '/project/variables/{variableId}'.replace('{variableId}', variableId);
20629
+ if (typeof name === 'undefined') {
20630
+ throw new AppwriteException('Missing required parameter: "name"');
20631
+ }
20632
+ if (typeof scopes === 'undefined') {
20633
+ throw new AppwriteException('Missing required parameter: "scopes"');
20634
+ }
20635
+ const apiPath = '/project/keys/{keyId}'.replace('{keyId}', keyId);
20586
20636
  const payload = {};
20587
- if (typeof key !== 'undefined') {
20588
- payload['key'] = key;
20637
+ if (typeof name !== 'undefined') {
20638
+ payload['name'] = name;
20589
20639
  }
20590
- if (typeof value !== 'undefined') {
20591
- payload['value'] = value;
20640
+ if (typeof scopes !== 'undefined') {
20641
+ payload['scopes'] = scopes;
20592
20642
  }
20593
- if (typeof secret !== 'undefined') {
20594
- payload['secret'] = secret;
20643
+ if (typeof expire !== 'undefined') {
20644
+ payload['expire'] = expire;
20595
20645
  }
20596
20646
  const uri = new URL(this.client.config.endpoint + apiPath);
20597
20647
  const apiHeaders = {
@@ -20599,21 +20649,21 @@
20599
20649
  };
20600
20650
  return this.client.call('put', uri, apiHeaders, payload);
20601
20651
  }
20602
- deleteVariable(paramsOrFirst) {
20652
+ deleteKey(paramsOrFirst) {
20603
20653
  let params;
20604
20654
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20605
20655
  params = (paramsOrFirst || {});
20606
20656
  }
20607
20657
  else {
20608
20658
  params = {
20609
- variableId: paramsOrFirst
20659
+ keyId: paramsOrFirst
20610
20660
  };
20611
20661
  }
20612
- const variableId = params.variableId;
20613
- if (typeof variableId === 'undefined') {
20614
- throw new AppwriteException('Missing required parameter: "variableId"');
20662
+ const keyId = params.keyId;
20663
+ if (typeof keyId === 'undefined') {
20664
+ throw new AppwriteException('Missing required parameter: "keyId"');
20615
20665
  }
20616
- const apiPath = '/project/variables/{variableId}'.replace('{variableId}', variableId);
20666
+ const apiPath = '/project/keys/{keyId}'.replace('{keyId}', keyId);
20617
20667
  const payload = {};
20618
20668
  const uri = new URL(this.client.config.endpoint + apiPath);
20619
20669
  const apiHeaders = {
@@ -20621,13 +20671,32 @@
20621
20671
  };
20622
20672
  return this.client.call('delete', uri, apiHeaders, payload);
20623
20673
  }
20624
- }
20625
-
20626
- class Projects {
20627
- constructor(client) {
20628
- this.client = client;
20674
+ updateLabels(paramsOrFirst) {
20675
+ let params;
20676
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20677
+ params = (paramsOrFirst || {});
20678
+ }
20679
+ else {
20680
+ params = {
20681
+ labels: paramsOrFirst
20682
+ };
20683
+ }
20684
+ const labels = params.labels;
20685
+ if (typeof labels === 'undefined') {
20686
+ throw new AppwriteException('Missing required parameter: "labels"');
20687
+ }
20688
+ const apiPath = '/project/labels';
20689
+ const payload = {};
20690
+ if (typeof labels !== 'undefined') {
20691
+ payload['labels'] = labels;
20692
+ }
20693
+ const uri = new URL(this.client.config.endpoint + apiPath);
20694
+ const apiHeaders = {
20695
+ 'content-type': 'application/json',
20696
+ };
20697
+ return this.client.call('put', uri, apiHeaders, payload);
20629
20698
  }
20630
- list(paramsOrFirst, ...rest) {
20699
+ listPlatforms(paramsOrFirst, ...rest) {
20631
20700
  let params;
20632
20701
  if (!paramsOrFirst || (paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20633
20702
  params = (paramsOrFirst || {});
@@ -20635,21 +20704,16 @@
20635
20704
  else {
20636
20705
  params = {
20637
20706
  queries: paramsOrFirst,
20638
- search: rest[0],
20639
- total: rest[1]
20707
+ total: rest[0]
20640
20708
  };
20641
20709
  }
20642
20710
  const queries = params.queries;
20643
- const search = params.search;
20644
20711
  const total = params.total;
20645
- const apiPath = '/projects';
20712
+ const apiPath = '/project/platforms';
20646
20713
  const payload = {};
20647
20714
  if (typeof queries !== 'undefined') {
20648
20715
  payload['queries'] = queries;
20649
20716
  }
20650
- if (typeof search !== 'undefined') {
20651
- payload['search'] = search;
20652
- }
20653
20717
  if (typeof total !== 'undefined') {
20654
20718
  payload['total'] = total;
20655
20719
  }
@@ -20657,90 +20721,40 @@
20657
20721
  const apiHeaders = {};
20658
20722
  return this.client.call('get', uri, apiHeaders, payload);
20659
20723
  }
20660
- create(paramsOrFirst, ...rest) {
20724
+ createAndroidPlatform(paramsOrFirst, ...rest) {
20661
20725
  let params;
20662
20726
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20663
20727
  params = (paramsOrFirst || {});
20664
20728
  }
20665
20729
  else {
20666
20730
  params = {
20667
- projectId: paramsOrFirst,
20731
+ platformId: paramsOrFirst,
20668
20732
  name: rest[0],
20669
- teamId: rest[1],
20670
- region: rest[2],
20671
- description: rest[3],
20672
- logo: rest[4],
20673
- url: rest[5],
20674
- legalName: rest[6],
20675
- legalCountry: rest[7],
20676
- legalState: rest[8],
20677
- legalCity: rest[9],
20678
- legalAddress: rest[10],
20679
- legalTaxId: rest[11]
20733
+ applicationId: rest[1]
20680
20734
  };
20681
20735
  }
20682
- const projectId = params.projectId;
20736
+ const platformId = params.platformId;
20683
20737
  const name = params.name;
20684
- const teamId = params.teamId;
20685
- const region = params.region;
20686
- const description = params.description;
20687
- const logo = params.logo;
20688
- const url = params.url;
20689
- const legalName = params.legalName;
20690
- const legalCountry = params.legalCountry;
20691
- const legalState = params.legalState;
20692
- const legalCity = params.legalCity;
20693
- const legalAddress = params.legalAddress;
20694
- const legalTaxId = params.legalTaxId;
20695
- if (typeof projectId === 'undefined') {
20696
- throw new AppwriteException('Missing required parameter: "projectId"');
20738
+ const applicationId = params.applicationId;
20739
+ if (typeof platformId === 'undefined') {
20740
+ throw new AppwriteException('Missing required parameter: "platformId"');
20697
20741
  }
20698
20742
  if (typeof name === 'undefined') {
20699
20743
  throw new AppwriteException('Missing required parameter: "name"');
20700
20744
  }
20701
- if (typeof teamId === 'undefined') {
20702
- throw new AppwriteException('Missing required parameter: "teamId"');
20745
+ if (typeof applicationId === 'undefined') {
20746
+ throw new AppwriteException('Missing required parameter: "applicationId"');
20703
20747
  }
20704
- const apiPath = '/projects';
20748
+ const apiPath = '/project/platforms/android';
20705
20749
  const payload = {};
20706
- if (typeof projectId !== 'undefined') {
20707
- payload['projectId'] = projectId;
20750
+ if (typeof platformId !== 'undefined') {
20751
+ payload['platformId'] = platformId;
20708
20752
  }
20709
20753
  if (typeof name !== 'undefined') {
20710
20754
  payload['name'] = name;
20711
20755
  }
20712
- if (typeof teamId !== 'undefined') {
20713
- payload['teamId'] = teamId;
20714
- }
20715
- if (typeof region !== 'undefined') {
20716
- payload['region'] = region;
20717
- }
20718
- if (typeof description !== 'undefined') {
20719
- payload['description'] = description;
20720
- }
20721
- if (typeof logo !== 'undefined') {
20722
- payload['logo'] = logo;
20723
- }
20724
- if (typeof url !== 'undefined') {
20725
- payload['url'] = url;
20726
- }
20727
- if (typeof legalName !== 'undefined') {
20728
- payload['legalName'] = legalName;
20729
- }
20730
- if (typeof legalCountry !== 'undefined') {
20731
- payload['legalCountry'] = legalCountry;
20732
- }
20733
- if (typeof legalState !== 'undefined') {
20734
- payload['legalState'] = legalState;
20735
- }
20736
- if (typeof legalCity !== 'undefined') {
20737
- payload['legalCity'] = legalCity;
20738
- }
20739
- if (typeof legalAddress !== 'undefined') {
20740
- payload['legalAddress'] = legalAddress;
20741
- }
20742
- if (typeof legalTaxId !== 'undefined') {
20743
- payload['legalTaxId'] = legalTaxId;
20756
+ if (typeof applicationId !== 'undefined') {
20757
+ payload['applicationId'] = applicationId;
20744
20758
  }
20745
20759
  const uri = new URL(this.client.config.endpoint + apiPath);
20746
20760
  const apiHeaders = {
@@ -20748,418 +20762,425 @@
20748
20762
  };
20749
20763
  return this.client.call('post', uri, apiHeaders, payload);
20750
20764
  }
20751
- get(paramsOrFirst) {
20765
+ updateAndroidPlatform(paramsOrFirst, ...rest) {
20752
20766
  let params;
20753
20767
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20754
20768
  params = (paramsOrFirst || {});
20755
20769
  }
20756
20770
  else {
20757
20771
  params = {
20758
- projectId: paramsOrFirst
20772
+ platformId: paramsOrFirst,
20773
+ name: rest[0],
20774
+ applicationId: rest[1]
20759
20775
  };
20760
20776
  }
20761
- const projectId = params.projectId;
20762
- if (typeof projectId === 'undefined') {
20763
- throw new AppwriteException('Missing required parameter: "projectId"');
20777
+ const platformId = params.platformId;
20778
+ const name = params.name;
20779
+ const applicationId = params.applicationId;
20780
+ if (typeof platformId === 'undefined') {
20781
+ throw new AppwriteException('Missing required parameter: "platformId"');
20764
20782
  }
20765
- const apiPath = '/projects/{projectId}'.replace('{projectId}', projectId);
20783
+ if (typeof name === 'undefined') {
20784
+ throw new AppwriteException('Missing required parameter: "name"');
20785
+ }
20786
+ if (typeof applicationId === 'undefined') {
20787
+ throw new AppwriteException('Missing required parameter: "applicationId"');
20788
+ }
20789
+ const apiPath = '/project/platforms/android/{platformId}'.replace('{platformId}', platformId);
20766
20790
  const payload = {};
20791
+ if (typeof name !== 'undefined') {
20792
+ payload['name'] = name;
20793
+ }
20794
+ if (typeof applicationId !== 'undefined') {
20795
+ payload['applicationId'] = applicationId;
20796
+ }
20767
20797
  const uri = new URL(this.client.config.endpoint + apiPath);
20768
- const apiHeaders = {};
20769
- return this.client.call('get', uri, apiHeaders, payload);
20798
+ const apiHeaders = {
20799
+ 'content-type': 'application/json',
20800
+ };
20801
+ return this.client.call('put', uri, apiHeaders, payload);
20770
20802
  }
20771
- update(paramsOrFirst, ...rest) {
20803
+ createApplePlatform(paramsOrFirst, ...rest) {
20772
20804
  let params;
20773
20805
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20774
20806
  params = (paramsOrFirst || {});
20775
20807
  }
20776
20808
  else {
20777
20809
  params = {
20778
- projectId: paramsOrFirst,
20810
+ platformId: paramsOrFirst,
20779
20811
  name: rest[0],
20780
- description: rest[1],
20781
- logo: rest[2],
20782
- url: rest[3],
20783
- legalName: rest[4],
20784
- legalCountry: rest[5],
20785
- legalState: rest[6],
20786
- legalCity: rest[7],
20787
- legalAddress: rest[8],
20788
- legalTaxId: rest[9]
20812
+ bundleIdentifier: rest[1]
20789
20813
  };
20790
20814
  }
20791
- const projectId = params.projectId;
20815
+ const platformId = params.platformId;
20792
20816
  const name = params.name;
20793
- const description = params.description;
20794
- const logo = params.logo;
20795
- const url = params.url;
20796
- const legalName = params.legalName;
20797
- const legalCountry = params.legalCountry;
20798
- const legalState = params.legalState;
20799
- const legalCity = params.legalCity;
20800
- const legalAddress = params.legalAddress;
20801
- const legalTaxId = params.legalTaxId;
20802
- if (typeof projectId === 'undefined') {
20803
- throw new AppwriteException('Missing required parameter: "projectId"');
20817
+ const bundleIdentifier = params.bundleIdentifier;
20818
+ if (typeof platformId === 'undefined') {
20819
+ throw new AppwriteException('Missing required parameter: "platformId"');
20804
20820
  }
20805
20821
  if (typeof name === 'undefined') {
20806
20822
  throw new AppwriteException('Missing required parameter: "name"');
20807
20823
  }
20808
- const apiPath = '/projects/{projectId}'.replace('{projectId}', projectId);
20824
+ if (typeof bundleIdentifier === 'undefined') {
20825
+ throw new AppwriteException('Missing required parameter: "bundleIdentifier"');
20826
+ }
20827
+ const apiPath = '/project/platforms/apple';
20809
20828
  const payload = {};
20829
+ if (typeof platformId !== 'undefined') {
20830
+ payload['platformId'] = platformId;
20831
+ }
20810
20832
  if (typeof name !== 'undefined') {
20811
20833
  payload['name'] = name;
20812
20834
  }
20813
- if (typeof description !== 'undefined') {
20814
- payload['description'] = description;
20815
- }
20816
- if (typeof logo !== 'undefined') {
20817
- payload['logo'] = logo;
20818
- }
20819
- if (typeof url !== 'undefined') {
20820
- payload['url'] = url;
20821
- }
20822
- if (typeof legalName !== 'undefined') {
20823
- payload['legalName'] = legalName;
20824
- }
20825
- if (typeof legalCountry !== 'undefined') {
20826
- payload['legalCountry'] = legalCountry;
20827
- }
20828
- if (typeof legalState !== 'undefined') {
20829
- payload['legalState'] = legalState;
20830
- }
20831
- if (typeof legalCity !== 'undefined') {
20832
- payload['legalCity'] = legalCity;
20833
- }
20834
- if (typeof legalAddress !== 'undefined') {
20835
- payload['legalAddress'] = legalAddress;
20836
- }
20837
- if (typeof legalTaxId !== 'undefined') {
20838
- payload['legalTaxId'] = legalTaxId;
20835
+ if (typeof bundleIdentifier !== 'undefined') {
20836
+ payload['bundleIdentifier'] = bundleIdentifier;
20839
20837
  }
20840
20838
  const uri = new URL(this.client.config.endpoint + apiPath);
20841
20839
  const apiHeaders = {
20842
20840
  'content-type': 'application/json',
20843
20841
  };
20844
- return this.client.call('patch', uri, apiHeaders, payload);
20842
+ return this.client.call('post', uri, apiHeaders, payload);
20845
20843
  }
20846
- delete(paramsOrFirst) {
20844
+ updateApplePlatform(paramsOrFirst, ...rest) {
20847
20845
  let params;
20848
20846
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20849
20847
  params = (paramsOrFirst || {});
20850
20848
  }
20851
20849
  else {
20852
20850
  params = {
20853
- projectId: paramsOrFirst
20851
+ platformId: paramsOrFirst,
20852
+ name: rest[0],
20853
+ bundleIdentifier: rest[1]
20854
20854
  };
20855
20855
  }
20856
- const projectId = params.projectId;
20857
- if (typeof projectId === 'undefined') {
20858
- throw new AppwriteException('Missing required parameter: "projectId"');
20856
+ const platformId = params.platformId;
20857
+ const name = params.name;
20858
+ const bundleIdentifier = params.bundleIdentifier;
20859
+ if (typeof platformId === 'undefined') {
20860
+ throw new AppwriteException('Missing required parameter: "platformId"');
20859
20861
  }
20860
- const apiPath = '/projects/{projectId}'.replace('{projectId}', projectId);
20862
+ if (typeof name === 'undefined') {
20863
+ throw new AppwriteException('Missing required parameter: "name"');
20864
+ }
20865
+ if (typeof bundleIdentifier === 'undefined') {
20866
+ throw new AppwriteException('Missing required parameter: "bundleIdentifier"');
20867
+ }
20868
+ const apiPath = '/project/platforms/apple/{platformId}'.replace('{platformId}', platformId);
20861
20869
  const payload = {};
20870
+ if (typeof name !== 'undefined') {
20871
+ payload['name'] = name;
20872
+ }
20873
+ if (typeof bundleIdentifier !== 'undefined') {
20874
+ payload['bundleIdentifier'] = bundleIdentifier;
20875
+ }
20862
20876
  const uri = new URL(this.client.config.endpoint + apiPath);
20863
20877
  const apiHeaders = {
20864
20878
  'content-type': 'application/json',
20865
20879
  };
20866
- return this.client.call('delete', uri, apiHeaders, payload);
20880
+ return this.client.call('put', uri, apiHeaders, payload);
20867
20881
  }
20868
- updateApiStatus(paramsOrFirst, ...rest) {
20882
+ createLinuxPlatform(paramsOrFirst, ...rest) {
20869
20883
  let params;
20870
20884
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20871
20885
  params = (paramsOrFirst || {});
20872
20886
  }
20873
20887
  else {
20874
20888
  params = {
20875
- projectId: paramsOrFirst,
20876
- api: rest[0],
20877
- status: rest[1]
20889
+ platformId: paramsOrFirst,
20890
+ name: rest[0],
20891
+ packageName: rest[1]
20878
20892
  };
20879
20893
  }
20880
- const projectId = params.projectId;
20881
- const api = params.api;
20882
- const status = params.status;
20883
- if (typeof projectId === 'undefined') {
20884
- throw new AppwriteException('Missing required parameter: "projectId"');
20894
+ const platformId = params.platformId;
20895
+ const name = params.name;
20896
+ const packageName = params.packageName;
20897
+ if (typeof platformId === 'undefined') {
20898
+ throw new AppwriteException('Missing required parameter: "platformId"');
20885
20899
  }
20886
- if (typeof api === 'undefined') {
20887
- throw new AppwriteException('Missing required parameter: "api"');
20900
+ if (typeof name === 'undefined') {
20901
+ throw new AppwriteException('Missing required parameter: "name"');
20888
20902
  }
20889
- if (typeof status === 'undefined') {
20890
- throw new AppwriteException('Missing required parameter: "status"');
20903
+ if (typeof packageName === 'undefined') {
20904
+ throw new AppwriteException('Missing required parameter: "packageName"');
20891
20905
  }
20892
- const apiPath = '/projects/{projectId}/api'.replace('{projectId}', projectId);
20906
+ const apiPath = '/project/platforms/linux';
20893
20907
  const payload = {};
20894
- if (typeof api !== 'undefined') {
20895
- payload['api'] = api;
20908
+ if (typeof platformId !== 'undefined') {
20909
+ payload['platformId'] = platformId;
20896
20910
  }
20897
- if (typeof status !== 'undefined') {
20898
- payload['status'] = status;
20911
+ if (typeof name !== 'undefined') {
20912
+ payload['name'] = name;
20913
+ }
20914
+ if (typeof packageName !== 'undefined') {
20915
+ payload['packageName'] = packageName;
20899
20916
  }
20900
20917
  const uri = new URL(this.client.config.endpoint + apiPath);
20901
20918
  const apiHeaders = {
20902
20919
  'content-type': 'application/json',
20903
20920
  };
20904
- return this.client.call('patch', uri, apiHeaders, payload);
20921
+ return this.client.call('post', uri, apiHeaders, payload);
20905
20922
  }
20906
- updateAPIStatus(paramsOrFirst, ...rest) {
20923
+ updateLinuxPlatform(paramsOrFirst, ...rest) {
20907
20924
  let params;
20908
20925
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20909
20926
  params = (paramsOrFirst || {});
20910
20927
  }
20911
20928
  else {
20912
20929
  params = {
20913
- projectId: paramsOrFirst,
20914
- api: rest[0],
20915
- status: rest[1]
20930
+ platformId: paramsOrFirst,
20931
+ name: rest[0],
20932
+ packageName: rest[1]
20916
20933
  };
20917
20934
  }
20918
- const projectId = params.projectId;
20919
- const api = params.api;
20920
- const status = params.status;
20921
- if (typeof projectId === 'undefined') {
20922
- throw new AppwriteException('Missing required parameter: "projectId"');
20935
+ const platformId = params.platformId;
20936
+ const name = params.name;
20937
+ const packageName = params.packageName;
20938
+ if (typeof platformId === 'undefined') {
20939
+ throw new AppwriteException('Missing required parameter: "platformId"');
20923
20940
  }
20924
- if (typeof api === 'undefined') {
20925
- throw new AppwriteException('Missing required parameter: "api"');
20941
+ if (typeof name === 'undefined') {
20942
+ throw new AppwriteException('Missing required parameter: "name"');
20926
20943
  }
20927
- if (typeof status === 'undefined') {
20928
- throw new AppwriteException('Missing required parameter: "status"');
20944
+ if (typeof packageName === 'undefined') {
20945
+ throw new AppwriteException('Missing required parameter: "packageName"');
20929
20946
  }
20930
- const apiPath = '/projects/{projectId}/api'.replace('{projectId}', projectId);
20947
+ const apiPath = '/project/platforms/linux/{platformId}'.replace('{platformId}', platformId);
20931
20948
  const payload = {};
20932
- if (typeof api !== 'undefined') {
20933
- payload['api'] = api;
20949
+ if (typeof name !== 'undefined') {
20950
+ payload['name'] = name;
20934
20951
  }
20935
- if (typeof status !== 'undefined') {
20936
- payload['status'] = status;
20952
+ if (typeof packageName !== 'undefined') {
20953
+ payload['packageName'] = packageName;
20937
20954
  }
20938
20955
  const uri = new URL(this.client.config.endpoint + apiPath);
20939
20956
  const apiHeaders = {
20940
20957
  'content-type': 'application/json',
20941
20958
  };
20942
- return this.client.call('patch', uri, apiHeaders, payload);
20959
+ return this.client.call('put', uri, apiHeaders, payload);
20943
20960
  }
20944
- updateApiStatusAll(paramsOrFirst, ...rest) {
20961
+ createWebPlatform(paramsOrFirst, ...rest) {
20945
20962
  let params;
20946
20963
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20947
20964
  params = (paramsOrFirst || {});
20948
20965
  }
20949
20966
  else {
20950
20967
  params = {
20951
- projectId: paramsOrFirst,
20952
- status: rest[0]
20968
+ platformId: paramsOrFirst,
20969
+ name: rest[0],
20970
+ hostname: rest[1]
20953
20971
  };
20954
20972
  }
20955
- const projectId = params.projectId;
20956
- const status = params.status;
20957
- if (typeof projectId === 'undefined') {
20958
- throw new AppwriteException('Missing required parameter: "projectId"');
20973
+ const platformId = params.platformId;
20974
+ const name = params.name;
20975
+ const hostname = params.hostname;
20976
+ if (typeof platformId === 'undefined') {
20977
+ throw new AppwriteException('Missing required parameter: "platformId"');
20959
20978
  }
20960
- if (typeof status === 'undefined') {
20961
- throw new AppwriteException('Missing required parameter: "status"');
20979
+ if (typeof name === 'undefined') {
20980
+ throw new AppwriteException('Missing required parameter: "name"');
20981
+ }
20982
+ if (typeof hostname === 'undefined') {
20983
+ throw new AppwriteException('Missing required parameter: "hostname"');
20962
20984
  }
20963
- const apiPath = '/projects/{projectId}/api/all'.replace('{projectId}', projectId);
20985
+ const apiPath = '/project/platforms/web';
20964
20986
  const payload = {};
20965
- if (typeof status !== 'undefined') {
20966
- payload['status'] = status;
20987
+ if (typeof platformId !== 'undefined') {
20988
+ payload['platformId'] = platformId;
20989
+ }
20990
+ if (typeof name !== 'undefined') {
20991
+ payload['name'] = name;
20992
+ }
20993
+ if (typeof hostname !== 'undefined') {
20994
+ payload['hostname'] = hostname;
20967
20995
  }
20968
20996
  const uri = new URL(this.client.config.endpoint + apiPath);
20969
20997
  const apiHeaders = {
20970
20998
  'content-type': 'application/json',
20971
20999
  };
20972
- return this.client.call('patch', uri, apiHeaders, payload);
21000
+ return this.client.call('post', uri, apiHeaders, payload);
20973
21001
  }
20974
- updateAPIStatusAll(paramsOrFirst, ...rest) {
21002
+ updateWebPlatform(paramsOrFirst, ...rest) {
20975
21003
  let params;
20976
21004
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
20977
21005
  params = (paramsOrFirst || {});
20978
21006
  }
20979
21007
  else {
20980
21008
  params = {
20981
- projectId: paramsOrFirst,
20982
- status: rest[0]
21009
+ platformId: paramsOrFirst,
21010
+ name: rest[0],
21011
+ hostname: rest[1]
20983
21012
  };
20984
21013
  }
20985
- const projectId = params.projectId;
20986
- const status = params.status;
20987
- if (typeof projectId === 'undefined') {
20988
- throw new AppwriteException('Missing required parameter: "projectId"');
21014
+ const platformId = params.platformId;
21015
+ const name = params.name;
21016
+ const hostname = params.hostname;
21017
+ if (typeof platformId === 'undefined') {
21018
+ throw new AppwriteException('Missing required parameter: "platformId"');
20989
21019
  }
20990
- if (typeof status === 'undefined') {
20991
- throw new AppwriteException('Missing required parameter: "status"');
21020
+ if (typeof name === 'undefined') {
21021
+ throw new AppwriteException('Missing required parameter: "name"');
20992
21022
  }
20993
- const apiPath = '/projects/{projectId}/api/all'.replace('{projectId}', projectId);
21023
+ if (typeof hostname === 'undefined') {
21024
+ throw new AppwriteException('Missing required parameter: "hostname"');
21025
+ }
21026
+ const apiPath = '/project/platforms/web/{platformId}'.replace('{platformId}', platformId);
20994
21027
  const payload = {};
20995
- if (typeof status !== 'undefined') {
20996
- payload['status'] = status;
21028
+ if (typeof name !== 'undefined') {
21029
+ payload['name'] = name;
21030
+ }
21031
+ if (typeof hostname !== 'undefined') {
21032
+ payload['hostname'] = hostname;
20997
21033
  }
20998
21034
  const uri = new URL(this.client.config.endpoint + apiPath);
20999
21035
  const apiHeaders = {
21000
21036
  'content-type': 'application/json',
21001
21037
  };
21002
- return this.client.call('patch', uri, apiHeaders, payload);
21038
+ return this.client.call('put', uri, apiHeaders, payload);
21003
21039
  }
21004
- updateAuthDuration(paramsOrFirst, ...rest) {
21040
+ createWindowsPlatform(paramsOrFirst, ...rest) {
21005
21041
  let params;
21006
21042
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21007
21043
  params = (paramsOrFirst || {});
21008
21044
  }
21009
21045
  else {
21010
21046
  params = {
21011
- projectId: paramsOrFirst,
21012
- duration: rest[0]
21047
+ platformId: paramsOrFirst,
21048
+ name: rest[0],
21049
+ packageIdentifierName: rest[1]
21013
21050
  };
21014
21051
  }
21015
- const projectId = params.projectId;
21016
- const duration = params.duration;
21017
- if (typeof projectId === 'undefined') {
21018
- throw new AppwriteException('Missing required parameter: "projectId"');
21052
+ const platformId = params.platformId;
21053
+ const name = params.name;
21054
+ const packageIdentifierName = params.packageIdentifierName;
21055
+ if (typeof platformId === 'undefined') {
21056
+ throw new AppwriteException('Missing required parameter: "platformId"');
21019
21057
  }
21020
- if (typeof duration === 'undefined') {
21021
- throw new AppwriteException('Missing required parameter: "duration"');
21058
+ if (typeof name === 'undefined') {
21059
+ throw new AppwriteException('Missing required parameter: "name"');
21022
21060
  }
21023
- const apiPath = '/projects/{projectId}/auth/duration'.replace('{projectId}', projectId);
21061
+ if (typeof packageIdentifierName === 'undefined') {
21062
+ throw new AppwriteException('Missing required parameter: "packageIdentifierName"');
21063
+ }
21064
+ const apiPath = '/project/platforms/windows';
21024
21065
  const payload = {};
21025
- if (typeof duration !== 'undefined') {
21026
- payload['duration'] = duration;
21066
+ if (typeof platformId !== 'undefined') {
21067
+ payload['platformId'] = platformId;
21068
+ }
21069
+ if (typeof name !== 'undefined') {
21070
+ payload['name'] = name;
21071
+ }
21072
+ if (typeof packageIdentifierName !== 'undefined') {
21073
+ payload['packageIdentifierName'] = packageIdentifierName;
21027
21074
  }
21028
21075
  const uri = new URL(this.client.config.endpoint + apiPath);
21029
21076
  const apiHeaders = {
21030
21077
  'content-type': 'application/json',
21031
21078
  };
21032
- return this.client.call('patch', uri, apiHeaders, payload);
21079
+ return this.client.call('post', uri, apiHeaders, payload);
21033
21080
  }
21034
- updateAuthLimit(paramsOrFirst, ...rest) {
21081
+ updateWindowsPlatform(paramsOrFirst, ...rest) {
21035
21082
  let params;
21036
21083
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21037
21084
  params = (paramsOrFirst || {});
21038
21085
  }
21039
21086
  else {
21040
21087
  params = {
21041
- projectId: paramsOrFirst,
21042
- limit: rest[0]
21088
+ platformId: paramsOrFirst,
21089
+ name: rest[0],
21090
+ packageIdentifierName: rest[1]
21043
21091
  };
21044
21092
  }
21045
- const projectId = params.projectId;
21046
- const limit = params.limit;
21047
- if (typeof projectId === 'undefined') {
21048
- throw new AppwriteException('Missing required parameter: "projectId"');
21093
+ const platformId = params.platformId;
21094
+ const name = params.name;
21095
+ const packageIdentifierName = params.packageIdentifierName;
21096
+ if (typeof platformId === 'undefined') {
21097
+ throw new AppwriteException('Missing required parameter: "platformId"');
21049
21098
  }
21050
- if (typeof limit === 'undefined') {
21051
- throw new AppwriteException('Missing required parameter: "limit"');
21099
+ if (typeof name === 'undefined') {
21100
+ throw new AppwriteException('Missing required parameter: "name"');
21052
21101
  }
21053
- const apiPath = '/projects/{projectId}/auth/limit'.replace('{projectId}', projectId);
21102
+ if (typeof packageIdentifierName === 'undefined') {
21103
+ throw new AppwriteException('Missing required parameter: "packageIdentifierName"');
21104
+ }
21105
+ const apiPath = '/project/platforms/windows/{platformId}'.replace('{platformId}', platformId);
21054
21106
  const payload = {};
21055
- if (typeof limit !== 'undefined') {
21056
- payload['limit'] = limit;
21107
+ if (typeof name !== 'undefined') {
21108
+ payload['name'] = name;
21109
+ }
21110
+ if (typeof packageIdentifierName !== 'undefined') {
21111
+ payload['packageIdentifierName'] = packageIdentifierName;
21057
21112
  }
21058
21113
  const uri = new URL(this.client.config.endpoint + apiPath);
21059
21114
  const apiHeaders = {
21060
21115
  'content-type': 'application/json',
21061
21116
  };
21062
- return this.client.call('patch', uri, apiHeaders, payload);
21117
+ return this.client.call('put', uri, apiHeaders, payload);
21063
21118
  }
21064
- updateAuthSessionsLimit(paramsOrFirst, ...rest) {
21119
+ getPlatform(paramsOrFirst) {
21065
21120
  let params;
21066
21121
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21067
21122
  params = (paramsOrFirst || {});
21068
21123
  }
21069
21124
  else {
21070
21125
  params = {
21071
- projectId: paramsOrFirst,
21072
- limit: rest[0]
21126
+ platformId: paramsOrFirst
21073
21127
  };
21074
21128
  }
21075
- const projectId = params.projectId;
21076
- const limit = params.limit;
21077
- if (typeof projectId === 'undefined') {
21078
- throw new AppwriteException('Missing required parameter: "projectId"');
21079
- }
21080
- if (typeof limit === 'undefined') {
21081
- throw new AppwriteException('Missing required parameter: "limit"');
21129
+ const platformId = params.platformId;
21130
+ if (typeof platformId === 'undefined') {
21131
+ throw new AppwriteException('Missing required parameter: "platformId"');
21082
21132
  }
21083
- const apiPath = '/projects/{projectId}/auth/max-sessions'.replace('{projectId}', projectId);
21133
+ const apiPath = '/project/platforms/{platformId}'.replace('{platformId}', platformId);
21084
21134
  const payload = {};
21085
- if (typeof limit !== 'undefined') {
21086
- payload['limit'] = limit;
21087
- }
21088
21135
  const uri = new URL(this.client.config.endpoint + apiPath);
21089
- const apiHeaders = {
21090
- 'content-type': 'application/json',
21091
- };
21092
- return this.client.call('patch', uri, apiHeaders, payload);
21136
+ const apiHeaders = {};
21137
+ return this.client.call('get', uri, apiHeaders, payload);
21093
21138
  }
21094
- updateMembershipsPrivacy(paramsOrFirst, ...rest) {
21139
+ deletePlatform(paramsOrFirst) {
21095
21140
  let params;
21096
21141
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21097
21142
  params = (paramsOrFirst || {});
21098
21143
  }
21099
21144
  else {
21100
21145
  params = {
21101
- projectId: paramsOrFirst,
21102
- userName: rest[0],
21103
- userEmail: rest[1],
21104
- mfa: rest[2]
21146
+ platformId: paramsOrFirst
21105
21147
  };
21106
21148
  }
21107
- const projectId = params.projectId;
21108
- const userName = params.userName;
21109
- const userEmail = params.userEmail;
21110
- const mfa = params.mfa;
21111
- if (typeof projectId === 'undefined') {
21112
- throw new AppwriteException('Missing required parameter: "projectId"');
21113
- }
21114
- if (typeof userName === 'undefined') {
21115
- throw new AppwriteException('Missing required parameter: "userName"');
21116
- }
21117
- if (typeof userEmail === 'undefined') {
21118
- throw new AppwriteException('Missing required parameter: "userEmail"');
21119
- }
21120
- if (typeof mfa === 'undefined') {
21121
- throw new AppwriteException('Missing required parameter: "mfa"');
21149
+ const platformId = params.platformId;
21150
+ if (typeof platformId === 'undefined') {
21151
+ throw new AppwriteException('Missing required parameter: "platformId"');
21122
21152
  }
21123
- const apiPath = '/projects/{projectId}/auth/memberships-privacy'.replace('{projectId}', projectId);
21153
+ const apiPath = '/project/platforms/{platformId}'.replace('{platformId}', platformId);
21124
21154
  const payload = {};
21125
- if (typeof userName !== 'undefined') {
21126
- payload['userName'] = userName;
21127
- }
21128
- if (typeof userEmail !== 'undefined') {
21129
- payload['userEmail'] = userEmail;
21130
- }
21131
- if (typeof mfa !== 'undefined') {
21132
- payload['mfa'] = mfa;
21133
- }
21134
21155
  const uri = new URL(this.client.config.endpoint + apiPath);
21135
21156
  const apiHeaders = {
21136
21157
  'content-type': 'application/json',
21137
21158
  };
21138
- return this.client.call('patch', uri, apiHeaders, payload);
21159
+ return this.client.call('delete', uri, apiHeaders, payload);
21139
21160
  }
21140
- updateMockNumbers(paramsOrFirst, ...rest) {
21161
+ updateProtocolStatus(paramsOrFirst, ...rest) {
21141
21162
  let params;
21142
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21163
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst) && ('protocolId' in paramsOrFirst || 'enabled' in paramsOrFirst))) {
21143
21164
  params = (paramsOrFirst || {});
21144
21165
  }
21145
21166
  else {
21146
21167
  params = {
21147
- projectId: paramsOrFirst,
21148
- numbers: rest[0]
21168
+ protocolId: paramsOrFirst,
21169
+ enabled: rest[0]
21149
21170
  };
21150
21171
  }
21151
- const projectId = params.projectId;
21152
- const numbers = params.numbers;
21153
- if (typeof projectId === 'undefined') {
21154
- throw new AppwriteException('Missing required parameter: "projectId"');
21172
+ const protocolId = params.protocolId;
21173
+ const enabled = params.enabled;
21174
+ if (typeof protocolId === 'undefined') {
21175
+ throw new AppwriteException('Missing required parameter: "protocolId"');
21155
21176
  }
21156
- if (typeof numbers === 'undefined') {
21157
- throw new AppwriteException('Missing required parameter: "numbers"');
21177
+ if (typeof enabled === 'undefined') {
21178
+ throw new AppwriteException('Missing required parameter: "enabled"');
21158
21179
  }
21159
- const apiPath = '/projects/{projectId}/auth/mock-numbers'.replace('{projectId}', projectId);
21180
+ const apiPath = '/project/protocols/{protocolId}/status'.replace('{protocolId}', protocolId);
21160
21181
  const payload = {};
21161
- if (typeof numbers !== 'undefined') {
21162
- payload['numbers'] = numbers;
21182
+ if (typeof enabled !== 'undefined') {
21183
+ payload['enabled'] = enabled;
21163
21184
  }
21164
21185
  const uri = new URL(this.client.config.endpoint + apiPath);
21165
21186
  const apiHeaders = {
@@ -21167,26 +21188,26 @@
21167
21188
  };
21168
21189
  return this.client.call('patch', uri, apiHeaders, payload);
21169
21190
  }
21170
- updateAuthPasswordDictionary(paramsOrFirst, ...rest) {
21191
+ updateServiceStatus(paramsOrFirst, ...rest) {
21171
21192
  let params;
21172
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21193
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst) && ('serviceId' in paramsOrFirst || 'enabled' in paramsOrFirst))) {
21173
21194
  params = (paramsOrFirst || {});
21174
21195
  }
21175
21196
  else {
21176
21197
  params = {
21177
- projectId: paramsOrFirst,
21198
+ serviceId: paramsOrFirst,
21178
21199
  enabled: rest[0]
21179
21200
  };
21180
21201
  }
21181
- const projectId = params.projectId;
21202
+ const serviceId = params.serviceId;
21182
21203
  const enabled = params.enabled;
21183
- if (typeof projectId === 'undefined') {
21184
- throw new AppwriteException('Missing required parameter: "projectId"');
21204
+ if (typeof serviceId === 'undefined') {
21205
+ throw new AppwriteException('Missing required parameter: "serviceId"');
21185
21206
  }
21186
21207
  if (typeof enabled === 'undefined') {
21187
21208
  throw new AppwriteException('Missing required parameter: "enabled"');
21188
21209
  }
21189
- const apiPath = '/projects/{projectId}/auth/password-dictionary'.replace('{projectId}', projectId);
21210
+ const apiPath = '/project/services/{serviceId}/status'.replace('{serviceId}', serviceId);
21190
21211
  const payload = {};
21191
21212
  if (typeof enabled !== 'undefined') {
21192
21213
  payload['enabled'] = enabled;
@@ -21197,209 +21218,340 @@
21197
21218
  };
21198
21219
  return this.client.call('patch', uri, apiHeaders, payload);
21199
21220
  }
21200
- updateAuthPasswordHistory(paramsOrFirst, ...rest) {
21221
+ getUsage(paramsOrFirst, ...rest) {
21201
21222
  let params;
21202
21223
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21203
21224
  params = (paramsOrFirst || {});
21204
21225
  }
21205
21226
  else {
21206
21227
  params = {
21207
- projectId: paramsOrFirst,
21208
- limit: rest[0]
21228
+ startDate: paramsOrFirst,
21229
+ endDate: rest[0],
21230
+ period: rest[1]
21209
21231
  };
21210
21232
  }
21211
- const projectId = params.projectId;
21212
- const limit = params.limit;
21213
- if (typeof projectId === 'undefined') {
21214
- throw new AppwriteException('Missing required parameter: "projectId"');
21233
+ const startDate = params.startDate;
21234
+ const endDate = params.endDate;
21235
+ const period = params.period;
21236
+ if (typeof startDate === 'undefined') {
21237
+ throw new AppwriteException('Missing required parameter: "startDate"');
21215
21238
  }
21216
- if (typeof limit === 'undefined') {
21217
- throw new AppwriteException('Missing required parameter: "limit"');
21239
+ if (typeof endDate === 'undefined') {
21240
+ throw new AppwriteException('Missing required parameter: "endDate"');
21218
21241
  }
21219
- const apiPath = '/projects/{projectId}/auth/password-history'.replace('{projectId}', projectId);
21242
+ const apiPath = '/project/usage';
21220
21243
  const payload = {};
21221
- if (typeof limit !== 'undefined') {
21222
- payload['limit'] = limit;
21244
+ if (typeof startDate !== 'undefined') {
21245
+ payload['startDate'] = startDate;
21246
+ }
21247
+ if (typeof endDate !== 'undefined') {
21248
+ payload['endDate'] = endDate;
21249
+ }
21250
+ if (typeof period !== 'undefined') {
21251
+ payload['period'] = period;
21223
21252
  }
21224
21253
  const uri = new URL(this.client.config.endpoint + apiPath);
21225
- const apiHeaders = {
21226
- 'content-type': 'application/json',
21227
- };
21228
- return this.client.call('patch', uri, apiHeaders, payload);
21254
+ const apiHeaders = {};
21255
+ return this.client.call('get', uri, apiHeaders, payload);
21229
21256
  }
21230
- updatePersonalDataCheck(paramsOrFirst, ...rest) {
21257
+ listVariables(paramsOrFirst, ...rest) {
21231
21258
  let params;
21232
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21259
+ if (!paramsOrFirst || (paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21233
21260
  params = (paramsOrFirst || {});
21234
21261
  }
21235
21262
  else {
21236
21263
  params = {
21237
- projectId: paramsOrFirst,
21238
- enabled: rest[0]
21264
+ queries: paramsOrFirst,
21265
+ total: rest[0]
21239
21266
  };
21240
21267
  }
21241
- const projectId = params.projectId;
21242
- const enabled = params.enabled;
21243
- if (typeof projectId === 'undefined') {
21244
- throw new AppwriteException('Missing required parameter: "projectId"');
21245
- }
21246
- if (typeof enabled === 'undefined') {
21247
- throw new AppwriteException('Missing required parameter: "enabled"');
21248
- }
21249
- const apiPath = '/projects/{projectId}/auth/personal-data'.replace('{projectId}', projectId);
21268
+ const queries = params.queries;
21269
+ const total = params.total;
21270
+ const apiPath = '/project/variables';
21250
21271
  const payload = {};
21251
- if (typeof enabled !== 'undefined') {
21252
- payload['enabled'] = enabled;
21272
+ if (typeof queries !== 'undefined') {
21273
+ payload['queries'] = queries;
21274
+ }
21275
+ if (typeof total !== 'undefined') {
21276
+ payload['total'] = total;
21253
21277
  }
21254
21278
  const uri = new URL(this.client.config.endpoint + apiPath);
21255
- const apiHeaders = {
21256
- 'content-type': 'application/json',
21257
- };
21258
- return this.client.call('patch', uri, apiHeaders, payload);
21279
+ const apiHeaders = {};
21280
+ return this.client.call('get', uri, apiHeaders, payload);
21259
21281
  }
21260
- updateSessionAlerts(paramsOrFirst, ...rest) {
21282
+ createVariable(paramsOrFirst, ...rest) {
21261
21283
  let params;
21262
21284
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21263
21285
  params = (paramsOrFirst || {});
21264
21286
  }
21265
21287
  else {
21266
21288
  params = {
21267
- projectId: paramsOrFirst,
21268
- alerts: rest[0]
21289
+ variableId: paramsOrFirst,
21290
+ key: rest[0],
21291
+ value: rest[1],
21292
+ secret: rest[2]
21269
21293
  };
21270
21294
  }
21271
- const projectId = params.projectId;
21272
- const alerts = params.alerts;
21273
- if (typeof projectId === 'undefined') {
21274
- throw new AppwriteException('Missing required parameter: "projectId"');
21295
+ const variableId = params.variableId;
21296
+ const key = params.key;
21297
+ const value = params.value;
21298
+ const secret = params.secret;
21299
+ if (typeof variableId === 'undefined') {
21300
+ throw new AppwriteException('Missing required parameter: "variableId"');
21275
21301
  }
21276
- if (typeof alerts === 'undefined') {
21277
- throw new AppwriteException('Missing required parameter: "alerts"');
21302
+ if (typeof key === 'undefined') {
21303
+ throw new AppwriteException('Missing required parameter: "key"');
21278
21304
  }
21279
- const apiPath = '/projects/{projectId}/auth/session-alerts'.replace('{projectId}', projectId);
21305
+ if (typeof value === 'undefined') {
21306
+ throw new AppwriteException('Missing required parameter: "value"');
21307
+ }
21308
+ const apiPath = '/project/variables';
21280
21309
  const payload = {};
21281
- if (typeof alerts !== 'undefined') {
21282
- payload['alerts'] = alerts;
21310
+ if (typeof variableId !== 'undefined') {
21311
+ payload['variableId'] = variableId;
21312
+ }
21313
+ if (typeof key !== 'undefined') {
21314
+ payload['key'] = key;
21315
+ }
21316
+ if (typeof value !== 'undefined') {
21317
+ payload['value'] = value;
21318
+ }
21319
+ if (typeof secret !== 'undefined') {
21320
+ payload['secret'] = secret;
21283
21321
  }
21284
21322
  const uri = new URL(this.client.config.endpoint + apiPath);
21285
21323
  const apiHeaders = {
21286
21324
  'content-type': 'application/json',
21287
21325
  };
21288
- return this.client.call('patch', uri, apiHeaders, payload);
21326
+ return this.client.call('post', uri, apiHeaders, payload);
21289
21327
  }
21290
- updateSessionInvalidation(paramsOrFirst, ...rest) {
21328
+ getVariable(paramsOrFirst) {
21291
21329
  let params;
21292
21330
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21293
21331
  params = (paramsOrFirst || {});
21294
21332
  }
21295
21333
  else {
21296
21334
  params = {
21297
- projectId: paramsOrFirst,
21298
- enabled: rest[0]
21335
+ variableId: paramsOrFirst
21299
21336
  };
21300
21337
  }
21301
- const projectId = params.projectId;
21302
- const enabled = params.enabled;
21303
- if (typeof projectId === 'undefined') {
21304
- throw new AppwriteException('Missing required parameter: "projectId"');
21305
- }
21306
- if (typeof enabled === 'undefined') {
21307
- throw new AppwriteException('Missing required parameter: "enabled"');
21338
+ const variableId = params.variableId;
21339
+ if (typeof variableId === 'undefined') {
21340
+ throw new AppwriteException('Missing required parameter: "variableId"');
21308
21341
  }
21309
- const apiPath = '/projects/{projectId}/auth/session-invalidation'.replace('{projectId}', projectId);
21342
+ const apiPath = '/project/variables/{variableId}'.replace('{variableId}', variableId);
21310
21343
  const payload = {};
21311
- if (typeof enabled !== 'undefined') {
21312
- payload['enabled'] = enabled;
21313
- }
21314
21344
  const uri = new URL(this.client.config.endpoint + apiPath);
21315
- const apiHeaders = {
21316
- 'content-type': 'application/json',
21317
- };
21318
- return this.client.call('patch', uri, apiHeaders, payload);
21345
+ const apiHeaders = {};
21346
+ return this.client.call('get', uri, apiHeaders, payload);
21319
21347
  }
21320
- updateAuthStatus(paramsOrFirst, ...rest) {
21348
+ updateVariable(paramsOrFirst, ...rest) {
21321
21349
  let params;
21322
21350
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21323
21351
  params = (paramsOrFirst || {});
21324
21352
  }
21325
21353
  else {
21326
21354
  params = {
21327
- projectId: paramsOrFirst,
21328
- method: rest[0],
21329
- status: rest[1]
21355
+ variableId: paramsOrFirst,
21356
+ key: rest[0],
21357
+ value: rest[1],
21358
+ secret: rest[2]
21330
21359
  };
21331
21360
  }
21332
- const projectId = params.projectId;
21333
- const method = params.method;
21334
- const status = params.status;
21335
- if (typeof projectId === 'undefined') {
21336
- throw new AppwriteException('Missing required parameter: "projectId"');
21361
+ const variableId = params.variableId;
21362
+ const key = params.key;
21363
+ const value = params.value;
21364
+ const secret = params.secret;
21365
+ if (typeof variableId === 'undefined') {
21366
+ throw new AppwriteException('Missing required parameter: "variableId"');
21337
21367
  }
21338
- if (typeof method === 'undefined') {
21339
- throw new AppwriteException('Missing required parameter: "method"');
21368
+ const apiPath = '/project/variables/{variableId}'.replace('{variableId}', variableId);
21369
+ const payload = {};
21370
+ if (typeof key !== 'undefined') {
21371
+ payload['key'] = key;
21340
21372
  }
21341
- if (typeof status === 'undefined') {
21342
- throw new AppwriteException('Missing required parameter: "status"');
21373
+ if (typeof value !== 'undefined') {
21374
+ payload['value'] = value;
21343
21375
  }
21344
- const apiPath = '/projects/{projectId}/auth/{method}'.replace('{projectId}', projectId).replace('{method}', method);
21345
- const payload = {};
21346
- if (typeof status !== 'undefined') {
21347
- payload['status'] = status;
21376
+ if (typeof secret !== 'undefined') {
21377
+ payload['secret'] = secret;
21348
21378
  }
21349
21379
  const uri = new URL(this.client.config.endpoint + apiPath);
21350
21380
  const apiHeaders = {
21351
21381
  'content-type': 'application/json',
21352
21382
  };
21353
- return this.client.call('patch', uri, apiHeaders, payload);
21383
+ return this.client.call('put', uri, apiHeaders, payload);
21354
21384
  }
21355
- updateConsoleAccess(paramsOrFirst) {
21385
+ deleteVariable(paramsOrFirst) {
21356
21386
  let params;
21357
21387
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21358
21388
  params = (paramsOrFirst || {});
21359
21389
  }
21360
21390
  else {
21361
21391
  params = {
21362
- projectId: paramsOrFirst
21392
+ variableId: paramsOrFirst
21393
+ };
21394
+ }
21395
+ const variableId = params.variableId;
21396
+ if (typeof variableId === 'undefined') {
21397
+ throw new AppwriteException('Missing required parameter: "variableId"');
21398
+ }
21399
+ const apiPath = '/project/variables/{variableId}'.replace('{variableId}', variableId);
21400
+ const payload = {};
21401
+ const uri = new URL(this.client.config.endpoint + apiPath);
21402
+ const apiHeaders = {
21403
+ 'content-type': 'application/json',
21404
+ };
21405
+ return this.client.call('delete', uri, apiHeaders, payload);
21406
+ }
21407
+ }
21408
+
21409
+ class Projects {
21410
+ constructor(client) {
21411
+ this.client = client;
21412
+ }
21413
+ list(paramsOrFirst, ...rest) {
21414
+ let params;
21415
+ if (!paramsOrFirst || (paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21416
+ params = (paramsOrFirst || {});
21417
+ }
21418
+ else {
21419
+ params = {
21420
+ queries: paramsOrFirst,
21421
+ search: rest[0],
21422
+ total: rest[1]
21423
+ };
21424
+ }
21425
+ const queries = params.queries;
21426
+ const search = params.search;
21427
+ const total = params.total;
21428
+ const apiPath = '/projects';
21429
+ const payload = {};
21430
+ if (typeof queries !== 'undefined') {
21431
+ payload['queries'] = queries;
21432
+ }
21433
+ if (typeof search !== 'undefined') {
21434
+ payload['search'] = search;
21435
+ }
21436
+ if (typeof total !== 'undefined') {
21437
+ payload['total'] = total;
21438
+ }
21439
+ const uri = new URL(this.client.config.endpoint + apiPath);
21440
+ const apiHeaders = {};
21441
+ return this.client.call('get', uri, apiHeaders, payload);
21442
+ }
21443
+ create(paramsOrFirst, ...rest) {
21444
+ let params;
21445
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21446
+ params = (paramsOrFirst || {});
21447
+ }
21448
+ else {
21449
+ params = {
21450
+ projectId: paramsOrFirst,
21451
+ name: rest[0],
21452
+ teamId: rest[1],
21453
+ region: rest[2],
21454
+ description: rest[3],
21455
+ logo: rest[4],
21456
+ url: rest[5],
21457
+ legalName: rest[6],
21458
+ legalCountry: rest[7],
21459
+ legalState: rest[8],
21460
+ legalCity: rest[9],
21461
+ legalAddress: rest[10],
21462
+ legalTaxId: rest[11]
21363
21463
  };
21364
21464
  }
21365
21465
  const projectId = params.projectId;
21466
+ const name = params.name;
21467
+ const teamId = params.teamId;
21468
+ const region = params.region;
21469
+ const description = params.description;
21470
+ const logo = params.logo;
21471
+ const url = params.url;
21472
+ const legalName = params.legalName;
21473
+ const legalCountry = params.legalCountry;
21474
+ const legalState = params.legalState;
21475
+ const legalCity = params.legalCity;
21476
+ const legalAddress = params.legalAddress;
21477
+ const legalTaxId = params.legalTaxId;
21366
21478
  if (typeof projectId === 'undefined') {
21367
21479
  throw new AppwriteException('Missing required parameter: "projectId"');
21368
21480
  }
21369
- const apiPath = '/projects/{projectId}/console-access'.replace('{projectId}', projectId);
21481
+ if (typeof name === 'undefined') {
21482
+ throw new AppwriteException('Missing required parameter: "name"');
21483
+ }
21484
+ if (typeof teamId === 'undefined') {
21485
+ throw new AppwriteException('Missing required parameter: "teamId"');
21486
+ }
21487
+ const apiPath = '/projects';
21370
21488
  const payload = {};
21489
+ if (typeof projectId !== 'undefined') {
21490
+ payload['projectId'] = projectId;
21491
+ }
21492
+ if (typeof name !== 'undefined') {
21493
+ payload['name'] = name;
21494
+ }
21495
+ if (typeof teamId !== 'undefined') {
21496
+ payload['teamId'] = teamId;
21497
+ }
21498
+ if (typeof region !== 'undefined') {
21499
+ payload['region'] = region;
21500
+ }
21501
+ if (typeof description !== 'undefined') {
21502
+ payload['description'] = description;
21503
+ }
21504
+ if (typeof logo !== 'undefined') {
21505
+ payload['logo'] = logo;
21506
+ }
21507
+ if (typeof url !== 'undefined') {
21508
+ payload['url'] = url;
21509
+ }
21510
+ if (typeof legalName !== 'undefined') {
21511
+ payload['legalName'] = legalName;
21512
+ }
21513
+ if (typeof legalCountry !== 'undefined') {
21514
+ payload['legalCountry'] = legalCountry;
21515
+ }
21516
+ if (typeof legalState !== 'undefined') {
21517
+ payload['legalState'] = legalState;
21518
+ }
21519
+ if (typeof legalCity !== 'undefined') {
21520
+ payload['legalCity'] = legalCity;
21521
+ }
21522
+ if (typeof legalAddress !== 'undefined') {
21523
+ payload['legalAddress'] = legalAddress;
21524
+ }
21525
+ if (typeof legalTaxId !== 'undefined') {
21526
+ payload['legalTaxId'] = legalTaxId;
21527
+ }
21371
21528
  const uri = new URL(this.client.config.endpoint + apiPath);
21372
21529
  const apiHeaders = {
21373
21530
  'content-type': 'application/json',
21374
21531
  };
21375
- return this.client.call('patch', uri, apiHeaders, payload);
21532
+ return this.client.call('post', uri, apiHeaders, payload);
21376
21533
  }
21377
- listDevKeys(paramsOrFirst, ...rest) {
21534
+ get(paramsOrFirst) {
21378
21535
  let params;
21379
21536
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21380
21537
  params = (paramsOrFirst || {});
21381
21538
  }
21382
21539
  else {
21383
21540
  params = {
21384
- projectId: paramsOrFirst,
21385
- queries: rest[0]
21541
+ projectId: paramsOrFirst
21386
21542
  };
21387
21543
  }
21388
21544
  const projectId = params.projectId;
21389
- const queries = params.queries;
21390
21545
  if (typeof projectId === 'undefined') {
21391
21546
  throw new AppwriteException('Missing required parameter: "projectId"');
21392
21547
  }
21393
- const apiPath = '/projects/{projectId}/dev-keys'.replace('{projectId}', projectId);
21548
+ const apiPath = '/projects/{projectId}'.replace('{projectId}', projectId);
21394
21549
  const payload = {};
21395
- if (typeof queries !== 'undefined') {
21396
- payload['queries'] = queries;
21397
- }
21398
21550
  const uri = new URL(this.client.config.endpoint + apiPath);
21399
21551
  const apiHeaders = {};
21400
21552
  return this.client.call('get', uri, apiHeaders, payload);
21401
21553
  }
21402
- createDevKey(paramsOrFirst, ...rest) {
21554
+ update(paramsOrFirst, ...rest) {
21403
21555
  let params;
21404
21556
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21405
21557
  params = (paramsOrFirst || {});
@@ -21408,36 +21560,185 @@
21408
21560
  params = {
21409
21561
  projectId: paramsOrFirst,
21410
21562
  name: rest[0],
21411
- expire: rest[1]
21563
+ description: rest[1],
21564
+ logo: rest[2],
21565
+ url: rest[3],
21566
+ legalName: rest[4],
21567
+ legalCountry: rest[5],
21568
+ legalState: rest[6],
21569
+ legalCity: rest[7],
21570
+ legalAddress: rest[8],
21571
+ legalTaxId: rest[9]
21412
21572
  };
21413
21573
  }
21414
21574
  const projectId = params.projectId;
21415
21575
  const name = params.name;
21416
- const expire = params.expire;
21576
+ const description = params.description;
21577
+ const logo = params.logo;
21578
+ const url = params.url;
21579
+ const legalName = params.legalName;
21580
+ const legalCountry = params.legalCountry;
21581
+ const legalState = params.legalState;
21582
+ const legalCity = params.legalCity;
21583
+ const legalAddress = params.legalAddress;
21584
+ const legalTaxId = params.legalTaxId;
21417
21585
  if (typeof projectId === 'undefined') {
21418
21586
  throw new AppwriteException('Missing required parameter: "projectId"');
21419
21587
  }
21420
21588
  if (typeof name === 'undefined') {
21421
21589
  throw new AppwriteException('Missing required parameter: "name"');
21422
21590
  }
21423
- if (typeof expire === 'undefined') {
21424
- throw new AppwriteException('Missing required parameter: "expire"');
21425
- }
21426
- const apiPath = '/projects/{projectId}/dev-keys'.replace('{projectId}', projectId);
21591
+ const apiPath = '/projects/{projectId}'.replace('{projectId}', projectId);
21427
21592
  const payload = {};
21428
21593
  if (typeof name !== 'undefined') {
21429
21594
  payload['name'] = name;
21430
21595
  }
21431
- if (typeof expire !== 'undefined') {
21432
- payload['expire'] = expire;
21596
+ if (typeof description !== 'undefined') {
21597
+ payload['description'] = description;
21598
+ }
21599
+ if (typeof logo !== 'undefined') {
21600
+ payload['logo'] = logo;
21601
+ }
21602
+ if (typeof url !== 'undefined') {
21603
+ payload['url'] = url;
21604
+ }
21605
+ if (typeof legalName !== 'undefined') {
21606
+ payload['legalName'] = legalName;
21607
+ }
21608
+ if (typeof legalCountry !== 'undefined') {
21609
+ payload['legalCountry'] = legalCountry;
21610
+ }
21611
+ if (typeof legalState !== 'undefined') {
21612
+ payload['legalState'] = legalState;
21613
+ }
21614
+ if (typeof legalCity !== 'undefined') {
21615
+ payload['legalCity'] = legalCity;
21616
+ }
21617
+ if (typeof legalAddress !== 'undefined') {
21618
+ payload['legalAddress'] = legalAddress;
21619
+ }
21620
+ if (typeof legalTaxId !== 'undefined') {
21621
+ payload['legalTaxId'] = legalTaxId;
21433
21622
  }
21434
21623
  const uri = new URL(this.client.config.endpoint + apiPath);
21435
21624
  const apiHeaders = {
21436
21625
  'content-type': 'application/json',
21437
21626
  };
21438
- return this.client.call('post', uri, apiHeaders, payload);
21627
+ return this.client.call('patch', uri, apiHeaders, payload);
21628
+ }
21629
+ delete(paramsOrFirst) {
21630
+ let params;
21631
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21632
+ params = (paramsOrFirst || {});
21633
+ }
21634
+ else {
21635
+ params = {
21636
+ projectId: paramsOrFirst
21637
+ };
21638
+ }
21639
+ const projectId = params.projectId;
21640
+ if (typeof projectId === 'undefined') {
21641
+ throw new AppwriteException('Missing required parameter: "projectId"');
21642
+ }
21643
+ const apiPath = '/projects/{projectId}'.replace('{projectId}', projectId);
21644
+ const payload = {};
21645
+ const uri = new URL(this.client.config.endpoint + apiPath);
21646
+ const apiHeaders = {
21647
+ 'content-type': 'application/json',
21648
+ };
21649
+ return this.client.call('delete', uri, apiHeaders, payload);
21650
+ }
21651
+ updateAuthDuration(paramsOrFirst, ...rest) {
21652
+ let params;
21653
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21654
+ params = (paramsOrFirst || {});
21655
+ }
21656
+ else {
21657
+ params = {
21658
+ projectId: paramsOrFirst,
21659
+ duration: rest[0]
21660
+ };
21661
+ }
21662
+ const projectId = params.projectId;
21663
+ const duration = params.duration;
21664
+ if (typeof projectId === 'undefined') {
21665
+ throw new AppwriteException('Missing required parameter: "projectId"');
21666
+ }
21667
+ if (typeof duration === 'undefined') {
21668
+ throw new AppwriteException('Missing required parameter: "duration"');
21669
+ }
21670
+ const apiPath = '/projects/{projectId}/auth/duration'.replace('{projectId}', projectId);
21671
+ const payload = {};
21672
+ if (typeof duration !== 'undefined') {
21673
+ payload['duration'] = duration;
21674
+ }
21675
+ const uri = new URL(this.client.config.endpoint + apiPath);
21676
+ const apiHeaders = {
21677
+ 'content-type': 'application/json',
21678
+ };
21679
+ return this.client.call('patch', uri, apiHeaders, payload);
21680
+ }
21681
+ updateAuthLimit(paramsOrFirst, ...rest) {
21682
+ let params;
21683
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21684
+ params = (paramsOrFirst || {});
21685
+ }
21686
+ else {
21687
+ params = {
21688
+ projectId: paramsOrFirst,
21689
+ limit: rest[0]
21690
+ };
21691
+ }
21692
+ const projectId = params.projectId;
21693
+ const limit = params.limit;
21694
+ if (typeof projectId === 'undefined') {
21695
+ throw new AppwriteException('Missing required parameter: "projectId"');
21696
+ }
21697
+ if (typeof limit === 'undefined') {
21698
+ throw new AppwriteException('Missing required parameter: "limit"');
21699
+ }
21700
+ const apiPath = '/projects/{projectId}/auth/limit'.replace('{projectId}', projectId);
21701
+ const payload = {};
21702
+ if (typeof limit !== 'undefined') {
21703
+ payload['limit'] = limit;
21704
+ }
21705
+ const uri = new URL(this.client.config.endpoint + apiPath);
21706
+ const apiHeaders = {
21707
+ 'content-type': 'application/json',
21708
+ };
21709
+ return this.client.call('patch', uri, apiHeaders, payload);
21710
+ }
21711
+ updateAuthSessionsLimit(paramsOrFirst, ...rest) {
21712
+ let params;
21713
+ if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21714
+ params = (paramsOrFirst || {});
21715
+ }
21716
+ else {
21717
+ params = {
21718
+ projectId: paramsOrFirst,
21719
+ limit: rest[0]
21720
+ };
21721
+ }
21722
+ const projectId = params.projectId;
21723
+ const limit = params.limit;
21724
+ if (typeof projectId === 'undefined') {
21725
+ throw new AppwriteException('Missing required parameter: "projectId"');
21726
+ }
21727
+ if (typeof limit === 'undefined') {
21728
+ throw new AppwriteException('Missing required parameter: "limit"');
21729
+ }
21730
+ const apiPath = '/projects/{projectId}/auth/max-sessions'.replace('{projectId}', projectId);
21731
+ const payload = {};
21732
+ if (typeof limit !== 'undefined') {
21733
+ payload['limit'] = limit;
21734
+ }
21735
+ const uri = new URL(this.client.config.endpoint + apiPath);
21736
+ const apiHeaders = {
21737
+ 'content-type': 'application/json',
21738
+ };
21739
+ return this.client.call('patch', uri, apiHeaders, payload);
21439
21740
  }
21440
- getDevKey(paramsOrFirst, ...rest) {
21741
+ updateMembershipsPrivacy(paramsOrFirst, ...rest) {
21441
21742
  let params;
21442
21743
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21443
21744
  params = (paramsOrFirst || {});
@@ -21445,24 +21746,45 @@
21445
21746
  else {
21446
21747
  params = {
21447
21748
  projectId: paramsOrFirst,
21448
- keyId: rest[0]
21749
+ userName: rest[0],
21750
+ userEmail: rest[1],
21751
+ mfa: rest[2]
21449
21752
  };
21450
21753
  }
21451
21754
  const projectId = params.projectId;
21452
- const keyId = params.keyId;
21755
+ const userName = params.userName;
21756
+ const userEmail = params.userEmail;
21757
+ const mfa = params.mfa;
21453
21758
  if (typeof projectId === 'undefined') {
21454
21759
  throw new AppwriteException('Missing required parameter: "projectId"');
21455
21760
  }
21456
- if (typeof keyId === 'undefined') {
21457
- throw new AppwriteException('Missing required parameter: "keyId"');
21761
+ if (typeof userName === 'undefined') {
21762
+ throw new AppwriteException('Missing required parameter: "userName"');
21458
21763
  }
21459
- const apiPath = '/projects/{projectId}/dev-keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
21764
+ if (typeof userEmail === 'undefined') {
21765
+ throw new AppwriteException('Missing required parameter: "userEmail"');
21766
+ }
21767
+ if (typeof mfa === 'undefined') {
21768
+ throw new AppwriteException('Missing required parameter: "mfa"');
21769
+ }
21770
+ const apiPath = '/projects/{projectId}/auth/memberships-privacy'.replace('{projectId}', projectId);
21460
21771
  const payload = {};
21772
+ if (typeof userName !== 'undefined') {
21773
+ payload['userName'] = userName;
21774
+ }
21775
+ if (typeof userEmail !== 'undefined') {
21776
+ payload['userEmail'] = userEmail;
21777
+ }
21778
+ if (typeof mfa !== 'undefined') {
21779
+ payload['mfa'] = mfa;
21780
+ }
21461
21781
  const uri = new URL(this.client.config.endpoint + apiPath);
21462
- const apiHeaders = {};
21463
- return this.client.call('get', uri, apiHeaders, payload);
21782
+ const apiHeaders = {
21783
+ 'content-type': 'application/json',
21784
+ };
21785
+ return this.client.call('patch', uri, apiHeaders, payload);
21464
21786
  }
21465
- updateDevKey(paramsOrFirst, ...rest) {
21787
+ updateMockNumbers(paramsOrFirst, ...rest) {
21466
21788
  let params;
21467
21789
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21468
21790
  params = (paramsOrFirst || {});
@@ -21470,42 +21792,29 @@
21470
21792
  else {
21471
21793
  params = {
21472
21794
  projectId: paramsOrFirst,
21473
- keyId: rest[0],
21474
- name: rest[1],
21475
- expire: rest[2]
21795
+ numbers: rest[0]
21476
21796
  };
21477
21797
  }
21478
21798
  const projectId = params.projectId;
21479
- const keyId = params.keyId;
21480
- const name = params.name;
21481
- const expire = params.expire;
21799
+ const numbers = params.numbers;
21482
21800
  if (typeof projectId === 'undefined') {
21483
21801
  throw new AppwriteException('Missing required parameter: "projectId"');
21484
21802
  }
21485
- if (typeof keyId === 'undefined') {
21486
- throw new AppwriteException('Missing required parameter: "keyId"');
21487
- }
21488
- if (typeof name === 'undefined') {
21489
- throw new AppwriteException('Missing required parameter: "name"');
21490
- }
21491
- if (typeof expire === 'undefined') {
21492
- throw new AppwriteException('Missing required parameter: "expire"');
21803
+ if (typeof numbers === 'undefined') {
21804
+ throw new AppwriteException('Missing required parameter: "numbers"');
21493
21805
  }
21494
- const apiPath = '/projects/{projectId}/dev-keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
21806
+ const apiPath = '/projects/{projectId}/auth/mock-numbers'.replace('{projectId}', projectId);
21495
21807
  const payload = {};
21496
- if (typeof name !== 'undefined') {
21497
- payload['name'] = name;
21498
- }
21499
- if (typeof expire !== 'undefined') {
21500
- payload['expire'] = expire;
21808
+ if (typeof numbers !== 'undefined') {
21809
+ payload['numbers'] = numbers;
21501
21810
  }
21502
21811
  const uri = new URL(this.client.config.endpoint + apiPath);
21503
21812
  const apiHeaders = {
21504
21813
  'content-type': 'application/json',
21505
21814
  };
21506
- return this.client.call('put', uri, apiHeaders, payload);
21815
+ return this.client.call('patch', uri, apiHeaders, payload);
21507
21816
  }
21508
- deleteDevKey(paramsOrFirst, ...rest) {
21817
+ updateAuthPasswordDictionary(paramsOrFirst, ...rest) {
21509
21818
  let params;
21510
21819
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21511
21820
  params = (paramsOrFirst || {});
@@ -21513,26 +21822,29 @@
21513
21822
  else {
21514
21823
  params = {
21515
21824
  projectId: paramsOrFirst,
21516
- keyId: rest[0]
21825
+ enabled: rest[0]
21517
21826
  };
21518
21827
  }
21519
21828
  const projectId = params.projectId;
21520
- const keyId = params.keyId;
21829
+ const enabled = params.enabled;
21521
21830
  if (typeof projectId === 'undefined') {
21522
21831
  throw new AppwriteException('Missing required parameter: "projectId"');
21523
21832
  }
21524
- if (typeof keyId === 'undefined') {
21525
- throw new AppwriteException('Missing required parameter: "keyId"');
21833
+ if (typeof enabled === 'undefined') {
21834
+ throw new AppwriteException('Missing required parameter: "enabled"');
21526
21835
  }
21527
- const apiPath = '/projects/{projectId}/dev-keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
21836
+ const apiPath = '/projects/{projectId}/auth/password-dictionary'.replace('{projectId}', projectId);
21528
21837
  const payload = {};
21838
+ if (typeof enabled !== 'undefined') {
21839
+ payload['enabled'] = enabled;
21840
+ }
21529
21841
  const uri = new URL(this.client.config.endpoint + apiPath);
21530
21842
  const apiHeaders = {
21531
21843
  'content-type': 'application/json',
21532
21844
  };
21533
- return this.client.call('delete', uri, apiHeaders, payload);
21845
+ return this.client.call('patch', uri, apiHeaders, payload);
21534
21846
  }
21535
- createJWT(paramsOrFirst, ...rest) {
21847
+ updateAuthPasswordHistory(paramsOrFirst, ...rest) {
21536
21848
  let params;
21537
21849
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21538
21850
  params = (paramsOrFirst || {});
@@ -21540,34 +21852,29 @@
21540
21852
  else {
21541
21853
  params = {
21542
21854
  projectId: paramsOrFirst,
21543
- scopes: rest[0],
21544
- duration: rest[1]
21855
+ limit: rest[0]
21545
21856
  };
21546
21857
  }
21547
21858
  const projectId = params.projectId;
21548
- const scopes = params.scopes;
21549
- const duration = params.duration;
21859
+ const limit = params.limit;
21550
21860
  if (typeof projectId === 'undefined') {
21551
21861
  throw new AppwriteException('Missing required parameter: "projectId"');
21552
21862
  }
21553
- if (typeof scopes === 'undefined') {
21554
- throw new AppwriteException('Missing required parameter: "scopes"');
21863
+ if (typeof limit === 'undefined') {
21864
+ throw new AppwriteException('Missing required parameter: "limit"');
21555
21865
  }
21556
- const apiPath = '/projects/{projectId}/jwts'.replace('{projectId}', projectId);
21866
+ const apiPath = '/projects/{projectId}/auth/password-history'.replace('{projectId}', projectId);
21557
21867
  const payload = {};
21558
- if (typeof scopes !== 'undefined') {
21559
- payload['scopes'] = scopes;
21560
- }
21561
- if (typeof duration !== 'undefined') {
21562
- payload['duration'] = duration;
21868
+ if (typeof limit !== 'undefined') {
21869
+ payload['limit'] = limit;
21563
21870
  }
21564
21871
  const uri = new URL(this.client.config.endpoint + apiPath);
21565
21872
  const apiHeaders = {
21566
21873
  'content-type': 'application/json',
21567
21874
  };
21568
- return this.client.call('post', uri, apiHeaders, payload);
21875
+ return this.client.call('patch', uri, apiHeaders, payload);
21569
21876
  }
21570
- listKeys(paramsOrFirst, ...rest) {
21877
+ updatePersonalDataCheck(paramsOrFirst, ...rest) {
21571
21878
  let params;
21572
21879
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21573
21880
  params = (paramsOrFirst || {});
@@ -21575,29 +21882,29 @@
21575
21882
  else {
21576
21883
  params = {
21577
21884
  projectId: paramsOrFirst,
21578
- queries: rest[0],
21579
- total: rest[1]
21885
+ enabled: rest[0]
21580
21886
  };
21581
21887
  }
21582
21888
  const projectId = params.projectId;
21583
- const queries = params.queries;
21584
- const total = params.total;
21889
+ const enabled = params.enabled;
21585
21890
  if (typeof projectId === 'undefined') {
21586
21891
  throw new AppwriteException('Missing required parameter: "projectId"');
21587
21892
  }
21588
- const apiPath = '/projects/{projectId}/keys'.replace('{projectId}', projectId);
21589
- const payload = {};
21590
- if (typeof queries !== 'undefined') {
21591
- payload['queries'] = queries;
21893
+ if (typeof enabled === 'undefined') {
21894
+ throw new AppwriteException('Missing required parameter: "enabled"');
21592
21895
  }
21593
- if (typeof total !== 'undefined') {
21594
- payload['total'] = total;
21896
+ const apiPath = '/projects/{projectId}/auth/personal-data'.replace('{projectId}', projectId);
21897
+ const payload = {};
21898
+ if (typeof enabled !== 'undefined') {
21899
+ payload['enabled'] = enabled;
21595
21900
  }
21596
21901
  const uri = new URL(this.client.config.endpoint + apiPath);
21597
- const apiHeaders = {};
21598
- return this.client.call('get', uri, apiHeaders, payload);
21902
+ const apiHeaders = {
21903
+ 'content-type': 'application/json',
21904
+ };
21905
+ return this.client.call('patch', uri, apiHeaders, payload);
21599
21906
  }
21600
- createKey(paramsOrFirst, ...rest) {
21907
+ updateSessionAlerts(paramsOrFirst, ...rest) {
21601
21908
  let params;
21602
21909
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21603
21910
  params = (paramsOrFirst || {});
@@ -21605,47 +21912,29 @@
21605
21912
  else {
21606
21913
  params = {
21607
21914
  projectId: paramsOrFirst,
21608
- name: rest[0],
21609
- scopes: rest[1],
21610
- keyId: rest[2],
21611
- expire: rest[3]
21915
+ alerts: rest[0]
21612
21916
  };
21613
21917
  }
21614
21918
  const projectId = params.projectId;
21615
- const name = params.name;
21616
- const scopes = params.scopes;
21617
- const keyId = params.keyId;
21618
- const expire = params.expire;
21919
+ const alerts = params.alerts;
21619
21920
  if (typeof projectId === 'undefined') {
21620
21921
  throw new AppwriteException('Missing required parameter: "projectId"');
21621
21922
  }
21622
- if (typeof name === 'undefined') {
21623
- throw new AppwriteException('Missing required parameter: "name"');
21624
- }
21625
- if (typeof scopes === 'undefined') {
21626
- throw new AppwriteException('Missing required parameter: "scopes"');
21923
+ if (typeof alerts === 'undefined') {
21924
+ throw new AppwriteException('Missing required parameter: "alerts"');
21627
21925
  }
21628
- const apiPath = '/projects/{projectId}/keys'.replace('{projectId}', projectId);
21926
+ const apiPath = '/projects/{projectId}/auth/session-alerts'.replace('{projectId}', projectId);
21629
21927
  const payload = {};
21630
- if (typeof keyId !== 'undefined') {
21631
- payload['keyId'] = keyId;
21632
- }
21633
- if (typeof name !== 'undefined') {
21634
- payload['name'] = name;
21635
- }
21636
- if (typeof scopes !== 'undefined') {
21637
- payload['scopes'] = scopes;
21638
- }
21639
- if (typeof expire !== 'undefined') {
21640
- payload['expire'] = expire;
21928
+ if (typeof alerts !== 'undefined') {
21929
+ payload['alerts'] = alerts;
21641
21930
  }
21642
21931
  const uri = new URL(this.client.config.endpoint + apiPath);
21643
21932
  const apiHeaders = {
21644
21933
  'content-type': 'application/json',
21645
21934
  };
21646
- return this.client.call('post', uri, apiHeaders, payload);
21935
+ return this.client.call('patch', uri, apiHeaders, payload);
21647
21936
  }
21648
- getKey(paramsOrFirst, ...rest) {
21937
+ updateSessionInvalidation(paramsOrFirst, ...rest) {
21649
21938
  let params;
21650
21939
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21651
21940
  params = (paramsOrFirst || {});
@@ -21653,24 +21942,29 @@
21653
21942
  else {
21654
21943
  params = {
21655
21944
  projectId: paramsOrFirst,
21656
- keyId: rest[0]
21945
+ enabled: rest[0]
21657
21946
  };
21658
21947
  }
21659
21948
  const projectId = params.projectId;
21660
- const keyId = params.keyId;
21949
+ const enabled = params.enabled;
21661
21950
  if (typeof projectId === 'undefined') {
21662
21951
  throw new AppwriteException('Missing required parameter: "projectId"');
21663
21952
  }
21664
- if (typeof keyId === 'undefined') {
21665
- throw new AppwriteException('Missing required parameter: "keyId"');
21953
+ if (typeof enabled === 'undefined') {
21954
+ throw new AppwriteException('Missing required parameter: "enabled"');
21666
21955
  }
21667
- const apiPath = '/projects/{projectId}/keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
21956
+ const apiPath = '/projects/{projectId}/auth/session-invalidation'.replace('{projectId}', projectId);
21668
21957
  const payload = {};
21958
+ if (typeof enabled !== 'undefined') {
21959
+ payload['enabled'] = enabled;
21960
+ }
21669
21961
  const uri = new URL(this.client.config.endpoint + apiPath);
21670
- const apiHeaders = {};
21671
- return this.client.call('get', uri, apiHeaders, payload);
21962
+ const apiHeaders = {
21963
+ 'content-type': 'application/json',
21964
+ };
21965
+ return this.client.call('patch', uri, apiHeaders, payload);
21672
21966
  }
21673
- updateKey(paramsOrFirst, ...rest) {
21967
+ updateAuthStatus(paramsOrFirst, ...rest) {
21674
21968
  let params;
21675
21969
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21676
21970
  params = (paramsOrFirst || {});
@@ -21678,74 +21972,56 @@
21678
21972
  else {
21679
21973
  params = {
21680
21974
  projectId: paramsOrFirst,
21681
- keyId: rest[0],
21682
- name: rest[1],
21683
- scopes: rest[2],
21684
- expire: rest[3]
21975
+ method: rest[0],
21976
+ status: rest[1]
21685
21977
  };
21686
21978
  }
21687
21979
  const projectId = params.projectId;
21688
- const keyId = params.keyId;
21689
- const name = params.name;
21690
- const scopes = params.scopes;
21691
- const expire = params.expire;
21980
+ const method = params.method;
21981
+ const status = params.status;
21692
21982
  if (typeof projectId === 'undefined') {
21693
21983
  throw new AppwriteException('Missing required parameter: "projectId"');
21694
21984
  }
21695
- if (typeof keyId === 'undefined') {
21696
- throw new AppwriteException('Missing required parameter: "keyId"');
21697
- }
21698
- if (typeof name === 'undefined') {
21699
- throw new AppwriteException('Missing required parameter: "name"');
21985
+ if (typeof method === 'undefined') {
21986
+ throw new AppwriteException('Missing required parameter: "method"');
21700
21987
  }
21701
- if (typeof scopes === 'undefined') {
21702
- throw new AppwriteException('Missing required parameter: "scopes"');
21988
+ if (typeof status === 'undefined') {
21989
+ throw new AppwriteException('Missing required parameter: "status"');
21703
21990
  }
21704
- const apiPath = '/projects/{projectId}/keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
21991
+ const apiPath = '/projects/{projectId}/auth/{method}'.replace('{projectId}', projectId).replace('{method}', method);
21705
21992
  const payload = {};
21706
- if (typeof name !== 'undefined') {
21707
- payload['name'] = name;
21708
- }
21709
- if (typeof scopes !== 'undefined') {
21710
- payload['scopes'] = scopes;
21711
- }
21712
- if (typeof expire !== 'undefined') {
21713
- payload['expire'] = expire;
21993
+ if (typeof status !== 'undefined') {
21994
+ payload['status'] = status;
21714
21995
  }
21715
21996
  const uri = new URL(this.client.config.endpoint + apiPath);
21716
21997
  const apiHeaders = {
21717
21998
  'content-type': 'application/json',
21718
21999
  };
21719
- return this.client.call('put', uri, apiHeaders, payload);
22000
+ return this.client.call('patch', uri, apiHeaders, payload);
21720
22001
  }
21721
- deleteKey(paramsOrFirst, ...rest) {
22002
+ updateConsoleAccess(paramsOrFirst) {
21722
22003
  let params;
21723
22004
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21724
22005
  params = (paramsOrFirst || {});
21725
22006
  }
21726
22007
  else {
21727
22008
  params = {
21728
- projectId: paramsOrFirst,
21729
- keyId: rest[0]
22009
+ projectId: paramsOrFirst
21730
22010
  };
21731
22011
  }
21732
22012
  const projectId = params.projectId;
21733
- const keyId = params.keyId;
21734
22013
  if (typeof projectId === 'undefined') {
21735
22014
  throw new AppwriteException('Missing required parameter: "projectId"');
21736
22015
  }
21737
- if (typeof keyId === 'undefined') {
21738
- throw new AppwriteException('Missing required parameter: "keyId"');
21739
- }
21740
- const apiPath = '/projects/{projectId}/keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
22016
+ const apiPath = '/projects/{projectId}/console-access'.replace('{projectId}', projectId);
21741
22017
  const payload = {};
21742
22018
  const uri = new URL(this.client.config.endpoint + apiPath);
21743
22019
  const apiHeaders = {
21744
22020
  'content-type': 'application/json',
21745
22021
  };
21746
- return this.client.call('delete', uri, apiHeaders, payload);
22022
+ return this.client.call('patch', uri, apiHeaders, payload);
21747
22023
  }
21748
- updateLabels(paramsOrFirst, ...rest) {
22024
+ listDevKeys(paramsOrFirst, ...rest) {
21749
22025
  let params;
21750
22026
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21751
22027
  params = (paramsOrFirst || {});
@@ -21753,29 +22029,24 @@
21753
22029
  else {
21754
22030
  params = {
21755
22031
  projectId: paramsOrFirst,
21756
- labels: rest[0]
22032
+ queries: rest[0]
21757
22033
  };
21758
22034
  }
21759
22035
  const projectId = params.projectId;
21760
- const labels = params.labels;
22036
+ const queries = params.queries;
21761
22037
  if (typeof projectId === 'undefined') {
21762
22038
  throw new AppwriteException('Missing required parameter: "projectId"');
21763
22039
  }
21764
- if (typeof labels === 'undefined') {
21765
- throw new AppwriteException('Missing required parameter: "labels"');
21766
- }
21767
- const apiPath = '/projects/{projectId}/labels'.replace('{projectId}', projectId);
22040
+ const apiPath = '/projects/{projectId}/dev-keys'.replace('{projectId}', projectId);
21768
22041
  const payload = {};
21769
- if (typeof labels !== 'undefined') {
21770
- payload['labels'] = labels;
22042
+ if (typeof queries !== 'undefined') {
22043
+ payload['queries'] = queries;
21771
22044
  }
21772
22045
  const uri = new URL(this.client.config.endpoint + apiPath);
21773
- const apiHeaders = {
21774
- 'content-type': 'application/json',
21775
- };
21776
- return this.client.call('put', uri, apiHeaders, payload);
22046
+ const apiHeaders = {};
22047
+ return this.client.call('get', uri, apiHeaders, payload);
21777
22048
  }
21778
- updateOAuth2(paramsOrFirst, ...rest) {
22049
+ createDevKey(paramsOrFirst, ...rest) {
21779
22050
  let params;
21780
22051
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21781
22052
  params = (paramsOrFirst || {});
@@ -21783,44 +22054,37 @@
21783
22054
  else {
21784
22055
  params = {
21785
22056
  projectId: paramsOrFirst,
21786
- provider: rest[0],
21787
- appId: rest[1],
21788
- secret: rest[2],
21789
- enabled: rest[3]
22057
+ name: rest[0],
22058
+ expire: rest[1]
21790
22059
  };
21791
22060
  }
21792
22061
  const projectId = params.projectId;
21793
- const provider = params.provider;
21794
- const appId = params.appId;
21795
- const secret = params.secret;
21796
- const enabled = params.enabled;
22062
+ const name = params.name;
22063
+ const expire = params.expire;
21797
22064
  if (typeof projectId === 'undefined') {
21798
22065
  throw new AppwriteException('Missing required parameter: "projectId"');
21799
22066
  }
21800
- if (typeof provider === 'undefined') {
21801
- throw new AppwriteException('Missing required parameter: "provider"');
21802
- }
21803
- const apiPath = '/projects/{projectId}/oauth2'.replace('{projectId}', projectId);
21804
- const payload = {};
21805
- if (typeof provider !== 'undefined') {
21806
- payload['provider'] = provider;
22067
+ if (typeof name === 'undefined') {
22068
+ throw new AppwriteException('Missing required parameter: "name"');
21807
22069
  }
21808
- if (typeof appId !== 'undefined') {
21809
- payload['appId'] = appId;
22070
+ if (typeof expire === 'undefined') {
22071
+ throw new AppwriteException('Missing required parameter: "expire"');
21810
22072
  }
21811
- if (typeof secret !== 'undefined') {
21812
- payload['secret'] = secret;
22073
+ const apiPath = '/projects/{projectId}/dev-keys'.replace('{projectId}', projectId);
22074
+ const payload = {};
22075
+ if (typeof name !== 'undefined') {
22076
+ payload['name'] = name;
21813
22077
  }
21814
- if (typeof enabled !== 'undefined') {
21815
- payload['enabled'] = enabled;
22078
+ if (typeof expire !== 'undefined') {
22079
+ payload['expire'] = expire;
21816
22080
  }
21817
22081
  const uri = new URL(this.client.config.endpoint + apiPath);
21818
22082
  const apiHeaders = {
21819
22083
  'content-type': 'application/json',
21820
22084
  };
21821
- return this.client.call('patch', uri, apiHeaders, payload);
22085
+ return this.client.call('post', uri, apiHeaders, payload);
21822
22086
  }
21823
- listPlatforms(paramsOrFirst, ...rest) {
22087
+ getDevKey(paramsOrFirst, ...rest) {
21824
22088
  let params;
21825
22089
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21826
22090
  params = (paramsOrFirst || {});
@@ -21828,24 +22092,24 @@
21828
22092
  else {
21829
22093
  params = {
21830
22094
  projectId: paramsOrFirst,
21831
- total: rest[0]
22095
+ keyId: rest[0]
21832
22096
  };
21833
22097
  }
21834
22098
  const projectId = params.projectId;
21835
- const total = params.total;
22099
+ const keyId = params.keyId;
21836
22100
  if (typeof projectId === 'undefined') {
21837
22101
  throw new AppwriteException('Missing required parameter: "projectId"');
21838
22102
  }
21839
- const apiPath = '/projects/{projectId}/platforms'.replace('{projectId}', projectId);
21840
- const payload = {};
21841
- if (typeof total !== 'undefined') {
21842
- payload['total'] = total;
22103
+ if (typeof keyId === 'undefined') {
22104
+ throw new AppwriteException('Missing required parameter: "keyId"');
21843
22105
  }
22106
+ const apiPath = '/projects/{projectId}/dev-keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
22107
+ const payload = {};
21844
22108
  const uri = new URL(this.client.config.endpoint + apiPath);
21845
22109
  const apiHeaders = {};
21846
22110
  return this.client.call('get', uri, apiHeaders, payload);
21847
22111
  }
21848
- createPlatform(paramsOrFirst, ...rest) {
22112
+ updateDevKey(paramsOrFirst, ...rest) {
21849
22113
  let params;
21850
22114
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21851
22115
  params = (paramsOrFirst || {});
@@ -21853,52 +22117,42 @@
21853
22117
  else {
21854
22118
  params = {
21855
22119
  projectId: paramsOrFirst,
21856
- type: rest[0],
22120
+ keyId: rest[0],
21857
22121
  name: rest[1],
21858
- key: rest[2],
21859
- store: rest[3],
21860
- hostname: rest[4]
22122
+ expire: rest[2]
21861
22123
  };
21862
22124
  }
21863
22125
  const projectId = params.projectId;
21864
- const type = params.type;
22126
+ const keyId = params.keyId;
21865
22127
  const name = params.name;
21866
- const key = params.key;
21867
- const store = params.store;
21868
- const hostname = params.hostname;
22128
+ const expire = params.expire;
21869
22129
  if (typeof projectId === 'undefined') {
21870
22130
  throw new AppwriteException('Missing required parameter: "projectId"');
21871
22131
  }
21872
- if (typeof type === 'undefined') {
21873
- throw new AppwriteException('Missing required parameter: "type"');
22132
+ if (typeof keyId === 'undefined') {
22133
+ throw new AppwriteException('Missing required parameter: "keyId"');
21874
22134
  }
21875
22135
  if (typeof name === 'undefined') {
21876
22136
  throw new AppwriteException('Missing required parameter: "name"');
21877
22137
  }
21878
- const apiPath = '/projects/{projectId}/platforms'.replace('{projectId}', projectId);
21879
- const payload = {};
21880
- if (typeof type !== 'undefined') {
21881
- payload['type'] = type;
22138
+ if (typeof expire === 'undefined') {
22139
+ throw new AppwriteException('Missing required parameter: "expire"');
21882
22140
  }
22141
+ const apiPath = '/projects/{projectId}/dev-keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
22142
+ const payload = {};
21883
22143
  if (typeof name !== 'undefined') {
21884
22144
  payload['name'] = name;
21885
22145
  }
21886
- if (typeof key !== 'undefined') {
21887
- payload['key'] = key;
21888
- }
21889
- if (typeof store !== 'undefined') {
21890
- payload['store'] = store;
21891
- }
21892
- if (typeof hostname !== 'undefined') {
21893
- payload['hostname'] = hostname;
22146
+ if (typeof expire !== 'undefined') {
22147
+ payload['expire'] = expire;
21894
22148
  }
21895
22149
  const uri = new URL(this.client.config.endpoint + apiPath);
21896
22150
  const apiHeaders = {
21897
22151
  'content-type': 'application/json',
21898
22152
  };
21899
- return this.client.call('post', uri, apiHeaders, payload);
22153
+ return this.client.call('put', uri, apiHeaders, payload);
21900
22154
  }
21901
- getPlatform(paramsOrFirst, ...rest) {
22155
+ deleteDevKey(paramsOrFirst, ...rest) {
21902
22156
  let params;
21903
22157
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21904
22158
  params = (paramsOrFirst || {});
@@ -21906,24 +22160,26 @@
21906
22160
  else {
21907
22161
  params = {
21908
22162
  projectId: paramsOrFirst,
21909
- platformId: rest[0]
22163
+ keyId: rest[0]
21910
22164
  };
21911
22165
  }
21912
22166
  const projectId = params.projectId;
21913
- const platformId = params.platformId;
22167
+ const keyId = params.keyId;
21914
22168
  if (typeof projectId === 'undefined') {
21915
22169
  throw new AppwriteException('Missing required parameter: "projectId"');
21916
22170
  }
21917
- if (typeof platformId === 'undefined') {
21918
- throw new AppwriteException('Missing required parameter: "platformId"');
22171
+ if (typeof keyId === 'undefined') {
22172
+ throw new AppwriteException('Missing required parameter: "keyId"');
21919
22173
  }
21920
- const apiPath = '/projects/{projectId}/platforms/{platformId}'.replace('{projectId}', projectId).replace('{platformId}', platformId);
22174
+ const apiPath = '/projects/{projectId}/dev-keys/{keyId}'.replace('{projectId}', projectId).replace('{keyId}', keyId);
21921
22175
  const payload = {};
21922
22176
  const uri = new URL(this.client.config.endpoint + apiPath);
21923
- const apiHeaders = {};
21924
- return this.client.call('get', uri, apiHeaders, payload);
22177
+ const apiHeaders = {
22178
+ 'content-type': 'application/json',
22179
+ };
22180
+ return this.client.call('delete', uri, apiHeaders, payload);
21925
22181
  }
21926
- updatePlatform(paramsOrFirst, ...rest) {
22182
+ createJWT(paramsOrFirst, ...rest) {
21927
22183
  let params;
21928
22184
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21929
22185
  params = (paramsOrFirst || {});
@@ -21931,49 +22187,34 @@
21931
22187
  else {
21932
22188
  params = {
21933
22189
  projectId: paramsOrFirst,
21934
- platformId: rest[0],
21935
- name: rest[1],
21936
- key: rest[2],
21937
- store: rest[3],
21938
- hostname: rest[4]
22190
+ scopes: rest[0],
22191
+ duration: rest[1]
21939
22192
  };
21940
22193
  }
21941
22194
  const projectId = params.projectId;
21942
- const platformId = params.platformId;
21943
- const name = params.name;
21944
- const key = params.key;
21945
- const store = params.store;
21946
- const hostname = params.hostname;
22195
+ const scopes = params.scopes;
22196
+ const duration = params.duration;
21947
22197
  if (typeof projectId === 'undefined') {
21948
22198
  throw new AppwriteException('Missing required parameter: "projectId"');
21949
22199
  }
21950
- if (typeof platformId === 'undefined') {
21951
- throw new AppwriteException('Missing required parameter: "platformId"');
21952
- }
21953
- if (typeof name === 'undefined') {
21954
- throw new AppwriteException('Missing required parameter: "name"');
22200
+ if (typeof scopes === 'undefined') {
22201
+ throw new AppwriteException('Missing required parameter: "scopes"');
21955
22202
  }
21956
- const apiPath = '/projects/{projectId}/platforms/{platformId}'.replace('{projectId}', projectId).replace('{platformId}', platformId);
22203
+ const apiPath = '/projects/{projectId}/jwts'.replace('{projectId}', projectId);
21957
22204
  const payload = {};
21958
- if (typeof name !== 'undefined') {
21959
- payload['name'] = name;
21960
- }
21961
- if (typeof key !== 'undefined') {
21962
- payload['key'] = key;
21963
- }
21964
- if (typeof store !== 'undefined') {
21965
- payload['store'] = store;
22205
+ if (typeof scopes !== 'undefined') {
22206
+ payload['scopes'] = scopes;
21966
22207
  }
21967
- if (typeof hostname !== 'undefined') {
21968
- payload['hostname'] = hostname;
22208
+ if (typeof duration !== 'undefined') {
22209
+ payload['duration'] = duration;
21969
22210
  }
21970
22211
  const uri = new URL(this.client.config.endpoint + apiPath);
21971
22212
  const apiHeaders = {
21972
22213
  'content-type': 'application/json',
21973
22214
  };
21974
- return this.client.call('put', uri, apiHeaders, payload);
22215
+ return this.client.call('post', uri, apiHeaders, payload);
21975
22216
  }
21976
- deletePlatform(paramsOrFirst, ...rest) {
22217
+ updateOAuth2(paramsOrFirst, ...rest) {
21977
22218
  let params;
21978
22219
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
21979
22220
  params = (paramsOrFirst || {});
@@ -21981,24 +22222,42 @@
21981
22222
  else {
21982
22223
  params = {
21983
22224
  projectId: paramsOrFirst,
21984
- platformId: rest[0]
22225
+ provider: rest[0],
22226
+ appId: rest[1],
22227
+ secret: rest[2],
22228
+ enabled: rest[3]
21985
22229
  };
21986
22230
  }
21987
22231
  const projectId = params.projectId;
21988
- const platformId = params.platformId;
22232
+ const provider = params.provider;
22233
+ const appId = params.appId;
22234
+ const secret = params.secret;
22235
+ const enabled = params.enabled;
21989
22236
  if (typeof projectId === 'undefined') {
21990
22237
  throw new AppwriteException('Missing required parameter: "projectId"');
21991
22238
  }
21992
- if (typeof platformId === 'undefined') {
21993
- throw new AppwriteException('Missing required parameter: "platformId"');
22239
+ if (typeof provider === 'undefined') {
22240
+ throw new AppwriteException('Missing required parameter: "provider"');
21994
22241
  }
21995
- const apiPath = '/projects/{projectId}/platforms/{platformId}'.replace('{projectId}', projectId).replace('{platformId}', platformId);
22242
+ const apiPath = '/projects/{projectId}/oauth2'.replace('{projectId}', projectId);
21996
22243
  const payload = {};
22244
+ if (typeof provider !== 'undefined') {
22245
+ payload['provider'] = provider;
22246
+ }
22247
+ if (typeof appId !== 'undefined') {
22248
+ payload['appId'] = appId;
22249
+ }
22250
+ if (typeof secret !== 'undefined') {
22251
+ payload['secret'] = secret;
22252
+ }
22253
+ if (typeof enabled !== 'undefined') {
22254
+ payload['enabled'] = enabled;
22255
+ }
21997
22256
  const uri = new URL(this.client.config.endpoint + apiPath);
21998
22257
  const apiHeaders = {
21999
22258
  'content-type': 'application/json',
22000
22259
  };
22001
- return this.client.call('delete', uri, apiHeaders, payload);
22260
+ return this.client.call('patch', uri, apiHeaders, payload);
22002
22261
  }
22003
22262
  listSchedules(paramsOrFirst, ...rest) {
22004
22263
  let params;
@@ -22111,74 +22370,6 @@
22111
22370
  const apiHeaders = {};
22112
22371
  return this.client.call('get', uri, apiHeaders, payload);
22113
22372
  }
22114
- updateServiceStatus(paramsOrFirst, ...rest) {
22115
- let params;
22116
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
22117
- params = (paramsOrFirst || {});
22118
- }
22119
- else {
22120
- params = {
22121
- projectId: paramsOrFirst,
22122
- service: rest[0],
22123
- status: rest[1]
22124
- };
22125
- }
22126
- const projectId = params.projectId;
22127
- const service = params.service;
22128
- const status = params.status;
22129
- if (typeof projectId === 'undefined') {
22130
- throw new AppwriteException('Missing required parameter: "projectId"');
22131
- }
22132
- if (typeof service === 'undefined') {
22133
- throw new AppwriteException('Missing required parameter: "service"');
22134
- }
22135
- if (typeof status === 'undefined') {
22136
- throw new AppwriteException('Missing required parameter: "status"');
22137
- }
22138
- const apiPath = '/projects/{projectId}/service'.replace('{projectId}', projectId);
22139
- const payload = {};
22140
- if (typeof service !== 'undefined') {
22141
- payload['service'] = service;
22142
- }
22143
- if (typeof status !== 'undefined') {
22144
- payload['status'] = status;
22145
- }
22146
- const uri = new URL(this.client.config.endpoint + apiPath);
22147
- const apiHeaders = {
22148
- 'content-type': 'application/json',
22149
- };
22150
- return this.client.call('patch', uri, apiHeaders, payload);
22151
- }
22152
- updateServiceStatusAll(paramsOrFirst, ...rest) {
22153
- let params;
22154
- if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
22155
- params = (paramsOrFirst || {});
22156
- }
22157
- else {
22158
- params = {
22159
- projectId: paramsOrFirst,
22160
- status: rest[0]
22161
- };
22162
- }
22163
- const projectId = params.projectId;
22164
- const status = params.status;
22165
- if (typeof projectId === 'undefined') {
22166
- throw new AppwriteException('Missing required parameter: "projectId"');
22167
- }
22168
- if (typeof status === 'undefined') {
22169
- throw new AppwriteException('Missing required parameter: "status"');
22170
- }
22171
- const apiPath = '/projects/{projectId}/service/all'.replace('{projectId}', projectId);
22172
- const payload = {};
22173
- if (typeof status !== 'undefined') {
22174
- payload['status'] = status;
22175
- }
22176
- const uri = new URL(this.client.config.endpoint + apiPath);
22177
- const apiHeaders = {
22178
- 'content-type': 'application/json',
22179
- };
22180
- return this.client.call('patch', uri, apiHeaders, payload);
22181
- }
22182
22373
  updateSmtp(paramsOrFirst, ...rest) {
22183
22374
  let params;
22184
22375
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
@@ -25248,7 +25439,8 @@
25248
25439
  name: rest[1],
25249
25440
  permissions: rest[2],
25250
25441
  rowSecurity: rest[3],
25251
- enabled: rest[4]
25442
+ enabled: rest[4],
25443
+ purge: rest[5]
25252
25444
  };
25253
25445
  }
25254
25446
  const databaseId = params.databaseId;
@@ -25257,6 +25449,7 @@
25257
25449
  const permissions = params.permissions;
25258
25450
  const rowSecurity = params.rowSecurity;
25259
25451
  const enabled = params.enabled;
25452
+ const purge = params.purge;
25260
25453
  if (typeof databaseId === 'undefined') {
25261
25454
  throw new AppwriteException('Missing required parameter: "databaseId"');
25262
25455
  }
@@ -25277,6 +25470,9 @@
25277
25470
  if (typeof enabled !== 'undefined') {
25278
25471
  payload['enabled'] = enabled;
25279
25472
  }
25473
+ if (typeof purge !== 'undefined') {
25474
+ payload['purge'] = purge;
25475
+ }
25280
25476
  const uri = new URL(this.client.config.endpoint + apiPath);
25281
25477
  const apiHeaders = {
25282
25478
  'content-type': 'application/json',
@@ -30642,9 +30838,10 @@
30642
30838
  name: rest[1],
30643
30839
  events: rest[2],
30644
30840
  enabled: rest[3],
30645
- security: rest[4],
30646
- httpUser: rest[5],
30647
- httpPass: rest[6]
30841
+ tls: rest[4],
30842
+ authUsername: rest[5],
30843
+ authPassword: rest[6],
30844
+ secret: rest[7]
30648
30845
  };
30649
30846
  }
30650
30847
  const webhookId = params.webhookId;
@@ -30652,9 +30849,10 @@
30652
30849
  const name = params.name;
30653
30850
  const events = params.events;
30654
30851
  const enabled = params.enabled;
30655
- const security = params.security;
30656
- const httpUser = params.httpUser;
30657
- const httpPass = params.httpPass;
30852
+ const tls = params.tls;
30853
+ const authUsername = params.authUsername;
30854
+ const authPassword = params.authPassword;
30855
+ const secret = params.secret;
30658
30856
  if (typeof webhookId === 'undefined') {
30659
30857
  throw new AppwriteException('Missing required parameter: "webhookId"');
30660
30858
  }
@@ -30684,14 +30882,17 @@
30684
30882
  if (typeof enabled !== 'undefined') {
30685
30883
  payload['enabled'] = enabled;
30686
30884
  }
30687
- if (typeof security !== 'undefined') {
30688
- payload['security'] = security;
30885
+ if (typeof tls !== 'undefined') {
30886
+ payload['tls'] = tls;
30887
+ }
30888
+ if (typeof authUsername !== 'undefined') {
30889
+ payload['authUsername'] = authUsername;
30689
30890
  }
30690
- if (typeof httpUser !== 'undefined') {
30691
- payload['httpUser'] = httpUser;
30891
+ if (typeof authPassword !== 'undefined') {
30892
+ payload['authPassword'] = authPassword;
30692
30893
  }
30693
- if (typeof httpPass !== 'undefined') {
30694
- payload['httpPass'] = httpPass;
30894
+ if (typeof secret !== 'undefined') {
30895
+ payload['secret'] = secret;
30695
30896
  }
30696
30897
  const uri = new URL(this.client.config.endpoint + apiPath);
30697
30898
  const apiHeaders = {
@@ -30731,9 +30932,9 @@
30731
30932
  url: rest[1],
30732
30933
  events: rest[2],
30733
30934
  enabled: rest[3],
30734
- security: rest[4],
30735
- httpUser: rest[5],
30736
- httpPass: rest[6]
30935
+ tls: rest[4],
30936
+ authUsername: rest[5],
30937
+ authPassword: rest[6]
30737
30938
  };
30738
30939
  }
30739
30940
  const webhookId = params.webhookId;
@@ -30741,9 +30942,9 @@
30741
30942
  const url = params.url;
30742
30943
  const events = params.events;
30743
30944
  const enabled = params.enabled;
30744
- const security = params.security;
30745
- const httpUser = params.httpUser;
30746
- const httpPass = params.httpPass;
30945
+ const tls = params.tls;
30946
+ const authUsername = params.authUsername;
30947
+ const authPassword = params.authPassword;
30747
30948
  if (typeof webhookId === 'undefined') {
30748
30949
  throw new AppwriteException('Missing required parameter: "webhookId"');
30749
30950
  }
@@ -30770,14 +30971,14 @@
30770
30971
  if (typeof enabled !== 'undefined') {
30771
30972
  payload['enabled'] = enabled;
30772
30973
  }
30773
- if (typeof security !== 'undefined') {
30774
- payload['security'] = security;
30974
+ if (typeof tls !== 'undefined') {
30975
+ payload['tls'] = tls;
30775
30976
  }
30776
- if (typeof httpUser !== 'undefined') {
30777
- payload['httpUser'] = httpUser;
30977
+ if (typeof authUsername !== 'undefined') {
30978
+ payload['authUsername'] = authUsername;
30778
30979
  }
30779
- if (typeof httpPass !== 'undefined') {
30780
- payload['httpPass'] = httpPass;
30980
+ if (typeof authPassword !== 'undefined') {
30981
+ payload['authPassword'] = authPassword;
30781
30982
  }
30782
30983
  const uri = new URL(this.client.config.endpoint + apiPath);
30783
30984
  const apiHeaders = {
@@ -30807,22 +31008,27 @@
30807
31008
  };
30808
31009
  return this.client.call('delete', uri, apiHeaders, payload);
30809
31010
  }
30810
- updateSignature(paramsOrFirst) {
31011
+ updateSecret(paramsOrFirst, ...rest) {
30811
31012
  let params;
30812
31013
  if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
30813
31014
  params = (paramsOrFirst || {});
30814
31015
  }
30815
31016
  else {
30816
31017
  params = {
30817
- webhookId: paramsOrFirst
31018
+ webhookId: paramsOrFirst,
31019
+ secret: rest[0]
30818
31020
  };
30819
31021
  }
30820
31022
  const webhookId = params.webhookId;
31023
+ const secret = params.secret;
30821
31024
  if (typeof webhookId === 'undefined') {
30822
31025
  throw new AppwriteException('Missing required parameter: "webhookId"');
30823
31026
  }
30824
- const apiPath = '/webhooks/{webhookId}/signature'.replace('{webhookId}', webhookId);
31027
+ const apiPath = '/webhooks/{webhookId}/secret'.replace('{webhookId}', webhookId);
30825
31028
  const payload = {};
31029
+ if (typeof secret !== 'undefined') {
31030
+ payload['secret'] = secret;
31031
+ }
30826
31032
  const uri = new URL(this.client.config.endpoint + apiPath);
30827
31033
  const apiHeaders = {
30828
31034
  'content-type': 'application/json',
@@ -31855,6 +32061,10 @@
31855
32061
  Scopes["WebhooksWrite"] = "webhooks.write";
31856
32062
  Scopes["ProjectRead"] = "project.read";
31857
32063
  Scopes["ProjectWrite"] = "project.write";
32064
+ Scopes["KeysRead"] = "keys.read";
32065
+ Scopes["KeysWrite"] = "keys.write";
32066
+ Scopes["PlatformsRead"] = "platforms.read";
32067
+ Scopes["PlatformsWrite"] = "platforms.write";
31858
32068
  Scopes["PoliciesWrite"] = "policies.write";
31859
32069
  Scopes["PoliciesRead"] = "policies.read";
31860
32070
  Scopes["ArchivesRead"] = "archives.read";
@@ -31864,12 +32074,8 @@
31864
32074
  Scopes["DomainsRead"] = "domains.read";
31865
32075
  Scopes["DomainsWrite"] = "domains.write";
31866
32076
  Scopes["EventsRead"] = "events.read";
31867
- Scopes["PlatformsRead"] = "platforms.read";
31868
- Scopes["PlatformsWrite"] = "platforms.write";
31869
32077
  Scopes["ProjectsRead"] = "projects.read";
31870
32078
  Scopes["ProjectsWrite"] = "projects.write";
31871
- Scopes["KeysRead"] = "keys.read";
31872
- Scopes["KeysWrite"] = "keys.write";
31873
32079
  Scopes["DevKeysRead"] = "devKeys.read";
31874
32080
  Scopes["DevKeysWrite"] = "devKeys.write";
31875
32081
  })(exports.Scopes || (exports.Scopes = {}));
@@ -31923,6 +32129,7 @@
31923
32129
  OAuthProvider["TradeshiftBox"] = "tradeshiftBox";
31924
32130
  OAuthProvider["Twitch"] = "twitch";
31925
32131
  OAuthProvider["Wordpress"] = "wordpress";
32132
+ OAuthProvider["X"] = "x";
31926
32133
  OAuthProvider["Yahoo"] = "yahoo";
31927
32134
  OAuthProvider["Yammer"] = "yammer";
31928
32135
  OAuthProvider["Yandex"] = "yandex";
@@ -33044,6 +33251,34 @@
33044
33251
  Addon["Baa"] = "baa";
33045
33252
  })(exports.Addon || (exports.Addon = {}));
33046
33253
 
33254
+ exports.ProtocolId = void 0;
33255
+ (function (ProtocolId) {
33256
+ ProtocolId["Rest"] = "rest";
33257
+ ProtocolId["Graphql"] = "graphql";
33258
+ ProtocolId["Websocket"] = "websocket";
33259
+ })(exports.ProtocolId || (exports.ProtocolId = {}));
33260
+
33261
+ exports.ServiceId = void 0;
33262
+ (function (ServiceId) {
33263
+ ServiceId["Account"] = "account";
33264
+ ServiceId["Avatars"] = "avatars";
33265
+ ServiceId["Databases"] = "databases";
33266
+ ServiceId["Tablesdb"] = "tablesdb";
33267
+ ServiceId["Locale"] = "locale";
33268
+ ServiceId["Health"] = "health";
33269
+ ServiceId["Project"] = "project";
33270
+ ServiceId["Storage"] = "storage";
33271
+ ServiceId["Teams"] = "teams";
33272
+ ServiceId["Users"] = "users";
33273
+ ServiceId["Vcs"] = "vcs";
33274
+ ServiceId["Sites"] = "sites";
33275
+ ServiceId["Functions"] = "functions";
33276
+ ServiceId["Proxy"] = "proxy";
33277
+ ServiceId["Graphql"] = "graphql";
33278
+ ServiceId["Migrations"] = "migrations";
33279
+ ServiceId["Messaging"] = "messaging";
33280
+ })(exports.ServiceId || (exports.ServiceId = {}));
33281
+
33047
33282
  exports.ProjectUsageRange = void 0;
33048
33283
  (function (ProjectUsageRange) {
33049
33284
  ProjectUsageRange["OneHour"] = "1h";
@@ -33060,13 +33295,6 @@
33060
33295
  Region["Tor"] = "tor";
33061
33296
  })(exports.Region || (exports.Region = {}));
33062
33297
 
33063
- exports.Api = void 0;
33064
- (function (Api) {
33065
- Api["Rest"] = "rest";
33066
- Api["Graphql"] = "graphql";
33067
- Api["Realtime"] = "realtime";
33068
- })(exports.Api || (exports.Api = {}));
33069
-
33070
33298
  exports.AuthMethod = void 0;
33071
33299
  (function (AuthMethod) {
33072
33300
  AuthMethod["Emailpassword"] = "email-password";
@@ -33078,25 +33306,6 @@
33078
33306
  AuthMethod["Phone"] = "phone";
33079
33307
  })(exports.AuthMethod || (exports.AuthMethod = {}));
33080
33308
 
33081
- exports.PlatformType = void 0;
33082
- (function (PlatformType) {
33083
- PlatformType["Web"] = "web";
33084
- PlatformType["Flutterweb"] = "flutter-web";
33085
- PlatformType["Flutterios"] = "flutter-ios";
33086
- PlatformType["Flutterandroid"] = "flutter-android";
33087
- PlatformType["Flutterlinux"] = "flutter-linux";
33088
- PlatformType["Fluttermacos"] = "flutter-macos";
33089
- PlatformType["Flutterwindows"] = "flutter-windows";
33090
- PlatformType["Appleios"] = "apple-ios";
33091
- PlatformType["Applemacos"] = "apple-macos";
33092
- PlatformType["Applewatchos"] = "apple-watchos";
33093
- PlatformType["Appletvos"] = "apple-tvos";
33094
- PlatformType["Android"] = "android";
33095
- PlatformType["Unity"] = "unity";
33096
- PlatformType["Reactnativeios"] = "react-native-ios";
33097
- PlatformType["Reactnativeandroid"] = "react-native-android";
33098
- })(exports.PlatformType || (exports.PlatformType = {}));
33099
-
33100
33309
  exports.ResourceType = void 0;
33101
33310
  (function (ResourceType) {
33102
33311
  ResourceType["Function"] = "function";
@@ -33105,23 +33314,6 @@
33105
33314
  ResourceType["Backup"] = "backup";
33106
33315
  })(exports.ResourceType || (exports.ResourceType = {}));
33107
33316
 
33108
- exports.ApiService = void 0;
33109
- (function (ApiService) {
33110
- ApiService["Account"] = "account";
33111
- ApiService["Avatars"] = "avatars";
33112
- ApiService["Databases"] = "databases";
33113
- ApiService["Tablesdb"] = "tablesdb";
33114
- ApiService["Locale"] = "locale";
33115
- ApiService["Health"] = "health";
33116
- ApiService["Storage"] = "storage";
33117
- ApiService["Teams"] = "teams";
33118
- ApiService["Users"] = "users";
33119
- ApiService["Sites"] = "sites";
33120
- ApiService["Functions"] = "functions";
33121
- ApiService["Graphql"] = "graphql";
33122
- ApiService["Messaging"] = "messaging";
33123
- })(exports.ApiService || (exports.ApiService = {}));
33124
-
33125
33317
  exports.SMTPSecure = void 0;
33126
33318
  (function (SMTPSecure) {
33127
33319
  SMTPSecure["Tls"] = "tls";
@@ -33689,6 +33881,15 @@
33689
33881
  ExecutionStatus["Scheduled"] = "scheduled";
33690
33882
  })(exports.ExecutionStatus || (exports.ExecutionStatus = {}));
33691
33883
 
33884
+ exports.PlatformType = void 0;
33885
+ (function (PlatformType) {
33886
+ PlatformType["Windows"] = "windows";
33887
+ PlatformType["Apple"] = "apple";
33888
+ PlatformType["Android"] = "android";
33889
+ PlatformType["Linux"] = "linux";
33890
+ PlatformType["Web"] = "web";
33891
+ })(exports.PlatformType || (exports.PlatformType = {}));
33892
+
33692
33893
  exports.HealthAntivirusStatus = void 0;
33693
33894
  (function (HealthAntivirusStatus) {
33694
33895
  HealthAntivirusStatus["Disabled"] = "disabled";