
I am using appwrite flutter sdk phone-auth secret generator function is working
but whenever I try to verify (phone-secret-verify function) it's giving invalid secret
whereas similar secret works via REST API
#flutter-sdk

can you pls share the exact error you getting in the terminal

appwrite user_invalid_token, Invalid token passed in the request

this generally happens because token is invalid which can happen either because you are chaching the token and using it and while you trying to use the token that token is already expired get replaced with new

can you show the code which you are having

the problem is same token works via REST API
but not with flutter-sdk function

I mean are you trying to make request using token? because in the SDK you don't need to token to make request

if you can show the code of sdk that could be helpful

@awais2075 can you share your code?

specifically, share the functions for generating the token, then using that token in the confirmation


I am getting phone no. from user
then secret
and using token.userId on otp-gneration

I got it
I am using update-phone-verification
instead of update-phone-session

sequence should be
before login
create-phone-session update-phone-session
after login create-phone-verification update-phone-verification

[SOLVED] Flutter SDK - Phone Auth Issue
Recommended threads
- "Memberships privacy" setting in 1.7.4
Hi everyone, I'm experiencing an issue with a clean self-hosted installation of Appwrite version 1.7.4. I previously used version 1.6.1, and if I remember corre...
- Function 404 error - Deployment with the...
I have a function in my Appwrite Cloud (free plan) project that cannot be accessed or deleted (404 in both UI and CLI). I'm stuck at the 5 functions limit and c...
- 1.6 to 1.7 does not work
Appwrite (self-hosted) stopped working after updating from 1.6.2 that was stable. Getting the general_server_error. Mentioning I fallowed all steps for upgrad...
