@appwrite.io/console 8.1.1 → 8.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/cjs/sdk.js +252 -1
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +253 -2
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +3902 -3626
- package/package.json +9 -6
- package/types/enums/addon.d.ts +3 -0
- package/types/enums/build-runtime.d.ts +3 -1
- package/types/enums/runtime.d.ts +3 -1
- package/types/enums/runtimes.d.ts +3 -1
- package/types/index.d.ts +1 -0
- package/types/models.d.ts +132 -4
- package/types/services/health.d.ts +2 -0
- package/types/services/migrations.d.ts +63 -0
- package/types/services/organizations.d.ts +139 -0
package/README.md
CHANGED
|
@@ -33,7 +33,7 @@ import { Client, Account } from "@appwrite.io/console";
|
|
|
33
33
|
To install with a CDN (content delivery network) add the following scripts to the bottom of your <body> tag, but before you use any Appwrite services:
|
|
34
34
|
|
|
35
35
|
```html
|
|
36
|
-
<script src="https://cdn.jsdelivr.net/npm/@appwrite.io/console@8.
|
|
36
|
+
<script src="https://cdn.jsdelivr.net/npm/@appwrite.io/console@8.3.0"></script>
|
|
37
37
|
```
|
|
38
38
|
|
|
39
39
|
|
package/dist/cjs/sdk.js
CHANGED
|
@@ -580,7 +580,7 @@ class Client {
|
|
|
580
580
|
'x-sdk-name': 'Console',
|
|
581
581
|
'x-sdk-platform': 'console',
|
|
582
582
|
'x-sdk-language': 'web',
|
|
583
|
-
'x-sdk-version': '8.
|
|
583
|
+
'x-sdk-version': '8.3.0',
|
|
584
584
|
'X-Appwrite-Response-Format': '1.9.0',
|
|
585
585
|
};
|
|
586
586
|
this.realtime = {
|
|
@@ -14750,6 +14750,100 @@ class Migrations {
|
|
|
14750
14750
|
const apiHeaders = {};
|
|
14751
14751
|
return this.client.call('get', uri, apiHeaders, payload);
|
|
14752
14752
|
}
|
|
14753
|
+
createJSONExport(paramsOrFirst, ...rest) {
|
|
14754
|
+
let params;
|
|
14755
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
14756
|
+
params = (paramsOrFirst || {});
|
|
14757
|
+
}
|
|
14758
|
+
else {
|
|
14759
|
+
params = {
|
|
14760
|
+
resourceId: paramsOrFirst,
|
|
14761
|
+
filename: rest[0],
|
|
14762
|
+
columns: rest[1],
|
|
14763
|
+
queries: rest[2],
|
|
14764
|
+
notify: rest[3]
|
|
14765
|
+
};
|
|
14766
|
+
}
|
|
14767
|
+
const resourceId = params.resourceId;
|
|
14768
|
+
const filename = params.filename;
|
|
14769
|
+
const columns = params.columns;
|
|
14770
|
+
const queries = params.queries;
|
|
14771
|
+
const notify = params.notify;
|
|
14772
|
+
if (typeof resourceId === 'undefined') {
|
|
14773
|
+
throw new AppwriteException('Missing required parameter: "resourceId"');
|
|
14774
|
+
}
|
|
14775
|
+
if (typeof filename === 'undefined') {
|
|
14776
|
+
throw new AppwriteException('Missing required parameter: "filename"');
|
|
14777
|
+
}
|
|
14778
|
+
const apiPath = '/migrations/json/exports';
|
|
14779
|
+
const payload = {};
|
|
14780
|
+
if (typeof resourceId !== 'undefined') {
|
|
14781
|
+
payload['resourceId'] = resourceId;
|
|
14782
|
+
}
|
|
14783
|
+
if (typeof filename !== 'undefined') {
|
|
14784
|
+
payload['filename'] = filename;
|
|
14785
|
+
}
|
|
14786
|
+
if (typeof columns !== 'undefined') {
|
|
14787
|
+
payload['columns'] = columns;
|
|
14788
|
+
}
|
|
14789
|
+
if (typeof queries !== 'undefined') {
|
|
14790
|
+
payload['queries'] = queries;
|
|
14791
|
+
}
|
|
14792
|
+
if (typeof notify !== 'undefined') {
|
|
14793
|
+
payload['notify'] = notify;
|
|
14794
|
+
}
|
|
14795
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
14796
|
+
const apiHeaders = {
|
|
14797
|
+
'content-type': 'application/json',
|
|
14798
|
+
};
|
|
14799
|
+
return this.client.call('post', uri, apiHeaders, payload);
|
|
14800
|
+
}
|
|
14801
|
+
createJSONImport(paramsOrFirst, ...rest) {
|
|
14802
|
+
let params;
|
|
14803
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
14804
|
+
params = (paramsOrFirst || {});
|
|
14805
|
+
}
|
|
14806
|
+
else {
|
|
14807
|
+
params = {
|
|
14808
|
+
bucketId: paramsOrFirst,
|
|
14809
|
+
fileId: rest[0],
|
|
14810
|
+
resourceId: rest[1],
|
|
14811
|
+
internalFile: rest[2]
|
|
14812
|
+
};
|
|
14813
|
+
}
|
|
14814
|
+
const bucketId = params.bucketId;
|
|
14815
|
+
const fileId = params.fileId;
|
|
14816
|
+
const resourceId = params.resourceId;
|
|
14817
|
+
const internalFile = params.internalFile;
|
|
14818
|
+
if (typeof bucketId === 'undefined') {
|
|
14819
|
+
throw new AppwriteException('Missing required parameter: "bucketId"');
|
|
14820
|
+
}
|
|
14821
|
+
if (typeof fileId === 'undefined') {
|
|
14822
|
+
throw new AppwriteException('Missing required parameter: "fileId"');
|
|
14823
|
+
}
|
|
14824
|
+
if (typeof resourceId === 'undefined') {
|
|
14825
|
+
throw new AppwriteException('Missing required parameter: "resourceId"');
|
|
14826
|
+
}
|
|
14827
|
+
const apiPath = '/migrations/json/imports';
|
|
14828
|
+
const payload = {};
|
|
14829
|
+
if (typeof bucketId !== 'undefined') {
|
|
14830
|
+
payload['bucketId'] = bucketId;
|
|
14831
|
+
}
|
|
14832
|
+
if (typeof fileId !== 'undefined') {
|
|
14833
|
+
payload['fileId'] = fileId;
|
|
14834
|
+
}
|
|
14835
|
+
if (typeof resourceId !== 'undefined') {
|
|
14836
|
+
payload['resourceId'] = resourceId;
|
|
14837
|
+
}
|
|
14838
|
+
if (typeof internalFile !== 'undefined') {
|
|
14839
|
+
payload['internalFile'] = internalFile;
|
|
14840
|
+
}
|
|
14841
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
14842
|
+
const apiHeaders = {
|
|
14843
|
+
'content-type': 'application/json',
|
|
14844
|
+
};
|
|
14845
|
+
return this.client.call('post', uri, apiHeaders, payload);
|
|
14846
|
+
}
|
|
14753
14847
|
createNHostMigration(paramsOrFirst, ...rest) {
|
|
14754
14848
|
let params;
|
|
14755
14849
|
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst) && ('resources' in paramsOrFirst || 'subdomain' in paramsOrFirst || 'region' in paramsOrFirst || 'adminSecret' in paramsOrFirst || 'database' in paramsOrFirst || 'username' in paramsOrFirst || 'password' in paramsOrFirst || 'port' in paramsOrFirst))) {
|
|
@@ -15280,6 +15374,152 @@ class Organizations {
|
|
|
15280
15374
|
};
|
|
15281
15375
|
return this.client.call('delete', uri, apiHeaders, payload);
|
|
15282
15376
|
}
|
|
15377
|
+
listAddons(paramsOrFirst) {
|
|
15378
|
+
let params;
|
|
15379
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
15380
|
+
params = (paramsOrFirst || {});
|
|
15381
|
+
}
|
|
15382
|
+
else {
|
|
15383
|
+
params = {
|
|
15384
|
+
organizationId: paramsOrFirst
|
|
15385
|
+
};
|
|
15386
|
+
}
|
|
15387
|
+
const organizationId = params.organizationId;
|
|
15388
|
+
if (typeof organizationId === 'undefined') {
|
|
15389
|
+
throw new AppwriteException('Missing required parameter: "organizationId"');
|
|
15390
|
+
}
|
|
15391
|
+
const apiPath = '/organizations/{organizationId}/addons'.replace('{organizationId}', organizationId);
|
|
15392
|
+
const payload = {};
|
|
15393
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
15394
|
+
const apiHeaders = {};
|
|
15395
|
+
return this.client.call('get', uri, apiHeaders, payload);
|
|
15396
|
+
}
|
|
15397
|
+
createBaaAddon(paramsOrFirst) {
|
|
15398
|
+
let params;
|
|
15399
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
15400
|
+
params = (paramsOrFirst || {});
|
|
15401
|
+
}
|
|
15402
|
+
else {
|
|
15403
|
+
params = {
|
|
15404
|
+
organizationId: paramsOrFirst
|
|
15405
|
+
};
|
|
15406
|
+
}
|
|
15407
|
+
const organizationId = params.organizationId;
|
|
15408
|
+
if (typeof organizationId === 'undefined') {
|
|
15409
|
+
throw new AppwriteException('Missing required parameter: "organizationId"');
|
|
15410
|
+
}
|
|
15411
|
+
const apiPath = '/organizations/{organizationId}/addons/baa'.replace('{organizationId}', organizationId);
|
|
15412
|
+
const payload = {};
|
|
15413
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
15414
|
+
const apiHeaders = {
|
|
15415
|
+
'content-type': 'application/json',
|
|
15416
|
+
};
|
|
15417
|
+
return this.client.call('post', uri, apiHeaders, payload);
|
|
15418
|
+
}
|
|
15419
|
+
getAddon(paramsOrFirst, ...rest) {
|
|
15420
|
+
let params;
|
|
15421
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
15422
|
+
params = (paramsOrFirst || {});
|
|
15423
|
+
}
|
|
15424
|
+
else {
|
|
15425
|
+
params = {
|
|
15426
|
+
organizationId: paramsOrFirst,
|
|
15427
|
+
addonId: rest[0]
|
|
15428
|
+
};
|
|
15429
|
+
}
|
|
15430
|
+
const organizationId = params.organizationId;
|
|
15431
|
+
const addonId = params.addonId;
|
|
15432
|
+
if (typeof organizationId === 'undefined') {
|
|
15433
|
+
throw new AppwriteException('Missing required parameter: "organizationId"');
|
|
15434
|
+
}
|
|
15435
|
+
if (typeof addonId === 'undefined') {
|
|
15436
|
+
throw new AppwriteException('Missing required parameter: "addonId"');
|
|
15437
|
+
}
|
|
15438
|
+
const apiPath = '/organizations/{organizationId}/addons/{addonId}'.replace('{organizationId}', organizationId).replace('{addonId}', addonId);
|
|
15439
|
+
const payload = {};
|
|
15440
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
15441
|
+
const apiHeaders = {};
|
|
15442
|
+
return this.client.call('get', uri, apiHeaders, payload);
|
|
15443
|
+
}
|
|
15444
|
+
deleteAddon(paramsOrFirst, ...rest) {
|
|
15445
|
+
let params;
|
|
15446
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
15447
|
+
params = (paramsOrFirst || {});
|
|
15448
|
+
}
|
|
15449
|
+
else {
|
|
15450
|
+
params = {
|
|
15451
|
+
organizationId: paramsOrFirst,
|
|
15452
|
+
addonId: rest[0]
|
|
15453
|
+
};
|
|
15454
|
+
}
|
|
15455
|
+
const organizationId = params.organizationId;
|
|
15456
|
+
const addonId = params.addonId;
|
|
15457
|
+
if (typeof organizationId === 'undefined') {
|
|
15458
|
+
throw new AppwriteException('Missing required parameter: "organizationId"');
|
|
15459
|
+
}
|
|
15460
|
+
if (typeof addonId === 'undefined') {
|
|
15461
|
+
throw new AppwriteException('Missing required parameter: "addonId"');
|
|
15462
|
+
}
|
|
15463
|
+
const apiPath = '/organizations/{organizationId}/addons/{addonId}'.replace('{organizationId}', organizationId).replace('{addonId}', addonId);
|
|
15464
|
+
const payload = {};
|
|
15465
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
15466
|
+
const apiHeaders = {
|
|
15467
|
+
'content-type': 'application/json',
|
|
15468
|
+
};
|
|
15469
|
+
return this.client.call('delete', uri, apiHeaders, payload);
|
|
15470
|
+
}
|
|
15471
|
+
confirmAddonPayment(paramsOrFirst, ...rest) {
|
|
15472
|
+
let params;
|
|
15473
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
15474
|
+
params = (paramsOrFirst || {});
|
|
15475
|
+
}
|
|
15476
|
+
else {
|
|
15477
|
+
params = {
|
|
15478
|
+
organizationId: paramsOrFirst,
|
|
15479
|
+
addonId: rest[0]
|
|
15480
|
+
};
|
|
15481
|
+
}
|
|
15482
|
+
const organizationId = params.organizationId;
|
|
15483
|
+
const addonId = params.addonId;
|
|
15484
|
+
if (typeof organizationId === 'undefined') {
|
|
15485
|
+
throw new AppwriteException('Missing required parameter: "organizationId"');
|
|
15486
|
+
}
|
|
15487
|
+
if (typeof addonId === 'undefined') {
|
|
15488
|
+
throw new AppwriteException('Missing required parameter: "addonId"');
|
|
15489
|
+
}
|
|
15490
|
+
const apiPath = '/organizations/{organizationId}/addons/{addonId}/confirmations'.replace('{organizationId}', organizationId).replace('{addonId}', addonId);
|
|
15491
|
+
const payload = {};
|
|
15492
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
15493
|
+
const apiHeaders = {
|
|
15494
|
+
'content-type': 'application/json',
|
|
15495
|
+
};
|
|
15496
|
+
return this.client.call('post', uri, apiHeaders, payload);
|
|
15497
|
+
}
|
|
15498
|
+
getAddonPrice(paramsOrFirst, ...rest) {
|
|
15499
|
+
let params;
|
|
15500
|
+
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
15501
|
+
params = (paramsOrFirst || {});
|
|
15502
|
+
}
|
|
15503
|
+
else {
|
|
15504
|
+
params = {
|
|
15505
|
+
organizationId: paramsOrFirst,
|
|
15506
|
+
addon: rest[0]
|
|
15507
|
+
};
|
|
15508
|
+
}
|
|
15509
|
+
const organizationId = params.organizationId;
|
|
15510
|
+
const addon = params.addon;
|
|
15511
|
+
if (typeof organizationId === 'undefined') {
|
|
15512
|
+
throw new AppwriteException('Missing required parameter: "organizationId"');
|
|
15513
|
+
}
|
|
15514
|
+
if (typeof addon === 'undefined') {
|
|
15515
|
+
throw new AppwriteException('Missing required parameter: "addon"');
|
|
15516
|
+
}
|
|
15517
|
+
const apiPath = '/organizations/{organizationId}/addons/{addon}/price'.replace('{organizationId}', organizationId).replace('{addon}', addon);
|
|
15518
|
+
const payload = {};
|
|
15519
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
15520
|
+
const apiHeaders = {};
|
|
15521
|
+
return this.client.call('get', uri, apiHeaders, payload);
|
|
15522
|
+
}
|
|
15283
15523
|
listAggregations(paramsOrFirst, ...rest) {
|
|
15284
15524
|
let params;
|
|
15285
15525
|
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
@@ -28715,6 +28955,7 @@ exports.Runtime = void 0;
|
|
|
28715
28955
|
Runtime["Dart38"] = "dart-3.8";
|
|
28716
28956
|
Runtime["Dart39"] = "dart-3.9";
|
|
28717
28957
|
Runtime["Dart310"] = "dart-3.10";
|
|
28958
|
+
Runtime["Dart311"] = "dart-3.11";
|
|
28718
28959
|
Runtime["Dotnet60"] = "dotnet-6.0";
|
|
28719
28960
|
Runtime["Dotnet70"] = "dotnet-7.0";
|
|
28720
28961
|
Runtime["Dotnet80"] = "dotnet-8.0";
|
|
@@ -28753,6 +28994,7 @@ exports.Runtime = void 0;
|
|
|
28753
28994
|
Runtime["Flutter332"] = "flutter-3.32";
|
|
28754
28995
|
Runtime["Flutter335"] = "flutter-3.35";
|
|
28755
28996
|
Runtime["Flutter338"] = "flutter-3.38";
|
|
28997
|
+
Runtime["Flutter341"] = "flutter-3.41";
|
|
28756
28998
|
})(exports.Runtime || (exports.Runtime = {}));
|
|
28757
28999
|
|
|
28758
29000
|
exports.Runtimes = void 0;
|
|
@@ -28805,6 +29047,7 @@ exports.Runtimes = void 0;
|
|
|
28805
29047
|
Runtimes["Dart38"] = "dart-3.8";
|
|
28806
29048
|
Runtimes["Dart39"] = "dart-3.9";
|
|
28807
29049
|
Runtimes["Dart310"] = "dart-3.10";
|
|
29050
|
+
Runtimes["Dart311"] = "dart-3.11";
|
|
28808
29051
|
Runtimes["Dotnet60"] = "dotnet-6.0";
|
|
28809
29052
|
Runtimes["Dotnet70"] = "dotnet-7.0";
|
|
28810
29053
|
Runtimes["Dotnet80"] = "dotnet-8.0";
|
|
@@ -28843,6 +29086,7 @@ exports.Runtimes = void 0;
|
|
|
28843
29086
|
Runtimes["Flutter332"] = "flutter-3.32";
|
|
28844
29087
|
Runtimes["Flutter335"] = "flutter-3.35";
|
|
28845
29088
|
Runtimes["Flutter338"] = "flutter-3.38";
|
|
29089
|
+
Runtimes["Flutter341"] = "flutter-3.41";
|
|
28846
29090
|
})(exports.Runtimes || (exports.Runtimes = {}));
|
|
28847
29091
|
|
|
28848
29092
|
exports.UseCases = void 0;
|
|
@@ -28997,6 +29241,11 @@ exports.SupabaseMigrationResource = void 0;
|
|
|
28997
29241
|
SupabaseMigrationResource["File"] = "file";
|
|
28998
29242
|
})(exports.SupabaseMigrationResource || (exports.SupabaseMigrationResource = {}));
|
|
28999
29243
|
|
|
29244
|
+
exports.Addon = void 0;
|
|
29245
|
+
(function (Addon) {
|
|
29246
|
+
Addon["Baa"] = "baa";
|
|
29247
|
+
})(exports.Addon || (exports.Addon = {}));
|
|
29248
|
+
|
|
29000
29249
|
exports.ProjectUsageRange = void 0;
|
|
29001
29250
|
(function (ProjectUsageRange) {
|
|
29002
29251
|
ProjectUsageRange["OneHour"] = "1h";
|
|
@@ -29458,6 +29707,7 @@ exports.BuildRuntime = void 0;
|
|
|
29458
29707
|
BuildRuntime["Dart38"] = "dart-3.8";
|
|
29459
29708
|
BuildRuntime["Dart39"] = "dart-3.9";
|
|
29460
29709
|
BuildRuntime["Dart310"] = "dart-3.10";
|
|
29710
|
+
BuildRuntime["Dart311"] = "dart-3.11";
|
|
29461
29711
|
BuildRuntime["Dotnet60"] = "dotnet-6.0";
|
|
29462
29712
|
BuildRuntime["Dotnet70"] = "dotnet-7.0";
|
|
29463
29713
|
BuildRuntime["Dotnet80"] = "dotnet-8.0";
|
|
@@ -29496,6 +29746,7 @@ exports.BuildRuntime = void 0;
|
|
|
29496
29746
|
BuildRuntime["Flutter332"] = "flutter-3.32";
|
|
29497
29747
|
BuildRuntime["Flutter335"] = "flutter-3.35";
|
|
29498
29748
|
BuildRuntime["Flutter338"] = "flutter-3.38";
|
|
29749
|
+
BuildRuntime["Flutter341"] = "flutter-3.41";
|
|
29499
29750
|
})(exports.BuildRuntime || (exports.BuildRuntime = {}));
|
|
29500
29751
|
|
|
29501
29752
|
exports.Adapter = void 0;
|