@appwrite.io/console 9.0.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/README.md +1 -1
- package/dist/cjs/sdk.js +14 -4
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +14 -4
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +14 -4
- package/package.json +1 -1
- package/types/models.d.ts +1 -1
- package/types/services/organizations.d.ts +2 -2
- package/types/services/webhooks.d.ts +8 -2
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@9.
|
|
36
|
+
<script src="https://cdn.jsdelivr.net/npm/@appwrite.io/console@9.1.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': '9.
|
|
583
|
+
'x-sdk-version': '9.1.0',
|
|
584
584
|
'X-Appwrite-Response-Format': '1.9.1',
|
|
585
585
|
};
|
|
586
586
|
this.realtime = {
|
|
@@ -27042,7 +27042,8 @@ class Webhooks {
|
|
|
27042
27042
|
enabled: rest[3],
|
|
27043
27043
|
tls: rest[4],
|
|
27044
27044
|
authUsername: rest[5],
|
|
27045
|
-
authPassword: rest[6]
|
|
27045
|
+
authPassword: rest[6],
|
|
27046
|
+
secret: rest[7]
|
|
27046
27047
|
};
|
|
27047
27048
|
}
|
|
27048
27049
|
const webhookId = params.webhookId;
|
|
@@ -27053,6 +27054,7 @@ class Webhooks {
|
|
|
27053
27054
|
const tls = params.tls;
|
|
27054
27055
|
const authUsername = params.authUsername;
|
|
27055
27056
|
const authPassword = params.authPassword;
|
|
27057
|
+
const secret = params.secret;
|
|
27056
27058
|
if (typeof webhookId === 'undefined') {
|
|
27057
27059
|
throw new AppwriteException('Missing required parameter: "webhookId"');
|
|
27058
27060
|
}
|
|
@@ -27091,6 +27093,9 @@ class Webhooks {
|
|
|
27091
27093
|
if (typeof authPassword !== 'undefined') {
|
|
27092
27094
|
payload['authPassword'] = authPassword;
|
|
27093
27095
|
}
|
|
27096
|
+
if (typeof secret !== 'undefined') {
|
|
27097
|
+
payload['secret'] = secret;
|
|
27098
|
+
}
|
|
27094
27099
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
27095
27100
|
const apiHeaders = {
|
|
27096
27101
|
'content-type': 'application/json',
|
|
@@ -27205,22 +27210,27 @@ class Webhooks {
|
|
|
27205
27210
|
};
|
|
27206
27211
|
return this.client.call('delete', uri, apiHeaders, payload);
|
|
27207
27212
|
}
|
|
27208
|
-
updateSecret(paramsOrFirst) {
|
|
27213
|
+
updateSecret(paramsOrFirst, ...rest) {
|
|
27209
27214
|
let params;
|
|
27210
27215
|
if ((paramsOrFirst && typeof paramsOrFirst === 'object' && !Array.isArray(paramsOrFirst))) {
|
|
27211
27216
|
params = (paramsOrFirst || {});
|
|
27212
27217
|
}
|
|
27213
27218
|
else {
|
|
27214
27219
|
params = {
|
|
27215
|
-
webhookId: paramsOrFirst
|
|
27220
|
+
webhookId: paramsOrFirst,
|
|
27221
|
+
secret: rest[0]
|
|
27216
27222
|
};
|
|
27217
27223
|
}
|
|
27218
27224
|
const webhookId = params.webhookId;
|
|
27225
|
+
const secret = params.secret;
|
|
27219
27226
|
if (typeof webhookId === 'undefined') {
|
|
27220
27227
|
throw new AppwriteException('Missing required parameter: "webhookId"');
|
|
27221
27228
|
}
|
|
27222
27229
|
const apiPath = '/webhooks/{webhookId}/secret'.replace('{webhookId}', webhookId);
|
|
27223
27230
|
const payload = {};
|
|
27231
|
+
if (typeof secret !== 'undefined') {
|
|
27232
|
+
payload['secret'] = secret;
|
|
27233
|
+
}
|
|
27224
27234
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
27225
27235
|
const apiHeaders = {
|
|
27226
27236
|
'content-type': 'application/json',
|