Search code examples
iosswiftxcodeapple-idapple-sign-in

Sign in with Apple ASAuthorizationAppleIDCredential returns random email when user select 'Hide My Email' option for iOS


When I go through the Sign in with apple I am getting first time exact email address and basic details of the user which I want but second time in response there is no email field in response.

My concern is that I want email address of the user so in future I can send notification email to that particular user. but apple gives random created email, in reality that doesn't exists. How to contact to user in future by email?


Solution

  • When I was finding solution I got to know, we have to pass an email address for following:

    The email addresses you register will be able to send and receive messages to and from customers using Apple’s private email relay service.

    enter image description here

    Once I added this I am able to send and receive the emails.

    https://developer.apple.com/account/resources/services/configure