Integrations
Three ways to connect Mailazy to the rest of your stack — the right one depends on whether you're sending data in, listening to events out, or both.
Pick your path
| Need | Use |
|---|---|
| Send transactional or marketing email from your app | REST API or SMTP relay |
| Trigger lifecycle automations from product events | POST /api/v1/events |
| Update your database when emails deliver / bounce / get clicked | Webhooks |
| Pipe contact data in from your CRM / e-commerce | Contact sync via API or pre-built connectors |
| Wire Mailazy up to a tool we don't have a connector for | Zapier / Make / n8n |
| Resell or embed Mailazy under your own brand | White-label program |
Webhooks
Subscribe one HTTPS endpoint per product; fan out by event type on your side.
Subscribe
POST /api/v1/webhooks
{
"url": "https://app.acme.com/mailazy/webhook",
"events": ["delivered", "opened", "clicked", "bounced", "complained", "unsubscribed"],
"secret": "auto"
} If you pass "secret": "auto" Mailazy generates a random secret and returns it once. You can also supply your own. Store it server-side; you'll need it to verify signatures.
Event payload
POST https://app.acme.com/mailazy/webhook
Content-Type: application/json
X-Mailazy-Signature: t=1747008000,v1=<sha256-hmac>
X-Mailazy-Event: delivered
{
"event": "delivered",
"messageId": "msg_01HXAB...",
"to": "alice@example.com",
"templateSlug": "password-reset",
"templateVersion": 4,
"timestamp": "2026-05-12T10:00:00Z",
"data": { "smtpResponse": "250 OK" }
} Verify the signature
HMAC-SHA256 over "<timestamp>.<raw-body>" using your webhook secret. Reject if v1 doesn't match or timestamp is older than 5 minutes (replay protection).
// Node.js example
import crypto from 'node:crypto';
function verify(rawBody, header, secret) {
const [t, v1] = header.split(',').map(p => p.split('=')[1]);
const expected = crypto.createHmac('sha256', secret)
.update(`${t}.${rawBody}`)
.digest('hex');
return crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(v1));
} Delivery semantics
- Retries with exponential backoff for 24 hours on any non-2xx response.
- At-least-once — your handler must be idempotent. Use
messageId + eventas the dedup key. - Events arrive out of order on rare occasions (e.g.
openedbeforedeliveredif your handler is slow). Code defensively.
Contact sync
Three patterns, increasing in sophistication:
Manual CSV import
For one-off or low-frequency syncs. Drag a CSV into the dashboard, or POST it to /api/v1/contacts/import. Supports skip-or-update on duplicates. See Contacts & lists.
Direct API writes
Have your app POST to /api/v1/contacts whenever a user signs up, upgrades, or changes plan. The metadata field is a free-form JSON blob — store anything you'll want to segment on (plan, company, signupSource).
Pre-built connectors
Direct connectors for the most common sources. One-click install in Settings → Integrations:
- E-commerce: Shopify, WooCommerce, BigCommerce, Magento
- CRM: HubSpot, Pipedrive, Salesforce
- Subscriptions / billing: Stripe, Paddle, Chargebee
- CDP / events: Segment, RudderStack
- Forms / lead capture: Typeform, Tally, Webflow Forms
Each connector maps the source's contact identity (Stripe customer, Shopify customer, HubSpot contact) to a Mailazy contact, keeps metadata in sync, and (for event sources like Segment) fires /events so your automations trigger automatically.
See the full integrations directory for the 80+ connectors available.
Zapier / Make / n8n
If your source isn't covered by a direct connector, every Mailazy capability is callable from no-code:
- Zapier — search for "Mailazy"; we expose triggers (delivered, opened, clicked, bounced) and actions (send email, create contact, add to list).
- Make (Integromat) — same trigger/action surface; modules under "Mailazy."
- n8n — community node available; or use the generic HTTP Request node against any
/api/v1/*endpoint.
Embedding Mailazy in your product
If you're building a SaaS that needs email infrastructure under your brand — and you want your customers to never see "Mailazy" — the White-label / OEM program is the right fit. Your customers get a co-branded portal at mail.yourdomain.com; sender headers, DNS records and support all read as you. Revenue share applies on top.
API examples in popular stacks
Node.js (with the official SDK)
import { Mailazy } from '@mailazy/node';
const m = new Mailazy({ key: process.env.MAILAZY_KEY, secret: process.env.MAILAZY_SECRET });
await m.send({
to: 'alice@example.com',
templateSlug: 'welcome',
variables: { name: 'Alice' },
}); Python
from mailazy import Mailazy
m = Mailazy(key=..., secret=...)
m.send(to='alice@example.com', template_slug='welcome', variables={'name': 'Alice'}) curl
curl -X POST https://api.mailazy.com/api/v1/send \
-H "X-API-Key: $MAILAZY_KEY" -H "X-API-Secret: $MAILAZY_SECRET" \
-H "Content-Type: application/json" \
-d '{"to":"alice@example.com","templateSlug":"welcome","variables":{"name":"Alice"}}'