RESTful JSON API for Inbox, Message retrieval, and Public Email Receiving
Base URL
https://mailegzz.com/api/v1
The GET /api/v1/inbox endpoint retrieves a list of email messages
stored in a mailbox.
Each message contains metadata such as message ID, sender address,
subject, timestamp, and a cleaned text field extracted from
the email body for easy OTP detection.
This endpoint supports pagination using the page and
page_size parameters.
| Name | Type | Required | Description |
|---|---|---|---|
| mailbox | string | Target mailbox email address (example: test@mailegzz.site) | |
| page | integer | - | Page number for pagination (default: 1) |
| page_size | integer | - | Number of messages per page (default: 50, max: 100) |
curl "https://mailegzz.com/api/v1/inbox?mailbox=test@mailegzz.com"
{
"address": "test@mailegzz.com",
"page": 1,
"page_size": 50,
"count": 2,
"messages": [
{
"id": "12",
"mailbox": "test@mailegzz.com",
"from": "noreply@github.com",
"subject": "Verify your email",
"date": "2026-01-10T07:32:11Z",
"size": 1342,
"text": "Your verification code is 834291"
}
]
}
The GET /api/v1/message/{id} endpoint retrieves the full details
of a specific email message.
Unlike the /api/v1/inbox endpoint, this response includes
the full email body and a cleaned text field that is optimized
for OTP extraction and automation.
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer |
Message ID obtained from
/api/v1/inbox
|
|
| mailbox | string | Target mailbox email address (example: test@mailegzz.com) |
curl "https://mailegzz.com/api/v1/message/12?mailbox=test@mailegzz.com"
{
"success": true,
"data": {
"id": 12,
"mailbox": "test@mailegzz.com",
"from": "noreply@github.com",
"subject": "Verify your email",
"date": "2026-01-10 07:32:11",
"text": "Your verification code is 834291",
"body": "Your verification code is 834291
"
}
}
The DELETE /api/v1/message/{id} endpoint permanently removes
a specific email message from a mailbox.
Once deleted, the message cannot be recovered.
This operation only affects the selected message ID and does not
delete other messages in the mailbox.
| Name | Type | Required | Description |
|---|---|---|---|
| id | integer |
Message ID obtained from
/api/v1/inbox
|
|
| mailbox | string | Target mailbox email address (example: test@mailegzz.com) |
curl -X DELETE \ "https://mailegzz.com/api/v1/message/12?mailbox=test@mailegzz.com"
{
"success": true,
"message": "Message deleted successfully",
"data": {
"id": 12,
"mailbox": "test@mailegzz.com"
}
}
Public endpoint used to deliver incoming emails into a MailEgzz mailbox.
Commonly used by bots, webhooks, or external services.
Supports full HTML content and optional message identifiers.
| Name | Type | Required | Description |
|---|---|---|---|
| to | string | Target mailbox address | |
| from | string | Sender email address | |
| subject | string | - | Email subject |
| body | string | - | HTML email body |
| msg_id | string | - | Optional unique message ID |
curl -X POST https://mailegzz.com/api/v1/receive \
-H "Content-Type: application/json" \
-d '{
"to": "test@mailegzz.com",
"from": "bot@service.com",
"subject": "Hello API",
"body": "Hello MailEgzz"
}'