hosting
GET /v1/sites/{siteId}/mail-log
Messages the site's mail sent or received.
Authentication
Send an API key as a bearer token. This endpoint does not state a specific permission in the specification, so give your key the least it needs and check the response rather than assuming.
This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.
Try it
Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.
curl -X GET https://api.zinndigital.com/v1/sites/{siteId}/mail-log \
-H "Authorization: Bearer zdk_live_…"Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console
Details
Paginated by the vendor, so `has_more` is its own answer rather than arithmetic on `total`. An empty page for a site with no mail is a normal state, not a failure. ⛔ Requires **`sites.panel_access`**, not `sites.view` — unlike every other read on this panel. Sender, recipient and subject lines are the customer's correspondence, the same class of data as their files and their database, and `sites.panel_access` is the key that already gates both. A principal holding only `sites.view` gets a 404.
Parameters
| Name | Type | Required | What it is |
|---|---|---|---|
siteId (path) | Uuid | Yes | Site ID (UUIDv7). |
period (query) | string<hourly, daily, weekly, monthly> | No | How far back to look, in the vendor's own four buckets. |
direction (query) | string<incoming, outgoing> | No | ⛔ One direction at a time — the vendor has no "both", so a client showing a combined view must make two calls and say which is which. |
search (query) | string | No | Free-text match on sender, recipient or subject. |
page (query) | integer | No | — |
page_size (query) | integer | No | — |
Response
| Name | Type | Required | What it is |
|---|---|---|---|
data | SiteMailLogEntry[] | Yes | — |
total | integer | Yes | — |
page | integer | Yes | — |
page_size | integer | Yes | — |
has_more | boolean | Yes | The vendor's own flag, not arithmetic on `total`. |
period | string | Yes | — |
direction | string | Yes | — |
periods | string[] | Yes | — |
directions | string[] | Yes | — |
Errors this endpoint can return
401 · 403 · 404 · 422 · 429 · 503