Auth0 integration guide

This document will guide you through configuring Sinch as a Multi-Factor authentication provider in Auth0.

Reminder

This is not a replacement for built-in Auth0's Multi-Factor authentication but rather an alternative.

What you need

Collect Sinch application key and secret

  1. Navigate to Apps in the Verification section of the Sinch customer dashboard .
  2. Locate and save the Key and Secret of the application you intend to use with Auth0. You will need them in the next steps.

sinch-dashboard

Install Sinch Verification Action

  1. Log into your Auth0 dashboard .
  2. In the Marketplace find Sinch Verification .

    auth-marketplace

  3. In the next window click Add integration .

    auth-marketplace

  4. Grant the action access it requires. You'll be prompted for App Key and App Secret . Enter the values that were obtained from the Sinch dashboard in the previous section.
  5. Click Create .

    add-integration-form

Configure post-login trigger

  1. Navigate to Actions -> Triggers in the lefthand menu.
  2. Find a post-login trigger and drag and drop Sinch Verification from installed actions as shown in the picture.

    configure-trigger

Pass additional metadata

Since Sinch is a plug-in into Auth0's Multi-Factor authentication system, it requires additional setup with regards to the user's phone number collection.

Important!

The requirement is that the user's phone number is passed to user metadata under the name phone_number.

The following section is one way to achieve this, but there may be more depending on your setup.

Custom sign up screen

  1. Navigate to Branding -> Universal Login and find Advanced Options

    branding-universal-login

  2. Locate HTML in the Login tab.

    ul-advanced-options

  3. Find Auth0Lock and add additionalSignUpFields with the following data. You might want to add more, for instance, icon to customize the screen to your liking. Refer to official documentation for all available options.
Copy
Copied
var lock = new Auth0Lock(config.clientID, config.auth0Domain, {
  ...
  additionalSignUpFields: [{
    name: "phone_number",
    placeholder: "phone number",
  }]
});

Once this is done, the Sinch Verification integration is ready for use.

We'd love to hear from you!
Rate this content:
Still have a question?
 
Ask the community.