Skip to main content
Glama

Download Template

download_template
Read-onlyIdempotent

Download the original source file of a stored Carbone template (e.g. the DOCX, XLSX, PPTX, or HTML file that was uploaded). Use this to inspect, edit, or back up a template. Pass a Template ID to download the currently deployed version, or a Version ID to download a specific version. Set sample: true to get the JSON sample dataset stored with the template instead of the template file.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sampleNoIf true, download the JSON SAMPLE DATASET saved with the template (the "sample" array passed to upload_template) instead of the template file, returned as inline JSON text by default, of the form [{ "data": {...}, "complement": {...}, "translations": {...}, "enum": {...} }] (each key optional). Use it to recover the example data a template expects before calling render_document. Errors if the template was uploaded without a sample.
outputPathNoNOT AVAILABLE on this server, which is reached over HTTP: the template file would be written to the server's disk instead of yours, so passing outputPath is rejected. Use asAttachment to receive the bytes.
templateIdYesTemplate ID (64-bit) or Version ID (SHA-256) to download. Template ID — downloads the currently deployed version of the template. Version ID — downloads that exact version regardless of deployment status. Both formats are returned by upload_template and list_templates.
asAttachmentNoIf true, return the template as a downloadable file attachment (base64 resource) instead of inline text/image. Useful in HTTP mode where outputPath is unavailable. Default: false. Ignored when outputPath is set.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • changedInput schema / properties / outputPath / description
      Previous value: -"NOT AVAILABLE on this server, which is reached over HTTP: the template file would be written to the server's disk instead of yours, so passing outputPath is rejected. Use asAttachment to receive the bytes, or returnLink for a one-time download URL."New value: +"NOT AVAILABLE on this server, which is reached over HTTP: the template file would be written to the server's disk instead of yours, so passing outputPath is rejected. Use asAttachment to receive the bytes."
    • changedInput schema / properties / sample / description
      Previous value: -"If true, download the JSON SAMPLE DATASET saved with the template (the \"sample\" array passed to upload_template) instead of the template file. Returns JSON of the form [{ \"data\": {...}, \"complement\": {...}, \"translations\": {...}, \"enum\": {...} }]. Use it to recover the example data a template expects — handy before calling render_document against an unfamiliar template. Errors if the template was uploaded without a sample."New value: +"If true, download the JSON SAMPLE DATASET saved with the template (the \"sample\" array passed to upload_template) instead of the template file, returned as inline JSON text by default, of the form [{ \"data\": {...}, \"complement\": {...}, \"translations\": {...}, \"enum\": {...} }] (each key optional). Use it to recover the example data a template expects before calling render_document. Errors if the template was uploaded without a sample."
  2. Changed2 schema fields changed
    • changedInput schema / properties / outputPath / description
      Previous value: -"Optional local file path to save the template file to (e.g. \"/home/user/template.docx\" or \"~/template.docx\"). When set, the file is written to disk and the tool returns the saved path + size instead of embedding the file inline. Local (stdio) mode only; rejected in HTTP mode."New value: +"NOT AVAILABLE on this server, which is reached over HTTP: the template file would be written to the server's disk instead of yours, so passing outputPath is rejected. Use asAttachment to receive the bytes, or returnLink for a one-time download URL."
    • addedInput schema / properties / sample
      Added value: +{
      +  "description": "If true, download the JSON SAMPLE DATASET saved with the template (the \"sample\" array passed to upload_template) instead of the template file. Returns JSON of the form [{ \"data\": {...}, \"complement\": {...}, \"translations\": {...}, \"enum\": {...} }]. Use it to recover the example data a template expects — handy before calling render_document against an unfamiliar template. Errors if the template was uploaded without a sample.",
      +  "type": "boolean"
      +}
  3. Changed2 schema fields changed
    • addedInput schema / properties / asAttachment
      Added value: +{
      +  "description": "If true, return the template as a downloadable file attachment (base64 resource) instead of inline text/image. Useful in HTTP mode where outputPath is unavailable. Default: false. Ignored when outputPath is set.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / outputPath
      Added value: +{
      +  "description": "Optional local file path to save the template file to (e.g. \"/home/user/template.docx\" or \"~/template.docx\"). When set, the file is written to disk and the tool returns the saved path + size instead of embedding the file inline. Local (stdio) mode only; rejected in HTTP mode.",
      +  "type": "string"
      +}
  4. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint/idempotent/non-destructive, so the safety profile is covered. The description adds real behavioral context beyond that: the deployed-vs-specific-version semantics of the two ID formats, and that sample:true yields the stored JSON dataset instead of the file (with an error if no sample 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?

Three sentences, front-loaded with purpose and then the ID-selection rule and the sample override. No redundancy or filler; each sentence carries a distinct decision-relevant fact.

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

Completeness4/5

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

There is no output schema, but the description covers the meaningful return variants (template file vs inline JSON sample) and the ID resolution rules. It leaves the delivery mechanism (inline vs attachment) to the parameter schema, which is acceptable given that coverage.

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 coverage is 100%, and the schema descriptions for sample, outputPath, and the ID formats are already very detailed. The description's parameter notes (sample:true, Template ID vs Version ID) largely restate what the schema explains, so this is the baseline 3 rather than added meaning.

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 states a specific verb and resource ('Download the original source file of a stored Carbone template') and immediately enumerates the concrete file types (DOCX, XLSX, PPTX, HTML). This clearly distinguishes it from siblings like render_document (which produces output) and inspect_template (which reads metadata) without the agent needing to open either 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?

It gives clear usage contexts ('inspect, edit, or back up a template') and, importantly, explains the two selector modes: a Template ID fetches the currently deployed version while a Version ID fetches an exact version. It does not explicitly state when to prefer this over inspect_template or render_document, so the routing guidance is strong but not exhaustive.

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.