@appwrite.io/console 15.0.0 → 15.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/esm/sdk.js CHANGED
@@ -620,7 +620,7 @@ class Client {
620
620
  'x-sdk-name': 'Console',
621
621
  'x-sdk-platform': 'console',
622
622
  'x-sdk-language': 'web',
623
- 'x-sdk-version': '15.0.0',
623
+ 'x-sdk-version': '15.1.0',
624
624
  'X-Appwrite-Response-Format': '1.9.5',
625
625
  };
626
626
  this.realtime = {
@@ -5928,7 +5928,7 @@ class Compute {
5928
5928
  if (typeof sql === 'undefined') {
5929
5929
  throw new AppwriteException('Missing required parameter: "sql"');
5930
5930
  }
5931
- const apiPath = '/compute/databases/{databaseId}/execution'.replace('{databaseId}', encodeURIComponent(String(databaseId)));
5931
+ const apiPath = '/compute/databases/{databaseId}/executions'.replace('{databaseId}', encodeURIComponent(String(databaseId)));
5932
5932
  const payload = {};
5933
5933
  if (typeof sql !== 'undefined') {
5934
5934
  payload['sql'] = sql;
@@ -20333,7 +20333,8 @@ class Oauth2 {
20333
20333
  codeChallengeMethod: rest[6],
20334
20334
  prompt: rest[7],
20335
20335
  maxAge: rest[8],
20336
- authorizationDetails: rest[9]
20336
+ authorizationDetails: rest[9],
20337
+ resource: rest[10]
20337
20338
  };
20338
20339
  }
20339
20340
  const clientId = params.clientId;
@@ -20347,6 +20348,7 @@ class Oauth2 {
20347
20348
  const prompt = params.prompt;
20348
20349
  const maxAge = params.maxAge;
20349
20350
  const authorizationDetails = params.authorizationDetails;
20351
+ const resource = params.resource;
20350
20352
  if (typeof clientId === 'undefined') {
20351
20353
  throw new AppwriteException('Missing required parameter: "clientId"');
20352
20354
  }
@@ -20394,6 +20396,9 @@ class Oauth2 {
20394
20396
  if (typeof authorizationDetails !== 'undefined') {
20395
20397
  payload['authorization_details'] = authorizationDetails;
20396
20398
  }
20399
+ if (typeof resource !== 'undefined') {
20400
+ payload['resource'] = resource;
20401
+ }
20397
20402
  const uri = new URL(this.client.config.endpoint + apiPath);
20398
20403
  const apiHeaders = {
20399
20404
  'accept': 'application/json',
@@ -20409,12 +20414,14 @@ class Oauth2 {
20409
20414
  params = {
20410
20415
  clientId: paramsOrFirst,
20411
20416
  scope: rest[0],
20412
- authorizationDetails: rest[1]
20417
+ authorizationDetails: rest[1],
20418
+ resource: rest[2]
20413
20419
  };
20414
20420
  }
20415
20421
  const clientId = params.clientId;
20416
20422
  const scope = params.scope;
20417
20423
  const authorizationDetails = params.authorizationDetails;
20424
+ const resource = params.resource;
20418
20425
  const apiPath = '/oauth2/{project_id}/device_authorization'.replace('{project_id}', encodeURIComponent(String(this.client.config.project)));
20419
20426
  const payload = {};
20420
20427
  if (typeof clientId !== 'undefined') {
@@ -20426,6 +20433,9 @@ class Oauth2 {
20426
20433
  if (typeof authorizationDetails !== 'undefined') {
20427
20434
  payload['authorization_details'] = authorizationDetails;
20428
20435
  }
20436
+ if (typeof resource !== 'undefined') {
20437
+ payload['resource'] = resource;
20438
+ }
20429
20439
  const uri = new URL(this.client.config.endpoint + apiPath);
20430
20440
  const apiHeaders = {
20431
20441
  'content-type': 'application/json',
@@ -20609,7 +20619,8 @@ class Oauth2 {
20609
20619
  clientId: rest[3],
20610
20620
  clientSecret: rest[4],
20611
20621
  codeVerifier: rest[5],
20612
- redirectUri: rest[6]
20622
+ redirectUri: rest[6],
20623
+ resource: rest[7]
20613
20624
  };
20614
20625
  }
20615
20626
  const grantType = params.grantType;
@@ -20620,6 +20631,7 @@ class Oauth2 {
20620
20631
  const clientSecret = params.clientSecret;
20621
20632
  const codeVerifier = params.codeVerifier;
20622
20633
  const redirectUri = params.redirectUri;
20634
+ const resource = params.resource;
20623
20635
  if (typeof grantType === 'undefined') {
20624
20636
  throw new AppwriteException('Missing required parameter: "grantType"');
20625
20637
  }
@@ -20649,6 +20661,9 @@ class Oauth2 {
20649
20661
  if (typeof redirectUri !== 'undefined') {
20650
20662
  payload['redirect_uri'] = redirectUri;
20651
20663
  }
20664
+ if (typeof resource !== 'undefined') {
20665
+ payload['resource'] = resource;
20666
+ }
20652
20667
  const uri = new URL(this.client.config.endpoint + apiPath);
20653
20668
  const apiHeaders = {
20654
20669
  'content-type': 'application/json',
@@ -32976,7 +32991,7 @@ class Usage {
32976
32991
  }
32977
32992
  else {
32978
32993
  params = {
32979
- metric: paramsOrFirst,
32994
+ metrics: paramsOrFirst,
32980
32995
  resource: rest[0],
32981
32996
  resourceId: rest[1],
32982
32997
  interval: rest[2],
@@ -32989,7 +33004,7 @@ class Usage {
32989
33004
  offset: rest[9]
32990
33005
  };
32991
33006
  }
32992
- const metric = params.metric;
33007
+ const metrics = params.metrics;
32993
33008
  const resource = params.resource;
32994
33009
  const resourceId = params.resourceId;
32995
33010
  const interval = params.interval;
@@ -33000,13 +33015,13 @@ class Usage {
33000
33015
  const orderDir = params.orderDir;
33001
33016
  const limit = params.limit;
33002
33017
  const offset = params.offset;
33003
- if (typeof metric === 'undefined') {
33004
- throw new AppwriteException('Missing required parameter: "metric"');
33018
+ if (typeof metrics === 'undefined') {
33019
+ throw new AppwriteException('Missing required parameter: "metrics"');
33005
33020
  }
33006
33021
  const apiPath = '/usage/events';
33007
33022
  const payload = {};
33008
- if (typeof metric !== 'undefined') {
33009
- payload['metric'] = metric;
33023
+ if (typeof metrics !== 'undefined') {
33024
+ payload['metrics'] = metrics;
33010
33025
  }
33011
33026
  if (typeof resource !== 'undefined') {
33012
33027
  payload['resource'] = resource;
@@ -33052,7 +33067,7 @@ class Usage {
33052
33067
  }
33053
33068
  else {
33054
33069
  params = {
33055
- metric: paramsOrFirst,
33070
+ metrics: paramsOrFirst,
33056
33071
  resourceId: rest[0],
33057
33072
  teamId: rest[1],
33058
33073
  interval: rest[2],
@@ -33065,7 +33080,7 @@ class Usage {
33065
33080
  offset: rest[9]
33066
33081
  };
33067
33082
  }
33068
- const metric = params.metric;
33083
+ const metrics = params.metrics;
33069
33084
  const resourceId = params.resourceId;
33070
33085
  const teamId = params.teamId;
33071
33086
  const interval = params.interval;
@@ -33076,13 +33091,13 @@ class Usage {
33076
33091
  const orderDir = params.orderDir;
33077
33092
  const limit = params.limit;
33078
33093
  const offset = params.offset;
33079
- if (typeof metric === 'undefined') {
33080
- throw new AppwriteException('Missing required parameter: "metric"');
33094
+ if (typeof metrics === 'undefined') {
33095
+ throw new AppwriteException('Missing required parameter: "metrics"');
33081
33096
  }
33082
33097
  const apiPath = '/usage/gauges';
33083
33098
  const payload = {};
33084
- if (typeof metric !== 'undefined') {
33085
- payload['metric'] = metric;
33099
+ if (typeof metrics !== 'undefined') {
33100
+ payload['metrics'] = metrics;
33086
33101
  }
33087
33102
  if (typeof resourceId !== 'undefined') {
33088
33103
  payload['resourceId'] = resourceId;