Back

Forgot Password Flutter using Deep Links

  • 0
  • Android
  • Auth
  • Flutter
  • Self Hosted
Shiba
12 Aug, 2024, 09:50

The flutter app opens when using the encoded url

adb shell am start -a android.intent.action.VIEW
\ -c android.intent.category.BROWSABLE
\ -d "https://xxx.xxxx.xxx/forgot_password?userId%3Ddsad%26secret%3Ddsaddsadsadsa%26expire%3Ddsadadsa"
\ com.xx.xxxxxxx.xxxxx

But not witout it

adb shell am start -a android.intent.action.VIEW
\ -d "https://xxx.xxxxx.xxxx/forgot_password?userId=dsad&secret=dsaddsadsadsa&expire=dsadadsa" \
com.xxx.xxxx.xxx

TypeScript

Hello xxxxx xxxx,

Follow this link to reset your xxxxxxx password.

https://xxxx.xxxx.xxxx?userId=65f1d741cc7e6b05e95d&secret=xxxxx&expire=xxxxxx

If you didn’t ask to reset your password, you can ignore this message.

Thanks,
xxxxx team

This is the email template we get , the url is not encoded , so the app does not open , redirected to browser

TL;DR
Developers are trying to open a Flutter app using encoded URLs for password reset but are having trouble with non-encoded URLs. They are sending an email with the non-encoded URL, which is causing the app to redirect to the browser instead of opening directly. The solution is to encode the URLs properly in the email template to ensure the app opens correctly.
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