MCP server
Templates
A body written once, sent many times.
Templates tools
| Tool | What it does |
|---|---|
| listTemplates | Every template on the active connection, with what each one expects. |
| getTemplate | One template by id or slug, with its published keys and its newest version. |
| createTemplate | Store a body, optionally publishing it so it can be sent immediately. |
| previewTemplate | Render one with values supplied, without sending it. |
| sendWithTemplate | Send a message built from a template, with props filled in. |
Templates belong to the CONNECTION, so these act on whichever mailbox setActiveConnection last named, and a template a colleague wrote is one of them.
A draft cannot be sent. previewTemplate renders one, sendWithTemplate refuses it with template_not_published, and that asymmetry is the point: a body nobody has published is a body nobody has approved.
Props are checked strictly on the way out. An unknown key or a missing required one refuses the send outright rather than mailing a blank where the order number should be, the one failure nothing downstream would report.