diff --git a/CHANGELOG.md b/CHANGELOG.md
index 68c2321..588ec87 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,17 @@
# Change Log
+## 28.0.0
+
+* Breaking: removed `Account.listLogs` and the `Log`, `LogList` models
+* Breaking: removed `Client.setDevKey`
+* Breaking: SDK now targets Appwrite 2.3 (`X-Appwrite-Response-Format: 2.3.0`)
+* Added: `Account.createIdTokenSession` for native Apple and Google sign-in with `IdTokenProvider` enum
+* Added: `Account.createRecoveryOTP` and `Account.updateRecoveryOTP` for code-based password recovery
+* Added: `Account.createEmailVerificationOTP` and `Account.updateEmailVerificationOTP`
+* Added: `Kakao` and `Tiktok` values to `OAuthProvider`
+* Added: `passwordPwned` field on `User` and `providerIdToken` field on `Identity`
+* Fixed: empty-string required path parameters are rejected instead of sent to the API
+
## 27.0.0
* Breaking: `Execution.functionId` replaced by `resourceId` and `resourceType`
diff --git a/README.md b/README.md
index 6a8cd83..bee9ad2 100644
--- a/README.md
+++ b/README.md
@@ -1,12 +1,12 @@
# Appwrite Web SDK

-
+
[](https://travis-ci.com/appwrite/sdk-generator)
[](https://twitter.com/appwrite)
[](https://appwrite.io/discord)
-**This SDK targets Appwrite server version 2.0.x as shipped on Appwrite Cloud.** Self-hosted releases can lag behind Cloud — if you run an older self-hosted build, use a matching older SDK from [previous releases](https://github.com/appwrite/sdk-for-web/releases) when APIs differ.
+**This SDK targets Appwrite server version 2.3.x as shipped on Appwrite Cloud.** Self-hosted releases can lag behind Cloud — if you run an older self-hosted build, use a matching older SDK from [previous releases](https://github.com/appwrite/sdk-for-web/releases) when APIs differ.
Appwrite is an open-source backend as a service server that abstracts and simplifies complex and repetitive development tasks behind a very simple to use REST API. Appwrite aims to help you develop your apps faster and in a more secure way. Use the Web SDK to integrate your app with the Appwrite server to easily start interacting with all of Appwrite backend APIs and tools. For full API documentation and tutorials go to [https://appwrite.io/docs](https://appwrite.io/docs)
@@ -33,7 +33,7 @@ import { Client, Account } from 'appwrite';
To install with a CDN (content delivery network) add the following scripts to the bottom of your
tag, but before you use any Appwrite services:
```html
-
+
```
## Getting Started
diff --git a/docs/examples/account/list-logs.md b/docs/examples/account/create-email-verification-otp.md
similarity index 74%
rename from docs/examples/account/list-logs.md
rename to docs/examples/account/create-email-verification-otp.md
index 180448e..5e29349 100644
--- a/docs/examples/account/list-logs.md
+++ b/docs/examples/account/create-email-verification-otp.md
@@ -7,9 +7,8 @@ const client = new Client()
const account = new Account(client);
-const result = await account.listLogs({
- queries: [], // optional
- total: false, // optional
+const result = await account.createEmailVerificationOTP({
+ phrase: false, // optional
});
console.log(result);
diff --git a/docs/examples/account/create-id-token-session.md b/docs/examples/account/create-id-token-session.md
new file mode 100644
index 0000000..abd586c
--- /dev/null
+++ b/docs/examples/account/create-id-token-session.md
@@ -0,0 +1,20 @@
+```javascript
+import { Client, Account, IdTokenProvider } from 'appwrite';
+
+const client = new Client()
+ .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint
+ .setProject(''); // Your project ID
+
+const account = new Account(client);
+
+const result = await account.createIdTokenSession({
+ provider: IdTokenProvider.Apple,
+ idToken: '',
+ nonce: '', // optional
+ accessToken: '', // optional
+ accessTokenExpiry: 0, // optional
+ name: '', // optional
+});
+
+console.log(result);
+```
diff --git a/docs/examples/account/create-recovery-otp.md b/docs/examples/account/create-recovery-otp.md
new file mode 100644
index 0000000..62bc8f3
--- /dev/null
+++ b/docs/examples/account/create-recovery-otp.md
@@ -0,0 +1,16 @@
+```javascript
+import { Client, Account } from 'appwrite';
+
+const client = new Client()
+ .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint
+ .setProject(''); // Your project ID
+
+const account = new Account(client);
+
+const result = await account.createRecoveryOTP({
+ email: 'email@example.com',
+ phrase: false, // optional
+});
+
+console.log(result);
+```
diff --git a/docs/examples/account/update-email-verification-otp.md b/docs/examples/account/update-email-verification-otp.md
new file mode 100644
index 0000000..d94f8ea
--- /dev/null
+++ b/docs/examples/account/update-email-verification-otp.md
@@ -0,0 +1,16 @@
+```javascript
+import { Client, Account } from 'appwrite';
+
+const client = new Client()
+ .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint
+ .setProject(''); // Your project ID
+
+const account = new Account(client);
+
+const result = await account.updateEmailVerificationOTP({
+ userId: '',
+ secret: '',
+});
+
+console.log(result);
+```
diff --git a/docs/examples/account/update-recovery-otp.md b/docs/examples/account/update-recovery-otp.md
new file mode 100644
index 0000000..c8b124c
--- /dev/null
+++ b/docs/examples/account/update-recovery-otp.md
@@ -0,0 +1,17 @@
+```javascript
+import { Client, Account } from 'appwrite';
+
+const client = new Client()
+ .setEndpoint('https://.cloud.appwrite.io/v1') // Your API Endpoint
+ .setProject(''); // Your project ID
+
+const account = new Account(client);
+
+const result = await account.updateRecoveryOTP({
+ userId: '',
+ secret: '',
+ password: 'password',
+});
+
+console.log(result);
+```
diff --git a/package-lock.json b/package-lock.json
index 14e4851..632c697 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "appwrite",
- "version": "27.0.0",
+ "version": "28.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "appwrite",
- "version": "27.0.0",
+ "version": "28.0.0",
"license": "BSD-3-Clause",
"dependencies": {
"json-bigint": "1.0.0"
@@ -17,19 +17,43 @@
"@rollup/plugin-node-resolve": "16.0.3",
"@rollup/plugin-typescript": "12.3.0",
"@types/json-bigint": "1.0.4",
- "eslint": "10.9.1",
+ "eslint": "10.10.0",
"playwright": "1.56.1",
"prettier": "3.9.6",
- "rollup": "4.63.1",
+ "rollup": "4.63.2",
"serve-handler": "6.1.7",
"tslib": "2.8.1",
"typescript": "5.9.3",
- "typescript-eslint": "8.69.0"
+ "typescript-eslint": "8.70.0"
},
"engines": {
"node": ">=18.0.0"
}
},
+ "node_modules/@cacheable/memory": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/@cacheable/memory/-/memory-2.2.0.tgz",
+ "integrity": "sha512-CTLKqLItRCEixEAewD3/j9DB3/o96gpTPD4eJ1v+DGOlxZRZncRQkGYqqnAGCscYd6RNeXfGeiuCphsPtqyIfQ==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "@cacheable/utils": "^2.5.0",
+ "@keyv/bigmap": "^1.3.1",
+ "hookified": "^1.15.1",
+ "keyv": "^5.6.0"
+ }
+ },
+ "node_modules/@cacheable/utils": {
+ "version": "2.5.0",
+ "resolved": "https://registry.npmjs.org/@cacheable/utils/-/utils-2.5.0.tgz",
+ "integrity": "sha512-buipgOVDkkPXNR5+xBpDw7Zk2n1EvU7qBJCNUcL7rhQ//kfpOXPAvQ511Os0vpLYJ1pZnvudNytkQt2hst3wqA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "hashery": "^1.5.1",
+ "keyv": "^5.6.0"
+ }
+ },
"node_modules/@eslint-community/eslint-utils": {
"version": "4.10.1",
"resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.10.1.tgz",
@@ -247,6 +271,30 @@
"dev": true,
"license": "MIT"
},
+ "node_modules/@keyv/bigmap": {
+ "version": "1.3.1",
+ "resolved": "https://registry.npmjs.org/@keyv/bigmap/-/bigmap-1.3.1.tgz",
+ "integrity": "sha512-WbzE9sdmQtKy8vrNPa9BRnwZh5UF4s1KTmSK0KUVLo3eff5BlQNNWDnFOouNpKfPKDnms9xynJjsMYjMaT/aFQ==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "hashery": "^1.4.0",
+ "hookified": "^1.15.0"
+ },
+ "engines": {
+ "node": ">= 18"
+ },
+ "peerDependencies": {
+ "keyv": "^5.6.0"
+ }
+ },
+ "node_modules/@keyv/serialize": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/@keyv/serialize/-/serialize-1.1.1.tgz",
+ "integrity": "sha512-dXn3FZhPv0US+7dtJsIi2R+c7qWYiReoEh5zUntWCf4oSpMNib8FDhSoed6m3QyZdx5hK7iLFkYk3rNxwt8vTA==",
+ "dev": true,
+ "license": "MIT"
+ },
"node_modules/@napi-rs/lzma-linux-x64-gnu": {
"version": "1.5.1",
"resolved": "https://registry.npmjs.org/@napi-rs/lzma-linux-x64-gnu/-/lzma-linux-x64-gnu-1.5.1.tgz",
@@ -367,9 +415,9 @@
}
},
"node_modules/@rollup/rollup-android-arm-eabi": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.63.1.tgz",
- "integrity": "sha512-UZ8sUxPTiHWYX9QNdJedb1kDZSpS1t/VPWBWGSgqHNi9w3Cu6IXvu2mzbhiTiPvtrqgTQJ+zqiAq2iPIPilpaQ==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.63.2.tgz",
+ "integrity": "sha512-Xa6RDoWa+hNiX6PgsljlH6W75RaONx3y6PVlbLhkEWW+GaPQ3dP5gwbL/erAzQHWwkvW5UxdD5l87Qx2FAQ/4A==",
"cpu": [
"arm"
],
@@ -381,9 +429,9 @@
]
},
"node_modules/@rollup/rollup-android-arm64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.63.1.tgz",
- "integrity": "sha512-cQ4nFQABN5cDvDpbvJ7bMStCpnaVxynZrRMfUJYgxcIk9Sh54FIO1vtfkg0B69REjER77ioZ/ov+eAApx/KmLQ==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.63.2.tgz",
+ "integrity": "sha512-vNASxsghMfQ5s+v3PrpnJd+ryL/26lxCCaGI+sDJ7VzmHiYXIrrVltsDhaawxLM1WcoMU2oYlbPHLaYQtBzhcg==",
"cpu": [
"arm64"
],
@@ -395,9 +443,9 @@
]
},
"node_modules/@rollup/rollup-darwin-arm64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.63.1.tgz",
- "integrity": "sha512-FQNqd1lRy/0QhDk3xeRIkSBiCpXCiDnZO3YLVdcDKN1UBiKToNftCzcXYNLshmPDUMlu2TdeS8tGcsU6f3YF1Q==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.63.2.tgz",
+ "integrity": "sha512-0dWDjmlrpZAgjPD/aPzUDhBW8APLRjAni5bOrM76wiiZm+E+KTMVKNhAzaTBohz8UyO2fKNAl0+fygbe2HZXOA==",
"cpu": [
"arm64"
],
@@ -409,9 +457,9 @@
]
},
"node_modules/@rollup/rollup-darwin-x64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.63.1.tgz",
- "integrity": "sha512-pvD16V939D3CloK0+qikpGaxiPrDUXTe7Y5cWOMkMSy7m1cawa8EGy/kXYi/G/cKAC4HDAbSnzCIk1WmsoOKXg==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.63.2.tgz",
+ "integrity": "sha512-N58uktcwzk3+qT4KHEuNdIxX1N01RWrkfVoml69EAbSaNDL+sbNVLx2RMl4Qd23lpA0fgPvyh5hHb4weD5WKmg==",
"cpu": [
"x64"
],
@@ -423,9 +471,9 @@
]
},
"node_modules/@rollup/rollup-freebsd-arm64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.63.1.tgz",
- "integrity": "sha512-pcFGeL2345VwdTnJhA6zLbew+YgWB0qBG2+dMtXjCicf6+rm6kO6cOoh5VnTe0ZMrMRgRyuHmCJxZWrIdzYuOw==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.63.2.tgz",
+ "integrity": "sha512-HWF2zH8EAp2scWRpt2PGe6iUGz7zi04waXsdRr3zb4DWCk2ImIo5FZu0jjmD53nP/DGSvnW0e7/1ToCNZs2lZw==",
"cpu": [
"arm64"
],
@@ -437,9 +485,9 @@
]
},
"node_modules/@rollup/rollup-freebsd-x64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.63.1.tgz",
- "integrity": "sha512-mRJlqSRulVzcKq/LKA6ICSIc3K/l4fzlVn/gePn2nXIHy8seRi5z/eeRE0d/XMBxcMldiXtQTSpRj0tkkC3g8Q==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.63.2.tgz",
+ "integrity": "sha512-MkvcwHMnzPSMOQEwB6wHnLzmc+hT8BGc5bW/Mhmjjgx3wbj6VBnlc47XsK74kD0K9MikFfXpQqyz4NUXaUW62A==",
"cpu": [
"x64"
],
@@ -451,9 +499,9 @@
]
},
"node_modules/@rollup/rollup-linux-arm-gnueabihf": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.63.1.tgz",
- "integrity": "sha512-YDUNvVM85TI3g/1OpnqKP1h4NeW/j64DfWMf+G3M809xNk1bJSnpFp4sh83NpmVE5DXnkh8ULor4LTVZKoYLHw==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.63.2.tgz",
+ "integrity": "sha512-xe1bCKPJaKsD0tfd7Rb6bGfUogJTpKbTEEthsfdb7hTfTRNJVQTdirabQx0o6ERVba/smkM720soMY+0QnrlSQ==",
"cpu": [
"arm"
],
@@ -465,9 +513,9 @@
]
},
"node_modules/@rollup/rollup-linux-arm-musleabihf": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.63.1.tgz",
- "integrity": "sha512-7Mcn71p9ZuQFAj+h+dhQXy/yeLePRS2yKRnmW1DijA9thKO5qap0GNOIQK4yQ6iP3SU0Mrb/yWo8h8vgRba8lw==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.63.2.tgz",
+ "integrity": "sha512-yOM7LdK0p6gk6+Q773OEwtlsikT1TL3yMmYsTtRlDRPha5vV2DC5x7LqRWDr6f3cSYNMKVqxzffXv8ivxNBIFQ==",
"cpu": [
"arm"
],
@@ -479,9 +527,9 @@
]
},
"node_modules/@rollup/rollup-linux-arm64-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.63.1.tgz",
- "integrity": "sha512-4YiLQTX6U4CSl0L9cluep9A9W6UmTfqBDc2/CH6wlu54pl4E7Jn3cOD8oxzvBDEGk/JMKgJ47C8g+radF7mwvg==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.63.2.tgz",
+ "integrity": "sha512-qiWuJJV3DybA2IfzvRimeKXGrGuVPv1zobSY/26KnP3HbV0VcNb3ECzgvtbvF3xjSMkcooou6HASXZuLdjnhpQ==",
"cpu": [
"arm64"
],
@@ -493,9 +541,9 @@
]
},
"node_modules/@rollup/rollup-linux-arm64-musl": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.63.1.tgz",
- "integrity": "sha512-2ra8F7w8OquwZN9z2/fKFnli69wa8PLwaVzRMIPGb13ByMJwC28Fbp8YcVGoUhlYMTt7j5j9bNgpysrN2UM+vw==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.63.2.tgz",
+ "integrity": "sha512-akcZquRzCY/KpUoZAMBhGf7oi4LmXq1BzRA5CPAC3rkUf28Y/sAYV3jSL+JKd7cwEyFvR5G0XVZ0gaMedP+60A==",
"cpu": [
"arm64"
],
@@ -507,9 +555,9 @@
]
},
"node_modules/@rollup/rollup-linux-loong64-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.63.1.tgz",
- "integrity": "sha512-Sy20ncyhjmBP0Ml+UvQbimjlk6VFgjW5uNP+qqwHB00mTE8Bl2C1TuHTlRwK2YoXeZbee5lP2XevBWVkAQAtSQ==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.63.2.tgz",
+ "integrity": "sha512-fNwYHrPyYyxauPzX/cpYw8Z7LQpp+DGA0KCoswA0aVFBpmdMil9XgjB8V3Ny64Ihu797+GKcuJqnsOKEmor7fA==",
"cpu": [
"loong64"
],
@@ -521,9 +569,9 @@
]
},
"node_modules/@rollup/rollup-linux-loong64-musl": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-musl/-/rollup-linux-loong64-musl-4.63.1.tgz",
- "integrity": "sha512-noITLp8oNjYliPnGWmLyelIHwULGqbHloQHGw1rtxbWhTuWooRpnZarZQJ1y9EUC4szuCusCc+HEpUtxpIwYvA==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-musl/-/rollup-linux-loong64-musl-4.63.2.tgz",
+ "integrity": "sha512-XfvsgzR7DZqREdst7K1Mj3ilSUM5xLAHJcIMDFPKdxTs9q5VHOT8aMA+a683fqBu7DQl8+Sd9HCsQYL8EMY9qA==",
"cpu": [
"loong64"
],
@@ -535,9 +583,9 @@
]
},
"node_modules/@rollup/rollup-linux-ppc64-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.63.1.tgz",
- "integrity": "sha512-hlxxXd+F1mWiAcaFR7Sv9ZQT6m6UfI8+Vy/kFJzztq2pDMU/0wZ9sish0iszNZvsQDo8Gc0i5yuFEOz5dDf6fA==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.63.2.tgz",
+ "integrity": "sha512-Pp7gVZggEFlbcuztay+/U0gVG9S1XAh8i7I1Re/htbAzo43P5wHZHw6pTyzotISqlKohoh9RpIfnOz3RbemK1w==",
"cpu": [
"ppc64"
],
@@ -549,9 +597,9 @@
]
},
"node_modules/@rollup/rollup-linux-ppc64-musl": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-musl/-/rollup-linux-ppc64-musl-4.63.1.tgz",
- "integrity": "sha512-EF7OpqQTQ/BvGqLzUi4rEHuagCV9MugAUXSHemwPW5vxZ75RR+jxO/2j95Ph2dalMpFHSVECjRoioHZgA9zOYA==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-musl/-/rollup-linux-ppc64-musl-4.63.2.tgz",
+ "integrity": "sha512-zkgL2xff6i7u5hau/m6FGeS8gRkLEdgLw522WGmdWWlLd9btmNl3S80mcEjtGq+kvgUekQ3+BOYLLLcPlS2LIA==",
"cpu": [
"ppc64"
],
@@ -563,9 +611,9 @@
]
},
"node_modules/@rollup/rollup-linux-riscv64-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.63.1.tgz",
- "integrity": "sha512-wQO3JesW9PRkwlabQ27y7sPfVOOTLRG73I4F2UYHG5PXun3J9U3y+b7ezVKSYbsvSKGQ1k1cq8Qlun4C9kLt3w==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.63.2.tgz",
+ "integrity": "sha512-qOheJomrkVCbbHFJ7L3J97cnhfogKqguAQphv26+3ZsAQIF1L19b+dArl//s8rjJHJLz9byykyM8NBP4nmSa1g==",
"cpu": [
"riscv64"
],
@@ -577,9 +625,9 @@
]
},
"node_modules/@rollup/rollup-linux-riscv64-musl": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.63.1.tgz",
- "integrity": "sha512-ouAGwhO6wHRXdnOVCOsB0tRFkA7nhNB2Nwax6oECXN0YiN8EYUTBAOudADOB1PI+yDL61TeNx/u7MVCzksNbkQ==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.63.2.tgz",
+ "integrity": "sha512-XlxLD54wQhH3FciCgMofxBw27NzUe818gJH410qWvc41UT0ZFcgxVjyX5/EK8MPTupjeVWqN5oy+9pCA9mqfCA==",
"cpu": [
"riscv64"
],
@@ -591,9 +639,9 @@
]
},
"node_modules/@rollup/rollup-linux-s390x-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.63.1.tgz",
- "integrity": "sha512-q2R38Sn+1J8RxhfJ+T54wSWmyKXWec+9jgDfqO2AtArEqHO5R2aeayp5H5OYLr5UYDVGsVaZPEFUooMhYCdz5A==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.63.2.tgz",
+ "integrity": "sha512-vdryWeRb2bLJZf0Fv/W8se6nvsHe2PkTCxV0meheK3nQE+G90VCJcke51Miy1yQRsfm2uqIyjXOu4wmUzbTtkQ==",
"cpu": [
"s390x"
],
@@ -605,9 +653,9 @@
]
},
"node_modules/@rollup/rollup-linux-x64-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.63.1.tgz",
- "integrity": "sha512-gfI5T24WLLuFfSKw7Go/zDXjAAV0fny0swTaDv+WjK7vqcw4cRhFfdsyKL1n+ukI+ooBxn3bVQnyrn06WpI50w==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.63.2.tgz",
+ "integrity": "sha512-bcq2h2pkKmH2po4cZV8VWzO4lL40STyu/nLoFpYMQp9C2tCVNTdcVv86MwSsn3D5s1FBe2Ty1atqvVAUTMimNg==",
"cpu": [
"x64"
],
@@ -619,9 +667,9 @@
]
},
"node_modules/@rollup/rollup-linux-x64-musl": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.63.1.tgz",
- "integrity": "sha512-4h6XqthmB4Hspji84wvgk+ElodTsGj+dbZqHJHHtKxj4mYq0ANSEEPX9ys3moJueqsRjwpaJYH7874Itwnj2ow==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.63.2.tgz",
+ "integrity": "sha512-EGoo5DMVMRkTId8fuTDaoxVlR5ZTsKULUezRjd9gCw5eeY+DjCvDpZAOlNUvKPGX+7rS1RWx6j+yOpNPx0cUgQ==",
"cpu": [
"x64"
],
@@ -633,9 +681,9 @@
]
},
"node_modules/@rollup/rollup-openbsd-x64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-openbsd-x64/-/rollup-openbsd-x64-4.63.1.tgz",
- "integrity": "sha512-dlfCOa87o1VAYegLQ9EKilx2JCeRofiyPGhTCmqnuXZ6bMPiycO1rq1+sKoulAp7pGLIsTIw+1x5R+zgh5LhhA==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-openbsd-x64/-/rollup-openbsd-x64-4.63.2.tgz",
+ "integrity": "sha512-MErl12k7BFHZG1TI9QF/3lSSZARzq9KgNy/FjnqFMCkv+N4RSSzoUCA5h2mqHX4Mox3WaTVKblyzhQ1zRb2ZuQ==",
"cpu": [
"x64"
],
@@ -647,9 +695,9 @@
]
},
"node_modules/@rollup/rollup-openharmony-arm64": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.63.1.tgz",
- "integrity": "sha512-cjkLbOlfcm3QGhMM1J5zaZjsw1GggbN6rw9UTSSRrPrR1KkcXnN7Uq9rPw34xImQ9VOY9GN+6u2Zj80B9ptkcw==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.63.2.tgz",
+ "integrity": "sha512-ILs8k07Wh4p0PsNY4wYLEaXZKMOpVhrG5QDB0yHhGhuzOfDlnyHN6sflL4El/MpUP1y8uY2lUZrv4oBS6pTT3g==",
"cpu": [
"arm64"
],
@@ -661,9 +709,9 @@
]
},
"node_modules/@rollup/rollup-win32-arm64-msvc": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.63.1.tgz",
- "integrity": "sha512-Li1KdUnWGE4N3e1F/B4RTB1ms+nG4WBgjByO46pkeBVX/2UBsY53xf5vK9WygVmnH3RwncIST7lkSdLSY6P9lg==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.63.2.tgz",
+ "integrity": "sha512-hKgB3nz/TKD3Wv78XEsyXzQsNjvhOHmwKQTvXADGOyU/cIClZDO7DsoggbdmJDPGp5V80tA3Vfv61PaKTLH3LA==",
"cpu": [
"arm64"
],
@@ -675,9 +723,9 @@
]
},
"node_modules/@rollup/rollup-win32-ia32-msvc": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.63.1.tgz",
- "integrity": "sha512-t4ZYOSoLTgwhuFMrmTMLx/+i1DQVK7HYqMc6kY46EApwi8X0nIVphzdNoThU3xt6n+N5urG1/gxBdCaKDLavfg==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.63.2.tgz",
+ "integrity": "sha512-T4wf1mudIDxN8Q/CWIBJC1u5gQUc+r5mPvlwoSbIvNkyVTP2TAFeobEmst5AQ4gMyAz4sSByVdoTDfvTmGK/8g==",
"cpu": [
"ia32"
],
@@ -689,9 +737,9 @@
]
},
"node_modules/@rollup/rollup-win32-x64-gnu": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.63.1.tgz",
- "integrity": "sha512-RgroPfMmKlD1RzSDxvwgcPiy2HNQKoYV7OmwIXDsk73uKW5t6B/V8KIy27SMv/FNXFo/oSBtWc9J0X7t91ezZg==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.63.2.tgz",
+ "integrity": "sha512-tC3IY7qoaD9Ll3/8WJQn49j5V2f/NuI9S41NOE2iM5MPs3sPIvOkVToLcz/7Bz4pyF7PSvrtwu8I/pUrGOSecQ==",
"cpu": [
"x64"
],
@@ -703,9 +751,9 @@
]
},
"node_modules/@rollup/rollup-win32-x64-msvc": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.63.1.tgz",
- "integrity": "sha512-at8QVep6S3h5Y6gSbdGU06bRY5WJkf6WUduM9YtvYMbYhB1MOFfUgc6kehitQXzOtMSaT70q7f9ydPhpqu821w==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.63.2.tgz",
+ "integrity": "sha512-6NHnk/K3eq2ZFYcU1X8g67s9qIJRCOTT92gwLMVBp08dB2uuuwI1/Q/empzL2Bfr2f2WRLJVwpp90RmacQyFkw==",
"cpu": [
"x64"
],
@@ -752,17 +800,17 @@
"license": "MIT"
},
"node_modules/@typescript-eslint/eslint-plugin": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.69.0.tgz",
- "integrity": "sha512-t5jQTKPIgVW1PE6dR6H6Qz5gm8zjMlX5/2gRaOGd9eO6V7J+tQc6iWKukEe7dY8u9HyYasQ0yfF0/FSSTEO2gA==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.70.0.tgz",
+ "integrity": "sha512-/v8HZt6RlyIZxB3ntehELOcUcfxKPVGWXnQdJuHRmzrqgF8nQypcC/oxGW+Ot4VGKDq81XugPKxx0n5PBtf9PA==",
"dev": true,
"license": "MIT",
"dependencies": {
"@eslint-community/regexpp": "^4.12.2",
- "@typescript-eslint/scope-manager": "8.69.0",
- "@typescript-eslint/type-utils": "8.69.0",
- "@typescript-eslint/utils": "8.69.0",
- "@typescript-eslint/visitor-keys": "8.69.0",
+ "@typescript-eslint/scope-manager": "8.70.0",
+ "@typescript-eslint/type-utils": "8.70.0",
+ "@typescript-eslint/utils": "8.70.0",
+ "@typescript-eslint/visitor-keys": "8.70.0",
"ignore": "^7.0.5",
"natural-compare": "^1.4.0",
"ts-api-utils": "^2.5.0"
@@ -775,15 +823,15 @@
"url": "https://opencollective.com/typescript-eslint"
},
"peerDependencies": {
- "@typescript-eslint/parser": "^8.69.0",
+ "@typescript-eslint/parser": "^8.70.0",
"eslint": "^8.57.0 || ^9.0.0 || ^10.0.0",
"typescript": ">=4.8.4 <6.1.0"
}
},
"node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore": {
- "version": "7.0.8",
- "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.8.tgz",
- "integrity": "sha512-YYNsSlXBjMk92SKnkwvB5LOVSa6OznlFUGcsvrFgNJbJCd0M1XKeFVRc8ZByeCqz32FivYNHJVooLmdqrmvp/Q==",
+ "version": "7.0.10",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.10.tgz",
+ "integrity": "sha512-HpbUakT7xp5miBUywCHf36ZEuAJNklBJDDsGpUIjMzOSmM8ELSfA9Sa/QDPeNeqeoN31u+UTCkL4klCOVvRm4Q==",
"dev": true,
"license": "MIT",
"engines": {
@@ -791,16 +839,16 @@
}
},
"node_modules/@typescript-eslint/parser": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.69.0.tgz",
- "integrity": "sha512-l4b0DhWioGg6Gt2ebGlvfkFMOjRsauxtsnDRwUSRX1qHq3HdTfQHV8wW9zEXeciai6HfeaKOedQn2Zoofx3WBw==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.70.0.tgz",
+ "integrity": "sha512-zYvrmj9Yxd63UGaXw+kdt6A0F0s0qveJyuatIM77bYC2DE4pgmg7a50u8LR7PRtXd0x+h+Tl3eXabGm06SWd3Q==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/scope-manager": "8.69.0",
- "@typescript-eslint/types": "8.69.0",
- "@typescript-eslint/typescript-estree": "8.69.0",
- "@typescript-eslint/visitor-keys": "8.69.0",
+ "@typescript-eslint/scope-manager": "8.70.0",
+ "@typescript-eslint/types": "8.70.0",
+ "@typescript-eslint/typescript-estree": "8.70.0",
+ "@typescript-eslint/visitor-keys": "8.70.0",
"debug": "^4.4.3"
},
"engines": {
@@ -816,14 +864,14 @@
}
},
"node_modules/@typescript-eslint/project-service": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.69.0.tgz",
- "integrity": "sha512-yi4obFrHMmnsesWehHbkg9zMA7Jt8cXT+mKM08G999pH1yT6nqgsHx7MYm0uY1wAj8CqiBXYRJ7WAT0QdQHQXg==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.70.0.tgz",
+ "integrity": "sha512-hFHbTNqhU9G+2eKFXCBVb1tjFT/LceiJ4+HfLO4pTpDI0KHi6iajpcFFkaSQ9gXmCh7n82A0PthaayEdN6mspQ==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/tsconfig-utils": "^8.69.0",
- "@typescript-eslint/types": "^8.69.0",
+ "@typescript-eslint/tsconfig-utils": "^8.70.0",
+ "@typescript-eslint/types": "^8.70.0",
"debug": "^4.4.3"
},
"engines": {
@@ -838,14 +886,14 @@
}
},
"node_modules/@typescript-eslint/scope-manager": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.69.0.tgz",
- "integrity": "sha512-ewfspqWvSxKSOaplqAUNbaSFO0eB6w1EtQ+esfYFRm3614Ty4uNtExkcbgd6nWsXphbqKyf9ZYdbZdv2xEoWEQ==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.70.0.tgz",
+ "integrity": "sha512-8nP3Kwh5hlgZ4FicGvmznAmJe8UL4sdU8tLukrPaMuQmDuk4Y8xYfzu/aYZW4xT2JCgc7H/TpDI5cGlxcWJSqQ==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/types": "8.69.0",
- "@typescript-eslint/visitor-keys": "8.69.0"
+ "@typescript-eslint/types": "8.70.0",
+ "@typescript-eslint/visitor-keys": "8.70.0"
},
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -856,9 +904,9 @@
}
},
"node_modules/@typescript-eslint/tsconfig-utils": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.69.0.tgz",
- "integrity": "sha512-xNqK7YTDZsLniQMV/4rpFR8Z5JlqeRvVjuG1YgF/mdPVH84HSD19L8CczMA0qg2RfwEV231GHH3VnToJDo4MfQ==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.70.0.tgz",
+ "integrity": "sha512-adnkeeNq9Sq1sUf4+FRVc0KdgYghzsgFpZSQVZVvY0LCuUuN0FnQgyGzCJeC4fW1cdXseBAjU2EOqUIjbNcZUw==",
"dev": true,
"license": "MIT",
"engines": {
@@ -873,15 +921,15 @@
}
},
"node_modules/@typescript-eslint/type-utils": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.69.0.tgz",
- "integrity": "sha512-ZfoJAVg3JZndQEpEl9petVlxau3lRuElc4HRMuAlLCf8to04/iHz692RUSNmXKDjEuJmIL+KZ2/BsOcBc16dsA==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.70.0.tgz",
+ "integrity": "sha512-NUMKIhYVaVIVLnRL9CRt+VVcuLgSHUCpXn4/+K8wql+vdInUzvx8BjUO1oJ7cG9shjFJKtF8F8Hh2kCh3/KBVw==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/types": "8.69.0",
- "@typescript-eslint/typescript-estree": "8.69.0",
- "@typescript-eslint/utils": "8.69.0",
+ "@typescript-eslint/types": "8.70.0",
+ "@typescript-eslint/typescript-estree": "8.70.0",
+ "@typescript-eslint/utils": "8.70.0",
"debug": "^4.4.3",
"ts-api-utils": "^2.5.0"
},
@@ -898,9 +946,9 @@
}
},
"node_modules/@typescript-eslint/types": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.69.0.tgz",
- "integrity": "sha512-K3VrubUPhlo9VDBS6QdI8YB5j7ClpqLRdefcz6PFrhnwicehBweqQ9Evhl4l+FYz0HdDmMqIiSX0aldGRYtDCA==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.70.0.tgz",
+ "integrity": "sha512-asTOIYhDg4zdzOScCyaytrsV3cR6B4ecPQlXw/dJIm7J/MZTtCtfVII9JD8Geh4jTCrK/Xe6cg5UevoleMcoJQ==",
"dev": true,
"license": "MIT",
"engines": {
@@ -912,16 +960,16 @@
}
},
"node_modules/@typescript-eslint/typescript-estree": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.69.0.tgz",
- "integrity": "sha512-AdFkgqck3Vudb/kWnxlyafU/4aBhHrbQ9locP2N4psXTy5mOBg0SHJumnLvx7r6g1gV4DKvUFwV2nJZBoqOD8w==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.70.0.tgz",
+ "integrity": "sha512-d9NmHMPEKQ7QCLLm1jI3zmoQBwT5KwFYjXBJ9ymZfKCUU+5rmTRykKAFvH5Qn/ZCds3CEAFS9OC9M/jkl0X2bA==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/project-service": "8.69.0",
- "@typescript-eslint/tsconfig-utils": "8.69.0",
- "@typescript-eslint/types": "8.69.0",
- "@typescript-eslint/visitor-keys": "8.69.0",
+ "@typescript-eslint/project-service": "8.70.0",
+ "@typescript-eslint/tsconfig-utils": "8.70.0",
+ "@typescript-eslint/types": "8.70.0",
+ "@typescript-eslint/visitor-keys": "8.70.0",
"debug": "^4.4.3",
"minimatch": "^10.2.2",
"semver": "^7.7.3",
@@ -956,16 +1004,16 @@
}
},
"node_modules/@typescript-eslint/utils": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.69.0.tgz",
- "integrity": "sha512-tUbx60BBqQa31kXF5MCsOOLL5E/WzUuxIn7YpAvq+eaUlqvk8/NXnXMBNAdLCr0icjkzem7iUA5QqWHe/hJ1aw==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.70.0.tgz",
+ "integrity": "sha512-oZmtKJz/4fufZ2p3+Cn3ijEojcdfR+1zYDH2xKYrEly0dR/Q/1xUPRCOlKGxod78nWlU2UnDe09GZ3TaknBFGA==",
"dev": true,
"license": "MIT",
"dependencies": {
"@eslint-community/eslint-utils": "^4.9.1",
- "@typescript-eslint/scope-manager": "8.69.0",
- "@typescript-eslint/types": "8.69.0",
- "@typescript-eslint/typescript-estree": "8.69.0"
+ "@typescript-eslint/scope-manager": "8.70.0",
+ "@typescript-eslint/types": "8.70.0",
+ "@typescript-eslint/typescript-estree": "8.70.0"
},
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -980,13 +1028,13 @@
}
},
"node_modules/@typescript-eslint/visitor-keys": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.69.0.tgz",
- "integrity": "sha512-+rmdgPA+EXkNgKYvHvFfhrs35utXbwaC5PGpDquSXcoXQDKUA5UjV0LmTucG/4JXkM31BTu4TilHtrN8IVBe8w==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.70.0.tgz",
+ "integrity": "sha512-BoC8PiO4Hkdo0TVJh9Ntxr5MxPDI7/oFsrygN5ADelFSeXG/qgNuucIGA+L5Z6JpPTE/uRfcTWtscjbUaufepQ==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/types": "8.69.0",
+ "@typescript-eslint/types": "8.70.0",
"eslint-visitor-keys": "^5.0.0"
},
"engines": {
@@ -1079,6 +1127,20 @@
"node": ">= 0.8"
}
},
+ "node_modules/cacheable": {
+ "version": "2.5.0",
+ "resolved": "https://registry.npmjs.org/cacheable/-/cacheable-2.5.0.tgz",
+ "integrity": "sha512-60cyAOytib/OzBw1JNSoSV/boK1AtHryDIjvVBk7XbN4ugfkM3+Sry7fEjNgPMGgOjuaZPAp8ruZ0Cxafwyq9g==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "@cacheable/memory": "^2.2.0",
+ "@cacheable/utils": "^2.5.0",
+ "hookified": "^1.15.0",
+ "keyv": "^5.6.0",
+ "qified": "^0.10.1"
+ }
+ },
"node_modules/commondir": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz",
@@ -1170,9 +1232,9 @@
}
},
"node_modules/eslint": {
- "version": "10.9.1",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-10.9.1.tgz",
- "integrity": "sha512-9VaAkDURekixUQJy0oJYl2DcN6oKMfxay7XzaGYAWQwsb6qfKf+x76R2k1L8kb1boc+FyCAaTA9GmiKaaiaF+A==",
+ "version": "10.10.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-10.10.0.tgz",
+ "integrity": "sha512-NPXn6r5zl4uET1DAVPaOwzX3rut4c0wcmw3dWJAfOsTM5+TogXo0DDjz8pwm/hL8cyVNpHqeK4JpN0NjnyFFNw==",
"dev": true,
"license": "MIT",
"workspaces": [
@@ -1184,7 +1246,7 @@
"@eslint/config-array": "^0.23.5",
"@eslint/config-helpers": "^0.7.0",
"@eslint/core": "^1.2.1",
- "@eslint/plugin-kit": "^0.7.2",
+ "@eslint/plugin-kit": "^0.7.3",
"@humanfs/node": "^0.16.6",
"@humanwhocodes/module-importer": "^1.0.1",
"@humanwhocodes/retry": "^0.4.2",
@@ -1199,7 +1261,7 @@
"esquery": "^1.7.0",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
- "file-entry-cache": "^8.0.0",
+ "file-entry-cache": "11.1.5 || >11.1.6 <12",
"find-up": "^5.0.0",
"glob-parent": "^6.0.2",
"ignore": "^5.2.0",
@@ -1387,16 +1449,13 @@
}
},
"node_modules/file-entry-cache": {
- "version": "8.0.0",
- "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz",
- "integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==",
+ "version": "11.1.5",
+ "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-11.1.5.tgz",
+ "integrity": "sha512-+PFTHITI08JIGhnNpGNI8T8inUpgZfk3GNEqfT9R2zZV2iFXg3CvqzSl/uEhs7TSGujYRELEANyDvS8Fj7+S7Q==",
"dev": true,
"license": "MIT",
"dependencies": {
- "flat-cache": "^4.0.0"
- },
- "engines": {
- "node": ">=16.0.0"
+ "flat-cache": "^6.1.23"
}
},
"node_modules/find-up": {
@@ -1417,17 +1476,15 @@
}
},
"node_modules/flat-cache": {
- "version": "4.0.1",
- "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz",
- "integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==",
+ "version": "6.1.23",
+ "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-6.1.23.tgz",
+ "integrity": "sha512-f++BY9pTk+983xK1FLzlLpmM0i0z+jHmx3QESGkURMXujQZz1k5wzwX6hjnQ8goaD0B+sYnDK1yZ6MTyZfUaqA==",
"dev": true,
"license": "MIT",
"dependencies": {
- "flatted": "^3.2.9",
- "keyv": "^4.5.4"
- },
- "engines": {
- "node": ">=16"
+ "cacheable": "^2.5.0",
+ "flatted": "^3.4.2",
+ "hookified": "^1.15.0"
}
},
"node_modules/flatted": {
@@ -1475,6 +1532,19 @@
"node": ">=10.13.0"
}
},
+ "node_modules/hashery": {
+ "version": "1.5.1",
+ "resolved": "https://registry.npmjs.org/hashery/-/hashery-1.5.1.tgz",
+ "integrity": "sha512-iZyKG96/JwPz1N55vj2Ie2vXbhu440zfUfJvSwEqEbeLluk7NnapfGqa7LH0mOsnDxTF85Mx8/dyR6HfqcbmbQ==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "hookified": "^1.15.0"
+ },
+ "engines": {
+ "node": ">=20"
+ }
+ },
"node_modules/hasown": {
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.4.tgz",
@@ -1488,6 +1558,13 @@
"node": ">= 0.4"
}
},
+ "node_modules/hookified": {
+ "version": "1.15.1",
+ "resolved": "https://registry.npmjs.org/hookified/-/hookified-1.15.1.tgz",
+ "integrity": "sha512-MvG/clsADq1GPM2KGo2nyfaWVyn9naPiXrqIe4jYjXNZQt238kWyOGrsyc/DmRAQ+Re6yeo6yX/yoNCG5KAEVg==",
+ "dev": true,
+ "license": "MIT"
+ },
"node_modules/ignore": {
"version": "5.3.2",
"resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz",
@@ -1580,13 +1657,6 @@
"bignumber.js": "^9.0.0"
}
},
- "node_modules/json-buffer": {
- "version": "3.0.1",
- "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz",
- "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==",
- "dev": true,
- "license": "MIT"
- },
"node_modules/json-schema-traverse": {
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
@@ -1602,13 +1672,13 @@
"license": "MIT"
},
"node_modules/keyv": {
- "version": "4.5.4",
- "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz",
- "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==",
+ "version": "5.6.0",
+ "resolved": "https://registry.npmjs.org/keyv/-/keyv-5.6.0.tgz",
+ "integrity": "sha512-CYDD3SOtsHtyXeEORYRx2qBtpDJFjRTGXUtmNEMGyzYOKj1TE3tycdlho7kA1Ufx9OYWZzg52QFBGALTirzDSw==",
"dev": true,
"license": "MIT",
"dependencies": {
- "json-buffer": "3.0.1"
+ "@keyv/serialize": "^1.1.1"
}
},
"node_modules/levn": {
@@ -1873,6 +1943,26 @@
"node": ">=6"
}
},
+ "node_modules/qified": {
+ "version": "0.10.1",
+ "resolved": "https://registry.npmjs.org/qified/-/qified-0.10.1.tgz",
+ "integrity": "sha512-+Owyggi9IxT1ePKGafcI87ubSmxol6smwJ+RAHDQlx9+9cPwFWDiKFFCPuWhr9ignlGpZ9vDQLw67N4dcTVFEA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "hookified": "^2.1.1"
+ },
+ "engines": {
+ "node": ">=20"
+ }
+ },
+ "node_modules/qified/node_modules/hookified": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/hookified/-/hookified-2.2.0.tgz",
+ "integrity": "sha512-p/LgFzRN5FeoD3DLS6bkUapeye6E4SI6yJs6KetENd18S+FBthqYq2amJUWpt5z0EQwwHemidjY5OqJGEKm5uA==",
+ "dev": true,
+ "license": "MIT"
+ },
"node_modules/range-parser": {
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.0.tgz",
@@ -1906,9 +1996,9 @@
}
},
"node_modules/rollup": {
- "version": "4.63.1",
- "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.63.1.tgz",
- "integrity": "sha512-3Df9jsstwhccuEfmAMi9l8XUh/GOkVObmFTU7CCVBysEbcOZLl84jCtaAZMcPiMz2EGKsATzQcU+Xr3n/wU6cg==",
+ "version": "4.63.2",
+ "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.63.2.tgz",
+ "integrity": "sha512-l5eyksV4tPBj6lJyEa37YzIOCSOV7lkZzEHUdpjWZbtD7wTcFYmEYXSgm5bT4vV+dZLb9rBG1W9GROOG4NS4Ew==",
"dev": true,
"license": "MIT",
"dependencies": {
@@ -1923,31 +2013,31 @@
},
"optionalDependencies": {
"@napi-rs/lzma-linux-x64-gnu": "1.5.1",
- "@rollup/rollup-android-arm-eabi": "4.63.1",
- "@rollup/rollup-android-arm64": "4.63.1",
- "@rollup/rollup-darwin-arm64": "4.63.1",
- "@rollup/rollup-darwin-x64": "4.63.1",
- "@rollup/rollup-freebsd-arm64": "4.63.1",
- "@rollup/rollup-freebsd-x64": "4.63.1",
- "@rollup/rollup-linux-arm-gnueabihf": "4.63.1",
- "@rollup/rollup-linux-arm-musleabihf": "4.63.1",
- "@rollup/rollup-linux-arm64-gnu": "4.63.1",
- "@rollup/rollup-linux-arm64-musl": "4.63.1",
- "@rollup/rollup-linux-loong64-gnu": "4.63.1",
- "@rollup/rollup-linux-loong64-musl": "4.63.1",
- "@rollup/rollup-linux-ppc64-gnu": "4.63.1",
- "@rollup/rollup-linux-ppc64-musl": "4.63.1",
- "@rollup/rollup-linux-riscv64-gnu": "4.63.1",
- "@rollup/rollup-linux-riscv64-musl": "4.63.1",
- "@rollup/rollup-linux-s390x-gnu": "4.63.1",
- "@rollup/rollup-linux-x64-gnu": "4.63.1",
- "@rollup/rollup-linux-x64-musl": "4.63.1",
- "@rollup/rollup-openbsd-x64": "4.63.1",
- "@rollup/rollup-openharmony-arm64": "4.63.1",
- "@rollup/rollup-win32-arm64-msvc": "4.63.1",
- "@rollup/rollup-win32-ia32-msvc": "4.63.1",
- "@rollup/rollup-win32-x64-gnu": "4.63.1",
- "@rollup/rollup-win32-x64-msvc": "4.63.1",
+ "@rollup/rollup-android-arm-eabi": "4.63.2",
+ "@rollup/rollup-android-arm64": "4.63.2",
+ "@rollup/rollup-darwin-arm64": "4.63.2",
+ "@rollup/rollup-darwin-x64": "4.63.2",
+ "@rollup/rollup-freebsd-arm64": "4.63.2",
+ "@rollup/rollup-freebsd-x64": "4.63.2",
+ "@rollup/rollup-linux-arm-gnueabihf": "4.63.2",
+ "@rollup/rollup-linux-arm-musleabihf": "4.63.2",
+ "@rollup/rollup-linux-arm64-gnu": "4.63.2",
+ "@rollup/rollup-linux-arm64-musl": "4.63.2",
+ "@rollup/rollup-linux-loong64-gnu": "4.63.2",
+ "@rollup/rollup-linux-loong64-musl": "4.63.2",
+ "@rollup/rollup-linux-ppc64-gnu": "4.63.2",
+ "@rollup/rollup-linux-ppc64-musl": "4.63.2",
+ "@rollup/rollup-linux-riscv64-gnu": "4.63.2",
+ "@rollup/rollup-linux-riscv64-musl": "4.63.2",
+ "@rollup/rollup-linux-s390x-gnu": "4.63.2",
+ "@rollup/rollup-linux-x64-gnu": "4.63.2",
+ "@rollup/rollup-linux-x64-musl": "4.63.2",
+ "@rollup/rollup-openbsd-x64": "4.63.2",
+ "@rollup/rollup-openharmony-arm64": "4.63.2",
+ "@rollup/rollup-win32-arm64-msvc": "4.63.2",
+ "@rollup/rollup-win32-ia32-msvc": "4.63.2",
+ "@rollup/rollup-win32-x64-gnu": "4.63.2",
+ "@rollup/rollup-win32-x64-msvc": "4.63.2",
"fsevents": "~2.3.2"
}
},
@@ -2081,16 +2171,16 @@
}
},
"node_modules/typescript-eslint": {
- "version": "8.69.0",
- "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.69.0.tgz",
- "integrity": "sha512-B3MltX0VqjUBNEe3b3sSuiRbfa6XrfHFtBiPamjT5AsW/dfq+y+bc0wyuS9DxAS1LyzCxRp2+rxzpLUvqM2BvA==",
+ "version": "8.70.0",
+ "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.70.0.tgz",
+ "integrity": "sha512-P/W5cz70/cQAuKfY3xwQMWWTV7BvJ0mAQmi+9mBcsVPaBUpd6Ohpa+fECv9rBFrQcig86jAiNBFNWUqnTjr4pw==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@typescript-eslint/eslint-plugin": "8.69.0",
- "@typescript-eslint/parser": "8.69.0",
- "@typescript-eslint/typescript-estree": "8.69.0",
- "@typescript-eslint/utils": "8.69.0"
+ "@typescript-eslint/eslint-plugin": "8.70.0",
+ "@typescript-eslint/parser": "8.70.0",
+ "@typescript-eslint/typescript-estree": "8.70.0",
+ "@typescript-eslint/utils": "8.70.0"
},
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
diff --git a/package.json b/package.json
index 7f56a38..4e3da6a 100644
--- a/package.json
+++ b/package.json
@@ -2,7 +2,7 @@
"name": "appwrite",
"homepage": "https://appwrite.io/support",
"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",
- "version": "27.0.0",
+ "version": "28.0.0",
"license": "BSD-3-Clause",
"main": "dist/cjs/sdk.js",
"exports": {
@@ -45,14 +45,14 @@
"@rollup/plugin-node-resolve": "16.0.3",
"@rollup/plugin-typescript": "12.3.0",
"@types/json-bigint": "1.0.4",
- "eslint": "10.9.1",
+ "eslint": "10.10.0",
"playwright": "1.56.1",
"prettier": "3.9.6",
- "rollup": "4.63.1",
+ "rollup": "4.63.2",
"serve-handler": "6.1.7",
"tslib": "2.8.1",
"typescript": "5.9.3",
- "typescript-eslint": "8.69.0"
+ "typescript-eslint": "8.70.0"
},
"overrides": {
"brace-expansion": "5.0.9"
diff --git a/src/client.ts b/src/client.ts
index 20382a6..89e59bd 100644
--- a/src/client.ts
+++ b/src/client.ts
@@ -373,7 +373,6 @@ class Client {
bearer: string;
locale: string;
session: string;
- devkey: string;
cookie: string;
impersonateuserid: string;
impersonateuseremail: string;
@@ -386,7 +385,6 @@ class Client {
bearer: '',
locale: '',
session: '',
- devkey: '',
cookie: '',
impersonateuserid: '',
impersonateuseremail: '',
@@ -399,8 +397,8 @@ class Client {
'x-sdk-name': 'Web',
'x-sdk-platform': 'client',
'x-sdk-language': 'web',
- 'x-sdk-version': '27.0.0',
- 'X-Appwrite-Response-Format': '2.0.0',
+ 'x-sdk-version': '28.0.0',
+ 'X-Appwrite-Response-Format': '2.3.0',
};
/**
@@ -536,20 +534,6 @@ class Client {
this.config.session = value;
return this;
}
- /**
- * Set DevKey
- *
- * Your secret dev API key
- *
- * @param value string
- *
- * @return {this}
- */
- setDevKey(value: string): this {
- this.headers['X-Appwrite-Dev-Key'] = value;
- this.config.devkey = value;
- return this;
- }
/**
* Set Cookie
*
@@ -978,12 +962,9 @@ class Client {
const options: RequestInit = {
method,
headers,
+ credentials: 'include',
};
- if (headers['X-Appwrite-Dev-Key'] === undefined) {
- options.credentials = 'include';
- }
-
if (method === 'GET') {
for (const [key, value] of Object.entries(Client.flatten(params))) {
url.searchParams.append(key, value);
diff --git a/src/enums/id-token-provider.ts b/src/enums/id-token-provider.ts
new file mode 100644
index 0000000..4f99708
--- /dev/null
+++ b/src/enums/id-token-provider.ts
@@ -0,0 +1,4 @@
+export enum IdTokenProvider {
+ Apple = 'apple',
+ Google = 'google',
+}
diff --git a/src/enums/o-auth-provider.ts b/src/enums/o-auth-provider.ts
index 2d838dd..92a9597 100644
--- a/src/enums/o-auth-provider.ts
+++ b/src/enums/o-auth-provider.ts
@@ -21,6 +21,7 @@ export enum OAuthProvider {
Gitlab = 'gitlab',
Google = 'google',
Huggingface = 'huggingface',
+ Kakao = 'kakao',
Keycloak = 'keycloak',
Kick = 'kick',
Linkedin = 'linkedin',
@@ -36,6 +37,7 @@ export enum OAuthProvider {
Slack = 'slack',
Spotify = 'spotify',
Stripe = 'stripe',
+ Tiktok = 'tiktok',
Tradeshift = 'tradeshift',
TradeshiftBox = 'tradeshiftBox',
Twitch = 'twitch',
diff --git a/src/index.ts b/src/index.ts
index 8956bf1..81ea122 100644
--- a/src/index.ts
+++ b/src/index.ts
@@ -1,7 +1,7 @@
/**
* Appwrite Web SDK
*
- * This SDK targets Appwrite server version 2.0.x as shipped on Appwrite Cloud.
+ * This SDK targets Appwrite server version 2.3.x as shipped on Appwrite Cloud.
* Self-hosted releases can lag behind Cloud — if you run an older self-hosted
* build, use a matching older SDK from
* [previous releases](https://github.com/appwrite/sdk-for-web/releases)
@@ -38,6 +38,7 @@ export { Channel } from './channel';
export { Operator, Condition } from './operator';
export { AuthenticatorType } from './enums/authenticator-type';
export { AuthenticationFactor } from './enums/authentication-factor';
+export { IdTokenProvider } from './enums/id-token-provider';
export { OAuthProvider } from './enums/o-auth-provider';
export { Browser } from './enums/browser';
export { CreditCard } from './enums/credit-card';
diff --git a/src/models.ts b/src/models.ts
index 0bdf24d..dda14b4 100644
--- a/src/models.ts
+++ b/src/models.ts
@@ -80,20 +80,6 @@ export namespace Models {
identities: Identity[];
};
- /**
- * Logs List
- */
- export type LogList = {
- /**
- * Total number of logs that matched your query.
- */
- total: number;
- /**
- * List of logs.
- */
- logs: Log[];
- };
-
/**
* Files List
*/
@@ -370,100 +356,6 @@ export namespace Models {
metadata?: object;
};
- /**
- * Log
- */
- export type Log = {
- /**
- * Event name.
- */
- event: string;
- /**
- * User ID of the actor recorded for this log. During impersonation, this is the original impersonator, not the impersonated target user.
- */
- userId: string;
- /**
- * User email of the actor recorded for this log. During impersonation, this is the original impersonator.
- */
- userEmail: string;
- /**
- * User name of the actor recorded for this log. During impersonation, this is the original impersonator.
- */
- userName: string;
- /**
- * API mode when event triggered.
- */
- mode: string;
- /**
- * User type who triggered the audit log. Possible values: user, admin, guest, hidden, keyProject, keyAccount, keyOrganization.
- */
- userType: string;
- /**
- * IP session in use when the session was created.
- */
- ip: string;
- /**
- * Log creation date in ISO 8601 format.
- */
- time: string;
- /**
- * Operating system code name. View list of [available options](https://github.com/appwrite/appwrite/blob/master/docs/lists/os.json).
- */
- osCode: string;
- /**
- * Operating system name.
- */
- osName: string;
- /**
- * Operating system version.
- */
- osVersion: string;
- /**
- * Client type.
- */
- clientType: string;
- /**
- * Client code name. View list of [available options](https://github.com/appwrite/appwrite/blob/master/docs/lists/clients.json).
- */
- clientCode: string;
- /**
- * Client name.
- */
- clientName: string;
- /**
- * Client version.
- */
- clientVersion: string;
- /**
- * Client engine name.
- */
- clientEngine: string;
- /**
- * Client engine name.
- */
- clientEngineVersion: string;
- /**
- * Device name.
- */
- deviceName: string;
- /**
- * Device brand name.
- */
- deviceBrand: string;
- /**
- * Device model name.
- */
- deviceModel: string;
- /**
- * Country two-character ISO 3166-1 alpha code.
- */
- countryCode: string;
- /**
- * Country name.
- */
- countryName: string;
- };
-
/**
* User
*/
@@ -546,6 +438,10 @@ export namespace Models {
* Whether the user email is in its canonical form.
*/
emailIsCanonical?: boolean;
+ /**
+ * Whether the password was found in a known data breach the last time it was checked. Null when the password has never been checked.
+ */
+ passwordPwned?: boolean;
/**
* Phone verification status.
*/
@@ -862,6 +758,10 @@ export namespace Models {
* Identity Provider Refresh Token.
*/
providerRefreshToken: string;
+ /**
+ * Identity Provider ID token (JWT) from the most recent native sign-in. Empty for identities created through the browser OAuth2 flow.
+ */
+ providerIdToken: string;
};
/**
@@ -1237,7 +1137,7 @@ export namespace Models {
*/
errors: string;
/**
- * Resource(function/site) execution duration in seconds.
+ * Total time the resource(function/site) took to respond, in seconds.
*/
duration: number;
/**
diff --git a/src/services/account.ts b/src/services/account.ts
index c00bdbd..72b18fb 100644
--- a/src/services/account.ts
+++ b/src/services/account.ts
@@ -4,6 +4,7 @@ import type { Models } from '../models';
import { AuthenticatorType } from '../enums/authenticator-type';
import { AuthenticationFactor } from '../enums/authentication-factor';
+import { IdTokenProvider } from '../enums/id-token-provider';
import { OAuthProvider } from '../enums/o-auth-provider';
export class Account {
client: Client;
@@ -247,7 +248,7 @@ export class Account {
const consentId = params.consentId;
- if (typeof consentId === 'undefined') {
+ if (typeof consentId === 'undefined' || consentId === '') {
throw new AppwriteException(
'Missing required parameter: "consentId"',
);
@@ -301,7 +302,7 @@ export class Account {
const consentId = params.consentId;
- if (typeof consentId === 'undefined') {
+ if (typeof consentId === 'undefined' || consentId === '') {
throw new AppwriteException(
'Missing required parameter: "consentId"',
);
@@ -380,7 +381,7 @@ export class Account {
const queries = params.queries;
const total = params.total;
- if (typeof consentId === 'undefined') {
+ if (typeof consentId === 'undefined' || consentId === '') {
throw new AppwriteException(
'Missing required parameter: "consentId"',
);
@@ -456,12 +457,12 @@ export class Account {
const consentId = params.consentId;
const tokenId = params.tokenId;
- if (typeof consentId === 'undefined') {
+ if (typeof consentId === 'undefined' || consentId === '') {
throw new AppwriteException(
'Missing required parameter: "consentId"',
);
}
- if (typeof tokenId === 'undefined') {
+ if (typeof tokenId === 'undefined' || tokenId === '') {
throw new AppwriteException(
'Missing required parameter: "tokenId"',
);
@@ -527,12 +528,12 @@ export class Account {
const consentId = params.consentId;
const tokenId = params.tokenId;
- if (typeof consentId === 'undefined') {
+ if (typeof consentId === 'undefined' || consentId === '') {
throw new AppwriteException(
'Missing required parameter: "consentId"',
);
}
- if (typeof tokenId === 'undefined') {
+ if (typeof tokenId === 'undefined' || tokenId === '') {
throw new AppwriteException(
'Missing required parameter: "tokenId"',
);
@@ -741,7 +742,7 @@ export class Account {
const identityId = params.identityId;
- if (typeof identityId === 'undefined') {
+ if (typeof identityId === 'undefined' || identityId === '') {
throw new AppwriteException(
'Missing required parameter: "identityId"',
);
@@ -756,6 +757,7 @@ export class Account {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -814,72 +816,6 @@ export class Account {
return this.client.call('post', uri, apiHeaders, payload);
}
- /**
- * Get the list of latest security activity logs for the currently logged in user. Each log returns user IP address, location and date and time of log.
- *
- * @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Only supported methods are limit and offset
- * @param {boolean} params.total - When set to false, the total count returned will be 0 and will not be calculated.
- * @throws {AppwriteException}
- * @returns {Promise}
- */
- listLogs(params?: {
- queries?: string[];
- total?: boolean;
- }): Promise;
- /**
- * Get the list of latest security activity logs for the currently logged in user. Each log returns user IP address, location and date and time of log.
- *
- * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Only supported methods are limit and offset
- * @param {boolean} total - When set to false, the total count returned will be 0 and will not be calculated.
- * @throws {AppwriteException}
- * @returns {Promise}
- * @deprecated Use the object parameter style method for a better developer experience.
- */
- listLogs(queries?: string[], total?: boolean): Promise;
- listLogs(
- paramsOrFirst?: { queries?: string[]; total?: boolean } | string[],
- ...rest: [boolean?]
- ): Promise {
- let params: { queries?: string[]; total?: boolean };
-
- if (
- (typeof paramsOrFirst === 'undefined' && rest.length === 0) ||
- (paramsOrFirst &&
- typeof paramsOrFirst === 'object' &&
- !Array.isArray(paramsOrFirst))
- ) {
- params = (paramsOrFirst || {}) as {
- queries?: string[];
- total?: boolean;
- };
- } else {
- params = {
- queries: paramsOrFirst as string[],
- total: rest[0] as boolean,
- };
- }
-
- const queries = params.queries;
- const total = params.total;
-
- const apiPath = '/account/logs';
- const payload: Payload = {};
- if (typeof queries !== 'undefined') {
- payload['queries'] = queries;
- }
- if (typeof total !== 'undefined') {
- payload['total'] = total;
- }
- const uri = new URL(this.client.config.endpoint + apiPath);
-
- const apiHeaders: { [header: string]: string } = {
- 'X-Appwrite-Project': this.client.config.project,
- accept: 'application/json',
- };
-
- return this.client.call('get', uri, apiHeaders, payload);
- }
-
/**
* Enable or disable MFA on an account.
*
@@ -1270,6 +1206,7 @@ export class Account {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -1325,6 +1262,7 @@ export class Account {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -2236,6 +2174,174 @@ export class Account {
return this.client.call('put', uri, apiHeaders, payload);
}
+ /**
+ * Use this endpoint to send a 6-digit password recovery code to the user's email address. Unlike [createRecovery](https://appwrite.io/docs/references/cloud/client-web/account#createRecovery), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a recovery page. Learn more about how to [complete the recovery process](https://appwrite.io/docs/references/cloud/client-web/account#updateRecoveryOTP). The code sent to the user's email address is valid for 15 minutes.
+ *
+ * Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
+ *
+ *
+ * @param {string} params.email - User email.
+ * @param {boolean} params.phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ */
+ createRecoveryOTP(params: {
+ email: string;
+ phrase?: boolean;
+ }): Promise;
+ /**
+ * Use this endpoint to send a 6-digit password recovery code to the user's email address. Unlike [createRecovery](https://appwrite.io/docs/references/cloud/client-web/account#createRecovery), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a recovery page. Learn more about how to [complete the recovery process](https://appwrite.io/docs/references/cloud/client-web/account#updateRecoveryOTP). The code sent to the user's email address is valid for 15 minutes.
+ *
+ * Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
+ *
+ *
+ * @param {string} email - User email.
+ * @param {boolean} phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ * @deprecated Use the object parameter style method for a better developer experience.
+ */
+ createRecoveryOTP(email: string, phrase?: boolean): Promise;
+ createRecoveryOTP(
+ paramsOrFirst: { email: string; phrase?: boolean } | string,
+ ...rest: [boolean?]
+ ): Promise {
+ let params: { email: string; phrase?: boolean };
+
+ if (
+ paramsOrFirst &&
+ typeof paramsOrFirst === 'object' &&
+ !Array.isArray(paramsOrFirst)
+ ) {
+ params = (paramsOrFirst || {}) as {
+ email: string;
+ phrase?: boolean;
+ };
+ } else {
+ params = {
+ email: paramsOrFirst as string,
+ phrase: rest[0] as boolean,
+ };
+ }
+
+ const email = params.email;
+ const phrase = params.phrase;
+
+ if (typeof email === 'undefined') {
+ throw new AppwriteException('Missing required parameter: "email"');
+ }
+ const apiPath = '/account/recovery/otp';
+ const payload: Payload = {};
+ if (typeof email !== 'undefined') {
+ payload['email'] = email;
+ }
+ if (typeof phrase !== 'undefined') {
+ payload['phrase'] = phrase;
+ }
+ const uri = new URL(this.client.config.endpoint + apiPath);
+
+ const apiHeaders: { [header: string]: string } = {
+ 'X-Appwrite-Project': this.client.config.project,
+ 'content-type': 'application/json',
+ accept: 'application/json',
+ };
+
+ return this.client.call('post', uri, apiHeaders, payload);
+ }
+
+ /**
+ * Use this endpoint to complete the user password recovery process using the 6-digit code that was emailed by [createRecoveryOTP](https://appwrite.io/docs/references/cloud/client-web/account#createRecoveryOTP). Pass the **userId** of the user along with the **secret** code from the email and the new **password** to set. If confirmed, this route will return a 200 status code, the code is consumed and the user's password is updated.
+ *
+ *
+ * @param {string} params.userId - User ID.
+ * @param {string} params.secret - Valid recovery OTP code.
+ * @param {string} params.password - New user password. Must be between 8 and 256 chars.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ */
+ updateRecoveryOTP(params: {
+ userId: string;
+ secret: string;
+ password: string;
+ }): Promise;
+ /**
+ * Use this endpoint to complete the user password recovery process using the 6-digit code that was emailed by [createRecoveryOTP](https://appwrite.io/docs/references/cloud/client-web/account#createRecoveryOTP). Pass the **userId** of the user along with the **secret** code from the email and the new **password** to set. If confirmed, this route will return a 200 status code, the code is consumed and the user's password is updated.
+ *
+ *
+ * @param {string} userId - User ID.
+ * @param {string} secret - Valid recovery OTP code.
+ * @param {string} password - New user password. Must be between 8 and 256 chars.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ * @deprecated Use the object parameter style method for a better developer experience.
+ */
+ updateRecoveryOTP(
+ userId: string,
+ secret: string,
+ password: string,
+ ): Promise;
+ updateRecoveryOTP(
+ paramsOrFirst:
+ { userId: string; secret: string; password: string } | string,
+ ...rest: [string?, string?]
+ ): Promise {
+ let params: { userId: string; secret: string; password: string };
+
+ if (
+ paramsOrFirst &&
+ typeof paramsOrFirst === 'object' &&
+ !Array.isArray(paramsOrFirst)
+ ) {
+ params = (paramsOrFirst || {}) as {
+ userId: string;
+ secret: string;
+ password: string;
+ };
+ } else {
+ params = {
+ userId: paramsOrFirst as string,
+ secret: rest[0] as string,
+ password: rest[1] as string,
+ };
+ }
+
+ const userId = params.userId;
+ const secret = params.secret;
+ const password = params.password;
+
+ if (typeof userId === 'undefined') {
+ throw new AppwriteException('Missing required parameter: "userId"');
+ }
+ if (typeof secret === 'undefined') {
+ throw new AppwriteException('Missing required parameter: "secret"');
+ }
+ if (typeof password === 'undefined') {
+ throw new AppwriteException(
+ 'Missing required parameter: "password"',
+ );
+ }
+ const apiPath = '/account/recovery/otp';
+ const payload: Payload = {};
+ if (typeof userId !== 'undefined') {
+ payload['userId'] = userId;
+ }
+ if (typeof secret !== 'undefined') {
+ payload['secret'] = secret;
+ }
+ if (typeof password !== 'undefined') {
+ payload['password'] = password;
+ }
+ const uri = new URL(this.client.config.endpoint + apiPath);
+
+ const apiHeaders: { [header: string]: string } = {
+ 'X-Appwrite-Project': this.client.config.project,
+ 'content-type': 'application/json',
+ accept: 'application/json',
+ };
+
+ return this.client.call('put', uri, apiHeaders, payload);
+ }
+
/**
* Get the list of active sessions across different devices for the currently logged in user.
*
@@ -2269,6 +2375,7 @@ export class Account {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -2375,6 +2482,169 @@ export class Account {
return this.client.call('post', uri, apiHeaders, payload);
}
+ /**
+ * Allow the user to login to their account using an OpenID Connect ID token obtained natively from the OAuth2 provider, for example via Google Credential Manager on Android or Sign in with Apple on iOS. No browser or redirect is involved: the ID token is verified against the provider's published signing keys and a session is created in a single request.
+ *
+ * Native sign-in is switched on per provider with its nativeEnabled setting. It is independent of the browser-based flow's enabled setting, which has no effect on this endpoint. The token's audience must match the provider's configured client ID or one of its native client IDs; tokens issued for any other client ID are rejected. For Sign in with Apple, register your app's bundle ID as a native client ID. For Google, the web client ID used by Credential Manager is usually the configured client ID; add your Android and iOS client IDs as native client IDs if your app requests tokens for them.
+ *
+ * Pass the raw nonce used when requesting the ID token so it can be validated against the token's nonce claim. When signing in with Apple, the nonce is required: hash it with SHA-256 before passing it to the Apple SDK, and send the raw value here - Apple tokens requested without a nonce are rejected. For Google the nonce is optional: it is validated whenever the token carries one, and ignored when the provider issued the token without one. Apple only returns the user's name on the first authorization, and never inside the ID token - capture it on the client and pass it via the name parameter.
+ *
+ * If there is already an active session, the new session will be attached to the logged-in account. If there are no active sessions, the server will attempt to look for a user with the same email address as the verified email received from the provider and attach the new session to the existing user. If no matching user is found - the server will create a new user.
+ *
+ * This flow does not return provider refresh tokens. You may pass an access token the provider handed your client, along with its lifetime, to store it on the session - but Appwrite cannot renew it once it expires. If your app needs long-lived access to provider APIs, use the browser-based OAuth2 flow instead.
+ *
+ * A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
+ *
+ *
+ * @param {IdTokenProvider} params.provider - OAuth2 provider that issued the ID token. Currently, supported providers are: apple, google.
+ * @param {string} params.idToken - OpenID Connect ID token (JWT) obtained natively from the provider, for example via Google Credential Manager or Sign in with Apple.
+ * @param {string} params.nonce - Raw nonce used when requesting the ID token. Required for Apple, and whenever the token carries a nonce claim, which must match it. Ignored when the provider issued the token without a nonce.
+ * @param {string} params.accessToken - Provider access token to store alongside the session for calling provider APIs. Never used for authentication.
+ * @param {number} params.accessTokenExpiry - Seconds until the provider access token expires, as reported by the provider. Stored so clients can tell when the stored token goes stale.
+ * @param {string} params.name - User name. Only used when creating a new user and the ID token has no name claim, such as on the first Sign in with Apple authorization.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ */
+ createIdTokenSession(params: {
+ provider: IdTokenProvider;
+ idToken: string;
+ nonce?: string;
+ accessToken?: string;
+ accessTokenExpiry?: number;
+ name?: string;
+ }): Promise;
+ /**
+ * Allow the user to login to their account using an OpenID Connect ID token obtained natively from the OAuth2 provider, for example via Google Credential Manager on Android or Sign in with Apple on iOS. No browser or redirect is involved: the ID token is verified against the provider's published signing keys and a session is created in a single request.
+ *
+ * Native sign-in is switched on per provider with its nativeEnabled setting. It is independent of the browser-based flow's enabled setting, which has no effect on this endpoint. The token's audience must match the provider's configured client ID or one of its native client IDs; tokens issued for any other client ID are rejected. For Sign in with Apple, register your app's bundle ID as a native client ID. For Google, the web client ID used by Credential Manager is usually the configured client ID; add your Android and iOS client IDs as native client IDs if your app requests tokens for them.
+ *
+ * Pass the raw nonce used when requesting the ID token so it can be validated against the token's nonce claim. When signing in with Apple, the nonce is required: hash it with SHA-256 before passing it to the Apple SDK, and send the raw value here - Apple tokens requested without a nonce are rejected. For Google the nonce is optional: it is validated whenever the token carries one, and ignored when the provider issued the token without one. Apple only returns the user's name on the first authorization, and never inside the ID token - capture it on the client and pass it via the name parameter.
+ *
+ * If there is already an active session, the new session will be attached to the logged-in account. If there are no active sessions, the server will attempt to look for a user with the same email address as the verified email received from the provider and attach the new session to the existing user. If no matching user is found - the server will create a new user.
+ *
+ * This flow does not return provider refresh tokens. You may pass an access token the provider handed your client, along with its lifetime, to store it on the session - but Appwrite cannot renew it once it expires. If your app needs long-lived access to provider APIs, use the browser-based OAuth2 flow instead.
+ *
+ * A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
+ *
+ *
+ * @param {IdTokenProvider} provider - OAuth2 provider that issued the ID token. Currently, supported providers are: apple, google.
+ * @param {string} idToken - OpenID Connect ID token (JWT) obtained natively from the provider, for example via Google Credential Manager or Sign in with Apple.
+ * @param {string} nonce - Raw nonce used when requesting the ID token. Required for Apple, and whenever the token carries a nonce claim, which must match it. Ignored when the provider issued the token without a nonce.
+ * @param {string} accessToken - Provider access token to store alongside the session for calling provider APIs. Never used for authentication.
+ * @param {number} accessTokenExpiry - Seconds until the provider access token expires, as reported by the provider. Stored so clients can tell when the stored token goes stale.
+ * @param {string} name - User name. Only used when creating a new user and the ID token has no name claim, such as on the first Sign in with Apple authorization.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ * @deprecated Use the object parameter style method for a better developer experience.
+ */
+ createIdTokenSession(
+ provider: IdTokenProvider,
+ idToken: string,
+ nonce?: string,
+ accessToken?: string,
+ accessTokenExpiry?: number,
+ name?: string,
+ ): Promise;
+ createIdTokenSession(
+ paramsOrFirst:
+ | {
+ provider: IdTokenProvider;
+ idToken: string;
+ nonce?: string;
+ accessToken?: string;
+ accessTokenExpiry?: number;
+ name?: string;
+ }
+ | IdTokenProvider,
+ ...rest: [string?, string?, string?, number?, string?]
+ ): Promise {
+ let params: {
+ provider: IdTokenProvider;
+ idToken: string;
+ nonce?: string;
+ accessToken?: string;
+ accessTokenExpiry?: number;
+ name?: string;
+ };
+
+ if (
+ paramsOrFirst &&
+ typeof paramsOrFirst === 'object' &&
+ !Array.isArray(paramsOrFirst) &&
+ ('provider' in paramsOrFirst ||
+ 'idToken' in paramsOrFirst ||
+ 'nonce' in paramsOrFirst ||
+ 'accessToken' in paramsOrFirst ||
+ 'accessTokenExpiry' in paramsOrFirst ||
+ 'name' in paramsOrFirst)
+ ) {
+ params = (paramsOrFirst || {}) as {
+ provider: IdTokenProvider;
+ idToken: string;
+ nonce?: string;
+ accessToken?: string;
+ accessTokenExpiry?: number;
+ name?: string;
+ };
+ } else {
+ params = {
+ provider: paramsOrFirst as IdTokenProvider,
+ idToken: rest[0] as string,
+ nonce: rest[1] as string,
+ accessToken: rest[2] as string,
+ accessTokenExpiry: rest[3] as number,
+ name: rest[4] as string,
+ };
+ }
+
+ const provider = params.provider;
+ const idToken = params.idToken;
+ const nonce = params.nonce;
+ const accessToken = params.accessToken;
+ const accessTokenExpiry = params.accessTokenExpiry;
+ const name = params.name;
+
+ if (typeof provider === 'undefined') {
+ throw new AppwriteException(
+ 'Missing required parameter: "provider"',
+ );
+ }
+ if (typeof idToken === 'undefined') {
+ throw new AppwriteException(
+ 'Missing required parameter: "idToken"',
+ );
+ }
+ const apiPath = '/account/sessions/id-token';
+ const payload: Payload = {};
+ if (typeof provider !== 'undefined') {
+ payload['provider'] = provider;
+ }
+ if (typeof idToken !== 'undefined') {
+ payload['idToken'] = idToken;
+ }
+ if (typeof nonce !== 'undefined') {
+ payload['nonce'] = nonce;
+ }
+ if (typeof accessToken !== 'undefined') {
+ payload['accessToken'] = accessToken;
+ }
+ if (typeof accessTokenExpiry !== 'undefined') {
+ payload['accessTokenExpiry'] = accessTokenExpiry;
+ }
+ if (typeof name !== 'undefined') {
+ payload['name'] = name;
+ }
+ const uri = new URL(this.client.config.endpoint + apiPath);
+
+ const apiHeaders: { [header: string]: string } = {
+ 'X-Appwrite-Project': this.client.config.project,
+ 'content-type': 'application/json',
+ accept: 'application/json',
+ };
+
+ return this.client.call('post', uri, apiHeaders, payload);
+ }
+
/**
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
*
@@ -2459,7 +2729,7 @@ export class Account {
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
*
*
- * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
+ * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, kakao, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tiktok, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
* @param {string} params.success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string} params.failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string[]} params.scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -2480,7 +2750,7 @@ export class Account {
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
*
*
- * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
+ * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, kakao, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tiktok, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
* @param {string} success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string} failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string[]} scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -2757,7 +3027,7 @@ export class Account {
const sessionId = params.sessionId;
- if (typeof sessionId === 'undefined') {
+ if (typeof sessionId === 'undefined' || sessionId === '') {
throw new AppwriteException(
'Missing required parameter: "sessionId"',
);
@@ -2813,7 +3083,7 @@ export class Account {
const sessionId = params.sessionId;
- if (typeof sessionId === 'undefined') {
+ if (typeof sessionId === 'undefined' || sessionId === '') {
throw new AppwriteException(
'Missing required parameter: "sessionId"',
);
@@ -2868,7 +3138,7 @@ export class Account {
const sessionId = params.sessionId;
- if (typeof sessionId === 'undefined') {
+ if (typeof sessionId === 'undefined' || sessionId === '') {
throw new AppwriteException(
'Missing required parameter: "sessionId"',
);
@@ -2883,6 +3153,7 @@ export class Account {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -2911,7 +3182,7 @@ export class Account {
}
/**
- * Use this endpoint to register a device for push notifications. Provide a target ID (custom or generated using ID.unique()), a device identifier (usually a device token), and optionally specify which provider should send notifications to this target. The target is automatically linked to the current session and includes device information like brand and model.
+ * Use this endpoint to register a device for push notifications. Provide a target ID (custom or generated using ID.unique()), a device identifier (usually a device token), and optionally specify which provider should send notifications to this target. The target is automatically linked to the current session and includes device information like brand and model. A session holds one push target per provider, so if one already exists this endpoint updates and returns that target instead of creating a second one, and a device that rotates its token is never notified twice.
*
* @param {string} params.targetId - Target ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
* @param {string} params.identifier - The target identifier (token, email, phone etc.)
@@ -2925,7 +3196,7 @@ export class Account {
providerId?: string;
}): Promise;
/**
- * Use this endpoint to register a device for push notifications. Provide a target ID (custom or generated using ID.unique()), a device identifier (usually a device token), and optionally specify which provider should send notifications to this target. The target is automatically linked to the current session and includes device information like brand and model.
+ * Use this endpoint to register a device for push notifications. Provide a target ID (custom or generated using ID.unique()), a device identifier (usually a device token), and optionally specify which provider should send notifications to this target. The target is automatically linked to the current session and includes device information like brand and model. A session holds one push target per provider, so if one already exists this endpoint updates and returns that target instead of creating a second one, and a device that rotates its token is never notified twice.
*
* @param {string} targetId - Target ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
* @param {string} identifier - The target identifier (token, email, phone etc.)
@@ -3055,7 +3326,7 @@ export class Account {
const targetId = params.targetId;
const identifier = params.identifier;
- if (typeof targetId === 'undefined') {
+ if (typeof targetId === 'undefined' || targetId === '') {
throw new AppwriteException(
'Missing required parameter: "targetId"',
);
@@ -3120,7 +3391,7 @@ export class Account {
const targetId = params.targetId;
- if (typeof targetId === 'undefined') {
+ if (typeof targetId === 'undefined' || targetId === '') {
throw new AppwriteException(
'Missing required parameter: "targetId"',
);
@@ -3135,6 +3406,7 @@ export class Account {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -3345,9 +3617,11 @@ export class Account {
*
* If authentication succeeds, `userId` and `secret` of a token will be appended to the success URL as query parameters. These can be used to create a new session using the [Create session](https://appwrite.io/docs/references/cloud/client-web/account#createSession) endpoint.
*
+ * If there is already an active session, the OAuth2 identity is attached to the logged-in account and that session stays active until the token is exchanged for a new one.
+ *
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
*
- * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
+ * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, kakao, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tiktok, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
* @param {string} params.success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string} params.failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string[]} params.scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -3365,9 +3639,11 @@ export class Account {
*
* If authentication succeeds, `userId` and `secret` of a token will be appended to the success URL as query parameters. These can be used to create a new session using the [Create session](https://appwrite.io/docs/references/cloud/client-web/account#createSession) endpoint.
*
+ * If there is already an active session, the OAuth2 identity is attached to the logged-in account and that session stays active until the token is exchanged for a new one.
+ *
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
*
- * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
+ * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, appwrite, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, kakao, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tiktok, tradeshift, tradeshiftBox, twitch, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
* @param {string} success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string} failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
* @param {string[]} scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -3807,6 +4083,144 @@ export class Account {
return this.client.call('put', uri, apiHeaders, payload);
}
+ /**
+ * Use this endpoint to send a 6-digit verification code to the currently logged in user's email address. Unlike [createEmailVerification](https://appwrite.io/docs/references/cloud/client-web/account#createEmailVerification), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a verification page. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updateEmailVerificationOTP). The code sent to the user's email address is valid for 15 minutes.
+ *
+ * Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
+ *
+ *
+ * @param {boolean} params.phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ */
+ createEmailVerificationOTP(params?: {
+ phrase?: boolean;
+ }): Promise;
+ /**
+ * Use this endpoint to send a 6-digit verification code to the currently logged in user's email address. Unlike [createEmailVerification](https://appwrite.io/docs/references/cloud/client-web/account#createEmailVerification), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a verification page. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updateEmailVerificationOTP). The code sent to the user's email address is valid for 15 minutes.
+ *
+ * Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
+ *
+ *
+ * @param {boolean} phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ * @deprecated Use the object parameter style method for a better developer experience.
+ */
+ createEmailVerificationOTP(phrase?: boolean): Promise;
+ createEmailVerificationOTP(
+ paramsOrFirst?: { phrase?: boolean } | boolean,
+ ): Promise {
+ let params: { phrase?: boolean };
+
+ if (
+ typeof paramsOrFirst === 'undefined' ||
+ (paramsOrFirst &&
+ typeof paramsOrFirst === 'object' &&
+ !Array.isArray(paramsOrFirst))
+ ) {
+ params = (paramsOrFirst || {}) as { phrase?: boolean };
+ } else {
+ params = {
+ phrase: paramsOrFirst as boolean,
+ };
+ }
+
+ const phrase = params.phrase;
+
+ const apiPath = '/account/verifications/email/otp';
+ const payload: Payload = {};
+ if (typeof phrase !== 'undefined') {
+ payload['phrase'] = phrase;
+ }
+ const uri = new URL(this.client.config.endpoint + apiPath);
+
+ const apiHeaders: { [header: string]: string } = {
+ 'X-Appwrite-Project': this.client.config.project,
+ 'content-type': 'application/json',
+ accept: 'application/json',
+ };
+
+ return this.client.call('post', uri, apiHeaders, payload);
+ }
+
+ /**
+ * Use this endpoint to complete the user email verification process using the 6-digit code that was emailed by [createEmailVerificationOTP](https://appwrite.io/docs/references/cloud/client-web/account#createEmailVerificationOTP). Pass the **userId** of the user being verified along with the **secret** code from the email. If confirmed, this route will return a 200 status code and the code is consumed.
+ *
+ *
+ * @param {string} params.userId - User ID.
+ * @param {string} params.secret - Valid verification OTP code.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ */
+ updateEmailVerificationOTP(params: {
+ userId: string;
+ secret: string;
+ }): Promise;
+ /**
+ * Use this endpoint to complete the user email verification process using the 6-digit code that was emailed by [createEmailVerificationOTP](https://appwrite.io/docs/references/cloud/client-web/account#createEmailVerificationOTP). Pass the **userId** of the user being verified along with the **secret** code from the email. If confirmed, this route will return a 200 status code and the code is consumed.
+ *
+ *
+ * @param {string} userId - User ID.
+ * @param {string} secret - Valid verification OTP code.
+ * @throws {AppwriteException}
+ * @returns {Promise}
+ * @deprecated Use the object parameter style method for a better developer experience.
+ */
+ updateEmailVerificationOTP(
+ userId: string,
+ secret: string,
+ ): Promise;
+ updateEmailVerificationOTP(
+ paramsOrFirst: { userId: string; secret: string } | string,
+ ...rest: [string?]
+ ): Promise {
+ let params: { userId: string; secret: string };
+
+ if (
+ paramsOrFirst &&
+ typeof paramsOrFirst === 'object' &&
+ !Array.isArray(paramsOrFirst)
+ ) {
+ params = (paramsOrFirst || {}) as {
+ userId: string;
+ secret: string;
+ };
+ } else {
+ params = {
+ userId: paramsOrFirst as string,
+ secret: rest[0] as string,
+ };
+ }
+
+ const userId = params.userId;
+ const secret = params.secret;
+
+ if (typeof userId === 'undefined') {
+ throw new AppwriteException('Missing required parameter: "userId"');
+ }
+ if (typeof secret === 'undefined') {
+ throw new AppwriteException('Missing required parameter: "secret"');
+ }
+ const apiPath = '/account/verifications/email/otp';
+ const payload: Payload = {};
+ if (typeof userId !== 'undefined') {
+ payload['userId'] = userId;
+ }
+ if (typeof secret !== 'undefined') {
+ payload['secret'] = secret;
+ }
+ const uri = new URL(this.client.config.endpoint + apiPath);
+
+ const apiHeaders: { [header: string]: string } = {
+ 'X-Appwrite-Project': this.client.config.project,
+ 'content-type': 'application/json',
+ accept: 'application/json',
+ };
+
+ return this.client.call('put', uri, apiHeaders, payload);
+ }
+
/**
* Use this endpoint to send a verification SMS to the currently logged in user. This endpoint is meant for use after updating a user's phone number using the [accountUpdatePhone](https://appwrite.io/docs/references/cloud/client-web/account#updatePhone) endpoint. Learn more about how to [complete the verification process](https://appwrite.io/docs/references/cloud/client-web/account#updatePhoneVerification). The verification code sent to the user's phone number is valid for 15 minutes.
*
diff --git a/src/services/databases.ts b/src/services/databases.ts
index 194fa6d..35c9a4f 100644
--- a/src/services/databases.ts
+++ b/src/services/databases.ts
@@ -156,7 +156,7 @@ export class Databases {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -240,7 +240,7 @@ export class Databases {
const commit = params.commit;
const rollback = params.rollback;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -304,7 +304,7 @@ export class Databases {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -319,6 +319,7 @@ export class Databases {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -376,7 +377,7 @@ export class Databases {
const transactionId = params.transactionId;
const operations = params.operations;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -498,12 +499,12 @@ export class Databases {
const total = params.total;
const ttl = params.ttl;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -660,12 +661,12 @@ export class Databases {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -797,17 +798,17 @@ export class Databases {
const queries = params.queries;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -964,17 +965,17 @@ export class Databases {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1135,17 +1136,17 @@ export class Databases {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1259,17 +1260,17 @@ export class Databases {
const documentId = params.documentId;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1294,6 +1295,7 @@ export class Databases {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -1409,22 +1411,22 @@ export class Databases {
const min = params.min;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
}
- if (typeof attribute === 'undefined') {
+ if (typeof attribute === 'undefined' || attribute === '') {
throw new AppwriteException(
'Missing required parameter: "attribute"',
);
@@ -1569,22 +1571,22 @@ export class Databases {
const max = params.max;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
}
- if (typeof attribute === 'undefined') {
+ if (typeof attribute === 'undefined' || attribute === '') {
throw new AppwriteException(
'Missing required parameter: "attribute"',
);
diff --git a/src/services/documents-db.ts b/src/services/documents-db.ts
index 2ed9a44..f30378d 100644
--- a/src/services/documents-db.ts
+++ b/src/services/documents-db.ts
@@ -153,7 +153,7 @@ export class DocumentsDB {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -236,7 +236,7 @@ export class DocumentsDB {
const commit = params.commit;
const rollback = params.rollback;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -299,7 +299,7 @@ export class DocumentsDB {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -314,6 +314,7 @@ export class DocumentsDB {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -370,7 +371,7 @@ export class DocumentsDB {
const transactionId = params.transactionId;
const operations = params.operations;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -491,12 +492,12 @@ export class DocumentsDB {
const total = params.total;
const ttl = params.ttl;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -652,12 +653,12 @@ export class DocumentsDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -779,12 +780,12 @@ export class DocumentsDB {
const documents = params.documents;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -906,17 +907,17 @@ export class DocumentsDB {
const queries = params.queries;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1072,17 +1073,17 @@ export class DocumentsDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1242,17 +1243,17 @@ export class DocumentsDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1365,17 +1366,17 @@ export class DocumentsDB {
const documentId = params.documentId;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1400,6 +1401,7 @@ export class DocumentsDB {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -1514,22 +1516,22 @@ export class DocumentsDB {
const min = params.min;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
}
- if (typeof attribute === 'undefined') {
+ if (typeof attribute === 'undefined' || attribute === '') {
throw new AppwriteException(
'Missing required parameter: "attribute"',
);
@@ -1673,22 +1675,22 @@ export class DocumentsDB {
const max = params.max;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
}
- if (typeof attribute === 'undefined') {
+ if (typeof attribute === 'undefined' || attribute === '') {
throw new AppwriteException(
'Missing required parameter: "attribute"',
);
diff --git a/src/services/functions.ts b/src/services/functions.ts
index 41c969d..b9a9264 100644
--- a/src/services/functions.ts
+++ b/src/services/functions.ts
@@ -68,7 +68,7 @@ export class Functions {
const queries = params.queries;
const total = params.total;
- if (typeof functionId === 'undefined') {
+ if (typeof functionId === 'undefined' || functionId === '') {
throw new AppwriteException(
'Missing required parameter: "functionId"',
);
@@ -204,7 +204,7 @@ export class Functions {
const headers = params.headers;
const scheduledAt = params.scheduledAt;
- if (typeof functionId === 'undefined') {
+ if (typeof functionId === 'undefined' || functionId === '') {
throw new AppwriteException(
'Missing required parameter: "functionId"',
);
@@ -293,12 +293,12 @@ export class Functions {
const functionId = params.functionId;
const executionId = params.executionId;
- if (typeof functionId === 'undefined') {
+ if (typeof functionId === 'undefined' || functionId === '') {
throw new AppwriteException(
'Missing required parameter: "functionId"',
);
}
- if (typeof executionId === 'undefined') {
+ if (typeof executionId === 'undefined' || executionId === '') {
throw new AppwriteException(
'Missing required parameter: "executionId"',
);
diff --git a/src/services/messaging.ts b/src/services/messaging.ts
index 17e14ab..d120f1d 100644
--- a/src/services/messaging.ts
+++ b/src/services/messaging.ts
@@ -67,7 +67,7 @@ export class Messaging {
const subscriberId = params.subscriberId;
const targetId = params.targetId;
- if (typeof topicId === 'undefined') {
+ if (typeof topicId === 'undefined' || topicId === '') {
throw new AppwriteException(
'Missing required parameter: "topicId"',
);
@@ -151,12 +151,12 @@ export class Messaging {
const topicId = params.topicId;
const subscriberId = params.subscriberId;
- if (typeof topicId === 'undefined') {
+ if (typeof topicId === 'undefined' || topicId === '') {
throw new AppwriteException(
'Missing required parameter: "topicId"',
);
}
- if (typeof subscriberId === 'undefined') {
+ if (typeof subscriberId === 'undefined' || subscriberId === '') {
throw new AppwriteException(
'Missing required parameter: "subscriberId"',
);
@@ -173,6 +173,7 @@ export class Messaging {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
diff --git a/src/services/organization.ts b/src/services/organization.ts
index 214ae07..1ea7838 100644
--- a/src/services/organization.ts
+++ b/src/services/organization.ts
@@ -188,7 +188,7 @@ export class Organization {
const installationId = params.installationId;
- if (typeof installationId === 'undefined') {
+ if (typeof installationId === 'undefined' || installationId === '') {
throw new AppwriteException(
'Missing required parameter: "installationId"',
);
@@ -259,7 +259,7 @@ export class Organization {
const installationId = params.installationId;
const authorizationDetails = params.authorizationDetails;
- if (typeof installationId === 'undefined') {
+ if (typeof installationId === 'undefined' || installationId === '') {
throw new AppwriteException(
'Missing required parameter: "installationId"',
);
@@ -319,7 +319,7 @@ export class Organization {
const installationId = params.installationId;
- if (typeof installationId === 'undefined') {
+ if (typeof installationId === 'undefined' || installationId === '') {
throw new AppwriteException(
'Missing required parameter: "installationId"',
);
diff --git a/src/services/presences.ts b/src/services/presences.ts
index e1e91a0..a612176 100644
--- a/src/services/presences.ts
+++ b/src/services/presences.ts
@@ -128,7 +128,7 @@ export class Presences {
const presenceId = params.presenceId;
- if (typeof presenceId === 'undefined') {
+ if (typeof presenceId === 'undefined' || presenceId === '') {
throw new AppwriteException(
'Missing required parameter: "presenceId"',
);
@@ -235,7 +235,7 @@ export class Presences {
const expiresAt = params.expiresAt;
const metadata = params.metadata;
- if (typeof presenceId === 'undefined') {
+ if (typeof presenceId === 'undefined' || presenceId === '') {
throw new AppwriteException(
'Missing required parameter: "presenceId"',
);
@@ -367,7 +367,7 @@ export class Presences {
const permissions = params.permissions;
const purge = params.purge;
- if (typeof presenceId === 'undefined') {
+ if (typeof presenceId === 'undefined' || presenceId === '') {
throw new AppwriteException(
'Missing required parameter: "presenceId"',
);
@@ -439,7 +439,7 @@ export class Presences {
const presenceId = params.presenceId;
- if (typeof presenceId === 'undefined') {
+ if (typeof presenceId === 'undefined' || presenceId === '') {
throw new AppwriteException(
'Missing required parameter: "presenceId"',
);
@@ -454,6 +454,7 @@ export class Presences {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
diff --git a/src/services/storage.ts b/src/services/storage.ts
index 7c9a0a0..5fd3911 100644
--- a/src/services/storage.ts
+++ b/src/services/storage.ts
@@ -92,7 +92,7 @@ export class Storage {
const search = params.search;
const total = params.total;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
@@ -234,7 +234,7 @@ export class Storage {
const permissions = params.permissions;
const folder = params.folder;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
@@ -323,12 +323,12 @@ export class Storage {
const bucketId = params.bucketId;
const fileId = params.fileId;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
}
- if (typeof fileId === 'undefined') {
+ if (typeof fileId === 'undefined' || fileId === '') {
throw new AppwriteException('Missing required parameter: "fileId"');
}
const apiPath = '/storage/buckets/{bucketId}/files/{fileId}'
@@ -421,12 +421,12 @@ export class Storage {
const name = params.name;
const permissions = params.permissions;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
}
- if (typeof fileId === 'undefined') {
+ if (typeof fileId === 'undefined' || fileId === '') {
throw new AppwriteException('Missing required parameter: "fileId"');
}
const apiPath = '/storage/buckets/{bucketId}/files/{fileId}'
@@ -494,12 +494,12 @@ export class Storage {
const bucketId = params.bucketId;
const fileId = params.fileId;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
}
- if (typeof fileId === 'undefined') {
+ if (typeof fileId === 'undefined' || fileId === '') {
throw new AppwriteException('Missing required parameter: "fileId"');
}
const apiPath = '/storage/buckets/{bucketId}/files/{fileId}'
@@ -511,6 +511,7 @@ export class Storage {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -570,12 +571,12 @@ export class Storage {
const fileId = params.fileId;
const token = params.token;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
}
- if (typeof fileId === 'undefined') {
+ if (typeof fileId === 'undefined' || fileId === '') {
throw new AppwriteException('Missing required parameter: "fileId"');
}
const apiPath = '/storage/buckets/{bucketId}/files/{fileId}/download'
@@ -777,12 +778,12 @@ export class Storage {
const output = params.output;
const token = params.token;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
}
- if (typeof fileId === 'undefined') {
+ if (typeof fileId === 'undefined' || fileId === '') {
throw new AppwriteException('Missing required parameter: "fileId"');
}
const apiPath = '/storage/buckets/{bucketId}/files/{fileId}/preview'
@@ -891,12 +892,12 @@ export class Storage {
const fileId = params.fileId;
const token = params.token;
- if (typeof bucketId === 'undefined') {
+ if (typeof bucketId === 'undefined' || bucketId === '') {
throw new AppwriteException(
'Missing required parameter: "bucketId"',
);
}
- if (typeof fileId === 'undefined') {
+ if (typeof fileId === 'undefined' || fileId === '') {
throw new AppwriteException('Missing required parameter: "fileId"');
}
const apiPath = '/storage/buckets/{bucketId}/files/{fileId}/view'
diff --git a/src/services/tables-db.ts b/src/services/tables-db.ts
index aa8a8b5..3a3d1fc 100644
--- a/src/services/tables-db.ts
+++ b/src/services/tables-db.ts
@@ -153,7 +153,7 @@ export class TablesDB {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -236,7 +236,7 @@ export class TablesDB {
const commit = params.commit;
const rollback = params.rollback;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -299,7 +299,7 @@ export class TablesDB {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -314,6 +314,7 @@ export class TablesDB {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -370,7 +371,7 @@ export class TablesDB {
const transactionId = params.transactionId;
const operations = params.operations;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -489,12 +490,12 @@ export class TablesDB {
const total = params.total;
const ttl = params.ttl;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
@@ -639,12 +640,12 @@ export class TablesDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
@@ -767,17 +768,17 @@ export class TablesDB {
const queries = params.queries;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
}
- if (typeof rowId === 'undefined') {
+ if (typeof rowId === 'undefined' || rowId === '') {
throw new AppwriteException('Missing required parameter: "rowId"');
}
const apiPath = '/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}'
@@ -918,17 +919,17 @@ export class TablesDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
}
- if (typeof rowId === 'undefined') {
+ if (typeof rowId === 'undefined' || rowId === '') {
throw new AppwriteException('Missing required parameter: "rowId"');
}
const apiPath = '/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}'
@@ -1073,17 +1074,17 @@ export class TablesDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
}
- if (typeof rowId === 'undefined') {
+ if (typeof rowId === 'undefined' || rowId === '') {
throw new AppwriteException('Missing required parameter: "rowId"');
}
const apiPath = '/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}'
@@ -1187,17 +1188,17 @@ export class TablesDB {
const rowId = params.rowId;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
}
- if (typeof rowId === 'undefined') {
+ if (typeof rowId === 'undefined' || rowId === '') {
throw new AppwriteException('Missing required parameter: "rowId"');
}
const apiPath = '/tablesdb/{databaseId}/tables/{tableId}/rows/{rowId}'
@@ -1213,6 +1214,7 @@ export class TablesDB {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -1321,20 +1323,20 @@ export class TablesDB {
const min = params.min;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
}
- if (typeof rowId === 'undefined') {
+ if (typeof rowId === 'undefined' || rowId === '') {
throw new AppwriteException('Missing required parameter: "rowId"');
}
- if (typeof column === 'undefined') {
+ if (typeof column === 'undefined' || column === '') {
throw new AppwriteException('Missing required parameter: "column"');
}
const apiPath =
@@ -1467,20 +1469,20 @@ export class TablesDB {
const max = params.max;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof tableId === 'undefined') {
+ if (typeof tableId === 'undefined' || tableId === '') {
throw new AppwriteException(
'Missing required parameter: "tableId"',
);
}
- if (typeof rowId === 'undefined') {
+ if (typeof rowId === 'undefined' || rowId === '') {
throw new AppwriteException('Missing required parameter: "rowId"');
}
- if (typeof column === 'undefined') {
+ if (typeof column === 'undefined' || column === '') {
throw new AppwriteException('Missing required parameter: "column"');
}
const apiPath =
diff --git a/src/services/teams.ts b/src/services/teams.ts
index c44b6f5..54aacf1 100644
--- a/src/services/teams.ts
+++ b/src/services/teams.ts
@@ -218,7 +218,7 @@ export class Teams {
const teamId = params.teamId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
const apiPath = '/teams/{teamId}'.replace(
@@ -286,7 +286,7 @@ export class Teams {
const teamId = params.teamId;
const name = params.name;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
if (typeof name === 'undefined') {
@@ -345,7 +345,7 @@ export class Teams {
const teamId = params.teamId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
const apiPath = '/teams/{teamId}'.replace(
@@ -358,6 +358,7 @@ export class Teams {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -421,7 +422,7 @@ export class Teams {
const queries = params.queries;
const total = params.total;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
const apiPath = '/teams/{teamId}/installations'.replace(
@@ -508,7 +509,7 @@ export class Teams {
const appId = params.appId;
const authorizationDetails = params.authorizationDetails;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
if (typeof appId === 'undefined') {
@@ -586,10 +587,10 @@ export class Teams {
const teamId = params.teamId;
const installationId = params.installationId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof installationId === 'undefined') {
+ if (typeof installationId === 'undefined' || installationId === '') {
throw new AppwriteException(
'Missing required parameter: "installationId"',
);
@@ -678,10 +679,10 @@ export class Teams {
const installationId = params.installationId;
const authorizationDetails = params.authorizationDetails;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof installationId === 'undefined') {
+ if (typeof installationId === 'undefined' || installationId === '') {
throw new AppwriteException(
'Missing required parameter: "installationId"',
);
@@ -754,10 +755,10 @@ export class Teams {
const teamId = params.teamId;
const installationId = params.installationId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof installationId === 'undefined') {
+ if (typeof installationId === 'undefined' || installationId === '') {
throw new AppwriteException(
'Missing required parameter: "installationId"',
);
@@ -856,7 +857,7 @@ export class Teams {
const search = params.search;
const total = params.total;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
const apiPath = '/teams/{teamId}/memberships'.replace(
@@ -1000,7 +1001,7 @@ export class Teams {
const url = params.url;
const name = params.name;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
if (typeof roles === 'undefined') {
@@ -1090,10 +1091,10 @@ export class Teams {
const teamId = params.teamId;
const membershipId = params.membershipId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof membershipId === 'undefined') {
+ if (typeof membershipId === 'undefined' || membershipId === '') {
throw new AppwriteException(
'Missing required parameter: "membershipId"',
);
@@ -1175,10 +1176,10 @@ export class Teams {
const membershipId = params.membershipId;
const roles = params.roles;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof membershipId === 'undefined') {
+ if (typeof membershipId === 'undefined' || membershipId === '') {
throw new AppwriteException(
'Missing required parameter: "membershipId"',
);
@@ -1254,10 +1255,10 @@ export class Teams {
const teamId = params.teamId;
const membershipId = params.membershipId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof membershipId === 'undefined') {
+ if (typeof membershipId === 'undefined' || membershipId === '') {
throw new AppwriteException(
'Missing required parameter: "membershipId"',
);
@@ -1274,6 +1275,7 @@ export class Teams {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -1361,10 +1363,10 @@ export class Teams {
const userId = params.userId;
const secret = params.secret;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
- if (typeof membershipId === 'undefined') {
+ if (typeof membershipId === 'undefined' || membershipId === '') {
throw new AppwriteException(
'Missing required parameter: "membershipId"',
);
@@ -1439,7 +1441,7 @@ export class Teams {
const teamId = params.teamId;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
const apiPath = '/teams/{teamId}/prefs'.replace(
@@ -1504,7 +1506,7 @@ export class Teams {
const teamId = params.teamId;
const prefs = params.prefs;
- if (typeof teamId === 'undefined') {
+ if (typeof teamId === 'undefined' || teamId === '') {
throw new AppwriteException('Missing required parameter: "teamId"');
}
if (typeof prefs === 'undefined') {
diff --git a/src/services/vectors-db.ts b/src/services/vectors-db.ts
index 083d7ce..6720033 100644
--- a/src/services/vectors-db.ts
+++ b/src/services/vectors-db.ts
@@ -153,7 +153,7 @@ export class VectorsDB {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -236,7 +236,7 @@ export class VectorsDB {
const commit = params.commit;
const rollback = params.rollback;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -299,7 +299,7 @@ export class VectorsDB {
const transactionId = params.transactionId;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -314,6 +314,7 @@ export class VectorsDB {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);
@@ -370,7 +371,7 @@ export class VectorsDB {
const transactionId = params.transactionId;
const operations = params.operations;
- if (typeof transactionId === 'undefined') {
+ if (typeof transactionId === 'undefined' || transactionId === '') {
throw new AppwriteException(
'Missing required parameter: "transactionId"',
);
@@ -491,12 +492,12 @@ export class VectorsDB {
const total = params.total;
const ttl = params.ttl;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -652,12 +653,12 @@ export class VectorsDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -799,12 +800,12 @@ export class VectorsDB {
const total = params.total;
const ttl = params.ttl;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
@@ -927,17 +928,17 @@ export class VectorsDB {
const queries = params.queries;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1093,17 +1094,17 @@ export class VectorsDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1263,17 +1264,17 @@ export class VectorsDB {
const permissions = params.permissions;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1386,17 +1387,17 @@ export class VectorsDB {
const documentId = params.documentId;
const transactionId = params.transactionId;
- if (typeof databaseId === 'undefined') {
+ if (typeof databaseId === 'undefined' || databaseId === '') {
throw new AppwriteException(
'Missing required parameter: "databaseId"',
);
}
- if (typeof collectionId === 'undefined') {
+ if (typeof collectionId === 'undefined' || collectionId === '') {
throw new AppwriteException(
'Missing required parameter: "collectionId"',
);
}
- if (typeof documentId === 'undefined') {
+ if (typeof documentId === 'undefined' || documentId === '') {
throw new AppwriteException(
'Missing required parameter: "documentId"',
);
@@ -1421,6 +1422,7 @@ export class VectorsDB {
const apiHeaders: { [header: string]: string } = {
'X-Appwrite-Project': this.client.config.project,
'content-type': 'application/json',
+ accept: 'application/json',
};
return this.client.call('delete', uri, apiHeaders, payload);