# Integrate Cloud Voice PBX with Microsoft Teams

This integration lets your Microsoft Teams users place and receive calls through your Cloud Voice PBX (Private Branch Exchange: the business phone system that routes your calls). Once the preparation is complete, you finish the setup from the integration configuration portal. Sign in with a Microsoft 365 administrator account and work through the four stages below to connect Cloud Voice with Microsoft Teams.

:::caution
You must sign in with a Microsoft 365 administrator account. Both the tenant check in Step 1 and the synchronization in Step 3 need administrator rights to read and change your Microsoft 365 settings, so a standard user account cannot complete this setup.
:::

## Step 1. Verify your Microsoft 365 tenant

Start by confirming that your Microsoft 365 tenant is ready for the integration. A tenant is your organization's dedicated Microsoft 365 environment.

1. In the top navigation bar, select the **Getting Started** tab.
2. On the **Prerequisites** page, select **Check My Tenant**.

   ![Prerequisites page with the option to validate the Microsoft 365 tenant](/images/pbx/check-tenant.png)

3. When prompted, choose your Microsoft 365 admin account. The portal begins checking the tenant.
4. When the tenant passes, select **Next** to continue to the PBX service setup.

   ![Tenant check passed, ready to move on to PBX setup](/images/pbx/check-tenant-next-step.png)

:::note
The tenant check is read-only: it reports whether your Microsoft 365 tenant meets the integration prerequisites (such as the required domains and permissions) and changes nothing. If the check fails, complete the outstanding preparation steps and run it again. You cannot move on until the tenant passes.
:::

## Step 2. Add your PBX service

1. Open the **PBX/Trunk** page and select the **PBX** tab.
2. Provide the PBX details:

   ![Form for adding the Cloud Voice PBX service to the integration](/images/pbx/add-p-cloudpbx-on-call2teams.png)

   - **Start by selecting your PBX from the available templates**: choose **Cloud Voice PBX**.
   - **Country**: select the country where your system operates.
   - **SIP Domain**: enter your PBX domain name, for example `yourcompany.cloudvoice.com`. SIP (Session Initiation Protocol) is the signaling standard that sets up and tears down voice calls.

   :::caution
   Enter the exact domain name of your Cloud Voice PBX in **SIP Domain**. If this value does not match your PBX, Teams users cannot register and every call will fail.
   :::

3. Select **Add PBX**. A green "Service successfully enabled" confirmation appears, and the portal moves automatically to the **Teams** page to begin synchronization.

## Step 3. Synchronize with Microsoft 365

1. Select **Sync Now - Changes Queued** to push your Cloud Voice configuration to Microsoft 365.

   ![Teams page with the control to synchronize Cloud Voice and Microsoft 365](/images/pbx/sync-microsoft-with-pbx.png)

2. When synchronization finishes, select **Next** to start mapping Teams users to extensions.

:::note
Synchronization can take several minutes to complete. Wait for it to finish before selecting **Next**: interrupting it can leave the configuration only partly applied.
:::

## Step 4. Link a Teams user to a SIP extension

So that a user can place and answer calls in Microsoft Teams through your phone system, associate that Teams user with a SIP extension.

1. On the **Users** page, complete the following fields:

   ![User association form linking a Teams user to a SIP extension](/images/pbx/interoperability-cloud.png)

   - **Select a User**: choose a Teams user from the drop-down list.

     :::note
     The selected user must hold both the required [Microsoft](/pbx/integrations/microsoft-teams/integrate-cloud-voice-with-microsoft-teams/#microsoft-teams-integration-guide-overview__table_cmp_wnq_ylb) and [Cloud Voice for Microsoft Teams](/pbx/integrations/microsoft-teams/integrate-cloud-voice-with-microsoft-teams/#microsoft-teams-integration-guide-overview__yeastar-for-microsoft-teams) licenses. Without them, the user cannot make or receive calls.
     :::

   - **Phone Number**: assign the user's phone number.
   - **SIP Username**: enter the extension's **Extension Number**.
   - **Auth Username**: enter the extension's **Registration Name**.
   - **Password**: enter the extension's **Registration password**.

   :::caution
   The **SIP Username**, **Auth Username**, and **Password** must match the extension's registration details exactly (its Extension Number, Registration Name, and Registration password in Cloud Voice). A single mismatch stops the user from registering, so the Teams user cannot place or receive calls.
   :::

2. Select **Add User and Sync**. A green "Service user successfully added" message confirms the change. When the user is linked to the PBX, the Registration status shows a success indicator ![registered](/images/pbx/call2team-add-users-success.png).

   ![User successfully associated with the PBX in the integration portal](/images/pbx/create-a-user-call2teams-success.png)

## Result

With the integration in place, Teams users can make and receive internal calls between Microsoft Teams and your Cloud Voice extensions.

## Next steps

- To let Teams users place outbound calls over a Cloud Voice trunk, [configure dial plans in Microsoft Teams](/pbx/integrations/microsoft-teams/configure-dial-plans-in-microsoft-teams/).
- To let Teams users receive inbound calls over a trunk, make sure at least one inbound route delivers calls to the extensions that are linked to those users.
