Create or update a template
template_upsertSave reusable copy. Pass templateId to update an existing template rather than create a new one. A snippet in the library, nothing more: saving it does not put it in any campaign, which is flow_set, and it is not one of the prebuilt sequence shapes flow_from_template applies. Updating replaces the body, so read it with template_get first if you do not already have the full text.
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": {
"title": "<title>",
"message": "<message>"
},
"name": "template_upsert"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | Yes | Short label. | |
| message | Yes | Body. Supports {{firstName}}-style merge fields. | |
| subject | No | For email and InMail templates. | |
| templateId | No | Template id, from `template_list`. | |
| useCredits | No | InMail templates: allow spending InMail credits. | |
| assingedUsers | No | Restrict to these team member ids. Field name is spelled this way in the schema. |