Send and receive your first threaded email quickly
Prerequisites
- An API key from your dashboard after signup at getmail.bot
- Your sandbox inbox address, visible in the dashboard after creating an inbox
Send your first email
Pick the interface that fits your stack. All three options call the same underlying endpoint.
- cURL
- Node.js
- Python
curl -X POST https://getmail.bot/v1/messages/send \
-H "Authorization: Bearer $MAILBOT_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"from": "$INBOX_ADDRESS",
"to": ["your@email.com"],
"subject": "Hello from mailbot!",
"body_text": "This is your first email sent through mailbot. Reply to this email and watch the thread appear in your dashboard."
}'
Install the SDK first:
npm install @yopiesuryadi/mailbot-sdk
import { MailBot } from '@yopiesuryadi/mailbot-sdk';
const client = new MailBot({ apiKey: process.env.MAILBOT_API_KEY });
const message = await client.messages.send({
inboxId: 'your-inbox-id',
to: ['your@email.com'],
subject: 'Hello from mailbot!',
bodyText: 'This is your first email sent through mailbot. Reply to this email and watch the thread appear in your dashboard.'
});
console.log('Sent:', message.id);
Install the SDK first:
pip install mailbot-sdk
from mailbot import MailBot
client = MailBot(api_key="your-api-key")
message = client.messages.send(
"your-inbox-id",
to=["your@email.com"],
subject="Hello from mailbot!",
body_text="This is your first email sent through mailbot. Reply to this email and watch the thread appear in your dashboard."
)
print("Sent:", message["id"])
Receive a reply
Reply to the email from your personal inbox. mailbot automatically threads the reply using Message-ID and In-Reply-To headers (RFC 5322). No parsing or manual matching required.
View the thread
Open your dashboard. You will see both messages under one thread with engagement badges (Delivered, Opened, Received).
Next: Connect your webhook
Now that you can send and receive threaded emails, connect a webhook to get real-time notifications when events happen. See the webhook guide for setup instructions and payload reference.