MS Teams ChatBot Installation
Creating and Configuring an Azure Bot for Microsoft Teams
Last updated
Creating and Configuring an Azure Bot for Microsoft Teams
Last updated
Azure Bot Service is a versatile platform hosted and developed on Microsoft Azure, designed to create and deploy chatbots. It allows bots to be utilized across various platforms and channels such as websites, mobile applications, Microsoft Teams, Skype, Facebook Messenger, and more.
Azure Bot Service equips developers with a range of tools and services, including natural language processing (NLP) capabilities, enabling bots to interact naturally with users through text or speech. Additionally, it integrates with the Azure Bot Framework, offering a variety of APIs and resources for developers to customize and enhance their bots.
This service allows businesses to automate and improve a multitude of tasks, from customer support to information dissemination, by creating efficient and responsive chatbots. Bots can be programmed to answer user questions, provide services, or perform specific tasks, thereby streamlining operations and enhancing user engagement.
In summary, the Azure Bot resource provides the essential infrastructure for a bot to access secured resources and enables communication with users through various channels like Web Chat. This guide will help you set up and configure an Azure Bot for seamless integration with Microsoft Teams, ensuring robust and dynamic interactions with your users.
You can follow the video of MS Teams bot creation. The steps on the video are listed below.
Instruction: Go to the Azure portal.
Detailed Guide: Visit the Azure Portal to manage your Azure resources.
Implementation Steps:
Open your web browser.
Navigate to Azure Portal.
Microsoft Documentation Link: Azure Portal
Instruction: Under the Azure Services, select Create a resource.
Detailed Guide: Once in the Azure Portal, look for the "Azure Services" section on the main dashboard. Click on Create a resource
.
Implementation Steps:
In the Azure Portal, locate the "Azure Services" section.
Click on Create a resource
.
Microsoft Documentation Link: Create a resource in Azure
Instruction: In the search box, enter bot, then press Enter. Select the Azure Bot card.
Detailed Guide: In the "Create a resource" page, you will find a search box. Enter bot
and press Enter. From the search results, select the Azure Bot
card.
Implementation Steps:
In the "Create a resource" page, find the search box.
Enter bot
and press Enter.
From the search results, select the Azure Bot
card.
Microsoft Documentation Link: Create a bot with Azure Bot Service
Instruction: Select Create. Enter the required values.
Detailed Guide: Click the Create
button. You will need to enter several required values:
Bot handle: A unique identifier for your bot.
Subscription: Choose your Azure subscription.
Resource Group: Either create a new resource group or use an existing one.
Region: Select the appropriate region.
Implementation Steps:
Click the Create
button.
Enter the required values:
Bot handle: A unique identifier for your bot.
Subscription: Choose your Azure subscription.
Resource Group: Either create a new resource group or use an existing one.
Region: Select the appropriate region.
Instruction: Select “Review + create.” If the validation passes, select Create. You should see the Azure Bot and the related key vault resources listed in the resource group you selected.
Detailed Guide: After filling in the required fields, click Review + create
. If the validation passes, click Create
.
Implementation Steps:
Click Review + create
.
If validation passes, click Create
.
Microsoft Documentation Link: Create a resource in Azure
Instruction: After the Create process is completed, select Go to Resource.
Detailed Guide: Once the creation process is complete, click on Go to resource
to access your Azure Bot.
Implementation Steps:
After the creation process completes, click Go to resource
.
Microsoft Documentation Link: Manage resources in the Azure portal
Instruction: On the resource page, click Channels on the left side panel.
Detailed Guide: On the Azure Bot resource page, look for the Channels
option in the left-side panel and click it.
Implementation Steps:
On the Azure Bot resource page, find the Channels
option in the left-side panel.
Click Channels
.
Microsoft Documentation Link: Connect a bot to channels
Instruction: On the Channel page, click on Microsoft Teams and accept the Terms of Service. On the next page, select Microsoft Teams Commercial option and then click Apply at the bottom of the page.
Detailed Guide: In the Channels page, find and click on Microsoft Teams
. Review and accept the Terms of Service. On the next page, select Microsoft Teams Commercial
and click Apply
.
Implementation Steps:
In the Channels page, click on Microsoft Teams
.
Review and accept the Terms of Service.
On the next page, select Microsoft Teams Commercial
and click Apply
.
Instruction: Select Configuration from the left side pane to fill the configuration fields like Messaging Endpoint and having Application ID and defining Application Password.
Detailed Guide: Navigate to the Configuration
section in the left-side pane. Fill in the Messaging Endpoint
with your Autom Mate Flow Webhook URL. Note down your Microsoft App ID, which will be used for creating App Credentials under Autom Mate’s Vault module. Next to the Microsoft App ID label, click Manage Password
to define the Application Password.
Implementation Steps:
Navigate to the Configuration
section in the left-side pane.
Fill in the Messaging Endpoint
with your Autom Mate Flow Webhook URL.
Note down your Microsoft App ID.
Next to the Microsoft App ID label, click Manage Password
to define the Application Password.
Microsoft Documentation Link: Configure your bot
Instruction: To define Microsoft Password, click on Manage Password right next to Microsoft App ID Label. After you click Manage Password, select New client secret.
Detailed Guide: After clicking Manage Password
, select New client secret
.
Implementation Steps:
Click Manage Password
next to the Microsoft App ID label.
Select New client secret
.
Microsoft Documentation Link: Add a client secret
Instruction: On the right side pane, fill the Description field to specify your Client secret’s friendly name and select one option to define Expire date of your client secret. Also, you can define a custom date as well. Click Add to save your Client secret. Copy your client secret by clicking right next to the created Value column.
Detailed Guide: On the right-side pane, fill in the Description
field with a friendly name for your client secret. Choose an expiration date or set a custom date. Click Add
to save the client secret. Copy your client secret from the value column.
Implementation Steps:
On the right-side pane, fill in the Description
field with a friendly name for your client secret.
Choose an expiration date or set a custom date.
Click Add
to save the client secret.
Copy your client secret from the value column.
Microsoft Documentation Link: Add a client secret
Instruction: If you want to customize your bot, click Branding & properties. To customize your bot with your company’s assets like Logo, website URL, terms of service URL, privacy statement URL, etc., fill in the necessary fields.
Detailed Guide: Go to Branding & properties
to customize your bot with your company's assets. Fill in details like logo, website URL, terms of service URL, privacy statement URL, etc.
Implementation Steps:
Click Branding & properties
.
Fill in the necessary fields such as logo, website URL, terms of service URL, and privacy statement URL.
Microsoft Documentation Link: Customize bot branding
Instruction: After creating the Azure bot on Azure Portal, publish the bot as an app on the developer portal. Go to Developer Portal. Click “Apps” from the left-side pane.
Detailed Guide: Go to the Developer Portal. From the left-side pane, select Apps
.
Implementation Steps:
Go to the Developer Portal.
From the left-side pane, select Apps
.
Microsoft Documentation Link: Overview of Teams Developer Portal
Instruction: Click “New App” from the top nav bar. Enter the name of the app and click “Add”.
Detailed Guide: Click New App
from the top navigation bar. Enter the name of your app and click Add
.
Implementation Steps:
Click New App
from the top navigation bar.
Enter the name of your app.
Click Add
.
Microsoft Documentation Link: Create your first Microsoft Teams app
Instruction: Fill the required fields under the “Basic Information” section. Fill the “Application (Client) ID” field with the ID value of your Azure Bot. After you fill all required fields, click “Save”.
Detailed Guide: Complete the required fields under the Basic Information
section. In the Application (Client) ID
field, enter the ID value of your Azure Bot. Click Save
.
Implementation Steps:
Complete the required fields under the Basic Information
section.
In the Application (Client) ID
field, enter the ID value of your Azure Bot.
Click Save
.
Microsoft Documentation Link: Teams app manifest
Instruction: From the left sidebar, click on “Permissions”. On the permissions page, select “ChannelMessage.Read.Group and ChannelMessage.Send.Group” permissions under Teams Permission. Select “ChatMessage.Read.Chat and ChatMessage.Send.Chat“ permissions under "Chat/Messaging Permissions". Save all changes.
Detailed Guide: From the left sidebar, click on Permissions
. Under Teams Permission
, select ChannelMessage.Read.Group
and ChannelMessage.Send.Group
. Under Chat/Messaging Permissions
, select ChatMessage.Read.Chat
and ChatMessage.Send.Chat
. Save all changes.
Implementation Steps:
From the left sidebar, click on Permissions
.
Under Teams Permission
, select ChannelMessage.Read.Group
and ChannelMessage.Send.Group
.
Under Chat/Messaging Permissions
, select ChatMessage.Read.Chat
and ChatMessage.Send.Chat
.
Save all changes.
Microsoft Documentation Link: Set permissions for Microsoft Teams apps
Instruction: After saving permissions' information, click on "App Features" from the left sidebar. On the App Features page, click on Bot. Fill the Bot ID field with your Bot’s app ID and check the checkboxes under the scopes. Then click Save.
Detailed Guide: Click on App Features
from the left sidebar. On the App Features page, click on Bot
. Enter the Bot ID with your Bot’s app ID. Check the appropriate checkboxes under the scopes. Click Save
.
Implementation Steps:
Click on App Features
from the left sidebar.
On the App Features page, click on Bot
.
Enter the Bot ID with your Bot’s app ID.
Check the appropriate checkboxes under the scopes.
Click Save
.
Instruction: Click “Publish” from the top-right corner to download the app package. Click “Download the app package” to use the package on publishing process. A zip file will be downloaded automatically and it should include manifest JSON, color, and outline image files.
Detailed Guide: Click Publish
from the top-right corner to download the app package. Click Download the app package
to download a zip file that includes the manifest JSON, color, and outline image files.
Implementation Steps:
Click Publish
from the top-right corner to download the app package.
Click Download the app package
to download a zip file that includes the manifest JSON, color, and outline image files.
Microsoft Documentation Link: Publish your app
Instruction: Before publishing the app package, test it by going to the Teams app validator page. Click “Upload manifest package” and select the downloaded zip file to validate your package. The test must be successful, otherwise possible errors must be corrected and the testing process must be started again.
Detailed Guide: Go to the Teams App Validator. Click Upload manifest package
and select the downloaded zip file to validate your package. Ensure the test is successful; if there are errors, correct them and re-test.
Implementation Steps:
Go to the Teams App Validator.
Click Upload manifest package
and select the downloaded zip file to validate your package.
Ensure the test is successful; if there are errors, correct them and re-test.
Microsoft Documentation Link: Validate your Microsoft Teams app
Instruction: To publish your app package, go to Teams Admin Center. Click “Upload new app” from the apps page. Click “Upload” and select the downloaded package that you created on the developer portal. The custom app should be uploaded successfully and the success modal should appear on the screen. You should see your app on the list by searching for the name of your app.
Detailed Guide: Go to the Teams Admin Center. From the Apps page, click Upload new app
. Click Upload
and select the downloaded package. The custom app should be uploaded successfully, and a success modal should appear on the screen. Verify your app is listed by searching for its name.
Implementation Steps:
Go to the Teams Admin Center.
From the Apps page, click Upload new app
.
Click Upload
and select the downloaded package.
The custom app should be uploaded successfully, and a success modal should appear on the screen.
Verify your app is listed by searching for its name.
Microsoft Documentation Link: Manage apps in Teams Admin Center
Instruction: To chat with your bot, go to Microsoft Teams on your computer. Click “Apps” from the left side pane and search for your app name that you just published. You should see that your bot has appeared. Click “Add”.
Detailed Guide: Open Microsoft Teams on your computer. From the left-side pane, click Apps
and search for your app name. Click Add
to start chatting with your bot.
Implementation Steps:
Open Microsoft Teams on your computer.
From the left-side pane, click Apps
.
Search for your app name.
Click Add
to start chatting with your bot.
Microsoft Documentation Link: Add and manage apps in Microsoft Teams