Everything you need to integrate with DeveloperLabs.email services
Sign up for an account and get your API key from the dashboard.
curl -X POST https://api.developerlabs.email/v1/auth \
-H "Content-Type: application/json" \
-d '{"email":"[email protected]","password":"yourpassword"}'
Use this simple API call to send an email:
const response = await fetch('https://api.developerlabs.email/v1/send', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer YOUR_API_KEY'
},
body: JSON.stringify({
to: '[email protected]',
from: '[email protected]',
subject: 'Hello from DeveloperLabs',
text: 'This is a test email sent via API'
})
});
Complete reference for our REST API endpoints including authentication, sending emails, and tracking.
View API DocsDetailed guides for setting up SMTP with various languages and frameworks.
View SMTP DocsGuide to processing inbound emails with our parsing API and webhooks.
View Parsing DocsOfficial libraries for popular programming languages to simplify integration.
View SDKsAll API requests require an API key sent in the Authorization header.
Authorization: Bearer YOUR_API_KEY
Get your API key from the dashboard after signing up.
Send emails via our REST API with this endpoint:
POST https://api.developerlabs.email/v1/send
Parameter | Type | Required | Description |
---|---|---|---|
to |
String/Array | Yes | Recipient email address(es) |
from |
String | Yes | Sender email address |
subject |
String | Yes | Email subject line |
text |
String | No* | Plain text version (required if no html) |
html |
String | No* | HTML version (required if no text) |
fetch('https://api.developerlabs.email/v1/send', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': 'Bearer YOUR_API_KEY'
},
body: JSON.stringify({
to: '[email protected]',
from: '[email protected]',
subject: 'Your Order Confirmation',
html: '<h1>Thank you for your order!</h1><p>Your order #12345 has been received.</p>'
})
})
.then(response => response.json())
.then(data => console.log(data));
Receive real-time notifications about email events by configuring webhooks in your dashboard.
Event | Description |
---|---|
delivered |
Email successfully delivered to recipient's mail server |
opened |
Recipient opened the email (if tracking enabled) |
clicked |
Recipient clicked a link (if tracking enabled) |
bounced |
Email could not be delivered |
{
"event": "delivered",
"message_id": "abc123",
"timestamp": 1689876543,
"recipient": "[email protected]",
"metadata": {
"custom_id": "order_123"
}
}
Use these SMTP settings to send emails through our servers:
Server | smtp.developerlabs.email |
---|---|
Port | 587 (STARTTLS) or 465 (SSL/TLS) |
Username | Your API key |
Password | Any non-empty string (ignored) |
const nodemailer = require('nodemailer');
let transporter = nodemailer.createTransport({
host: 'smtp.developerlabs.email',
port: 587,
secure: false, // true for 465, false for other ports
auth: {
user: 'YOUR_API_KEY',
pass: 'any-string' // ignored, but required
}
});
let info = await transporter.sendMail({
from: '"Sender" <[email protected]>',
to: '[email protected]',
subject: 'Hello from Node.js',
text: 'Plain text version',
html: '<b>HTML version</b>'
});
import smtplib
from email.mime.text import MIMEText
msg = MIMEText('Email body here')
msg['Subject'] = 'Python SMTP Test'
msg['From'] = '[email protected]'
msg['To'] = '[email protected]'
with smtplib.SMTP('smtp.developerlabs.email', 587) as server:
server.starttls()
server.login('YOUR_API_KEY', 'any-string') # password ignored
server.send_message(msg)
Official Node.js library for the DeveloperLabs.email API
npm install @developerlabs/email
const { DeveloperLabsEmail } = require('@developerlabs/email');
const client = new DeveloperLabsEmail('YOUR_API_KEY');
client.send({
to: '[email protected]',
from: '[email protected]',
subject: 'Welcome!',
text: 'Thanks for signing up'
})
.then(response => console.log(response))
.catch(error => console.error(error));
Official Python client for the DeveloperLabs.email API
pip install developerlabs-email
from developerlabs_email import EmailClient
client = EmailClient(api_key="YOUR_API_KEY")
response = client.send_email(
to="[email protected]",
from_email="[email protected]",
subject="Welcome!",
text="Thanks for signing up"
)
print(response)