
Microsoft 365 TeamsIncomingWebhook
CertifiedSend message via Teams incoming webhook
Microsoft 365 TeamsIncomingWebhook
Send message via Teams incoming webhook
Posts a JSON payload to a Microsoft Teams Incoming Webhook; ideal for errors notifications. No Graph permission required, only the webhook URL.
type: io.kestra.plugin.microsoft365.teams.TeamsIncomingWebhookExamples
Send a Microsoft Teams notification on a failed flow execution
id: unreliable_flow
namespace: company.team
tasks:
- id: fail
type: io.kestra.plugin.scripts.shell.Commands
runner: PROCESS
commands:
- exit 1
errors:
- id: alert_on_failure
type: io.kestra.plugin.microsoft365.teams.TeamsIncomingWebhook
url: "{{ secret('TEAMS_WEBHOOK') }}" # format: https://microsoft.webhook.office.com/webhook/xyz
payload: |
{
"type": "message",
"attachments": [
{
"contentType": "application/vnd.microsoft.card.adaptive",
"content": {
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"type": "AdaptiveCard",
"version": "1.4",
"body": [
{
"type": "TextBlock",
"size": "Large",
"weight": "Bolder",
"text": "Kestra Execution Notification"
},
{
"type": "TextBlock",
"text": "Execution ID: `{{ execution.id }}`",
"wrap": true
},
{
"type": "TextBlock",
"text": "Flow: `{{ flow.id }}` in namespace `{{ flow.namespace }}`",
"wrap": true
},
{
"type": "TextBlock",
"text": "Status: **{{ execution.state }}**",
"wrap": true
}
],
"actions": [
{
"type": "Action.OpenUrl",
"title": "View Execution",
"url": "{{ kestra.url }}/ui/executions/{{ flow.namespace }}/{{ flow.id }}/{{ execution.id }}"
}
]
}
}
]
}
Send a Microsoft Teams notification message.
id: send_notification
namespace: company.team
tasks:
- id: send_teams_notification
type: io.kestra.plugin.microsoft365.teams.TeamsIncomingWebhook
url: "https://microsoft.webhook.office.com/webhookb2/XXXXXXXXXX"
payload: |
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"themeColor": "0076D7",
"summary": "Notification message",
"sections": [
{
"activityTitle": "Rolling Workflow started",
"activitySubtitle": "Workflow Notification",
"markdown": true
}
],
"potentialAction": [
{
"@type": "OpenUri",
"name": "Rolling Workflow",
"targets": [
{
"os": "default",
"uri": "{{ vars.systemUrl }}"
}
]
}
]
}
Properties
url *string
1Teams incoming webhook URL
assets
Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.
io.kestra.core.models.assets.AssetsDeclaration
IGNOREFAILWARNAsset failure behavior
Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.
Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.
The assets consumed as inputs.
io.kestra.core.models.assets.AssetIdentifier
1The assets produced as outputs.
io.kestra.plugin.ee.assets.Dataset
1150{}1150io.kestra.plugin.ee.assets.File
1150{}1150io.kestra.plugin.ee.assets.Table
1150{}1150io.kestra.plugin.ee.assets.VM
1150{}1150io.kestra.core.models.assets.External
1150{}1150io.kestra.core.models.assets.Custom
11501Custom asset type
{}1150options
HTTP client options
Optional timeouts, charset, headers, and limits for Teams webhook calls
io.kestra.plugin.microsoft365.teams.AbstractTeamsConnection-RequestOptions
The time allowed to establish a connection to the server before failing.
PT0SIdle pool timeout
Time an idle connection stays in the pool before closing
UTF-8Default charset
java.nio.charset.Charset
HTTP headers
HTTP headers to include in the request
10485760Max response size
Maximum response content length in bytes
PT5MThe time allowed for a read connection to remain idle before closing it.
PT10SThe maximum time allowed for reading data from the server before failing.
payload string
Teams message payload
Raw JSON payload for the webhook (Adaptive Card or MessageCard)