SMTP Email Sender for Openclaw

A versatile skill for AI agents to send emails and configure SMTP services like QQ, 126, and Aliyun via environment variables.

seanmwx
v1.0.0
Mar 30, 2026
0
785
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install email-agent

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install email-agent using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is SMTP Email Sender?

The email_sender skill empowers your AI agent to handle outgoing mail communication using standard SMTP protocols. It provides built-in support for popular providers like 126, QQ, Sina, and Aliyun, while offering a custom mode for any other mail server. By integrating this into Openclaw Skills, developers can scaffold reusable email senders and automate notifications directly from their coding environment.

This skill is designed to bridge the gap between AI-generated logic and real-world communication. Whether you need to send a simple test notification or build a robust mailing subsystem, this component provides the necessary configuration presets and scripts to ensure reliable delivery through secure SMTP channels.

SMTP Email Sender Use Cases

  • Sending one-off test emails to verify SMTP connectivity.
  • Scaffolding reusable SMTP logic for Python-based applications.
  • Configuring environment variables for secure mailbox access using authorization codes.
  • Debugging complex SMTP handshake issues involving SSL or STARTTLS settings.

How SMTP Email Sender Works

  1. The skill attempts to load configuration from a .env file at the repository root, falling back to an internal configuration block if the file is missing.
  2. It identifies provider-specific defaults such as host, port, and SSL settings based on the EMAIL_PROVIDER environment variable.
  3. The agent collects recipient details, subject lines, and body content from the user request.
  4. A validation check is performed via a dry-run command to ensure the configuration and secrets are valid without actually sending an email.
  5. The scripts/send_email.py script executes the final transmission once the parameters are confirmed by the user.

SMTP Email Sender Setup

To get started with this skill within Openclaw Skills, create a .env file with your credentials:

EMAIL_PROVIDER=qq
SMTP_PASSWORD=your_smtp_authorization_code
[email protected]

Ensure your Python environment is ready and run the validation script to test the connection:

python scripts/send_email.py --to-email [email protected] --email-subject "Test" --email-body "Hello" --dry-run

SMTP Email Sender Data Schema & Taxonomy

The skill relies on specific environment variables and CLI arguments to manage the mailing lifecycle:

Variable Description Default
EMAIL_PROVIDER Preset provider (126, qq, sina, aliyun, custom) 126
SMTP_PASSWORD App-specific authorization code or mailbox password Required
SMTP_USE_SSL Enable SMTPS (Port 465) or STARTTLS (Port 587) true
FROM_EMAIL The authenticated sender address Required
SMTP_TIMEOUT Connection timeout in seconds 30

SMTP Email Sender Advanced Features

  • Dry-run mode to validate credentials without consuming quota or sending accidental messages.
  • Support for custom SMTP servers allowing integration with private corporate mail relays.
  • Automatic port and SSL/TLS mapping based on common provider presets to reduce manual configuration.
  • Flexible environment file loading using the --env-file flag for managing multiple mail profiles.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*