Get Last Unread Message
Fetch the most recent unread email message for a specified email address.
Endpoint: POST /api/mail/last-unread-message
Fetch the most recent unread email message for a specified email address.
Request Headers
Authorization: Bearer your_api_token_here
Content-Type: application/json
Request Body
{
"email": "ms3cgwumw0@mloqq.com"
}
Response Example
{
"message": {
"id": 3,
"subject": "New Message",
"from": "sender@example.com",
"body": "This is an unread message.",
"html": "This is an unread message.",
"created_at": "2025-06-01T18:49:00Z"
}
}
Usage Examples
JavaScript (fetch)
fetch('https://mailblinker.com/api/mail/last-unread-message', {
method: 'POST',
headers: {
'Authorization': 'Bearer 5720c4dbb4601183486a9259a8e8f7b9b6fef2dc61f34ee901516995710e49aa',
'Content-Type': 'application/json'
},
body: JSON.stringify({ email: 'ms3cgwumw0@mloqq.com' })
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));
Python (requests)
import requests
import sys
sys.stdout.reconfigure(encoding='utf-8')
url = 'https://mailblinker.com/api/mail/last-unread-message'
headers = {
'Authorization': 'Bearer 5720c4dbb4601183486a9259a8e8f7b9b6fef2dc61f34ee901516995710e49aa',
'Content-Type': 'application/json'
}
data = {
'email': 'ms3cgwumw0@mloqq.com'
}
response = requests.post(url, headers=headers, json=data)
print(response.json())
cURL
curl -X POST https://mailblinker.com/api/mail/last-unread-message \
-H "Authorization: Bearer your_api_token_here" \
-H "Content-Type: application/json" \
-d '{"email": "ms3cgwumw0@mloqq.com"}'