Skip to main content
Glama

Br Generate Nfse

br__generate_nfse

Generate an unsigned DPS (Declaração de Prestação de Serviços) XML for Brazilian NFS-e Nacional (ADN) schema v1.01. Returns the XML and DPS ID for subsequent signing and submission.

Instructions

Gerar um DPS não assinado para NFS-e Nacional (ADN), schema v1.01.

O DPS (Declaração de Prestação de Serviços) gerado não contém <ds:Signature> — assine-o com br__sign_nfse antes de submeter ao ADN via br__submit_nfse.

Returns a dict with:

  • xml: the generated unsigned DPS XML string

  • dps_id: the 45-character DPS Id (infDPS Id attribute)

  • warnings: list of non-fatal notices

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dpsYesDPS data matching the NFSeDocument schema (NFS-e Nacional, ADN, schema v1.01)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.5.0

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations, the description carries the full behavioral burden. It discloses the output is an unsigned DPS (no <ds:Signature>), the schema version, and the return dict fields (xml, dps_id, warnings). This is sufficient for a pure-generation tool; no destructive side effects are implied.

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 short sentences in a clear order: what it generates, what to do next, and what it returns. No redundant filler or restatement of the title.

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?

For a single-parameter, nested-object generation tool with an output schema, the description covers purpose, workflow, non-signature behavior, and return values. It also references the exact document schema (NFSeDocument, ADN, v1.01) so an agent can construct valid input.

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?

Input schema coverage is 100%, so the schema already documents the only parameter ('DPS data matching the NFSeDocument schema'). The tool description adds no additional parameter-level meaning beyond schema v1.01, but it doesn't need to because the schema and referenced NFSeDocument schema cover it. Baseline 3 applies.

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 opens with a specific action and artifact: 'Gerar um DPS não assinado para NFS-e Nacional (ADN), schema v1.01'. It explicitly distinguishes itself from siblings by noting the DPS is unsigned and requires br__sign_nfse/br__submit_nfse.

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?

It names the exact sibling tools and sequence: sign with br__sign_nfse before submitting via br__submit_nfse. This makes the intended usage context and boundary of the tool explicit.

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