Azure Bot Services : Deploy and Endpoint (Microsoft Teams)

This tutorial explains how to create and connect an Azure Bot Services Endpoint to Azure Bot Service (Microsoft Bot Framework). 

The Azure Bot Services Endpoint needs to make requests to the following domains:. You can whitelist these in your proxy if necessary:

  • login.botframework.com/v1/.well-known/openidconfiguration
  • login.microsoftonline.com/botframework.com/oauth2/v2.0/token
  • *.botframework.com matching to the corresponding channel (e.g. msteams.botframework.com)

Setup Process

  1. Create an Azure Bot Services Endpoint
  2. Integrate Azure Bot Services with your Bot Framework team
  3. Send messages to your Bot

1. Create an Azure Bot Services Endpoint

 

The first thing you need to do is create an Azure Bot Services Endpoint. In order to do this, navigate to your Project, click on the button in the lower left corner and create an Endpoint.

 

 

After creating your Endpoint, you should be able to navigate to the Endpoint configuration of your Azure Bot Services Endpoint. Here you need to set the Flow that the Endpoint should point to, and you can change the NLU Connector of the Endpoint.

 

 

Now that you have created the Azure Bot Services Endpoint, all that is left to do is to connect it to the Azure Bot Services. The Azure Bot Services Endpoint contains Azure Bot Services Settings which are two settings we need in order to connect to the Endpoint of the Azure Bot Service. We will need:

  • The app ID of your bot in Azure Bot Service
  • A secret of your bot in Azure Bot Service

The next chapter will describe where you can find this setting in Azure Bot Services.

 

2. Creating a bot in Azure Bot Service

Requirements
✔ Endpoint URL

 

In order to create a bot in Azure Bot Service, log into the Azure portal and search for "Bot Services". Create a new bot and choose "Azure Bot".

 

Select "Create", which will take you to the "create an azure bot" menu.

 

 

Complete the information on the next page and finish the creation of the bot. 

Once the bot shows up in your list of Bot Services, click it and go to the "Configuration" page. Add the Endpoint URL as the messaging endpoint.

 

 

You will also find the Microsoft App ID on the settings page, which will be needed in step 3.

 

3. Connecting your Azure Bot Services Endpoint to Azure Bot Service

Requirements
✔ Endpoint URL
✔ Bot in Azure Bot Service

 

To connect your Endpoint to the Azure Bot Service, do the following steps:

  1. Get the bot's App ID and App Password from Azure Bot Service. In the Azure Bot Service Dashboard, go to the Configuration page of your bot.
  2. Find the Microsoft App ID field. Copy the value and save it temporarily, for example, in a text editor.
  3. Open the Azure Active Directory admin center and click Azure Active Directory > App registrations.
  4. Select created bot from the application list.
  5. In the Manage menu, click Certificates & secretes.
  6. Create a client secret. Copy the value and save it temporarily, for example, in a text editor.
  7.  

Additional security settings for secure Azure tenants.

 

Some Azure tenants will require a manual change to the signInAudience parameter in the App's manifest. This will be obvious if messages are not received when first testing the bot. To alter this value, go to App Registrations > {Your Bot Registration} > Manifest and select AzureADMultipleOrgs as the signInAudience parameter.

Now you have the App Id and the App Password (Client Secret) so you can open the Azure Bot Services Endpoint and put in the values in the corresponding fields in the Bot Framework Settings Form.

 

 

You have now finished connecting your Endpoint to Azure Bot Service! Connect a channel to your bot in Azure Bot Service and communicate with your Conversation AI.

Azure Bot Services allows you to connect to a variety of channels, including a direct chat bot in Microsoft Teams, as shown below: