Send your first email
Create a key, verify a domain and send a message. Most teams are sending within an hour; the only slow step is waiting for DNS.
Before you start
You need a MigoSMTP account and a domain you control, such as example.com. Sending from a subdomain like mail.example.com keeps your marketing and product mail separate from your main domain, and is a good default.
1. Create an API key
In the dashboard open API keys and create a key with send permission. Give each application its own key so you can revoke one without touching the others. Store it as a secret, never in source control.
export MIGOSMTP_KEY="YOUR_API_KEY"
2. Verify a domain
Add your sending domain in the dashboard and publish the DNS records it shows: SPF, DKIM and, recommended, a DMARC policy. DNS changes can take time to spread, so wait until the domain status reads Verified before sending.
3. Send a message
Call the send endpoint with a from address on your verified domain. Replace the example addresses with your own.
curl -X POST https://api.migosmtp.com/v1/send \
-H "Authorization: Bearer $MIGOSMTP_KEY" \
-H "Content-Type: application/json" \
-d '{"from":"[email protected]","to":"[email protected]","subject":"Hello","text":"It works."}'4. Check the result
The response includes a message id. Use it to look up the message and its events in the dashboard, or receive them in your own system through webhooks.
Prefer SMTP?
If your application already speaks SMTP, point it at the SMTP host shown in your dashboard instead. No code change is needed beyond the connection settings. See the SMTP integration guide.
Before you go live
Check these first: send from a verified domain, publish a DMARC record, handle 429 responses with a backoff, subscribe to bounce and complaint webhooks so you stop mailing addresses that fail, and keep API keys out of your repository.
Where to next
Read the API reference for every endpoint, set up webhooks for delivery events, and review error codes and rate limits so your integration handles failure well.