Back

Cannot upgrade an anonymous account with magic url

  • 0
  • Auth
  • Cloud
Pingu
7 Mar, 2025, 02:40

Unless I am just not doing it right, its not possible to upgrade an account from anonymous, using magic URL.

This is fine - I have worked around it in my app now - however the docs suggest that this should be possible: https://appwrite.io/docs/products/auth/anonymous (scroll to the bottom section)

I am still sending a magic url, but on the page it takes them to, if they have an old anonymous account, then I perform updates where needed to move data onto their new account for the magic URL. This could be cumbersome though, so being able to upgrade an account from anon using magic url would be nice to have...

TL;DR
Developers are unable to upgrade an account from anonymous using a magic URL due to limitations in the authentication system. The documentation suggests it's possible, but in reality, specifying the user's current ID results in an error. A workaround involves updating the account manually by moving data onto a new account for magic URL users.
Pingu
7 Mar, 2025, 02:41

Should have been more clear - When creating a magic link request, specifying the users current Id results in an error response, saying that the document already exists. Specifying a different ID creates a new account.

Steven
7 Mar, 2025, 02:48

Hmm ya...maybe we need to update those docs..

Steven
7 Mar, 2025, 02:49

Can you use the update email endpoint?

Pingu
7 Mar, 2025, 02:56

I don't want passwords for users, update email endpoint requires password. (My UI doesn't have anywhere for password entry, and I'm having enough push back from users about not wanting to provide email addresses, let alone passwords... Hence why I am creating an option to allow anonymous logins lol)

Pingu
7 Mar, 2025, 02:57

Currently I only have magic url option for logging in - and right now I'm working on added anonymous auth as an alternative for those who refuse to provide their email address

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more