Skip to main content
Glama

generate_eu_einvoice_xml

Read-onlyIdempotent

Generate EN 16931 compliant EU e-invoice XML in Peppol BIS 3.0 UBL, German XRechnung 3.0 UBL, or Factur-X/ZUGFeRD 2.3 CII from invoice, seller, buyer, and line item data for compliant European billing.

Instructions

Generate EN 16931 EU E-Invoice XML (Peppol BIS 3.0 UBL, German XRechnung 3.0 UBL, or Factur-X/ZUGFeRD 2.3 CII) via Apify Cloud.

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": {
      "invoice_number": "<invoice_number>",
      "seller": "<seller>",
      "buyer": "<buyer>",
      "lines": "<lines>"
    },
    "name": "generate_eu_einvoice_xml"
  }
}

Input Schema

NameRequiredDescriptionDefault
buyerYesBuyer legal entity details.
linesYesInvoice line items with quantities, unit prices, and VAT rates.
formatNoTarget European e-invoice XML standard.peppol-ubl-3.0
sellerYesSeller legal entity details.
currencyNoISO 4217 document currency code (e.g., EUR).EUR
due_dateNoPayment due date in YYYY-MM-DD format (BT-9).
issue_dateNoInvoice issue date in YYYY-MM-DD format (BT-2).
invoice_numberYesUnique supplier invoice number (BT-1).
buyer_referenceNoPurchase order reference or German XRechnung Leitweg-ID (BT-10).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false, and openWorldHint=true, so the safe, repeatable profile is covered. The description adds the meaningful fact that generation happens remotely 'via Apify Cloud', implying an external network dependency with possible latency, but says nothing about what happens on validation failure or where the resulting document goes.

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?

It is a single front-loaded sentence with no filler or restated boilerplate. The parenthetical enumerating three standards is dense but every word names a real supported target format.

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?

With nine parameters, nested seller/buyer objects, and no output schema, the description should clarify how the generated XML is returned (inline string, file URL, or dataset record) and whether the payload is validated against the selected profile. It covers the formats but omits the return and validation story, which is a real gap for a generation tool.

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 100%, including per-field descriptions with BT references such as BT-1, BT-2, BT-9, and an enum with a default, so the schema already carries the parameter burden. The description only maps the enum options to named standards, which is marginal added value rather than new semantics.

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 concrete verb and resource: generating EN 16931 EU e-invoice XML, and enumerates the three supported standards (Peppol BIS 3.0 UBL, XRechnung 3.0 UBL, Factur-X/ZUGFeRD 2.3 CII). It does not differentiate itself from the sibling generators, which all produce other financial file formats, leaving that routing to the agent.

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

Usage Guidelines2/5

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

There is no guidance on when to use this tool versus a sibling like generate_sepa_xml or validate_bank_routing, nor any statement of prerequisites. The only usage signal is the list of supported standards, and how to choose among them (peppol-ubl-3.0 vs xrechnung-3.0-ubl vs facturx-cii-en16931) is left entirely to the schema enum.

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