get_batch_mail
A batch with its status (draft → paid → generating → submitted → in_progress → completed | partially_completed | failed; cancelled), recipient summary, pricing (credits_charged, refunded_cents), field_kit, tracking (QR pieces scanned and confirmed), links and the first 50 pieces, each with its qr (code, link, your ref, scans, first_scanned_at, confirmed_at, expires_at; sandbox verify pieces also carry short_code). Poll it after confirm; batch.submitted / batch.completed also arrive on the agent's webhook. Every piece: page with offset and limit, or ask for the pieces scanned, confirmed (verify: the address verified) or not_scanned with qr; REST: GET /v1/batch-mail/{id}/pieces.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"batch_id": "<batch_id>"
},
"name": "get_batch_mail"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| qr | No | Only the pieces whose QR code was scanned, confirmed (verify: the address verified) or not scanned yet. Batches with QR codes only. | |
| limit | No | Pieces per page, default 50. | |
| offset | No | Pieces to skip, default 0. | |
| batch_id | Yes | The batch's id (UUID). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes | batch, pieces (in mailing order; the first 50 unless qr, limit or offset say otherwise) and pagination. |