npx skills add nocoo/microsoft-teams-send-as-workflowREADME
Microsoft Teams Send As Workflow
Send messages and Adaptive Cards to Microsoft Teams channels via Incoming Webhook.
Features
- 📨 Simple text messages - Quick notifications and alerts
- 🎴 Adaptive Cards - Rich formatted cards with facts, images, and buttons
- 🔧 Raw payloads - Full control over custom message structures
- ⚠️ Helpful error handling - Clear guidance for setup issues
Prerequisites
You need a Webhook URL from Teams. To create one:
- In Teams, go to the target channel
- Open Workflows app (search from Apps or click three dots below input)
- Find template: "Post to a channel when a webhook request is received"
- Name the workflow (e.g., "CLI Notification Bot")
- Select target Team and Channel
- Copy the generated HTTP POST URL
Quick Start
python3 scripts/send_teams.py <WEBHOOK_URL> --text "Hello Teams!"
Message Types
📝 Simple Text Message
python3 scripts/send_teams.py <WEBHOOK_URL> -t "🚀 Deployment completed successfully"
🎴 Adaptive Card
Inline JSON:
python3 scripts/send_teams.py <WEBHOOK_URL> -c '{
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"type": "AdaptiveCard",
"version": "1.4",
"body": [
{
"type": "TextBlock",
"text": "Build Report",
"weight": "Bolder",
"size": "Medium"
}
]
}'
From JSON file:
python3 scripts/send_teams.py <WEBHOOK_URL> -c card.json
🔧 Raw Payload
python3 scripts/send_teams.py <WEBHOOK_URL> -r '{"type": "message", "text": "Custom"}'
Script Reference
scripts/send_teams.py
| Argument | Description |
|---|---|
webhook_url | Teams Incoming Webhook URL (required positional) |
-t, --text TEXT | Send simple text message |
-c, --card CARD | Send Adaptive Card (JSON string or .json file) |
-r, --raw RAW | Send raw custom payload (JSON string or .json file) |
-v, --verbose | Enable verbose output |
Troubleshooting
⚠️ Workflow Suspended
If you receive errors about a "suspended" workflow:
- Open Power Automate (or your org's URL)
- Go to My flows / Workflows
- Find your workflow → Resume / Activate / Turn on
- Retry sending your message
License
MIT License - see LICENSE for details.
Publisher
Statistics
Stars0
Forks0
Open Issues0
LicenseMIT License
CreatedJan 23, 2026