Skip to main content
Glama

Ray notifications

Create template

create_template

Create a template (POST /templates; write scope). channelKind is permanent and must match the channels you'll send through (list_channels templateKind). It is saved as an unpublished draft unless publish: true; sending by templateId needs a published version (publish_template). Names are unique per workspace including archived templates: a collision returns 409, so unarchive_template the old one instead. Returns { id, requiredParams }. Designed (drag-and-drop) email templates can only be made in the dashboard.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesTemplate name, unique per workspace (archived templates included).
folderNoOptional folder path for organisation, e.g. "billing".
contentYesChannel-shaped template body; the shape is fixed by `channelKind`: email_html → `{ subject, bodyHtml, bodyText }`; fcm_basic → `{ title, body, imageUrl?, data?: { [key]: string } }`; slack_text → `{ text }`; discord_text → `{ content }` (max 2000 chars); telegram_text → `{ text, disableLinkPreview? }`; sms_text → `{ text }` (plain text, max 1600; long text is split into several billed SMS — on sendsms_mn into parts of 159 plain-Latin / 69 Cyrillic chars); webhook_json → `{ title, body, data?: { [key]: string } }`. Use `{{name}}` placeholders and `{{#items}}…{{/items}}` sections; the required params are derived from them automatically.
publishNotrue = publish this version immediately so sends by templateId use it. Default false (saved as draft).
logTitleYesShort title shown in the in-app feed and delivery logs, e.g. "Invoice {{number}} is due". Placeholders allowed.
channelKindYesWhich channel family the template renders for. Must match the `templateKind` of the channels you will send through (list_channels). Can't be changed after creation.
logDescriptionYesOne-line description for the in-app feed and delivery logs. Placeholders allowed.
paramOverridesNoPer-param metadata keyed by param name: `{ optional?: boolean, description?: string }`. Mark a placeholder optional so sends may omit it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / content / description
      Previous value: -"Channel-shaped template body; the shape is fixed by `channelKind`: email_html → `{ subject, bodyHtml, bodyText }`; fcm_basic → `{ title, body, imageUrl?, data?: { [key]: string } }`; slack_text → `{ text }`; discord_text → `{ content }` (max 2000 chars); telegram_text → `{ text, disableLinkPreview? }`; sms_text → `{ text }` (plain text, max 1600; sendsms_mn channels only send up to 159 chars after rendering); webhook_json → `{ title, body, data?: { [key]: string } }`. Use `{{name}}` placeholders and `{{#items}}…{{/items}}` sections; the required params are derived from them automatically."New value: +"Channel-shaped template body; the shape is fixed by `channelKind`: email_html → `{ subject, bodyHtml, bodyText }`; fcm_basic → `{ title, body, imageUrl?, data?: { [key]: string } }`; slack_text → `{ text }`; discord_text → `{ content }` (max 2000 chars); telegram_text → `{ text, disableLinkPreview? }`; sms_text → `{ text }` (plain text, max 1600; long text is split into several billed SMS — on sendsms_mn into parts of 159 plain-Latin / 69 Cyrillic chars); webhook_json → `{ title, body, data?: { [key]: string } }`. Use `{{name}}` placeholders and `{{#items}}…{{/items}}` sections; the required params are derived from them automatically."
  2. Changed2 schema fields changed
    • changedInput schema / properties / channelKind / enum
      Previous value: -[
      -  "email_html",
      -  "fcm_basic",
      -  "slack_text",
      -  "discord_text",
      -  "telegram_text",
      -  "webhook_json"
      -]New value: +[
      +  "email_html",
      +  "fcm_basic",
      +  "slack_text",
      +  "discord_text",
      +  "telegram_text",
      +  "sms_text",
      +  "webhook_json"
      +]
    • changedInput schema / properties / content / description
      Previous value: -"Channel-shaped template body; the shape is fixed by `channelKind`: email_html → `{ subject, bodyHtml, bodyText }`; fcm_basic → `{ title, body, imageUrl?, data?: { [key]: string } }`; slack_text → `{ text }`; discord_text → `{ content }` (max 2000 chars); telegram_text → `{ text, disableLinkPreview? }`; webhook_json → `{ title, body, data?: { [key]: string } }`. Use `{{name}}` placeholders and `{{#items}}…{{/items}}` sections; the required params are derived from them automatically."New value: +"Channel-shaped template body; the shape is fixed by `channelKind`: email_html → `{ subject, bodyHtml, bodyText }`; fcm_basic → `{ title, body, imageUrl?, data?: { [key]: string } }`; slack_text → `{ text }`; discord_text → `{ content }` (max 2000 chars); telegram_text → `{ text, disableLinkPreview? }`; sms_text → `{ text }` (plain text, max 1600; sendsms_mn channels only send up to 159 chars after rendering); webhook_json → `{ title, body, data?: { [key]: string } }`. Use `{{name}}` placeholders and `{{#items}}…{{/items}}` sections; the required params are derived from them automatically."
  3. First observed

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only mark this as a non-read-only, non-idempotent mutation. The description adds important behavior: channelKind is permanent, templates save as drafts unless publish is true, collisions return 409, and the return value is { id, requiredParams }. It also names the required list_channels verification. No contradiction with annotations exists.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four dense sentences, each earning its place: the core creation call, the permanent channelKind constraint, the draft/publish behavior, the unique-name collision handling, the return shape, and the dashboard limitation. No filler or redundant restatement of the title.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex tool with 8 parameters, nested objects, and no output schema, the description covers the key behavioral gaps: endpoint, write scope, return shape, uniqueness rules, publish semantics, and a notable platform limitation. The input schema already provides rich per-parameter documentation, so nothing critical is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3. The description adds cross-parameter context not in the schema, such as channelKind needing to match list_channels templateKind and publish controlling unpublished-vs-published state. It also explains that requiredParams are auto-derived from placeholders, which helps agents understand the response despite the absence of an output schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action: create a template via POST /templates with write scope. It also distinguishes this tool from related operations like publish_template and update_template_draft by describing the draft/publish lifecycle.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly gives when-to-use guidance and alternatives: publishing is needed before sending by templateId (publish_template), archived name collisions should be resolved via unarchive_template, and drag-and-drop email templates must use the dashboard. This is strong routing advice beyond the schema.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.