Prepare a batch of Certified Mail letters
prepare_certified_mail_batchCreates an UNSENT draft of 2 or more separately addressed U.S. letters for USPS Certified Mail (the same notice to several tenants, separate demands to several companies) and returns one review_url. The person signs in there, reads every letter, sees each price and the total, and approves once; each letter is charged only when the printer accepts it. PREPARING IS NOT SENDING: nothing is printed, mailed or charged by this call. Pass either template_text with {{blanks}} filled per mailing from merge_fields and the recipient (recipient_name, city, ...), or letter_text per mailing, not both. Put addresses in recipient_address_block and sender_address_block, not in the letter. Unfilled blanks, incomplete addresses and duplicates are named per mailing in missing_for_mailing; fix them and call again with a new client_request_id. One service per batch. Not for marketing, advertising or unsolicited mail, and not for one letter (use prepare_certified_letter). If the person has a spreadsheet you cannot read, use source "web_import" and give them import_url.
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": {
"source": "<source>"
},
"name": "prepare_certified_mail_batch"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| source | Yes | direct: the letters and addresses are in this call. web_import: the person uploads a list on piloxa.com. | |
| mailings | No | ||
| batch_name | No | ||
| template_text | No | One letter for every mailing, from the salutation to the closing, with {{blanks}}. | |
| signature_name | No | ||
| default_service | No | Defaults to CERTIFIED_ERR (with electronic return receipt). | |
| template_subject | No | ||
| client_request_id | No | Reuse on a retry of the same request: the same draft comes back. | |
| sender_address_block | No | The return address as written, printed on every envelope. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| quote | No | ||
| counts | No | ||
| mailed | Yes | ||
| charged | Yes | ||
| prepared | Yes | ||
| expires_at | No | ||
| import_url | No | ||
| review_url | No | ||
| batch_token | No | ||
| missing_for_mailing | No | ||
| requires_human_approval | No |