Send Email Skill
Send HTML email notifications to specified recipients via an Azure Logic App HTTP trigger.
Overview
This skill constructs a well-formatted HTML email from user-provided content and posts it to a configured Logic App endpoint for delivery.
Usage
Required Environment Variable
The mailing URL must be set via environment variable:
- •
MAILING_URL: The Azure Logic App HTTP trigger URL for email sending
Required Input from User
The user must provide:
- •Content: The information/message to be sent (any format - text, data, structured content)
- •Recipients: One or more email addresses
- •Title (optional): Subject line for the email
- •Time frame (optional): Relevant date/period context
Payload Schema
The skill constructs and sends a JSON payload:
{
"title": "Email Subject",
"timeFrame": "January 28, 2026",
"body": "<html><body>...</body></html>",
"workflowRunUrl": "https://github.com/org/repo/actions/runs/12345",
"recipients": ["user1@example.com", "user2@example.com"]
}
For the full JSON schema, see references/payload-schema.json.
HTML Body Construction
The skill must transform user-provided content into well-formatted HTML:
- •
Use semantic HTML structure with inline CSS (email clients don't support external stylesheets)
- •
Base template:
html<html> <body style="font-family: Arial, sans-serif; line-height: 1.6; color: #333; max-width: 800px; margin: 0 auto; padding: 20px;"> <div style="background: #f6f8fa; padding: 20px; border-radius: 8px; margin-bottom: 20px;"> <h1 style="color: #0366d6; margin: 0;">{{title}}</h1> <p style="color: #586069; margin: 5px 0 0 0;">{{timeFrame}}</p> </div> <!-- Main content goes here - format based on user input --> {{content}} <hr style="border: none; border-top: 1px solid #e1e4e8; margin: 20px 0;"> <p style="color: #586069; font-size: 12px;"> Generated by <a href="{{workflowRunUrl}}" style="color: #0366d6;">GitHub Actions workflow</a> </p> </body> </html> - •
Content formatting guidelines:
- •Plain text → Wrap in
<p>tags - •Lists → Use
<ul>or<ol>with appropriate styling - •Tables/data → Use
<table>with borders and padding - •Links → Use
<a>tags withcolor: #0366d6 - •Emphasis → Use
<strong>or styled<span>elements - •Code → Use
<code>with monospace font and background
- •Plain text → Wrap in
Workflow
- •Receive content and recipients from user
- •Validate that
MAILING_URLenvironment variable is set - •Validate that recipients list is not empty
- •Construct HTML body from the user-provided content
- •POST the JSON payload to the Logic App endpoint
- •Report success or failure to the user
Example Commands
- •"Send this to user@example.com via email"
- •"Email the following summary to the team"
- •"Mail this information to john@company.com"
- •"Send an email with these details"
Implementation
Use curl or equivalent HTTP client to POST the JSON:
curl -X POST "$MAILING_URL" \
-H "Content-Type: application/json" \
-d '{
"title": "Email Subject",
"timeFrame": "January 28, 2026",
"body": "<html><body>...</body></html>",
"workflowRunUrl": "https://github.com/org/repo/actions/runs/12345",
"recipients": ["user@example.com"]
}'
Response Handling
- •HTTP 2xx: Email sent successfully ✅
- •HTTP 4xx/5xx: Failed to send email ❌
Report the result to the user with the HTTP status code.