Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
127 changes: 127 additions & 0 deletions components/microsoft_teams_bot/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
# Overview

By connecting a Microsoft Teams Bot to Pipedream, you can build interactive chat experiences and automate messaging workflows using any of the thousands of apps available on Pipedream.

# Getting Started

To connect your Teams Bot to Pipedream, you'll need to create a bot in Azure, set up a webhook in Pipedream, and configure the Teams app manifest. Follow the detailed instructions below to get started.

## Configuring a Teams Bot in Azure Portal

To get started, you'll need the following:
- An Azure account
- A Microsoft Teams account
- Basic familiarity with Azure Portal

## Quickstart

1. Create a bot in Azure Portal
2. Set up a Pipedream webhook
3. Configure the bot's messaging endpoint
4. Create and upload the Teams app manifest
5. Install the bot in Teams
6. Configure your Pipedream workflow

For detailed instructions, follow the steps below.

## Detailed Setup Instructions

### 1. Create a Bot in Azure

1. Sign in to the [Azure Portal](https://portal.azure.com)
2. Create a new "Azure Bot" resource
3. During creation:
- Select "Create new" Microsoft App ID
- Note down the generated App ID (client_id)
4. Navigate to the "Configuration" section
5. Generate a new client secret
6. Note down the secret value immediately (you won't be able to see it again)

### 2. Set Up Pipedream Webhook to receive bot messages

1. Go to Pipedream
2. Create a new workflow starting with an HTTP trigger
3. Copy the generated webhook URL (format: https://xxx.m.pipedream.net)
- This will be your bot messaging endpoint

Comment on lines +42 to +46
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Add HTTPS validation step for webhook security.

For security best practices, add instructions to verify the HTTPS certificate of the webhook endpoint.

 2. Create a new workflow starting with an HTTP trigger
 3. Copy the generated webhook URL (format: https://xxx.m.pipedream.net)
    - This will be your bot messaging endpoint
+4. Verify that the webhook URL uses HTTPS and has a valid SSL certificate
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
1. Go to Pipedream
2. Create a new workflow starting with an HTTP trigger
3. Copy the generated webhook URL (format: https://xxx.m.pipedream.net)
- This will be your bot messaging endpoint
1. Go to Pipedream
2. Create a new workflow starting with an HTTP trigger
3. Copy the generated webhook URL (format: https://xxx.m.pipedream.net)
- This will be your bot messaging endpoint
4. Verify that the webhook URL uses HTTPS and has a valid SSL certificate
🧰 Tools
🪛 Markdownlint (0.37.0)

44-44: null
Bare URL used

(MD034, no-bare-urls)

### 3. Configure Bot's Messaging Endpoint

1. Return to your Azure Bot resource
2. Under "Configuration"
3. Set Messaging endpoint to your Pipedream webhook URL

### 4. Create Teams App Manifest

1. Create a new file called `manifest.json` with the following template:

```json
{
"$schema": "https://developer.microsoft.com/en-us/json-schemas/teams/v1.14/MicrosoftTeams.schema.json",
"manifestVersion": "1.14",
"version": "1.0.0",
"id": "<your-bot-app-id>",
"packageName": "com.yourcompany.bot",
"developer": {
"name": "Your Company",
"websiteUrl": "https://your-website.com",
"privacyUrl": "https://your-website.com/privacy",
"termsOfUseUrl": "https://your-website.com/terms"
},
"name": {
"short": "Your Bot Name",
"full": "Your Bot Full Name"
},
"description": {
"short": "A brief description",
"full": "A full description of your bot"
},
"icons": {
"outline": "outline.png",
"color": "color.png"
},
"accentColor": "#FFFFFF",
"bots": [
{
"botId": "<your-bot-app-id>",
"scopes": [
"personal",
"team",
"groupchat"
],
"supportsFiles": false,
"isNotificationOnly": false
}
],
"permissions": [
"messageTeamMembers"
]
}
```
Comment on lines +57 to +99
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Add manifest validation instructions and highlight required changes.

The manifest template needs additional guidance:

  1. Highlight all placeholders that need to be replaced (e.g., <your-bot-app-id>, company details)
  2. Add instructions for manifest validation
 1. Create a new file called `manifest.json` with the following template:
+   - Replace all values wrapped in <angle brackets>
+   - Update company information and URLs
+   - Ensure icon files match the specified dimensions
+
+2. Validate your manifest using the Microsoft Teams App Studio or Developer Portal

Committable suggestion skipped: line range outside the PR's diff.


2. Create two icon files:
- `outline.png` (32x32 pixels)
- `color.png` (192x192 pixels)
3. Zip these three files together

### 5. Install Bot in Teams

1. Open Microsoft Teams
2. Go to Apps > Upload a custom app
3. Upload your zip file
4. Follow installation prompts, and your bot will now be added to Microsoft Teams!

### 6. Configure Pipedream Workflow

1. Add "Microsoft Teams Bot" app in Pipedream
2. Enter your Bot's App ID and client secret
3. Configure your workflow to process and respond to messages

# Troubleshooting

- **Authentication Issues**: Verify your App ID and client secret are correct
- **Messaging Endpoint Errors**: Ensure your Pipedream webhook URL is properly configured in Azure
- **Teams Installation Problems**: Check that your manifest.json and icon files meet all requirements

For more details, please see:
* [Azure Bot Service Documentation](https://docs.microsoft.com/en-us/azure/bot-service/)
* [Teams App Manifest Documentation](https://docs.microsoft.com/en-us/microsoftteams/platform/resources/schema/manifest-schema)
Loading