@everyone
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
Votes
1
Replies
14
Participants
Unknown
Messages
15
@everyone
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
Rank 5: Hypervisor
can you pls share the exact error you getting in the terminal
@everyone
appwrite user_invalid_token, Invalid token passed in the request
Rank 5: Hypervisor
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
Rank 5: Hypervisor
can you show the code which you are having
@everyone
the problem is
same token works via REST API
but not with
flutter-sdk function
Rank 5: Hypervisor
I mean are you trying to make request using token? because in the SDK you don't need to token to make request
Rank 5: Hypervisor
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
@everyone
@everyone
I am getting
phone no.
from user
then
secret
and using token.userId
on otp-gneration
@everyone
I got it
I am using
update-phone-verification
instead of
update-phone-session
@everyone
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