@appwrite.io/console 15.6.0 → 15.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/cjs/sdk.js +237 -33
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +237 -33
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +237 -33
- package/package.json +2 -2
- package/types/enums/build-runtime.d.ts +1 -0
- package/types/enums/runtime.d.ts +1 -0
- package/types/models.d.ts +152 -15
- package/types/services/backups.d.ts +6 -6
- package/types/services/documents-db.d.ts +13 -4
- package/types/services/mongo.d.ts +3 -6
- package/types/services/mysql.d.ts +5 -8
- package/types/services/postgresql.d.ts +5 -8
- package/types/services/project.d.ts +10 -10
- package/types/services/storage.d.ts +4 -1
- package/types/services/tables-db.d.ts +13 -4
- package/types/services/vectors-db.d.ts +13 -4
- package/types/services/waf.d.ts +126 -18
package/dist/iife/sdk.js
CHANGED
|
@@ -4445,7 +4445,7 @@
|
|
|
4445
4445
|
'x-sdk-name': 'Console',
|
|
4446
4446
|
'x-sdk-platform': 'console',
|
|
4447
4447
|
'x-sdk-language': 'web',
|
|
4448
|
-
'x-sdk-version': '15.
|
|
4448
|
+
'x-sdk-version': '15.8.0',
|
|
4449
4449
|
'X-Appwrite-Response-Format': '1.9.5',
|
|
4450
4450
|
};
|
|
4451
4451
|
this.realtime = {
|
|
@@ -13315,7 +13315,8 @@
|
|
|
13315
13315
|
name: rest[0],
|
|
13316
13316
|
enabled: rest[1],
|
|
13317
13317
|
specification: rest[2],
|
|
13318
|
-
replicas: rest[3]
|
|
13318
|
+
replicas: rest[3],
|
|
13319
|
+
syncMode: rest[4]
|
|
13319
13320
|
};
|
|
13320
13321
|
}
|
|
13321
13322
|
const databaseId = params.databaseId;
|
|
@@ -13323,6 +13324,7 @@
|
|
|
13323
13324
|
const enabled = params.enabled;
|
|
13324
13325
|
const specification = params.specification;
|
|
13325
13326
|
const replicas = params.replicas;
|
|
13327
|
+
const syncMode = params.syncMode;
|
|
13326
13328
|
if (typeof databaseId === 'undefined') {
|
|
13327
13329
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
13328
13330
|
}
|
|
@@ -13346,6 +13348,9 @@
|
|
|
13346
13348
|
if (typeof replicas !== 'undefined') {
|
|
13347
13349
|
payload['replicas'] = replicas;
|
|
13348
13350
|
}
|
|
13351
|
+
if (typeof syncMode !== 'undefined') {
|
|
13352
|
+
payload['syncMode'] = syncMode;
|
|
13353
|
+
}
|
|
13349
13354
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
13350
13355
|
const apiHeaders = {
|
|
13351
13356
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -13530,13 +13535,17 @@
|
|
|
13530
13535
|
databaseId: paramsOrFirst,
|
|
13531
13536
|
name: rest[0],
|
|
13532
13537
|
enabled: rest[1],
|
|
13533
|
-
|
|
13538
|
+
specification: rest[2],
|
|
13539
|
+
replicas: rest[3],
|
|
13540
|
+
syncMode: rest[4]
|
|
13534
13541
|
};
|
|
13535
13542
|
}
|
|
13536
13543
|
const databaseId = params.databaseId;
|
|
13537
13544
|
const name = params.name;
|
|
13538
13545
|
const enabled = params.enabled;
|
|
13546
|
+
const specification = params.specification;
|
|
13539
13547
|
const replicas = params.replicas;
|
|
13548
|
+
const syncMode = params.syncMode;
|
|
13540
13549
|
if (typeof databaseId === 'undefined') {
|
|
13541
13550
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
13542
13551
|
}
|
|
@@ -13551,9 +13560,15 @@
|
|
|
13551
13560
|
if (typeof enabled !== 'undefined') {
|
|
13552
13561
|
payload['enabled'] = enabled;
|
|
13553
13562
|
}
|
|
13563
|
+
if (typeof specification !== 'undefined') {
|
|
13564
|
+
payload['specification'] = specification;
|
|
13565
|
+
}
|
|
13554
13566
|
if (typeof replicas !== 'undefined') {
|
|
13555
13567
|
payload['replicas'] = replicas;
|
|
13556
13568
|
}
|
|
13569
|
+
if (typeof syncMode !== 'undefined') {
|
|
13570
|
+
payload['syncMode'] = syncMode;
|
|
13571
|
+
}
|
|
13557
13572
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
13558
13573
|
const apiHeaders = {
|
|
13559
13574
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -22274,8 +22289,7 @@
|
|
|
22274
22289
|
pitrRetentionDays: rest[10],
|
|
22275
22290
|
storageAutoscaling: rest[11],
|
|
22276
22291
|
storageAutoscalingThresholdPercent: rest[12],
|
|
22277
|
-
storageAutoscalingMaxGb: rest[13]
|
|
22278
|
-
api: rest[14]
|
|
22292
|
+
storageAutoscalingMaxGb: rest[13]
|
|
22279
22293
|
};
|
|
22280
22294
|
}
|
|
22281
22295
|
const databaseId = params.databaseId;
|
|
@@ -22293,7 +22307,6 @@
|
|
|
22293
22307
|
const storageAutoscaling = params.storageAutoscaling;
|
|
22294
22308
|
const storageAutoscalingThresholdPercent = params.storageAutoscalingThresholdPercent;
|
|
22295
22309
|
const storageAutoscalingMaxGb = params.storageAutoscalingMaxGb;
|
|
22296
|
-
const api = params.api;
|
|
22297
22310
|
if (typeof databaseId === 'undefined') {
|
|
22298
22311
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
22299
22312
|
}
|
|
@@ -22347,9 +22360,6 @@
|
|
|
22347
22360
|
if (typeof storageAutoscalingMaxGb !== 'undefined') {
|
|
22348
22361
|
payload['storageAutoscalingMaxGb'] = storageAutoscalingMaxGb;
|
|
22349
22362
|
}
|
|
22350
|
-
if (typeof api !== 'undefined') {
|
|
22351
|
-
payload['api'] = api;
|
|
22352
|
-
}
|
|
22353
22363
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
22354
22364
|
const apiHeaders = {
|
|
22355
22365
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -23455,8 +23465,7 @@
|
|
|
23455
23465
|
pitrRetentionDays: rest[10],
|
|
23456
23466
|
storageAutoscaling: rest[11],
|
|
23457
23467
|
storageAutoscalingThresholdPercent: rest[12],
|
|
23458
|
-
storageAutoscalingMaxGb: rest[13]
|
|
23459
|
-
api: rest[14]
|
|
23468
|
+
storageAutoscalingMaxGb: rest[13]
|
|
23460
23469
|
};
|
|
23461
23470
|
}
|
|
23462
23471
|
const databaseId = params.databaseId;
|
|
@@ -23474,7 +23483,6 @@
|
|
|
23474
23483
|
const storageAutoscaling = params.storageAutoscaling;
|
|
23475
23484
|
const storageAutoscalingThresholdPercent = params.storageAutoscalingThresholdPercent;
|
|
23476
23485
|
const storageAutoscalingMaxGb = params.storageAutoscalingMaxGb;
|
|
23477
|
-
const api = params.api;
|
|
23478
23486
|
if (typeof databaseId === 'undefined') {
|
|
23479
23487
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
23480
23488
|
}
|
|
@@ -23528,9 +23536,6 @@
|
|
|
23528
23536
|
if (typeof storageAutoscalingMaxGb !== 'undefined') {
|
|
23529
23537
|
payload['storageAutoscalingMaxGb'] = storageAutoscalingMaxGb;
|
|
23530
23538
|
}
|
|
23531
|
-
if (typeof api !== 'undefined') {
|
|
23532
|
-
payload['api'] = api;
|
|
23533
|
-
}
|
|
23534
23539
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
23535
23540
|
const apiHeaders = {
|
|
23536
23541
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -27644,8 +27649,7 @@
|
|
|
27644
27649
|
pitrRetentionDays: rest[10],
|
|
27645
27650
|
storageAutoscaling: rest[11],
|
|
27646
27651
|
storageAutoscalingThresholdPercent: rest[12],
|
|
27647
|
-
storageAutoscalingMaxGb: rest[13]
|
|
27648
|
-
api: rest[14]
|
|
27652
|
+
storageAutoscalingMaxGb: rest[13]
|
|
27649
27653
|
};
|
|
27650
27654
|
}
|
|
27651
27655
|
const databaseId = params.databaseId;
|
|
@@ -27663,7 +27667,6 @@
|
|
|
27663
27667
|
const storageAutoscaling = params.storageAutoscaling;
|
|
27664
27668
|
const storageAutoscalingThresholdPercent = params.storageAutoscalingThresholdPercent;
|
|
27665
27669
|
const storageAutoscalingMaxGb = params.storageAutoscalingMaxGb;
|
|
27666
|
-
const api = params.api;
|
|
27667
27670
|
if (typeof databaseId === 'undefined') {
|
|
27668
27671
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
27669
27672
|
}
|
|
@@ -27717,9 +27720,6 @@
|
|
|
27717
27720
|
if (typeof storageAutoscalingMaxGb !== 'undefined') {
|
|
27718
27721
|
payload['storageAutoscalingMaxGb'] = storageAutoscalingMaxGb;
|
|
27719
27722
|
}
|
|
27720
|
-
if (typeof api !== 'undefined') {
|
|
27721
|
-
payload['api'] = api;
|
|
27722
|
-
}
|
|
27723
27723
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
27724
27724
|
const apiHeaders = {
|
|
27725
27725
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -35175,14 +35175,16 @@
|
|
|
35175
35175
|
bucketId: paramsOrFirst,
|
|
35176
35176
|
fileId: rest[0],
|
|
35177
35177
|
file: rest[1],
|
|
35178
|
-
permissions: rest[2]
|
|
35178
|
+
permissions: rest[2],
|
|
35179
|
+
folder: rest[3]
|
|
35179
35180
|
};
|
|
35180
|
-
onProgress = rest[
|
|
35181
|
+
onProgress = rest[4];
|
|
35181
35182
|
}
|
|
35182
35183
|
const bucketId = params.bucketId;
|
|
35183
35184
|
const fileId = params.fileId;
|
|
35184
35185
|
const file = params.file;
|
|
35185
35186
|
const permissions = params.permissions;
|
|
35187
|
+
const folder = params.folder;
|
|
35186
35188
|
if (typeof bucketId === 'undefined') {
|
|
35187
35189
|
throw new AppwriteException('Missing required parameter: "bucketId"');
|
|
35188
35190
|
}
|
|
@@ -35203,6 +35205,9 @@
|
|
|
35203
35205
|
if (typeof permissions !== 'undefined') {
|
|
35204
35206
|
payload['permissions'] = permissions;
|
|
35205
35207
|
}
|
|
35208
|
+
if (typeof folder !== 'undefined') {
|
|
35209
|
+
payload['folder'] = folder;
|
|
35210
|
+
}
|
|
35206
35211
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
35207
35212
|
const apiHeaders = {
|
|
35208
35213
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -35519,7 +35524,8 @@
|
|
|
35519
35524
|
name: rest[0],
|
|
35520
35525
|
enabled: rest[1],
|
|
35521
35526
|
specification: rest[2],
|
|
35522
|
-
replicas: rest[3]
|
|
35527
|
+
replicas: rest[3],
|
|
35528
|
+
syncMode: rest[4]
|
|
35523
35529
|
};
|
|
35524
35530
|
}
|
|
35525
35531
|
const databaseId = params.databaseId;
|
|
@@ -35527,6 +35533,7 @@
|
|
|
35527
35533
|
const enabled = params.enabled;
|
|
35528
35534
|
const specification = params.specification;
|
|
35529
35535
|
const replicas = params.replicas;
|
|
35536
|
+
const syncMode = params.syncMode;
|
|
35530
35537
|
if (typeof databaseId === 'undefined') {
|
|
35531
35538
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
35532
35539
|
}
|
|
@@ -35550,6 +35557,9 @@
|
|
|
35550
35557
|
if (typeof replicas !== 'undefined') {
|
|
35551
35558
|
payload['replicas'] = replicas;
|
|
35552
35559
|
}
|
|
35560
|
+
if (typeof syncMode !== 'undefined') {
|
|
35561
|
+
payload['syncMode'] = syncMode;
|
|
35562
|
+
}
|
|
35553
35563
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
35554
35564
|
const apiHeaders = {
|
|
35555
35565
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -35763,13 +35773,17 @@
|
|
|
35763
35773
|
databaseId: paramsOrFirst,
|
|
35764
35774
|
name: rest[0],
|
|
35765
35775
|
enabled: rest[1],
|
|
35766
|
-
|
|
35776
|
+
specification: rest[2],
|
|
35777
|
+
replicas: rest[3],
|
|
35778
|
+
syncMode: rest[4]
|
|
35767
35779
|
};
|
|
35768
35780
|
}
|
|
35769
35781
|
const databaseId = params.databaseId;
|
|
35770
35782
|
const name = params.name;
|
|
35771
35783
|
const enabled = params.enabled;
|
|
35784
|
+
const specification = params.specification;
|
|
35772
35785
|
const replicas = params.replicas;
|
|
35786
|
+
const syncMode = params.syncMode;
|
|
35773
35787
|
if (typeof databaseId === 'undefined') {
|
|
35774
35788
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
35775
35789
|
}
|
|
@@ -35781,9 +35795,15 @@
|
|
|
35781
35795
|
if (typeof enabled !== 'undefined') {
|
|
35782
35796
|
payload['enabled'] = enabled;
|
|
35783
35797
|
}
|
|
35798
|
+
if (typeof specification !== 'undefined') {
|
|
35799
|
+
payload['specification'] = specification;
|
|
35800
|
+
}
|
|
35784
35801
|
if (typeof replicas !== 'undefined') {
|
|
35785
35802
|
payload['replicas'] = replicas;
|
|
35786
35803
|
}
|
|
35804
|
+
if (typeof syncMode !== 'undefined') {
|
|
35805
|
+
payload['syncMode'] = syncMode;
|
|
35806
|
+
}
|
|
35787
35807
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
35788
35808
|
const apiHeaders = {
|
|
35789
35809
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -42238,7 +42258,8 @@
|
|
|
42238
42258
|
name: rest[0],
|
|
42239
42259
|
enabled: rest[1],
|
|
42240
42260
|
specification: rest[2],
|
|
42241
|
-
replicas: rest[3]
|
|
42261
|
+
replicas: rest[3],
|
|
42262
|
+
syncMode: rest[4]
|
|
42242
42263
|
};
|
|
42243
42264
|
}
|
|
42244
42265
|
const databaseId = params.databaseId;
|
|
@@ -42246,6 +42267,7 @@
|
|
|
42246
42267
|
const enabled = params.enabled;
|
|
42247
42268
|
const specification = params.specification;
|
|
42248
42269
|
const replicas = params.replicas;
|
|
42270
|
+
const syncMode = params.syncMode;
|
|
42249
42271
|
if (typeof databaseId === 'undefined') {
|
|
42250
42272
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
42251
42273
|
}
|
|
@@ -42269,6 +42291,9 @@
|
|
|
42269
42291
|
if (typeof replicas !== 'undefined') {
|
|
42270
42292
|
payload['replicas'] = replicas;
|
|
42271
42293
|
}
|
|
42294
|
+
if (typeof syncMode !== 'undefined') {
|
|
42295
|
+
payload['syncMode'] = syncMode;
|
|
42296
|
+
}
|
|
42272
42297
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
42273
42298
|
const apiHeaders = {
|
|
42274
42299
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -42514,13 +42539,17 @@
|
|
|
42514
42539
|
databaseId: paramsOrFirst,
|
|
42515
42540
|
name: rest[0],
|
|
42516
42541
|
enabled: rest[1],
|
|
42517
|
-
|
|
42542
|
+
specification: rest[2],
|
|
42543
|
+
replicas: rest[3],
|
|
42544
|
+
syncMode: rest[4]
|
|
42518
42545
|
};
|
|
42519
42546
|
}
|
|
42520
42547
|
const databaseId = params.databaseId;
|
|
42521
42548
|
const name = params.name;
|
|
42522
42549
|
const enabled = params.enabled;
|
|
42550
|
+
const specification = params.specification;
|
|
42523
42551
|
const replicas = params.replicas;
|
|
42552
|
+
const syncMode = params.syncMode;
|
|
42524
42553
|
if (typeof databaseId === 'undefined') {
|
|
42525
42554
|
throw new AppwriteException('Missing required parameter: "databaseId"');
|
|
42526
42555
|
}
|
|
@@ -42535,9 +42564,15 @@
|
|
|
42535
42564
|
if (typeof enabled !== 'undefined') {
|
|
42536
42565
|
payload['enabled'] = enabled;
|
|
42537
42566
|
}
|
|
42567
|
+
if (typeof specification !== 'undefined') {
|
|
42568
|
+
payload['specification'] = specification;
|
|
42569
|
+
}
|
|
42538
42570
|
if (typeof replicas !== 'undefined') {
|
|
42539
42571
|
payload['replicas'] = replicas;
|
|
42540
42572
|
}
|
|
42573
|
+
if (typeof syncMode !== 'undefined') {
|
|
42574
|
+
payload['syncMode'] = syncMode;
|
|
42575
|
+
}
|
|
42541
42576
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
42542
42577
|
const apiHeaders = {
|
|
42543
42578
|
'X-Appwrite-Project': this.client.config.project,
|
|
@@ -43717,6 +43752,163 @@
|
|
|
43717
43752
|
};
|
|
43718
43753
|
return this.client.call('patch', uri, apiHeaders, payload);
|
|
43719
43754
|
}
|
|
43755
|
+
createChallengeRule(paramsOrFirst, ...rest) {
|
|
43756
|
+
let params;
|
|
43757
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
43758
|
+
params = (paramsOrFirst || {});
|
|
43759
|
+
}
|
|
43760
|
+
else {
|
|
43761
|
+
params = {
|
|
43762
|
+
ruleId: paramsOrFirst,
|
|
43763
|
+
resourceType: rest[0],
|
|
43764
|
+
name: rest[1],
|
|
43765
|
+
resourceId: rest[2],
|
|
43766
|
+
description: rest[3],
|
|
43767
|
+
challengeType: rest[4],
|
|
43768
|
+
priority: rest[5],
|
|
43769
|
+
enabled: rest[6],
|
|
43770
|
+
conditions: rest[7],
|
|
43771
|
+
difficulty: rest[8],
|
|
43772
|
+
ttl: rest[9]
|
|
43773
|
+
};
|
|
43774
|
+
}
|
|
43775
|
+
const ruleId = params.ruleId;
|
|
43776
|
+
const resourceType = params.resourceType;
|
|
43777
|
+
const name = params.name;
|
|
43778
|
+
const resourceId = params.resourceId;
|
|
43779
|
+
const description = params.description;
|
|
43780
|
+
const challengeType = params.challengeType;
|
|
43781
|
+
const priority = params.priority;
|
|
43782
|
+
const enabled = params.enabled;
|
|
43783
|
+
const conditions = params.conditions;
|
|
43784
|
+
const difficulty = params.difficulty;
|
|
43785
|
+
const ttl = params.ttl;
|
|
43786
|
+
if (typeof ruleId === 'undefined') {
|
|
43787
|
+
throw new AppwriteException('Missing required parameter: "ruleId"');
|
|
43788
|
+
}
|
|
43789
|
+
if (typeof resourceType === 'undefined') {
|
|
43790
|
+
throw new AppwriteException('Missing required parameter: "resourceType"');
|
|
43791
|
+
}
|
|
43792
|
+
if (typeof name === 'undefined') {
|
|
43793
|
+
throw new AppwriteException('Missing required parameter: "name"');
|
|
43794
|
+
}
|
|
43795
|
+
const apiPath = '/waf/rules/challenge';
|
|
43796
|
+
const payload = {};
|
|
43797
|
+
if (typeof ruleId !== 'undefined') {
|
|
43798
|
+
payload['ruleId'] = ruleId;
|
|
43799
|
+
}
|
|
43800
|
+
if (typeof resourceType !== 'undefined') {
|
|
43801
|
+
payload['resourceType'] = resourceType;
|
|
43802
|
+
}
|
|
43803
|
+
if (typeof resourceId !== 'undefined') {
|
|
43804
|
+
payload['resourceId'] = resourceId;
|
|
43805
|
+
}
|
|
43806
|
+
if (typeof name !== 'undefined') {
|
|
43807
|
+
payload['name'] = name;
|
|
43808
|
+
}
|
|
43809
|
+
if (typeof description !== 'undefined') {
|
|
43810
|
+
payload['description'] = description;
|
|
43811
|
+
}
|
|
43812
|
+
if (typeof challengeType !== 'undefined') {
|
|
43813
|
+
payload['challengeType'] = challengeType;
|
|
43814
|
+
}
|
|
43815
|
+
if (typeof priority !== 'undefined') {
|
|
43816
|
+
payload['priority'] = priority;
|
|
43817
|
+
}
|
|
43818
|
+
if (typeof enabled !== 'undefined') {
|
|
43819
|
+
payload['enabled'] = enabled;
|
|
43820
|
+
}
|
|
43821
|
+
if (typeof conditions !== 'undefined') {
|
|
43822
|
+
payload['conditions'] = conditions;
|
|
43823
|
+
}
|
|
43824
|
+
if (typeof difficulty !== 'undefined') {
|
|
43825
|
+
payload['difficulty'] = difficulty;
|
|
43826
|
+
}
|
|
43827
|
+
if (typeof ttl !== 'undefined') {
|
|
43828
|
+
payload['ttl'] = ttl;
|
|
43829
|
+
}
|
|
43830
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
43831
|
+
const apiHeaders = {
|
|
43832
|
+
'X-Appwrite-Project': this.client.config.project,
|
|
43833
|
+
'content-type': 'application/json',
|
|
43834
|
+
'accept': 'application/json',
|
|
43835
|
+
};
|
|
43836
|
+
return this.client.call('post', uri, apiHeaders, payload);
|
|
43837
|
+
}
|
|
43838
|
+
updateChallengeRule(paramsOrFirst, ...rest) {
|
|
43839
|
+
let params;
|
|
43840
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
43841
|
+
params = (paramsOrFirst || {});
|
|
43842
|
+
}
|
|
43843
|
+
else {
|
|
43844
|
+
params = {
|
|
43845
|
+
ruleId: paramsOrFirst,
|
|
43846
|
+
resourceType: rest[0],
|
|
43847
|
+
resourceId: rest[1],
|
|
43848
|
+
name: rest[2],
|
|
43849
|
+
description: rest[3],
|
|
43850
|
+
challengeType: rest[4],
|
|
43851
|
+
priority: rest[5],
|
|
43852
|
+
enabled: rest[6],
|
|
43853
|
+
conditions: rest[7],
|
|
43854
|
+
difficulty: rest[8],
|
|
43855
|
+
ttl: rest[9]
|
|
43856
|
+
};
|
|
43857
|
+
}
|
|
43858
|
+
const ruleId = params.ruleId;
|
|
43859
|
+
const resourceType = params.resourceType;
|
|
43860
|
+
const resourceId = params.resourceId;
|
|
43861
|
+
const name = params.name;
|
|
43862
|
+
const description = params.description;
|
|
43863
|
+
const challengeType = params.challengeType;
|
|
43864
|
+
const priority = params.priority;
|
|
43865
|
+
const enabled = params.enabled;
|
|
43866
|
+
const conditions = params.conditions;
|
|
43867
|
+
const difficulty = params.difficulty;
|
|
43868
|
+
const ttl = params.ttl;
|
|
43869
|
+
if (typeof ruleId === 'undefined') {
|
|
43870
|
+
throw new AppwriteException('Missing required parameter: "ruleId"');
|
|
43871
|
+
}
|
|
43872
|
+
const apiPath = '/waf/rules/challenge/{ruleId}'.replace('{ruleId}', encodeURIComponent(String(ruleId)));
|
|
43873
|
+
const payload = {};
|
|
43874
|
+
if (typeof resourceType !== 'undefined') {
|
|
43875
|
+
payload['resourceType'] = resourceType;
|
|
43876
|
+
}
|
|
43877
|
+
if (typeof resourceId !== 'undefined') {
|
|
43878
|
+
payload['resourceId'] = resourceId;
|
|
43879
|
+
}
|
|
43880
|
+
if (typeof name !== 'undefined') {
|
|
43881
|
+
payload['name'] = name;
|
|
43882
|
+
}
|
|
43883
|
+
if (typeof description !== 'undefined') {
|
|
43884
|
+
payload['description'] = description;
|
|
43885
|
+
}
|
|
43886
|
+
if (typeof challengeType !== 'undefined') {
|
|
43887
|
+
payload['challengeType'] = challengeType;
|
|
43888
|
+
}
|
|
43889
|
+
if (typeof priority !== 'undefined') {
|
|
43890
|
+
payload['priority'] = priority;
|
|
43891
|
+
}
|
|
43892
|
+
if (typeof enabled !== 'undefined') {
|
|
43893
|
+
payload['enabled'] = enabled;
|
|
43894
|
+
}
|
|
43895
|
+
if (typeof conditions !== 'undefined') {
|
|
43896
|
+
payload['conditions'] = conditions;
|
|
43897
|
+
}
|
|
43898
|
+
if (typeof difficulty !== 'undefined') {
|
|
43899
|
+
payload['difficulty'] = difficulty;
|
|
43900
|
+
}
|
|
43901
|
+
if (typeof ttl !== 'undefined') {
|
|
43902
|
+
payload['ttl'] = ttl;
|
|
43903
|
+
}
|
|
43904
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
43905
|
+
const apiHeaders = {
|
|
43906
|
+
'X-Appwrite-Project': this.client.config.project,
|
|
43907
|
+
'content-type': 'application/json',
|
|
43908
|
+
'accept': 'application/json',
|
|
43909
|
+
};
|
|
43910
|
+
return this.client.call('patch', uri, apiHeaders, payload);
|
|
43911
|
+
}
|
|
43720
43912
|
createDenyRule(paramsOrFirst, ...rest) {
|
|
43721
43913
|
let params;
|
|
43722
43914
|
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
@@ -43858,9 +44050,10 @@
|
|
|
43858
44050
|
interval: rest[3],
|
|
43859
44051
|
resourceId: rest[4],
|
|
43860
44052
|
description: rest[5],
|
|
43861
|
-
|
|
43862
|
-
|
|
43863
|
-
|
|
44053
|
+
key: rest[6],
|
|
44054
|
+
priority: rest[7],
|
|
44055
|
+
enabled: rest[8],
|
|
44056
|
+
conditions: rest[9]
|
|
43864
44057
|
};
|
|
43865
44058
|
}
|
|
43866
44059
|
const ruleId = params.ruleId;
|
|
@@ -43870,6 +44063,7 @@
|
|
|
43870
44063
|
const interval = params.interval;
|
|
43871
44064
|
const resourceId = params.resourceId;
|
|
43872
44065
|
const description = params.description;
|
|
44066
|
+
const key = params.key;
|
|
43873
44067
|
const priority = params.priority;
|
|
43874
44068
|
const enabled = params.enabled;
|
|
43875
44069
|
const conditions = params.conditions;
|
|
@@ -43911,6 +44105,9 @@
|
|
|
43911
44105
|
if (typeof interval !== 'undefined') {
|
|
43912
44106
|
payload['interval'] = interval;
|
|
43913
44107
|
}
|
|
44108
|
+
if (typeof key !== 'undefined') {
|
|
44109
|
+
payload['key'] = key;
|
|
44110
|
+
}
|
|
43914
44111
|
if (typeof priority !== 'undefined') {
|
|
43915
44112
|
payload['priority'] = priority;
|
|
43916
44113
|
}
|
|
@@ -43942,9 +44139,10 @@
|
|
|
43942
44139
|
description: rest[3],
|
|
43943
44140
|
limit: rest[4],
|
|
43944
44141
|
interval: rest[5],
|
|
43945
|
-
|
|
43946
|
-
|
|
43947
|
-
|
|
44142
|
+
key: rest[6],
|
|
44143
|
+
priority: rest[7],
|
|
44144
|
+
enabled: rest[8],
|
|
44145
|
+
conditions: rest[9]
|
|
43948
44146
|
};
|
|
43949
44147
|
}
|
|
43950
44148
|
const ruleId = params.ruleId;
|
|
@@ -43954,6 +44152,7 @@
|
|
|
43954
44152
|
const description = params.description;
|
|
43955
44153
|
const limit = params.limit;
|
|
43956
44154
|
const interval = params.interval;
|
|
44155
|
+
const key = params.key;
|
|
43957
44156
|
const priority = params.priority;
|
|
43958
44157
|
const enabled = params.enabled;
|
|
43959
44158
|
const conditions = params.conditions;
|
|
@@ -43980,6 +44179,9 @@
|
|
|
43980
44179
|
if (typeof interval !== 'undefined') {
|
|
43981
44180
|
payload['interval'] = interval;
|
|
43982
44181
|
}
|
|
44182
|
+
if (typeof key !== 'undefined') {
|
|
44183
|
+
payload['key'] = key;
|
|
44184
|
+
}
|
|
43983
44185
|
if (typeof priority !== 'undefined') {
|
|
43984
44186
|
payload['priority'] = priority;
|
|
43985
44187
|
}
|
|
@@ -46662,6 +46864,7 @@
|
|
|
46662
46864
|
Runtime["Node23"] = "node-23";
|
|
46663
46865
|
Runtime["Node24"] = "node-24";
|
|
46664
46866
|
Runtime["Node25"] = "node-25";
|
|
46867
|
+
Runtime["Node26"] = "node-26";
|
|
46665
46868
|
Runtime["Php80"] = "php-8.0";
|
|
46666
46869
|
Runtime["Php81"] = "php-8.1";
|
|
46667
46870
|
Runtime["Php82"] = "php-8.2";
|
|
@@ -47275,6 +47478,7 @@
|
|
|
47275
47478
|
BuildRuntime["Node23"] = "node-23";
|
|
47276
47479
|
BuildRuntime["Node24"] = "node-24";
|
|
47277
47480
|
BuildRuntime["Node25"] = "node-25";
|
|
47481
|
+
BuildRuntime["Node26"] = "node-26";
|
|
47278
47482
|
BuildRuntime["Php80"] = "php-8.0";
|
|
47279
47483
|
BuildRuntime["Php81"] = "php-8.1";
|
|
47280
47484
|
BuildRuntime["Php82"] = "php-8.2";
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@appwrite.io/console",
|
|
3
3
|
"homepage": "https://appwrite.io/support",
|
|
4
4
|
"description": "Appwrite is an open-source self-hosted backend server that abstracts and simplifies complex and repetitive development tasks behind a very simple REST API",
|
|
5
|
-
"version": "15.
|
|
5
|
+
"version": "15.8.0",
|
|
6
6
|
"license": "BSD-3-Clause",
|
|
7
7
|
"main": "dist/cjs/sdk.js",
|
|
8
8
|
"exports": {
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"@rollup/plugin-typescript": "12.3.0",
|
|
41
41
|
"@types/json-bigint": "1.0.4",
|
|
42
42
|
"playwright": "1.56.1",
|
|
43
|
-
"rollup": "4.62.
|
|
43
|
+
"rollup": "4.62.3",
|
|
44
44
|
"serve-handler": "6.1.7",
|
|
45
45
|
"tslib": "2.8.1",
|
|
46
46
|
"typescript": "5.9.3"
|