---
title: "Integrating Azure AD B2C"
slug: "integrating-azure-ad-b2c"
updated: 2023-06-29T15:47:39Z
published: 2023-06-29T15:47:40Z
---

> ## Documentation Index
> Fetch the complete documentation index at: https://help.nexudus.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Integrating Azure AD B2C

## What you need to get started

### A Microsoft Azure account

If you don't have a Microsoft Azure account yet, visit [azure.microsoft.com](https://azure.microsoft.com) to create one.

### An active directory B2C tenant

You also need an Azure Active Directory (B2C) tenant. This tenant will allow customers to use their own active directory. Microsoft offers a handy tutorial to create your tenant — [Create an Azure Active Directory B2C tenant](https://learn.microsoft.com/en-us/azure/active-directory-b2c/tutorial-create-tenant).

### An application within your directory tenant

You also need a dedicated application within your Microsoft Azure account. Microsoft offers a handy tutorial to create your tenant — [Register a web application](https://learn.microsoft.com/en-us/azure/active-directory-b2c/tutorial-register-applications?tabs=app-reg-ga)

          Simply make sure you select **Accounts in any identity provider or organizational directory (for authenticating users with user flows)** under *Supported account types* when registering your application.

          

![AzureADB2C_APplicationAccountType_Highlight](https://cdn.document360.io/4f9a66c7-3dbb-4052-97d8-5439302e1512/Images/Documentation/AzureADB2C_APplicationAccountType_Highlight.png)

### Your application ID and directory tenant ID

Once you've created the application, copy the **Application (client) ID** and the **Directory (tenant) ID** and save them. You'll need them to enable the integration on the Admin Panel.

![image.png](https://cdn.document360.io/4f9a66c7-3dbb-4052-97d8-5439302e1512/Images/Documentation/image%28532%29.png)

### A client secret

You also need a client secret to enable the integration on the Admin Panel.

![image.png](https://cdn.document360.io/4f9a66c7-3dbb-4052-97d8-5439302e1512/Images/Documentation/image%28533%29.png)

1. Click **Certificates and Secrets** in the navigation menu and then click on the **Client Secret** tab.
2. Click **New client secret**.
3. Name your secret and set an expiration period.

          You need to create a new secret once this one expires and update your Nexudus settings accordingly.

          

Azure sends you a reminder before the secret expires, but we strongly recommend also setting your own reminder in your calendar.

**If the secret expires before your update, users won't be able to log in to the Members Portal.**

1. Copy **Value** of your client secret (not the ID) and save it somewhere.

          Treat your secret as you would any other password and make sure you save it somewhere safe.

          

### A user flow

The last element you need before enabling the integration on the Admin Panel is a user flow in Azure. The user flow defines the user details that your directory shares with Nexudus.

Azure offers a handy tutorial to help you create your user flow — [Create user flows and custom policies in Azure Active Directory B2C](https://learn.microsoft.com/en-us/azure/active-directory-b2c/tutorial-create-user-flows?pivots=b2c-user-flow)

          Make sure your user flow includes at least the following attributes/claims:

          

**Collect Attributes**

- City
- Country/Region
- Email address
- Given name
- Surname

**Return claims**

- City
- Country/Region
- Display Name
- Given name
- Surname

---

## Integrating Azure Active Directory (B2C)

Make sure you have the following details handy to complete the process:

- Your Azure Active Directory (B2C) **Directory (tenant)** and **Application (client)** IDs
- Your Azure Active Directory (B2C) **client secret**
- Your Azure Active Directory (B2C) **user flow**

1. Log in to [dashboard.nexudus.com](https://dashboard.nexudus.com/) if you aren't already.
2. Click [**Settings > Integrations > Azure Active Directory**](https://dashboard.nexudus.com/settings/integrations/ad).
3. Enable the **Azure Active Directory integration** toggle.
4. Enable the **Create new users in Nexudus if they don't exist toggle** if you want to automatically register users without an existing customer account as contacts in Nexudus.
5. Enable the **Prevent users from using their Nexudus password to log in** if you want customers to only be able to use Azure AD to log in to their account.

          Enabling this option will automatically redirect users to Azure AD when they click on your Members Portal login page.

          

1. Add your Azure Active Directory (B2C) **Directory (tenant) ID** in the **Tenant ID** field.
2. Add your Azure Active Directory (B2C) **Application (client) ID** in the **Client ID** field.
3. Add your Azure Active Directory (B2C) application's client secret in the **Client Secret** field.
4. Add the text you want to show customers on the Members Portal in the **Sign in button label**.

*The default text is **Sign in with Corporate Account**.*

1. Click the **Save Changes** button.

---

All set! You've completed your Azure Active Directory (B2C) integration.
