Microsoft Teams
Goal: DownBad alerts post to a Microsoft Teams channel as cards.
You need a paid DownBad plan and permission to create workflows in Teams. Some organizations restrict that to admins.
- Create the workflow. In Teams, open the channel, choose ⋯ → Workflows, and pick the template Post to a channel when a webhook request is received.
- Name it and choose where it posts. Confirm the team and channel, then finish the wizard.
- Copy the URL Teams shows. It’s a long address on
logic.azure.comorenvironment.api.powerplatform.com. Thesig=part of it is the secret, so keep the whole URL private. - Add it in DownBad. Go to Settings › Alerts, press Add webhook and paste the URL. DownBad recognizes it as Microsoft Teams.
- Leave Who can trigger the flow on Anyone, unless your organization restricted the workflow. Then follow Workflows restricted to your organization.
- Press Test now, then save and add the channel to the notification profiles that should use it.
Expected result
Section titled “Expected result”An Adaptive Card arrives with the DownBad logo, headed DownBad WebHook Channel Integrated and marked as an integration test. It’s posted by the account that owns the workflow, through the Workflows app. Real alerts show the monitor, its status, the reason, the time and a link to the incident.
Workflows restricted to your organization
Section titled “Workflows restricted to your organization”A workflow’s trigger step, When a Teams webhook request is received, has a setting called Who can trigger the flow. The template sets it to Anyone: whoever has the URL can post. Some organizations change it to Any user in my tenant or Specific users in my tenant. A tenant is your organization’s Microsoft account directory. With either of those, a request must carry a sign-in token from Microsoft Entra ID (Microsoft’s sign-in service), and DownBad signs in as an app registration you create for it.
You need permission to create app registrations in the Microsoft Entra admin center. Some organizations restrict that to admins.
- Register an app. In the Microsoft Entra admin center, open App registrations › New registration, name it (for example “DownBad alerts”) and register it with the default settings.
- Copy two IDs. The app’s Overview shows the Directory (tenant) ID and the Application (client) ID.
- Add a client secret. Open Certificates & secrets › New client secret, choose an expiry, and copy the secret’s Value right away. Microsoft shows it only once. The Secret ID next to it isn’t the secret.
- For “Specific users in my tenant” only: open Enterprise applications, find the app, copy its Object ID, and add it to the workflow trigger’s Allowed users.
- Fill in DownBad. In the channel form, set Who can trigger the flow to Any user in my tenant, or specific users, and paste the tenant ID, the client ID and the secret’s Value.
- Press Test now.
DownBad gets a new token from Microsoft before alerts, so nothing needs renewing while the client secret is valid. The secret does expire, on the date you chose in step 3. Before then, add a new secret to the app and paste its Value into the channel. DownBad keeps the secret in a masked field and removes it from every test result and the alert history.
If the workflow is set to Anyone, leave DownBad on Anyone too. Microsoft refuses a request to an Anyone workflow that carries a sign-in.
Troubleshooting
Section titled “Troubleshooting”The test says it succeeded, but nothing appears in Teams. A Workflows trigger accepts the request before the flow runs, so a flow that fails later still looks like a success to DownBad. Open the workflow in Teams or Power Automate, check its run history, and look at the failed step. The usual cause is a flow whose owner left the organization or lost access to the channel.
The delivery fails with HTTP 401 or 403.
The sig= value in the URL is missing or was regenerated. Copy the URL again
from the workflow’s trigger.
The delivery fails with DirectApiAuthorizationRequired.
The workflow only lets signed-in callers trigger it, but DownBad is set to
Anyone. Set up an app registration as in
Workflows restricted to your organization,
or set the workflow’s Who can trigger the flow to Anyone.
The delivery fails with MisMatchingOAuthClaims.
The workflow didn’t accept DownBad’s sign-in. Check that the tenant ID is the
one the workflow belongs to. For Specific users in my tenant, check that
the app’s Object ID from Enterprise applications is in Allowed users.
“Microsoft Entra ID refused DownBad’s sign-in”, with AADSTS7000215 or AADSTS7000222. The client secret is wrong or has expired, or the Secret ID was pasted instead of its Value. Add a new client secret to the app and paste its Value.
“Microsoft Entra ID refused DownBad’s sign-in”, with AADSTS700016 or AADSTS90002. The client ID or the tenant ID is wrong. Copy both again from the app’s Overview.
The delivery fails with HTTP 404. The workflow was deleted or turned off. Turn it back on, or create a new one and paste its URL.
“This URL is not a Microsoft Teams webhook address.”
The URL isn’t a Workflows trigger. If it’s a webhook.office.com connector
URL, create a workflow as above instead.
Alerts arrive, but as raw text instead of a card. The channel was set up as Custom, usually because it uses an old connector URL. Replace it with a Workflows URL.
Test now goes through, but no card appears, and the workflow’s run history
says “Attachments is null” or “Property ‘type’ must be ‘AdaptiveCard’”.
The channel is set up as Custom, so DownBad sends its raw event JSON, which the
Teams workflow can’t post. This happens to a channel saved before DownBad
recognized Workflows URLs on environment.api.powerplatform.com that have
extra parts before /workflows/. Edit the channel, choose Microsoft Teams
as the provider, save, and press Test now.
Alerts stopped and the bell says the webhook was switched off. Ten alerts in a row failed. Fix the cause above, then press Test now to switch the channel back on.