Skip to main content
Glama

Vorlage mit Werten füllen

template_apply_with_merge_fields
Read-only

Füllt die Platzhalter einer gespeicherten Vorlage mit deinen Werten und gibt Betreff und Inhalt oder ein vollständiges Anschreiben-Formular-Paket zurück. Bei einer Blockvorlage kommen statt content die fertigen blocks zurück. Briefkopf und Marke werden getrennt bei Vorschau oder Versand gewählt. Eine eigenständige Formularvorlage mit sendable:false und releaseBlocker:null braucht coverTemplateId aus einer direkt adressierbaren Briefvorlage; eine gespeicherte Verknüpfung bleibt nur der optionale Standard. Übergib danach templateId, templateVersionId, coverTemplateId, coverTemplateVersionId und die ursprünglichen templateMergeValues unverändert an order_send. Gib Paketabschnitte so weiter, wie sie zurückkommen. Fehlt eine Pflichtangabe, antwortet das Tool mit MERGE_FIELDS_MISSING und nennt die fehlenden oder ungültigen Felder. EN: Fills a saved template and returns subject and content or a complete cover-form package. For a block template the finished blocks are returned instead of content. Letterhead and brand are selected separately at preview or send time. A standalone form template with sendable:false and releaseBlocker:null needs coverTemplateId from a directly addressable letter template; a saved link is only the optional default. Then pass templateId, templateVersionId, coverTemplateId, coverTemplateVersionId and the original templateMergeValues unchanged to order_send. Pass package sections on exactly as they come back. If a required value is missing, the tool returns MERGE_FIELDS_MISSING and lists the missing or invalid fields.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
languageNoSprache fuer die Formatierung von Betrag und Datum. Standard de. EN: Language for money and date formatting. Defaults to de.
reasoningNo
templateIdYesId der Vorlage aus template_list / template_get. EN: The template ID from template_list / template_get.
mergeValuesNoZuordnung von Platzhalter-Namen zu Werten, z. B. { "provider": "Telekom" }. Der Typ des Merge-Feldes gilt: date erwartet ISO JJJJ-MM-TT, currency ganzzahlige Cent, number eine Zahl, rows eine Liste von Zeilenobjekten mit den Spaltenschluesseln der gebundenen Tabelle. EN: Mapping of placeholder names to values, e.g. { "provider": "Telekom" }. The merge field's type applies: date expects ISO YYYY-MM-DD, currency integer cents, number a number, rows a list of row objects keyed by the bound table's column keys.
coverTemplateIdNoOptionales Anschreiben für eine eigenständige Formularvorlage. Ohne gespeicherte Verknüpfung ist es zum Anwenden erforderlich. EN: Optional cover letter for a standalone form template. Required when applying a form that has no saved link.
mandantennummerNoOptionaler Mandantenbezug (nur Kontext). EN: Optional client reference (context only).
templateVersionIdNoExakte freigegebene oder ersetzte Vorlagenversion. Ohne Angabe wird die aktuell freigegebene Version verwendet. EN: Exact released or superseded template version. If omitted, the currently released version is used.
coverTemplateVersionIdNoOptional: exakte freigegebene Version des gewählten Anschreibens. EN: Optional exact released version of the selected cover letter.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the readOnlyHint and destructiveHint annotations, the description discloses error behavior (MERGE_FIELDS_MISSING with missing/invalid fields), output shape differences (blocks vs content vs form package), and the rule that letterhead and brand are not set here. No contradiction with annotations.

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

Conciseness3/5

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

The content is front-loaded and logically ordered, but every section is repeated in German and English, so the description is about twice as long as necessary. The redundant bilingual duplication keeps it from earning a higher score for conciseness.

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?

With no output schema, the description compensates by naming the three output variants (content, blocks, cover-form package) and the error response. It also covers the post-processing handoff to order_send. Exact response field names/types are absent, but the essential behavioral context is present.

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 high, so baseline is 3; the description adds workflow meaning by requiring the same templateId/templateVersionId/coverTemplateId/coverTemplateVersionId and mergeValues to be passed unchanged to order_send. It also clarifies the conditional requirement on coverTemplateId. Minor naming mismatch ('templateMergeValues' vs schema's 'mergeValues') prevents a 5.

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?

Description opens with a concrete verb and resource: filling a saved template's placeholders and returning Betreff/Inhalt or a complete cover-form package. It also specifies block templates return blocks instead of content, which distinguishes this as the template-application step from siblings such as template_get/template_preview and order_send.

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 clearly frames when the tool is used: before order_send, and instructs passing the resulting IDs and mergeValues unchanged. It also explains when coverTemplateId is required for standalone form templates, but it does not explicitly list alternatives or when-not-to-use conditions.

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.