Skip to main content
Glama
InvoicePDFs MCP Server

InvoicePDFs MCP Server

Official
by invoicepdfs

document_create

Creates a draft invoice or other document with computed totals stored at creation, so you can render it only after finalizing.

Instructions

Create a document in draft.

Totals are computed and stored at creation, so the figures you read back are the ones that were issued rather than a recalculation. Nothing is rendered — use create_document_render once the document is final.

Input Schema

NameRequiredDescriptionDefault
notesNo
termsNo
localeNoen-US
numberYes
reasonNo
paymentNo
ship_toNo
brandingNo
currencyYes
due_dateNo
shippingNo
discountsNo
issue_dateYes
line_itemsYes
tax_schemeNoUNCL5153 — what kind of tax this invoice states. One document, one answer: an invoice is issued under a tax regime, not a different one per line. Optional, and deliberately not defaulted, because a PDF does not need it and assuming `VAT` would put a claim in a tax document that you did not make. Required to produce or check an e-invoice, where it must be `VAT` — every ruleset built on EN 16931 describes VAT and tests for that string literally, so a document stating anything else is refused rather than relabelled.
customer_idYes
custom_fieldsNo
delivery_dateNoBT-72. When the goods or services were actually supplied — not the issue date, and what decides the VAT period. XRechnung requires this, an invoicing period, or a period on every line.
document_typeNoinvoice
Idempotency-KeyNo
buyer_referenceNoBT-10. Mandatory in Peppol BIS unless an order reference is present — often the buyer's own PO or cost-centre string.
source_document_idNo
branding_profile_idNo
business_profile_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations, the description carries the full burden. It usefully discloses two behaviors: the document lands in draft state, and totals are frozen at creation rather than recalculated. However, for a mutation tool it omits permissions/auth needs, idempotency behavior (despite an Idempotency-Key parameter), what happens on duplicate `number`, and how the draft is finalized via document_transition.

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?

Three short sentences, front-loaded with the action and the resulting state, and every sentence carries distinct information (state, totals semantics, rendering deferral). The only friction is the mismatched backticked tool name.

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?

For a 24-parameter, six-required-field creation tool with no annotations and no output schema, the description should at minimum cover required inputs, idempotency, and what is returned (a draft document id). It covers none of these, leaving an agent to reverse-engineer the call from a large schema.

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?

Twenty-four parameters at 13% schema description coverage, and the description explains none of them — not the six required fields (number, issue_date, currency, business_profile_id, customer_id, line_items), not the Idempotency-Key, not the draft/finalization relationship to document_type. The schema does carry rich prose on a few fields (tax_scheme, delivery_date, buyer_reference), but the description adds zero compensating meaning.

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?

States a clear verb and resource ('Create a document') plus the resulting state ('in `draft`'), which is genuinely differentiating information. It implicitly separates itself from document_calculate (totals are stored, not recalculated) and from the render siblings, though it never distinguishes itself from document_duplicate or document_update by name.

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?

Gives one explicit routing rule ('use `create_document_render` once the document is final'), but that tool name does not match any listed sibling — the available tools are document_render and document_render_stored, so an agent following the text literally will look for a non-existent tool. No guidance on when to prefer document_duplicate, document_calculate, or document_transition in the lifecycle.

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