Mailbox insights
GET
/api/v1/mailbox/insightsPatterns in the mailbox over a window (30d, 90d default, 180d or 365d): what needs attention, how fast replies go out, when mail arrives, who you write to most, and clutter. Each block is left out when there is nothing to say. Results are cached; refresh=true recomputes.
Errors
| Status | When |
|---|---|
401 |
No token, or the session expired or was signed out. Sign in again with POST /mailbox-auth/login. |
403 |
The account has a temporary password: until POST /security/password succeeds, every other call answers this with error_code: password_change_required. |
503 |
Insights are busy on this server; try again shortly. |
Parameters
| Name | In | Type | Description |
|---|---|---|---|
window | query | string | |
refresh | query | boolean |
Request
GET
/api/v1/mailbox/insightscurl -X GET 'https://courier.mailyte.com/api/v1/mailbox/insights' \
-H 'Authorization: Bearer MAILBOX_TOKEN'const response = await fetch('https://courier.mailyte.com/api/v1/mailbox/insights', {
method: 'GET',
headers: {
Authorization: 'Bearer MAILBOX_TOKEN',
},
});
const { data } = await response.json();import requests
response = requests.get(
"https://courier.mailyte.com/api/v1/mailbox/insights",
headers={"Authorization": "Bearer MAILBOX_TOKEN"},
)
data = response.json()["data"]<?php
$response = Http::withToken('MAILBOX_TOKEN')
->get('https://courier.mailyte.com/api/v1/mailbox/insights');
$data = $response->json('data');require "net/http"
require "json"
uri = URI("https://courier.mailyte.com/api/v1/mailbox/insights")
request = Net::HTTP::Get.new(uri)
request["Authorization"] = "Bearer MAILBOX_TOKEN"
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |http| http.request(request) }Response
Successful Response
dataobjectwindowobjectfromstringtostringmessages_consideredintegercachedboolean
attentionobjectUnanswered and unread mail worth a look.
response_timeobjectHow long replies take, both ways.
rhythmobjectBusiest hours and days, in the holder's time zone.
relationshipsobjectTop correspondents.
hygieneobjectNewsletters and clutter.
200
application/json{
"type": "success",
"msg": "Insights retrieved successfully",
"data": {
"window": {
"from": "2026-07-13T00:00:00+00:00",
"to": "2026-10-11T12:00:00+00:00",
"messages_considered": 1696,
"cached": true
},
"relationships": {
"top_correspondents": [
{
"email": "tunde@example.com",
"name": "Tunde Bello",
"messages": 64
}
]
}
}
}Returned inside the standard envelope.
Errors
| Status | When |
|---|---|
401 | No token, or the session expired or was signed out. Sign in again with `POST /mailbox-auth/login`. |
403 | The account has a temporary password: until `POST /security/password` succeeds, every other call answers this with `error_code: password_change_required`. |
422 | Validation Error |
503 | Insights are busy on this server; try again shortly. |
Every status, with what causes it and what to do, is on the error reference.