asksteps: create an email or SMS template
asksteps_create_message_templateCreates an email or SMS template. Requires "automation:write". Nothing is sent: a new template is used by no workflow and no process, so it has no effect until a person attaches it to a process transition, an email block or a workflow in the studio. Block types are limited to heading, text, button, image (absolute https source, no upload), divider, spacer and booking-details — a block of type "html" is rejected, and sender, reply-to and sender domain are not settable. Shortcodes like {{contact.firstname}} are checked; call asksteps_get_automation_catalog for block fields, shortcodes and limits. Answers with the issues (path, code, shortcode) when the content is wrong, and with the template as saved — after cleaning, for example a dangerous link target removed.
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": {
"spec": "<spec>"
},
"name": "asksteps_create_message_template"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| spec | Yes | The template: name, channel, category, defaultLocale and content. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Path of the editor in the asksteps studio. | |
| note | Yes | One or two sentences for the user. | |
| spec | No | The template as saved — after cleaning (for example a dangerous link target removed). Check it against what you meant to send. | |
| issues | No | The problems found, with path and code (and the shortcode when it is one). Empty unless status is "invalid". | |
| status | Yes | Outcome. One of: "created" (not used by any workflow or process yet, so nothing is sent), "updated", "invalid" (the issues say exactly what to fix; nothing was saved), "stale" (the template was changed since you read it: read it again and redo the change), "not_editable" (it contains an html block), "confirmation_required" (a workflow or process in use sends from it and the account has not authorised an agent to change it: NOTHING was written, give the user the url), "limit_reached" (the account holds the maximum number of templates), "rate_limited" (too many changes to live objects in the last minute), "not_found", "not_connected", "error". Authorisation can also refuse before the tool runs: "plan_required" (the account's plan does not include agent access), "not_enabled" (the account owner has not switched agent access on), "permission_denied" (the connected user's role lacks the permission; the note names it), "mandate_required" (the owner has not granted a mandate for this). The note then says what the user has to do. | |
| inLiveUse | No | Whether an active workflow or an active or paused process sends from this template. | |
| updatedAt | No | Pass this value as expected_updated_at to the next change. | |
| templateId | No | The id of the template. |