Change how a letter travels
set_mail_serviceChange how a previewed letter travels without previewing it again: standard (ordinary first-class mail), certified (USPS Certified Mail) or certified_return_receipt (Certified Mail with an electronic return receipt). Only when the person asks to add or remove certified mail: it costs more and is paid with Pay & Send, never a letter pack or a gift letter, and a postcard or a gift letter cannot be certified. Give the draftId from the preview and mailService; the page does not change, its price does.
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": {
"draftId": "<draftId>",
"mailService": "<mailService>"
},
"name": "set_mail_service"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| draftId | Yes | The draftId from a letter preview | |
| mailService | Yes | How the letter travels: standard (ordinary first-class mail), certified (USPS Certified Mail) or certified_return_receipt (Certified Mail with an electronic return receipt). Certified mail costs more and is paid with Pay & Send: no letter pack and no gift letter pays for it. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pages | No | Present only for a letter of more than one page: the pages it prints on, both sides of the paper. No letter pack or gift letter pays for it; it is paid with Pay & Send. | |
| draftId | Yes | ||
| message | Yes | ||
| canSendNow | Yes | Whether the balance or a gift letter pays for the letter as it is now: certified mail is paid with Pay & Send, so it is false for it | |
| mailService | No | Present only when the letter now goes as certified mail: which service. Absent: an ordinary letter | |
| deliveryClass | No | With the terms, for a letter that is certified mail or while certified mail is offered, and for a sent letter: how it is delivered, as a new preview would say it. A card draws it on its Delivery line | |
| contentVersion | No | The version of this mail as it is now: send it with the send, so what is mailed is what the person saw | |
| sendEligibility | Yes | ||
| reasonCannotSend | No | ||
| deliveryDisclaimer | No | With it, the words that qualify the delivery | |
| contentVersionBefore | No | The version of this mail the change was made to: for the preview card, which takes contentVersion only when this is the version it shows |