Email Delivery
Automatically send branded license key emails to customers upon key generation.
Overview
Keymint's Email Delivery Engine automatically sends professional, branded license key emails to your customers the moment a license key is generated — via the dashboard or the API. No integration required.
Key Features
- Zero-config managed delivery — Keymint handles delivery infrastructure (powered by Amazon SES), reputation, and abuse prevention.
- Custom SMTP — Bring your own mail server for full control over sender identity and routing.
- HTML templates — Design rich email templates with variable interpolation and a live preview editor.
- Plan-based access — Features are gated by subscription tier (Sender identity, HTML customization, and SMTP).
How It Works
When a license key is generated (either via the dashboard or the REST API), Keymint compiles your HTML template with the customer and license data, then delivers the email through your chosen provider.
Delivery Providers
| Provider | Configuration | Use Case |
|---|---|---|
| Keymint Managed | Zero config. Sends from no-reply@keymint.dev | Fastest setup. Ideal for teams that don't need custom branding. |
| Custom SMTP | SMTP host, port, credentials | Full control over sender email, domain, and routing. |
Email Variables
The following variables are available in your subject line and HTML template:
| Variable | Description |
|---|---|
{{customer_name}} | The customer's full name |
{{customer_email}} | The customer's email address |
{{product_name}} | The product the license is associated with |
{{license_key}} | The generated license key string |
{{expiry_date}} | The license expiration date (if applicable) |
{{max_activations}} | The maximum number of device activations |
Configuration
Email delivery settings are configured per workspace under Workspace Settings → Email Delivery.
1. Enable Delivery
Toggle on the global Enable Email Delivery switch to activate automated sending.
2. Choose Provider
Select Keymint Managed for zero configuration, or Custom SMTP to route through your own infrastructure.
3. SMTP Configuration (Custom SMTP Only)
| Field | Required | Description |
|---|---|---|
| SMTP Host | Yes | Your SMTP server hostname |
| Port | Yes | Typically 465 (SSL) or 587 (TLS) |
| Secure Connection | Recommended | Enable SSL/TLS |
| Username | Yes | SMTP authentication username |
| Password | Yes | SMTP authentication password |
Use the Test Connection button to verify your SMTP credentials before saving.
4. Sender Identity
| Field | Plan Requirement | Description |
|---|---|---|
| Sender Name | Standard | Display name. Defaults to "Keymint Delivery". |
| Sender Email | Custom SMTP only | From address. Keymint Managed uses no-reply@keymint.dev. |
| Subject Line | Standard | Email subject. Supports {{product_name}} variable. |
5. HTML Template
Available on Standard plan and above. Use the tabbed editor to write custom HTML with live preview using mock data.
<div style="font-family: Arial, sans-serif; max-width: 600px; margin: auto;">
<h2>Your License Key for {{product_name}}</h2>
<p>Hi {{customer_name}},</p>
<p>Here is your license key: <strong>{{license_key}}</strong></p>
<p>Expires: {{expiry_date}}</p>
</div>6. Delivery Triggers
Toggle whether emails are sent when keys are generated:
- Via API — Triggered when a key is created through the REST API.
- Via Dashboard — Triggered when a key is created from the dashboard UI.
Abuse Prevention
When using the Keymint Managed provider, emails pass through automated abuse prevention:
- Brand Blocklist — Sender names and subject lines containing major brand trademarks or phishing-related keywords are flagged.
- Mandatory Footer — All Keymint-managed emails include an abuse reporting footer for recipients.
Template Security
Custom HTML templates are sanitized before compilation:
- Sanitizer — Templates are parsed and sanitized with DOMPurify (not regex): scripts, iframes, event handlers, SVG/SMIL payloads, and
javascript:/data:URI schemes (including entity-encoded variants) are removed. Templates containing<style>blocks may lose styling. - Variable escaping — Template variables (
{{customer_name}},{{product_name}}, etc.) are HTML-escaped before interpolation, so user-supplied values are always rendered as plain text. - Preview sandbox — The dashboard preview iframes run with
sandbox="", so even a malformed template cannot execute scripts in the dashboard session. - Custom SMTP — SMTP hosts are validated against the SSRF guard (public HTTPS hosts only; private/loopback/internal addresses and DNS-rebinding are rejected,
localhostallowed in development only).
These measures protect the shared sending domain's deliverability reputation for all customers.
Plan Limits
| Feature | Free | Startup | Standard |
|---|---|---|---|
| Email Delivery | ✅ | ✅ | ✅ |
| Custom SMTP | ❌ | ❌ | ✅ |
| HTML Template Customization | ❌ | ❌ | ✅ |
| Sender Identity Customization | ❌ | ❌ | ✅ |
Email delivery is unlimited on all plans. The natural limit is the license count — you need a license key to trigger each email. There's no separate daily cap.
Testing
SMTP Connection Test
Verify your SMTP credentials are valid before enabling delivery. The test opens a connection to your server, attempts authentication, and reports success or specific failure details.
Test Email
Send a sample email to your configured sender email address using the current template and settings. This confirms end-to-end delivery without creating a real license key.
API Integration
Email delivery is triggered automatically when license keys are generated via the REST API — no special flag needed. Delivery behavior is controlled by the Delivery Triggers settings in your workspace:
- Via API — Enabled by default. Toggle off to prevent email sending for API-generated keys.
- Via Dashboard — Enabled by default. Toggle off to prevent email sending for dashboard-generated keys.
The standard Create License Key endpoint requires no additional parameters. Email delivery follows your workspace configuration automatically.