> For the complete documentation index, see [llms.txt](https://docs.softwaresecured.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.softwaresecured.com/account/integrations/microsoft-teams.md).

# Microsoft Teams

### **Prerequisites**

A <code class="expression">space.vars.product\_name</code> account with <mark style="color:orange;">Org Admin</mark> permissions.

### Steps

{% stepper %}
{% step %}

#### Open Workflows

1. In Microsoft Teams, find the channel that you want to receive notifications in.
2. Hover over the channel name and click the **•••** (three dots) menu that appears.
3. In the menu, select <mark style="color:blue;">**Workflows**</mark>**.**
   {% endstep %}

{% step %}

#### Create a Workflow

1. In the Workflows panel, click <mark style="color:blue;">**Workflows Home**</mark> (lower-right corner).&#x20;
2. Click <mark style="color:blue;">**Build from scratch**</mark> (upper-right corner).
   {% endstep %}

{% step %}

#### Select a Trigger

1. Click <mark style="color:blue;">**Select a trigger**</mark>**.**
2. To see all available triggers, click <mark style="color:blue;">**Build with Power Automate**</mark>.
3. Select the <mark style="color:blue;">**Built-in**</mark> tab, then select <mark style="color:blue;">**Microsoft Teams**</mark> from the list.&#x20;
4. Choose <mark style="color:blue;">**When a Teams webhook request is received**</mark>.
5. For <mark style="color:blue;">**Who can trigger the flow?**</mark>, select <mark style="color:blue;">**Anyone**</mark>.
6. Leave the <mark style="color:blue;">**HTTP POST URL**</mark> field blank. It will be auto-generated when you save.&#x20;
   {% endstep %}

{% step %}

#### Add an Action

1. Click <mark style="color:blue;">**+ New Step**</mark>, then search for and select <mark style="color:blue;">**Microsoft Teams**</mark>.
2. Search for and select <mark style="color:blue;">**Post message in a chat or channel**</mark>**.**
3. Configure the following options:
   * <mark style="color:blue;">**Post as**</mark> → Flow bot.
   * <mark style="color:blue;">**Post in**</mark> → Channel.
   * <mark style="color:blue;">**Team**</mark> → Select your team name.
   * <mark style="color:blue;">**Channel**</mark> → Select your channel name.
     {% endstep %}

{% step %}

#### Configure the Message

1. Click on the <mark style="color:blue;">**Message**</mark> text area.
2. In the popup that appears, select <mark style="color:blue;">**Expression**</mark>**.**
3. Enter the following expression and click <mark style="color:blue;">**OK**</mark>:

   ```
   triggerBody()?['text']
   ```
4. Click <mark style="color:blue;">**Save**</mark> and wait for it to save.
5. Close the Workflows panel.
   {% endstep %}

{% step %}

#### Copy your Webhook URL

1. Hover over your channel and click the **•••** (three dots) menu again.
2. Select <mark style="color:blue;">**Workflows**</mark>.
3. Scroll to <mark style="color:blue;">**Your workflows**</mark> and click the workflow you just created.&#x20;
4. Click <mark style="color:blue;">**Copy webhook link**</mark> to copy the URL to your clipboard.
   {% endstep %}

{% step %}

#### Connect to Portal

1. Go to <mark style="color:orange;">**Portal → Integrations → Microsoft Teams**</mark>.
2. Paste the copied URL into the <mark style="color:orange;">**Webhook URL**</mark> field.&#x20;
3. Enter the name of the channel you connected (such as `alerts`)
4. Click <mark style="color:orange;">**Connect Teams**</mark>.
   {% endstep %}
   {% endstepper %}

### Results

Your channel will now receive notifications from <code class="expression">space.vars.product\_name</code>.&#x20;
