Mailinator api documentation
Mailinator is a popular email testing and development tool that provides a free, public email address that can be used to test and verify email addresses, as well as to receive and parse incoming emails. Here is the API documentation for Mailinator:
API Endpoints
- Create a new email account:
POST /api/v1/email
- Request Body:
{"email": "[email protected]"}
- Response:
{"email": "[email protected]", "password": "password"}
- Request Body:
- Get email account information:
GET /api/v1/email/{email}
- Path Parameter:
email
(e.g. "[email protected]") - Response:
{"email": "[email protected]", "password": "password", "inbox": [...], "sent": [...]}
(inbox and sent items are arrays of email objects)
- Path Parameter:
- Send an email:
POST /api/v1/email/{email}/send
- Path Parameter:
email
(e.g. "[email protected]") - Request Body:
{"to": "[email protected]", "subject": "Test email", "body": "This is a test email"}
(optional) - Response:
{"message": "Email sent successfully"}
- Path Parameter:
- Get email content:
GET /api/v1/email/{email}/inbox/{inboxId}
- Path Parameters:
email
(e.g. "[email protected]"),inboxId
(e.g. "1234567890") - Response:
{"email": {"subject": "Test email", "body": "This is a test email"}}
- Path Parameters:
- Delete an email account:
DELETE /api/v1/email/{email}
- Path Parameter:
email
(e.g. "[email protected]") - Response:
{"message": "Email account deleted successfully"}
- Path Parameter:
API Parameters
email
: The email address to create, retrieve, or delete.inboxId
: The ID of the email in the inbox.to
: The recipient's email address (for sending an email).subject
: The subject of the email (for sending an email).body
: The body of the email (for sending an email).
API Response Formats
- JSON: The default response format is JSON.
API Rate Limits
- Mailinator has a rate limit of 100 requests per minute per IP address.
API Authentication
- Mailinator does not require authentication to use the API.
API Error Handling
- Mailinator returns HTTP error codes (e.g. 404, 500) for errors.
Please note that Mailinator's API is subject to change, and it's always a good idea to check the official documentation for the most up-to-date information.