Apple Social Connection
This guide outlines the steps to configure Sign in with Apple as a social login provider in AuthAction.
Apple does not use the Client ID and Client Secret pattern of the other providers. You will need four values:
- Services ID — acts as the client ID. This is a separate identifier from your App ID.
- Private key (.p8) — used in place of a client secret.
- Team ID and Key ID — identify the key when signing requests.
All four are required.
A paid Apple Developer Program membership is needed. Sign in with Apple is not available on a free account.
Step 1: Create an App ID
Section titled “Step 1: Create an App ID”- Go to Certificates, Identifiers & Profiles in the Apple Developer portal.
- Select Identifiers, then click the + button.
- Choose App IDs, then App.
- Enter a Description and an explicit Bundle ID (for example
com.example.app). - Under Capabilities, enable Sign in with Apple.
- Click Continue, then Register.
You need an App ID even if you only support web login — the Services ID in the next step groups under it.
Step 2: Create a Services ID
Section titled “Step 2: Create a Services ID”- In Identifiers, click the + button again.
- Choose Services IDs, then click Continue.
- Enter a Description and an Identifier (for example
com.example.auth). - Click Continue, then Register.
The Identifier you enter here is your client ID in AuthAction. It is a different value from the App ID’s bundle ID.
Step 3: Configure Web Authentication
Section titled “Step 3: Configure Web Authentication”- In Identifiers, switch the filter to Services IDs and select the Services ID you just created.
- Tick Sign In with Apple, then click Configure.
- Set Primary App ID to the App ID from Step 1.
- Next to Website URLs, click the + button.
- Under Domains and Subdomains, enter your AuthAction domain without a scheme:
<tenant-name>.<region>.authaction.com
- Under Return URLs, enter the full callback URL:
https://<tenant-name>.<region>.authaction.com/oauth2/login/callback
- Click Next, then Done, then Continue, then Save.
If you use a custom domain, register that domain and its callback URL instead — for example auth.example.com and https://auth.example.com/oauth2/login/callback. The return URL must match the domain your users land on.
Return URLs must use https:// and cannot contain query parameters. No domain verification file is required.
Step 4: Create a Sign in with Apple Key
Section titled “Step 4: Create a Sign in with Apple Key”- In the Apple Developer portal, go to Keys, then click the + button.
- Enter a Key Name.
- Tick Sign in with Apple, then click Configure.
- Select the App ID from Step 1 as the Primary App ID, then click Save.
- Click Continue, then Register.
- Click Download to save the
.p8file, and note the Key ID shown on the page.
The .p8 file can only be downloaded once. If you lose it, revoke the key and create a new one.
Step 5: Find Your Team ID
Section titled “Step 5: Find Your Team ID”Your 10-character Team ID appears in the top-right of the Apple Developer portal, and under Membership details.
Step 6: Configure Apple in AuthAction
Section titled “Step 6: Configure Apple in AuthAction”-
Sign in to the AuthAction Dashboard.
-
Navigate to Connections > Social Connections.
-
Select Apple from the available providers.
-
Enter the four values:
Field Value Services ID (Client ID) The Services ID identifier from Step 2, for example com.example.authPrivate key (.p8) The full contents of the .p8file, including theBEGIN/ENDlinesTeam ID Your 10-character Team ID from Step 5 Key ID The Key ID of the .p8key from Step 4 -
Click Save.
Paste the .p8 contents exactly as they appear in the file, with real line breaks.
Step 7: Enable the Apple Connection for Your Application
Section titled “Step 7: Enable the Apple Connection for Your Application”- Navigate to Applications in the AuthAction Dashboard.
- Select the application you want to enable Apple authentication for.
- Enable the Apple Social Connection toggle.
- Save the changes.
Step 8: Verify the Integration
Section titled “Step 8: Verify the Integration”- Open your application’s login page.
- Confirm the Sign in with Apple option is available.
- Click it and authenticate with an Apple Account.
- Confirm that the user is redirected back to your application successfully.
Things to Know
Section titled “Things to Know”The user’s name is returned only once. Apple sends it on the first authorization for a given user and never again. AuthAction stores it at that point. To test this path again, remove the app under Apple Account > Sign in with Apple on your device and sign in once more.
Users can hide their email address. Apple’s Private Email Relay lets users sign in with a generated @privaterelay.appleid.com address. AuthAction identifies users by Apple’s stable sub claim, so the account stays the same user either way.
Only name and email are requested. These are the only scopes AuthAction requests from Apple.
Troubleshooting
Section titled “Troubleshooting”invalid_client at token exchange. One of the four values is wrong. Most often the Services ID has been set to the App ID’s bundle ID, or the Team ID or Key ID does not match the .p8 key.
Invalid redirect URI. The return URL registered on the Services ID does not match the one AuthAction sends. Check the domain, the exact /oauth2/login/callback path, and that you registered your custom domain if you use one.
The key is rejected. The .p8 contents were altered when pasted — usually escaped \n sequences instead of real line breaks. Paste the file contents verbatim.
Once verified, users can sign in with Apple in both development and production environments.