---
schema_version: "1"
id: bb4bdfcfc02dfb6fa89c4e59cc5a40c7df2677535a5f8bcc26ac0fc55ba36b6f
title: Create a Registration Handler
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/branded_apps_apple_id_handler.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.branded_apps_apple_id_handler.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: f3d9e240a9a9a9d7fcd8de5b166a4a9680bcd2cae486e9b5b42a9b633dd2a4b1
description: A registration handler is an Apex class that handles the heavy lifting of creating Salesforce users, updating users, and linking to existing users, accounts, and contacts.
products:
  - Experiences
  - Mobile App
  - Cross Cloud
release: "264"
---
# Create a Registration Handler

A registration handler is an Apex class that handles the heavy lifting of creating Salesforce users, updating users, and linking to existing users, accounts, and contacts.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Setup for Mobile Publisher available in: Lightning Experience</td></tr></tbody><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Setup for Mobile Publisher available in: production only (not sandbox)</td></tr></tbody><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in Lightning Experience in: <strong>Enterprise</strong>, <strong>Performance</strong>, and <strong>Unlimited</strong> Editions</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d15202e59">User Permissions Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d15202e59 ">To create and modify a Mobile Publisher project:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d15202e59 ">Manage mySalesforce Apps</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d15202e59 ">To view the settings:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d15202e59 ">View Setup and Configuration</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d15202e59 ">To edit the settings:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d15202e59 ">
              <p>Customize Application </p>
              <p style="margin-bottom:0;">AND</p>
              <p style="margin-bottom:0;"> Manage Auth. Providers</p>
            </td>

          </tr>
        </tbody>
      </table>

Your registration handler enables SSO to Salesforce using your Apple authentication provider. Create a registration handler based on a sample SocialRegHandler registration handler available from GitHub. Then update your Apple auth.provider with the new handler.

1. Download SocialRegHandler from GitHub: [https://github.com/salesforceidentity/social-signon-reghandler](https://github.com/salesforceidentity/social-signon-reghandler).
2. From Setup, enter Apex Classes in the Quick Find box, then click **Apex Classes**.
3. Locate the Apex class for the registration handler created when you created the Apple auth. provider. Replace the contents with the Apex code downloaded from GitHub.
4. Modify the Apex class for Apple. For reference, see [RegistrationHandler Interface](https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_auth_plugin.htm).
5. From the Apple Auth. Provider page, for Registration Handler, select the Apple registration handler that you created.
6. For Execute Registration As, select a Salesforce admin with Manage Users permission.
    
    Execute Registration As provides the context in which the registration handler runs. Choose a user regardless of whether you’re specifying an existing registration handler class or creating one from the template. In production, you typically create a system user for the Execute Registration As user. This way, operations performed by the handler are easily traced back to the registration process. For example, if a contact is created, the system user creates it.
7. Save your settings.