Skip to main content
Glama

Peru Data MCP by Vira

Preview a Peruvian invoice (Facturin)

facturin_preview_invoice
Read-only

Build a free preview of a Peruvian electronic invoice with IGV (18% VAT) correctly calculated. Nothing is sent to SUNAT; this is a draft to show the user what the document will contain.

`items`: list of {"description": str, "quantity": number, "unit_price": number}.
`document_type`: "boleta" (receipt for consumers) or "factura" (invoice for companies; requires `customer_ruc`).
`prices_include_igv`: true if unit prices already include IGV (usual for boletas). `currency`: "PEN" or "USD".
To issue it for real, valid before SUNAT with PDF, XML and CDR, the user creates a Facturin account.

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": {
      "items": "<items>"
    },
    "name": "facturin_preview_invoice"
  }
}

Input Schema

NameRequiredDescriptionDefault
itemsYes
currencyNoPEN
customer_rucNo
document_typeNoboleta
prices_include_igvNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, and the description reinforces this by stating nothing is submitted to SUNAT and the preview is free. It also discloses the real-world caveat that only an account can produce a SUNAT-valid document with PDF, XML and CDR. It adds genuine context beyond the annotations without contradicting them.

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?

The core purpose and the no-SUNAT caveat are front-loaded, then parameters are listed in a scannable backticked block. Every sentence carries information an agent needs; nothing is redundant with the schema field names alone.

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?

For a 5-parameter tool with no output schema, the description covers inputs and the side-effect profile thoroughly. The one gap is that it never says what the preview actually returns (e.g. computed totals or an IGV breakdown), leaving the agent to infer the response shape.

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

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description carries the full burden and does so: it defines the item object shape (description, quantity, unit_price), explains document_type values with business meaning ('boleta' for consumers, 'factura' for companies requiring customer_ruc), and clarifies prices_include_igv semantics and currency options. This is meaning the bare schema would not convey.

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 ('Build a free preview of a Peruvian electronic invoice') and pins down the domain-specific calculation (IGV at 18%). An agent can immediately distinguish this from the lookup/macro siblings in the same Peru/Facturin family, which none of the other tool names resemble.

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 clear when-to-use context: 'Nothing is sent to SUNAT; this is a draft to show the user what the document will contain,' and a when-not path ('To issue it for real... the user creates a Facturin account'). It does not point to any sibling tool as an alternative, but the boundary between preview and real issuance is explicit.

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