Skip to main content
Glama

Get Facturae XML (B2G)

get_invoice_facturae
Read-only

Return the Facturae 3.2.1 XML of a finalized invoice, for invoicing Spanish public administrations (schools, ayuntamientos, universities). The XML is UNSIGNED and therefore not submittable on its own: FACe requires a XAdES-signed .xsig even through its web form. Use it to preview and validate the data; to actually file the invoice use submit_invoice_to_face, which signs it first. Requires the customer to be marked as public administration with the three DIR3 codes set; if data is missing, the tool explains exactly what to add.

Input Schema

NameRequiredDescriptionDefault
invoice_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond readOnlyHint=false mutation semantics by disclosing that the XML is UNSIGNED and therefore not submittable on its own, that FACe requires a XAdES-signed .xsig even via web form, and how the tool behaves when DIR3 data is missing ('the tool explains exactly what to add'). That is exactly the behavioral context annotations cannot carry.

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?

Four tight sentences, front-loaded with what is returned, then the signature caveat, then the alternative tool, then the precondition. No repetition of the name or title, no filler.

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 one parameter and no output schema, the description covers what is returned, its validity limits, the applicable alternative, and failure behavior — enough to call correctly. A minor gap is that it does not say whether the invoice must first be finalized via finalize_invoice, only that it is 'a finalized invoice'.

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 coverage is 0% and the single parameter invoice_id has no type description in the schema. The description implies the id must refer to a finalized invoice, which adds useful meaning, but it does not clarify whether non-finalized or non-B2G invoices error out or return partial data.

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?

States a specific verb and resource with version precision: 'Return the Facturae 3.2.1 XML of a finalized invoice'. It distinguishes itself from nearby siblings like get_invoice and get_invoice_display by naming the exact artifact returned and the B2G/FACe scope.

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 scopes use to previewing and validating, and names the alternative: 'to actually file the invoice use submit_invoice_to_face, which signs it first'. It also states the prerequisite (customer marked as public administration with three DIR3 codes) that determines whether the call can succeed.

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.

Resources