motorical_get_logs
Search and paginate SMTP send logs for one Motor Block to trace delivery outcomes and failures. Filter by SMTP code class or exact code, recipient query, date range, and current outcome.
Instructions
Search send logs for one Motor Block. Paginate with cursor. Recipient addresses are masked unless the token carries logs.pii, which OAuth tokens never do. To find failures by cause use smtpCode: the stored code is whatever the receiving server reported, in either form (basic like 550 or enhanced like 5.7.1), so a class such as 5xx (all permanent failures), 4xx (all temporary ones) or a group such as 5.7.x (policy and reputation blocks) is usually what you want; an exact code matches only that exact form. Requires OAuth scope: read:analytics (see motorical_whoami for what it allows).
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "motorical_get_logs"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | ISO date or datetime, inclusive | |
| from | No | ISO date or datetime, inclusive | |
| limit | No | Page size | |
| query | No | Space-separated key:value terms, all of which must match: recipient:<exact address>, domain:<exact domain>, code:<an SMTP code filter in the same forms as smtpCode, no spaces>, id:<message uuid>. Text without a key: prefix is ignored; there is no subject search. | |
| cursor | No | Opaque cursor from a previous page | |
| smtpCode | No | Filter by SMTP code, as the receiving server reported it (basic like 550 or enhanced like 5.7.1, both appear in the same logs). Forms: exact 550 or 5.7.1; a class 5xx or 4xx (5.x.x also works); a group 5.7.x; or a comma-separated list of up to 10, no spaces, e.g. 5.7.x,4xx. An invalid value is a 400 that says what is accepted | |
| includePII | No | Unmask recipient addresses. Requires the logs.pii scope, which is never granted to OAuth tokens — the API returns 403. | |
| motorBlockId | No | Required when the authorization covers more than one Motor Block | |
| currentOutcome | No | Filter to one delivery outcome, e.g. delivered, bounced, deferred |