Custom Domain Setup
Why use a custom domain
By default, sandbox inboxes use the mailbot.id domain. Custom domains let you send from your own domain (e.g., support@yourcompany.com), which improves deliverability, builds recipient trust, and keeps your brand consistent.
Custom domains are available on the Builder plan and above.
Add your domain
Domains are managed through the API or an SDK that exposes domain operations. The current MCP tool set does not include domain management. The dashboard covers plan, usage and API keys only, so there is no Domains screen to open.
curl -X POST https://getmail.bot/v1/domains \
-H "Authorization: Bearer mb_xxx" \
-H "Content-Type: application/json" \
-d '{"domain": "yourcompany.com"}'
The response carries a dns_records array with the three records to publish, one each named SPF, DKIM and
DMARC. GET /v1/domains/:id returns the same array again at any time.
Configure DNS records
You need to add three TXT records to your domain's DNS. These records authenticate your emails and protect your domain from spoofing.
SPF record
Tells receiving mail servers that mailbot is authorized to send email on behalf of your domain.
| Field | Value |
|---|---|
| Type | TXT |
| Host | yourcompany.com (or @) |
| Value | Copy the SPF entry from dns_records in the API response |
DKIM record
Adds a cryptographic signature to every email, proving it was not altered in transit.
| Field | Value |
|---|---|
| Type | TXT |
| Host | default._domainkey.yourcompany.com |
| Value | v=DKIM1; k=rsa; p=... — copy the DKIM entry from dns_records |
DMARC record
Defines how receiving servers should handle emails that fail SPF or DKIM checks.
| Field | Value |
|---|---|
| Type | TXT |
| Host | _dmarc.yourcompany.com |
| Value | Copy the DMARC entry from dns_records |
Note: use the exact values from the dns_records array that POST /v1/domains returns, and that GET /v1/domains/:id returns again at any time. DKIM is generated per domain, so it is never the same for two domains.
DNS provider instructions
Cloudflare
- Log in to your Cloudflare dashboard
- Select your domain
- Go to DNS > Records
- Click "Add record" for each of the three records above
- Set Type to TXT, enter the Name (Host) and Content (Value)
- Save each record. TXT records do not have a proxy setting.
Namecheap
- Log in to Namecheap and go to Domain List
- Click "Manage" next to your domain
- Go to Advanced DNS
- Click "Add New Record" for each TXT record
- Set Type to TXT Record, Host, and Value as shown above
- Save all changes
GoDaddy
- Log in to GoDaddy and go to My Products
- Click DNS next to your domain
- Click "Add" under Records
- Set Type to TXT, Name, and Value for each record
- Set TTL to 1 hour
- Save
Route53
- Open the Route53 console in AWS
- Select your hosted zone
- Click "Create record" for each TXT record
- Set Record type to TXT
- Enter the Record name and Value
- Use the default TTL (300 seconds)
- Click "Create records"
Other providers
Add TXT records using the type, host and value fields from the dns_records array. Most DNS providers have similar interfaces. If you are unsure, check your provider's documentation for "adding TXT records."
Verify your domain
After publishing all three records, ask mailbot to check them:
curl -X POST https://getmail.bot/v1/domains/{domain_id}/verify \
-H "Authorization: Bearer mb_xxx"
The response reports each record separately as spf_verified, dkim_verified and dmarc_verified, plus the
overall status, a last_check_at timestamp and a next_step sentence. A record that has not been checked
yet reads as not verified rather than as a pass.
DNS propagation can take up to 48 hours, but usually completes within 15 minutes. If verification fails, double check that you published the exact values from dns_records and that there are no trailing spaces.
Start sending from your domain
Once the domain is verified, create an inbox on it. There is no endpoint that moves an existing inbox to a different domain, so make a new inbox and send from that one:
curl -X POST https://getmail.bot/v1/inboxes \
-H "Authorization: Bearer mb_xxx" \
-H "Content-Type: application/json" \
-d '{"username": "support", "domain": "yourcompany.com"}'
Use the address field from the response as the sending address. Emails from this inbox go out on your own
domain.