1. アプリのcapabilityでSign in with Apple を選択
- Xcodeで選択
- Apple Developerサイトで選択
2. コード実装
- Sign in with Apple用ボタン&ハンドラ作成
1 | func setupProviderLoginView() { |
- Sign in with Apple用Delegate実装
1 | extension LoginViewController: ASAuthorizationControllerDelegate { |
- Sign in成功時のログ例
1 | "userIdentifier : 000000.00000000000000000000000000000000.0000" |
3. xxxxxxxxx@privaterelay.appleid.com へメールを送信
こちらのメアドは以下の設定なしでは送信しても届かない
- Apple Developerサイトで設定
- ドメインとメアドの登録
4. Sign out方法
設定アプリ -> パスワードとセキュリティ -> Apple IDを使用中のApp -> アプリを選択 -> 停止ボタンを選択
https://stackoverflow.com/questions/58018184/how-to-revoke-sign-in-with-apple-credentials-for-a-specific-app
参考
https://developer.apple.com/documentation/authenticationservices
https://help.apple.com/developer-account/?lang=en#/devde676e696



