Developer-first SMTP email infrastructure.
MailZeno is a modern transactional email system built for developers who want full SMTP control, strong security, and clean API ergonomics β without vendor lock-in.
Bring your own SMTP. Keep full control.
π Website: https://mailzeno.dev
π Documentation: https://docs.mailzeno.dev
π GitHub: https://github.com/mailzeno/mailzeno
- Bring Your Own SMTP (Gmail, Outlook, Zoho, SES, custom SMTP)
- API-first architecture
- AES-256-GCM encrypted SMTP credentials
- SMTP connection pooling
- Automatic retry for transient failures (SMTP 4xx + network errors)
- Exponential backoff with jitter
- Rate limit handling (429 + Retry-After support)
- Idempotency key support
- Structured error responses
- Request ID propagation
- React email rendering support
- Fully typed TypeScript SDK
- ESM + CommonJS support
- Node.js 18+ compatible
Most email APIs lock you into their infrastructure.
MailZeno is different:
- You use your own SMTP provider
- You control deliverability
- You control sender reputation
- You avoid vendor lock-in
- You keep portability
If you already have SMTP access (SES, Zoho, Gmail, Outlook, custom), MailZeno gives you a modern API layer on top.
| Package | Description |
|---|---|
@mailzeno/core |
Low-level SMTP engine with pooling + retry |
@mailzeno/client |
Official JavaScript SDK for MailZeno API |
Install the SDK:
npm install @mailzeno/client- Create an account at https://mailzeno.dev
- Add your SMTP credentials
- Generate an API key
- Install the SDK:
npm install @mailzeno/clientThen send your first email:
import { MailZeno } from "@mailzeno/client"
const mailzeno = new MailZeno("mz_api_your_api_key")
await mailzeno.emails.send({
smtpId: "your_smtp_id",
from: "you@example.com",
to: "recipient@example.com",
subject: "Hello from MailZeno",
html: "<h1>Hello world</h1>"
})Send emails using stored templates with dynamic variables.
await mailzeno.emails.send({
smtpId: "smtp_id",
from: "you@example.com",
to: "user@example.com",
templateKey: "welcome_email",
variables: {
name: "Harsh",
company: "MailZeno"
}
})Templates support {{variable}} placeholders.
Example template:
<h1>Welcome {{name}}</h1>
<p>Thanks for joining {{company}}</p>Prevent duplicate sends during retries or network failures:
await mailzeno.emails.send(
{
smtpId: "smtp_id",
from: "you@example.com",
to: "user@example.com",
subject: "Payment receipt",
html: "<h1>Thank you</h1>"
},
{
idempotencyKey: "unique-request-id-123"
}
)The SDK automatically retries:
- HTTP 5xx responses
- 429 rate limit responses
- Network errors
- Timeouts
Retries use exponential backoff with jitter.
const mailzeno = new MailZeno("api_key", {
baseUrl: "https://api.mailzeno.dev",
retries: 2,
retryDelay: 500,
timeout: 10000
})try {
await mailzeno.emails.send(payload)
} catch (error) {
console.error(error)
}Errors include:
status(HTTP status)code(API error code)requestId(x-request-id for debugging)
MailZeno is built with security-first principles:
- SMTP credentials encrypted using AES-256-GCM
- Strict TLS validation
- Per-user SMTP isolation
- API keys are stored as SHA-256 hashes
- Structured error handling
- Controlled retry strategy
- Rate limiting enforcement
MailZeno follows a layered design:
@mailzeno/coreβ SMTP engine (pooling + retry)- Service layer β Business logic
- API layer β Authentication + rate limiting
@mailzeno/clientβ Developer SDK
This separation keeps the SMTP engine reusable while enforcing SaaS policies at the API layer.
mailzeno/
ββ packages/
β ββ core/
β ββ client/
ββ apps/
β ββ web/
Version: 0.x (Public Beta)
MailZeno is under active development.
Breaking changes may occur before v1 stable.
Contributions and feedback are welcome.
Please open an issue before submitting major changes.
The open-source packages under /packages are licensed under the MIT License.
The SaaS application code under /apps/web is part of the MailZeno hosted service and is not intended for commercial redistribution.