Manage temporary inboxes over HTTP. Base URL: .... TinyMail only receives email; it does not send it.
/api/all-domains/ requires the X-Domain-Token header.
Get a paginated list of a user's emails. List responses contain metadata only (no body / html_body).
| Parameter | Location | Description |
|---|---|---|
domain | path | Email domain, e.g. example.com |
user | path | Username, e.g. testuser |
page | query, optional | Page number (default 1) |
limit | query, optional | Items per page (default 20, maximum 100) |
curl -X GET "https://BASE_URL/api/email/example.com/testuser/?page=1&limit=20"
{
"emails": [
{
"id": 123,
"subject": "Welcome",
"sender": "[email protected]",
"date": "2026-09-30T10:30:00.000Z",
"has_attachments": false,
"size": 1234
}
],
"total": 5,
"page": 1,
"limit": 20,
"has_more": false
}
Get the full details of an email.
curl -X GET "https://BASE_URL/api/email/example.com/testuser/123"
Delete a specific email.
curl -X DELETE "https://BASE_URL/api/email/example.com/testuser/123"
{ "status": "deleted" }
Add a new domain or update an existing domain's online status. The domain must have an MX record pointing to the system's hostname to be accepted (status added, is_online: true).
curl -X POST "https://BASE_URL/api/add-domain/newdomain.com"
// Successfully added
{ "status": "added", "domain": "newdomain.com", "is_online": true }
// Existing domain: update its status
{ "status": "updated", "domain": "newdomain.com", "is_online": false }
All online domains (private, token required):
curl -X GET "https://BASE_URL/api/all-domains/" \
-H "X-Domain-Token: YOUR_TOKEN"
Random online domains (public):
curl -X GET "https://BASE_URL/api/random-domains/?limit=10"
{ "domains": ["domain1.com", "domain2.com"], "total": 2 }
Check whether a domain has a valid MX record pointing to the system.
curl -X GET "https://BASE_URL/api/check-mx/example.com"
{ "result": "online" } // or "offline"
| Code | Meaning |
|---|---|
| 200 | Success |
| 400 | Invalid request (e.g. malformed domain/email) |
| 401 | Missing or invalid token for a private endpoint |
| 404 | Email not found |
| 429 | Rate limit exceeded |
{ "detail": "Domain not found" }
[email protected]