Skip to main content
Glama

analyze_template

Fetch a MoEngage email template by ID and version, parse its HTML, and return a structured content map with metadata, images, and text nodes for editing or localization.

Instructions

Fetch existing template from MoEngage, parse HTML, return structured content map (NO HTML).

Both parameters are required — together they pin the exact template revision to fetch. Never omit version: without it the wrong revision may be fetched and cached, causing localize_template to patch the wrong HTML.

Provides ~8:1 compression vs raw HTML. Agent sees structured text nodes instead of HTML.

Returns:

  • template_meta: name, id, version, subject, sender, preview_text

  • content_map: ordered list of {id, context, text, localizable, jinja_expressions, link?}

  • images: list of {id, context, url, alt_text, link_url}

  • structure_summary: one-line description

  • html_bytes: size metric

The HTML is cached in-memory (15-min TTL) for subsequent localize_template / patch_template_text calls.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
external_template_idYes
versionYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

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

With no annotations, the description fully covers behavioral traits: caching behavior (15-min TTL), compression ratio (~8:1), that HTML is not returned but cached, and the detailed return structure. No contradictions.

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?

Well-structured with bullet points for returns and a clear warning. The description is moderately concise; a bit of redundancy ('Both parameters are required') could be trimmed, but overall effective.

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?

Given the complexity and presence of an output schema, the description is complete. It explains the tool's role among siblings, return values, and caching behavior, leaving no major gaps for an agent to misunderstand.

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?

The input schema has 2 parameters with 0% description coverage, but the description adds substantial meaning by explaining that together they pin the exact revision and emphasizing the importance of version. This compensates well, though it could explicitly define external_template_id.

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 tool fetches a template, parses HTML, and returns a structured content map. It uses specific verb+resource ('Fetch existing template from MoEngage, parse HTML, return structured content map') and distinguishes from sibling tools like localize_template and patch_template_text.

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?

Explicitly states both parameters are required and warns against omitting version, explaining the consequence of fetching the wrong revision. Provides context for caching (15-min TTL) and relation to subsequent tools, offering clear when-to-use guidance.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/poddubnyoleg/moengage_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server