Skip to main content
Glama

gerar_xml

Generate tax group XML from a prior tax calculation response, enabling downstream NF-e or XML workflows under LC 214/2025.

Instructions

Gera o XML do grupo de tributação a partir da resposta de calcular_tributos feita SEM observabilidade (POST /regime-geral).

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": {
      "resultado_calculo": "<resultado_calculo>"
    },
    "name": "gerar_xml"
  }
}

Input Schema

NameRequiredDescriptionDefault
tipoNonfe
resultado_calculoYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It discloses the upstream dependency and endpoint context, but says nothing about side effects, failure modes, determinism, or what the generated XML contains. For a generation tool with zero annotation coverage, this is a substantial gap.

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?

The definition is a single, front-loaded sentence with no redundant wording. However, the unexplained 'SEM observabilidade' phrase reduces clarity despite the efficient structure.

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

Completeness2/5

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

The tool has two parameters, a nested object, no annotations, and no output schema. The description omits the expected structure of `resultado_calculo`, the meaning and options for `tipo`, and any indication of the returned XML format. It is not complete enough for an agent to invoke the tool confidently.

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

Parameters2/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. It clarifies that `resultado_calculo` comes from `calcular_tributos`, but does not describe the nested object's expected shape. It also says nothing about `tipo`, including its default value of 'nfe' or any allowed alternatives.

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?

The description states a specific verb and resource: it generates the XML for the tax group from the response of `calcular_tributos`. It also identifies the required upstream call, which helps distinguish it from siblings such as `validar_xml`. The phrase 'SEM observabilidade' is not explained, leaving part of the scope ambiguous.

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

Usage Guidelines3/5

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

It establishes a prerequisite: the input must come from `calcular_tributos` performed without observability via POST /regime-geral. It does not state when to avoid this tool, nor does it name alternatives such as `validar_xml` for validation. Usage is therefore implied but not fully guided.

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