For the complete documentation index, see llms.txt. This page is also available as Markdown.

Microsoft Teams for Alert Notifications

Use this integration when your network operations team coordinates incident response in Microsoft Teams. It sends ThousandEyes alert notifications to a channel that responders already monitor. Each notification shows whether an alert was triggered or cleared, its severity, and a link to the alert in ThousandEyes. This shared view helps responders track alert status without relying on a separate email inbox.

This example uses a standard Microsoft Teams channel, an incoming webhook workflow that accepts requests from outside Microsoft Teams, and a custom webhook operation in ThousandEyes. Microsoft manages the Teams setup steps and interface. Use the linked Microsoft documentation if the options in Teams differ from this example.

Prerequisites

System
Requirement

Microsoft Teams

Your account can access the target team and post in its channel. If you need a new team, your organization must allow you to create one. See Create a team from scratch in Microsoft Teams.

Microsoft Teams channel

This procedure uses a standard channel. By default, team owners and members can create standard channels, but an admin can limit this permission. See Standard, private, or shared channels in Microsoft Teams.

Microsoft Teams Workflows

Your account can use the Workflows app. A Teams admin must enable the app and allow it for your account. See Create flows in Microsoft Teams and Manage app permission policies in Microsoft Teams.

ThousandEyes

Your role can create integrations and assign alert rules in the ThousandEyes platform.

Creating a Microsoft Teams Workflow

  1. Choose an existing standard channel for ThousandEyes alerts. If you need a new team, follow Create a team from scratch in Microsoft Teams.

  2. Confirm that the account that owns the workflow can access the team and post in the channel.

  3. Follow Send messages in Teams using incoming webhooks to create a channel webhook. Use values like these for a ThousandEyes workflow:

    Microsoft Teams Setting
    Example Value

    Template

    Send webhook alerts to a channel

    Workflow name

    ThousandEyes alert notifications

    Who can trigger the workflow

    Anyone

    Team

    Network Operations

    Channel

    ThousandEyes Alerts

    ThousandEyes sends webhook requests without a Microsoft identity. If you create the workflow from scratch, select Anyone for the When a Teams webhook request is received trigger.

  4. Save the workflow and copy its webhook URL. Microsoft also explains how to retrieve the URL later in Send messages in Teams using incoming webhooks.

  5. Store the workflow URL securely. You use it to configure the ThousandEyes connector and operation.

The Anyone option does not require Microsoft authentication. Anyone who has the workflow URL can send requests to it, so do not share the URL or include it in tickets, chat messages, or source control.

Microsoft Teams workflows belong to individual owners, not to a team or channel. Use an organization-managed account or add a co-owner so the workflow continues if the original owner leaves. See Create and send messages.

Creating the ThousandEyes Integration

In ThousandEyes, a custom webhook setup has two parts:

  • A generic connector, which stores the workflow host in the Target field.

  • A custom webhook operation, which stores the workflow path, query parameters, headers, and body.

Split the Microsoft Teams workflow URL into these fields before you create the connector and operation. Decode percent-encoded characters when you move query parameter values into the JSON object. For example, use /triggers/manual/run instead of %2Ftriggers%2Fmanual%2Frun for the sp value.

For example, if your workflow URL is:

Use the following ThousandEyes values:

ThousandEyes Field
Value

Target

https://prod-81.westus.logic.azure.com:443

Path

/workflows/122c49e2573a46fc9c211efeb3dd/triggers/manual/paths/invoke

URL Query Parameters

See the JSON example below.

Use the Integration Templates flow if you don't already have a generic connector for Microsoft Teams. If you already have the connector, use the Operations flow instead.

Creating a Connector and Operation from the Integration Template

  1. In the ThousandEyes platform, go to Manage > Integrations.

  2. Select the Integrations 2.0 tab.

  3. Select the Integration Templates tab.

  4. Select the Custom Webhook template.

  5. Set up the generic connector:

    • Name: Type a name that helps you identify the Microsoft Teams channel or workflow.

    • Target: Type the scheme, host, and port from the Microsoft Teams workflow URL.

    • Auth Type: Select Custom unless your organization has configured a separate authentication requirement for the target.

  6. Select Save & Assign Operation.

  7. Set up the custom webhook operation:

    • Operation Name: Type a name that helps you identify the alert-notification operation.

    • Preset Configurations: Select Microsoft Teams if you want ThousandEyes to populate a starting Adaptive Card payload and the Content-Type: application/json header. Selecting a preset replaces any values already in the operation fields.

    • Path: Type the path from the Microsoft Teams workflow URL.

    • Custom Headers: If you don't use the Microsoft Teams preset, add a header with Content-Type as the name and application/json as the value.

    • URL Query Parameters: Paste a JSON object that contains the query parameters from the Microsoft Teams workflow URL. Use /triggers/manual/run for the sp value, not %2Ftriggers%2Fmanual%2Frun.

    • Body: Paste the payload shown below. Microsoft Teams workflows support Adaptive Cards v1.4.

    Replace <account-group-name> with the account group name that you want the card to display before you save the operation.

Open this Alert Button Block

The Action.OpenUrl block in the Body payload creates the Open this Alert button. The title property controls the button label that appears in Microsoft Teams.

The URL expression sends you to the relevant alert:

  • {{#eq type.id 2}} sends triggered alerts to Active Alerts with tab=active.

  • {{else}} sends cleared alerts to Alerts History with tab=history.

  • {{alert.rule.account.id}} selects the account group, and {{alert.id}} filters the list to the alert from the notification.

Alternatively, use the Adaptive Card Designer to customize your card, and then paste that code in the Body field. When you use the designer, nest the Adaptive Card object inside the attachment's content object.

  1. Select Test to verify that the new webhook works.

    • A successful test returns a Testing completed successfully! message.

    • If the test fails:

      • Verify that the connector Target, operation Path, and operation URL Query Parameters match the Microsoft Teams workflow URL from Creating a Microsoft Teams Workflow.

      • Verify that the sp query parameter uses /triggers/manual/run.

      • Verify that the operation includes a Content-Type header with application/json as the value.

      • If the test still fails, contact ThousandEyes Support.

  2. Select Save Integration.

  3. Apply the webhook to your existing alert rules using the resulting Manage Alert Rules panel.

Creating an Operation for an Existing Connector

If you already have a generic connector for the Microsoft Teams workflow host, create only the custom webhook operation:

  1. In the ThousandEyes platform, go to Manage > Integrations.

  2. Select the Integrations 2.0 tab.

  3. Select the Operations tab.

  4. Select New Operation.

  5. Select Custom Webhook.

  6. Fill out the operation fields using the guidance in Creating a Connector and Operation from the Integration Template.

  7. Save the operation and assign it to the generic connector that contains the Microsoft Teams workflow target.

  8. Use Manage Alert Rules to assign the operation to the alert rules that should send notifications to Microsoft Teams.

Receiving Alert Cards

If you use the payload in this article, including the Open this Alert button block, the webhook sends an Adaptive Card with the account group, rule name, severity, and alert ID.

Alert State
Card Behavior

Triggered

The title is red. Open this alert opens the Active Alerts screen for the account group and alert ID.

Cleared

The title is green. Open this alert opens the Alerts History screen for the account group and alert ID.

For more information about configuring webhooks, see Custom Webhooks.

Last updated