I'm currently struggling to setup forgot password in my flutter app. It requires the use of deep linking and universal which are still tough to setup. Can someone give a procedure of implementing forgot password. Anyone who has completed implementing it pls share code
Are you asking about how to implement this outside of a flutter mobile app because it's difficult to do it in app?
How to implement it in general is difficult
So anyone who can explain the steps
Or anyone who has the code can show us
Deep linking isn't really specific to Appwrite so you might find more resources in a flutter discord server or maybe some other online resource
import 'package:appwrite/appwrite.dart';
void main() { // Init SDK Client client = Client(); Account account = Account(client);
client .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint .setProject('5df5acd0d48c2') // Your project ID ; Future result = account.createRecovery( email: 'email@example.com', url: 'https://example.com', );
result .then((response) { print(response); }).catchError((error) { print(error.response); }); }
What url do we add to this function
The url that would send the user back to your app
Let's my domain is www.frank.com I'll set my deep link to catch this url to send user back to my app right.?
import 'package:appwrite/appwrite.dart';
void main() { // Init SDK Client client = Client(); Account account = Account(client);
client .setEndpoint('https://[HOSTNAME_OR_IP]/v1') // Your API Endpoint .setProject('5df5acd0d48c2') // Your project ID ; Future result = account.updateRecovery( userId: '[USER_ID]', secret: '[SECRET]', password: 'password', passwordAgain: 'password', );
result .then((response) { print(response); }).catchError((error) { print(error.response); }); }
Yes
What about the secret.?
How do I get it to my second function
The secret will be in the query string of the url
Recommended threads
- listRows result parsing issue
I'm using Appwrite Dart SDK "24.2.0". When I perform a listRows call in dart, I have this reponse in JSON: in " Future<models.RowList> listRows()" { "total" :...
- Broken Flutter SDK >=24.1.0
Row.fromMap now does: ``` data: Map<String, dynamic>.from(map["data"] ?? {}) ``` But Appwrite Cloud TablesDB row responses return custom row columns flattene...
- Flutter OAuth2 does not attach Google se...
Hi Appwrite team, I’m using Appwrite Auth in a Flutter mobile app and trying to upgrade an anonymous user to Google OAuth. Docs say that if there is already a...