To set up Facebook as an identity provider for the "Single Sign-On with OAuth 2" add-on, you will need a Facebook Login app. If you have it already configured in your Facebook Developer account, you will need only to connect it properly to your X-Cart-based store. If you don't have a configured Facebook Login app, you will need to set it up.

To create a Facebook Login app:

  • Log in to your Facebook Developer account.

  • Click Create App button.

  • Select the Build Connected Experience option and complete the app creation procedure following the regular steps.

  • Open the app Settings -> Basic page to get your App ID and App Secret and specify your store URL in the App Domains field.
    Please also don't forget to fill in the Privacy Policy URL, Terms of Service URL, and Category fields. You will this to go live with your app.

  • In the Products -> Facebook login menu, open the Settings page. Here you need to specify the Valid OAuth Redirect URIs value.
    It should be like https://your_xcart_based_store_url/?target=oauth2return&provider=facebook

  • Make your app live by switching the In development toggle to Live.

To set up the Facebook identity provider in X-Cart:

  • On the Providers page of your store's Admin area (Store Setup -> Providers), open the Facebook provider details page and configure the general settings as described here.

  • Proceed to Settings.
    Paste the Facebook Login app App ID and App Secret data in the relevant fields.

  • Click Update to complete the provider set-up in your store Admin area.

Login with Facebook comes configured and enabled as a result.

The Facebook login icon will appear:

  • in the storefront header;

  • on the checkout page.

When a buyer clicks this icon to sign-up in your store, the "Log in to Facebook" form appears where they can sign in with an existing Facebook account.

Your X-Cart-based store registers this information and records it in the related customer account (Social Accounts tab).

In case this is a buyer's first-time sign-up, a new customer account is created, provided the Single Sign-On with OAuth 2 add-on is configured accordingly.

Did this answer your question?