Modern enterprise incident response relies on rapid, context-rich alerting. When a third-party monitoring system (like Datadog, PagerDuty, or a custom internal API) detects an anomaly, simply firing off an email is insufficient. Engineering teams operate in Microsoft Teams, and they require structured, actionable alerts delivered directly to their channel. While developers could write custom Node.js middleware to ingest webhooks and format the output, Microsoft Azure Logic Apps provides a robust, serverless orchestration engine. By configuring a Logic App to parse incoming JSON webhook payloads, administrators can dynamically generate and trigger rich Microsoft Teams Adaptive Cards, transforming static alerts into interactive triage dashboards without writing a single line of code.
The Architecture of the Integration
Azure Logic Apps operate on a trigger-and-action paradigm.
- The Trigger: An HTTP Request trigger exposes a public URL. When your monitoring system fires a webhook, it POSTs a JSON payload to this URL.
- The Parsing Action: The Logic App intercepts the JSON and uses a predefined schema to parse the raw data into strongly-typed dynamic variables.
- The Output Action: The Logic App utilizes the native Microsoft Teams connector to format those variables into an Adaptive Card payload and injects it directly into a specific Teams channel.
Configuring the Webhook Receiver
To begin, navigate to the Azure Portal and create a new Logic App (Consumption).
Open the Logic App Designer and select the When a HTTP request is received trigger.
To parse the incoming data, you must provide a JSON schema. If your monitoring tool sends a payload like this:
{
"alert_id": "CRIT-992",
"severity": "High",
"server": "db-prod-01",
"message": "CPU utilization exceeded 95% for 10 minutes."
}
You can paste this exact JSON into the Use sample payload to generate schema tool within the trigger. The Logic App will automatically generate the corresponding JSON schema. Once you save the Logic App, Azure will generate a unique, authenticated HTTP POST URL. You configure your monitoring tool to send its webhooks to this endpoint.
Designing the Adaptive Card Payload
Adaptive Cards are a JSON-based UI framework used across Microsoft 365. Rather than sending a plain text message, an Adaptive Card allows you to render bold headers, columns, color-coded severity blocks, and interactive action buttons directly in the Teams chat window.
You design the visual layout using the official Adaptive Cards Designer web portal (adaptivecards.io). Once the visual layout is finalized, you copy the generated JSON template.
{
"type": "AdaptiveCard",
"body": [
{
"type": "TextBlock",
"size": "Medium",
"weight": "Bolder",
"text": "Incident Alert: @{triggerBody()?['alert_id']}"
},
{
"type": "FactSet",
"facts": [
{
"title": "Severity:",
"value": "@{triggerBody()?['severity']}"
},
{
"title": "Server:",
"value": "@{triggerBody()?['server']}"
}
]
},
{
"type": "TextBlock",
"text": "@{triggerBody()?['message']}",
"wrap": true
}
],
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"version": "1.4"
}
Notice the syntax @{triggerBody()?['server']}. This is the Logic App expression language. It instructs the Logic App to dynamically inject the parsed variables from the HTTP trigger directly into the card’s JSON structure.
Triggering the Teams Message
Return to the Logic App Designer.
- Add a new step and search for the Microsoft Teams connector.
- Select the Post card in a chat or channel action.
- Authenticate with an account that has permission to post to the target team.
- Set Post as to “Flow bot”.
- Set Post in to “Channel”, and select your specific Team and Incident Response channel.
- In the Adaptive Card input field, paste the JSON template you designed. The Logic App designer will automatically recognize the dynamic variables and link them to the HTTP trigger outputs.
Save the Logic App. The next time your monitoring system detects a critical failure and POSTs a webhook to the Azure endpoint, the Logic App will autonomously parse the payload, construct the complex JSON UI structure, and instantly render a high-visibility, interactive Adaptive Card in the Microsoft Teams channel, drastically reducing Time-to-Triage (TTT) for the engineering squad.