Hello,
I have this error when i'm trying to log.
I'm using :
- SDK client
- Email login (OTP)
- Vue 3, web
The mail i used is not register in my AW console so it will be created but i have this 409 error.
Solution already done : create a route in my back to have users list and return an unique ID or userId but same error.
My code :
const client = new Client()
.setEndpoint(import.meta.env.VITE_API_APPWRITE_FUNCTION_API_ENDPOINT)
.setProject(import.meta.env.VITE_API_APPWRITE_PROJECT_ID_KEY);
const account = new Account(client);
return await account.createEmailToken(
ID.unique(),
email
);
TL;DR
Issue: Error message "Document with the requested ID already exists" encountered when trying to log in using SDK client, Email login (OTP), and Vue 3 web. The email used is not registered in the AW console, resulting in a 409 error even after creating a route in the backend to generate a unique ID.
Solution: Change the ID generation method to use `ID.unique()`.