# Bot Setup

## Required information for Creating MS Teams Chatbot

To do MS Teams integration, you will need the following details on your end.&#x20;

* Bot ID
* Bot Password
* Update the Webhook endpoint in the Bot Details
* Create and Publish an app for your organization

## Steps to complete integration

### Step 1: Setup MS Teams Bot&#x20;

1. Login to the MS Teams using the following URL <https://teams.microsoft.com/v2/>. If you do not have the MS Teams documentation, Create the one before proceeding.

2. Once logged in, Navigate to the developer portal of MS Teams.

   <figure><img src="/files/kPnyqp4of0CQBZLrZRVt" alt=""><figcaption><p>MS Teams Developer Portal</p></figcaption></figure>

3. Choose the "Tools" tab and click on "Bot Management Option"\
   \
   &#x20;

   <figure><img src="/files/ZrNAML29a1tGIkAMwQNP" alt=""><figcaption><p>Bot Management on MS Teams</p></figcaption></figure>

4. On this Page, Locate the "New Bot" option and add the bot by giving it a name.&#x20;

5. Once the bot is created, Enter the following Webhook endpoint address and click "save" to proceed.\
   <https://api.v7.botpenguin.com/ms-teams/webhook\\>
   \
   \ <br>

   <figure><img src="/files/4FHcs3bnY3dV8L79Oxhi" alt=""><figcaption><p>Configure Webhook Endpoint</p></figcaption></figure>

6. Navigate to "Client Secrets" and add new and Copy the Provide secret key. Keep this secret key safe. This will be used while creating the configuration on BotPenguin.<br>

   <figure><img src="/files/tK7qpYHK4gHtoKROReFp" alt=""><figcaption><p>Bot Password</p></figcaption></figure>

7. Return to the bot listing page and copy the "Bot ID". Keep this key safe. This will be used while creating the configuration on BotPenguin.<br>

   <figure><img src="/files/0hE0jOF06lvEEDL9xHbm" alt=""><figcaption><p>Copy Bot ID</p></figcaption></figure>

### Step 2: Create the MS Teams App

1. Navigate back to the "Apps" tab and click on "New App".&#x20;

2. Create the new app by providing the name. (e.g BotPenguin)

3. Fill in the basic information of the App. \
   \
   An example of the same is as follows

   1. Short Name - BotPenguin
   2. Full name - BotPenguin - The chatbot builder platform
   3. Short description- BotPenguin is an omnichannel platform to automate your communications.
   4. Long description - BotPenguin is an advanced chatbot platform designed to streamline and enhance conversational experiences for businesses across various industries. With a focus on user-friendly interactions, BotPenguin leverages artificial intelligence and natural language processing to create intelligent chatbots that can efficiently handle customer queries, provide information, and engage in meaningful conversations.
   5. Version - 1.0.0
   6. Developer or company name - BotPenguin
   7. Website (must be a valid HTTPS URL) - <https://botpenguin.com/>
   8. Privacy policy- <https://botpenguin.com/privacy-policy>
   9. &#x20;Terms of use - <https://botpenguin.com/terms-and-conditions>
   10. App ID: Same as Bot ID

   <figure><img src="/files/TRy2KbWUm7fIcNvBqLLN" alt=""><figcaption><p>Manage Basic Information</p></figcaption></figure>

4. You can give your own branding to your app or leave as it is.

   <figure><img src="/files/AATmvewTo8ycKc7aZjCf" alt=""><figcaption><p>Manage Branding</p></figcaption></figure>

5. Navigate to the "App Features" tab and add the "Bot". Once the next page opens, choose the relevant bot and assign the following scopes&#x20;

   1. Personal&#x20;
   2. Teams
   3. Group Chat

   Also, Check the following options under what your bot can do.

   1. Upload and Download files

      <figure><img src="/files/Nvv4LcXLGKIN1RbnolfQ" alt=""><figcaption><p>Configure Bot</p></figcaption></figure>

6. Now, Move to the "Publish to Org" tab, and Submit your app for your organization. <br>

   <figure><img src="/files/7dalIdAIuCtuYzWmMOI9" alt=""><figcaption><p>Publish your app</p></figcaption></figure>

### Step 3: Approve your app as Admin

1. Open the Teams admin portal using the following link <https://admin.teams.microsoft.com/>

2. Locate the "Manage Apps" options under the "Team Apps" Section. Search for your app and click on the same. <br>

   <figure><img src="/files/A9DZoVrLr7ernQXXSKyU" alt=""><figcaption><p>Approve App</p></figcaption></figure>

3. Click on the App and Click "Publish"

4. Once you have approved the apps, It takes some time to get listed for your users.&#x20;

### Step 4: Save the configuration on BotPenguin

1. Navigate to the [BotPenguin Dashboard](https://app.botpenguin.com/).
2. Click on "New bot" on the top left.&#x20;

<figure><img src="/files/twxylvmMjkBGVLoyLF6O" alt=""><figcaption></figcaption></figure>

3. Choose MS Teams as Platform.

<figure><img src="/files/y92OU5DzTQpaIMhb7hkh" alt=""><figcaption></figcaption></figure>

4. Select the Business Goal and click on proceed to Next step.

<figure><img src="/files/GxYz6YyshqDozGcrz8R9" alt=""><figcaption></figcaption></figure>

5. Name your bot and Fill in the Bot ID and Bot Secret (Bot Password) which you copied in 1st step.&#x20;

<figure><img src="/files/eRE2YVYA5VNduQHBGA02" alt=""><figcaption></figcaption></figure>

Once you have updated the same. Your bot will be created.&#x20;

If everything is correct and you are still unable to move forward, write to us at <support@botpenguin.com>. We will respond back within 48 business hours.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.botpenguin.com/bots/ms-teams-bot/bot-setup.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
