Back

Issue with Apple Sign-In Implementation

  • 0
  • Flutter
Jakub Sosna
22 Sep, 2023, 08:02

I am facing issues while implementing Apple Sign-In in Appwrite. I followed the instructions outlined in this article https://dev.to/appwrite/apple-sign-in-with-appwrite-2576 and I have also configured web to capture the OAuth2 callback URL according to the documentation https://appwrite.io/docs/getting-started-for-flutter#web.

Expected Behavior: After successful login, I should be redirected back to the application without any issues, and the web view should close automatically.

Actual Behavior: After logging in, I am redirected to the HTML page that I initially set up for web configuration. The web view doesn't close, and the login process is not completed. If I click "cancel" an error appears - "PlatformException(CANCELED, User canceled login, null, null)".

Steps to Reproduce:

  1. Set up Apple Sign-In in Appwrite according to the article.
  2. Try to login via Apple.
  3. Redirected to the HTML page that I configured for web.
TL;DR
The user is facing issues while implementing Apple Sign-In in Appwrite. After logging in, they are redirected to the HTML page they set up for web configuration, the web view doesn't close, and the login process is not completed. Clicking "cancel" triggers an error. The user followed the instructions in the provided article and configured web to capture the OAuth2 callback URL. Solution: The user resolved the issue by ensuring that the success parameter is only passed when calling createOAuth2Session() in a web environment.
Jakub Sosna
22 Sep, 2023, 08:45

I've resolved the issue. The success parameter should be passed only when calling createOAuth2Session() in a web environment.

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