Skip to main content
Glama
rtc-calculadora-mcp

rtc-calculadora-mcp

by tmoreiradev

validar_xml

Validate fiscal XML documents or tax-group XML against the official XSD, returning a valid status or the exact error location by line and column.

Instructions

Valida um XML contra o XSD oficial. subtipo="grupo" valida so os grupos de tributacao (como os de gerar_xml_grupo); "nota" valida o documento inteiro. Devolve "valido" ou o erro com linha e coluna.

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": {
      "xml": "<xml>"
    },
    "name": "validar_xml"
  }
}

Input Schema

NameRequiredDescriptionDefault
xmlYes
tipoNonfe
subtipoNogrupo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations at all, the description carries the full disclosure burden, and it does disclose the validation authority (official XSD) and the return shape ('Devolve "valido" ou o erro com linha e coluna'), which is genuinely useful diagnostic context. It omits whether validation is local or network-bound, any size or performance limits, and whether partial results are ever returned.

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?

Three short sentences with the primary purpose front-loaded and the mode explanation immediately after; every sentence carries information. Slightly dense use of embedded quotes, but no filler.

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

Completeness3/5

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

The output schema exists, so the description does not need to specify return structure in detail, and it does not attempt to. For a 3-parameter tool with zero schema descriptions and no annotations, however, the definition leaves the 'xml' input format and the 'tipo' parameter unexplained, which is a real gap.

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 compensate, and it only partly does: it fully explains the 'subtipo' enum semantics but never says what 'xml' actually is (raw XML string vs. file path vs. identifier) and says nothing about the 'tipo' enum beyond the fact that document type matters. The most consequential ambiguity in the schema is left unresolved.

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

Purpose4/5

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

States a specific verb and resource ('Valida um XML contra o XSD oficial') and then, unusually, explains its two operating modes ('subtipo="grupo"' vs 'nota'), which lets an agent distinguish the tool's own scopes. It stops short of positioning itself against siblings such as descrever_erro or calcular_tributos, so an agent still has to infer when this tool is the right choice.

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?

Gives explicit mode-selection guidance: 'grupo' validates only the tributação groups (cross-referencing gerar_xml_grupo as the producer of such groups), while 'nota' validates the whole document. There is no negative guidance, no prerequisites, and no routing to alternative tools, so it is clear context without exclusions.

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