-
Set up App Registrations
To register your Client and Server applications, please refer to our registrations set up guideline
-
Deploy to Azure
-
Follow the button to deploy to Azure through Azure Resource Manager template.
-
The template provisions an instance of Communication Services and App Service with deployed code.
-
When the deployment is completed successfully, a few configurations need to be updated on Application settings within Azure App Service using the information from server app registration. You can refer to the Configure Common Settings page to update Application settings within Azure App Service.
Edit the values of following keys by visiting the server app registration:
Note If you created the app regsitrations using scripts, then the
AzureActiveDirectory
configuration values could be found from src/appSettings.ts file within your locally cloned repository.-
AzureActiveDirectory__ClientId
: "<Application Id from 'Overview page of the server app>" -
AzureActiveDirectory__ClientSecret
: "<Client Secret Value from 'Certifactes & secrets' of server app>" -
AzureActiveDirectory__TenantId
: "<Tenant Id from 'Overview' page of the server app>" -
Record the value of
CommunicationServices__ConnectionString
from automatically created Azure Communication Services resource after first deployment to use for subsequent deployments, if you plan to deploy the sample through Azure Resource Manager Template multiple times.
-
‼️ For the multiple deployments of the sample, there could be an error of "mismatched Azure Communication Services Identity not belonging to the Azure Communication Services resource" while invoking/api/token
or/api/user
endpoints and using same Azure Active Directory user account for signing in on client side. The issue would happen since the Azure Communication Services Identity is specific to an Azure Communication Services resource. So if a different Azure Communication Services resource is used within subsequent deployments (Note: The aforementioned Azure Resource Manager template deployment always creates new resources including Azure Communication Services), the persisted Azure Communication Services Identity within Azure Active Directory user instance will not match the Azure Communication Services resource for Azure Active Directory user account. For more information regarding Identity Mapping you can visit Identity Mapping Design. So, please make sure to use theConnectionString
from the same Azure Communication Services in all the deployments if using the same Azure Active Directory instance to sign in.Recommendations
-
For subsequent deployments, swap the "CommunicationServices__ConnectionString" within Application Settings of newly deployed App Service from App Service of earlier created deployment or connection string of any manually created Azure Communication Services used in prior deployments.
-
You can also follow the Troubleshooting section on README to resolve the issue of Mismatched Azure Communication Services Identity and Azure Communication Services resource.
-
-
We have two ways of testing the backend service
- Calling the backend APIs directly with an Azure Active Directory Access Token
- Using the MinimalClient
Please see the two options in detail here. Test backend service.
Here is a set of endpoints that can be tested. API Endpoints.