Skip to main content
Glama

Create Template

create_template
Destructive

Save an existing Draft as a reusable template. Mirrors dashboard POST /api/documents/drafts/{id}/save-as-template (API-key twin POST /api/v1/documents/drafts/{id}/save-as-template). There is no blank-template flow — start from a Draft. Returns template_id and role names. The Draft itself is unchanged. Requires Authorization: Bearer zs_....

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": {
      "document_id": "<document_id>",
      "name": "<name>"
    },
    "name": "create_template"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYes
document_idYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations declare a non-read-only, non-idempotent, destructive write; the description adds genuinely useful context beyond them — the source Draft is left unchanged, an API key is required, and the result carries template_id plus role names. It omits that repeated calls are not idempotent (duplicate templates may be created), which would have fully closed the loop on the annotations.

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

Conciseness4/5

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

Four short sentences, front-loaded with the core action and the key constraint. The endpoint-mirroring parenthetical is the one segment that does not directly help an agent invoke the tool, but it is brief.

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 two-parameter write tool with an output schema, the description covers the source object, the precondition, auth, and side effects on the Draft; return values need not be explained since the output schema exists. Nothing essential for a correct call is missing.

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

Parameters3/5

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

Schema description coverage is 0%, so the description must carry the load. It clarifies that document_id refers to an existing Draft (not an arbitrary document), which is real added meaning, but says nothing about what 'name' denotes or its constraints.

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?

States a specific verb and resource ('Save an existing Draft as a reusable template') and immediately clarifies scope with 'There is no blank-template flow — start from a Draft.' An agent can distinguish this from list_templates or send_from_template without opening any schema.

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

Usage Guidelines4/5

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

The 'no blank-template flow — start from a Draft' line is a real precondition that tells the agent when this tool is applicable and implicitly when it isn't. It does not name a sibling to use for listing or creating the prerequisite Draft, but the guidance is clear enough to act on.

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.

Resources