Creates compliant French e-invoices locally: Factur-X PDF/A-3 with EN 16931 CII XML, legal numbering
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent — or use 1-click editor setup below.
💡 Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Small Go binary that turns a print-ready HTML invoice into Factur-X: a compliant PDF/A-3 with the CII EN 16931 XML embedded, and optionally submits it to a French e-invoicing platform (PDP — plateforme de dématérialisation partenaire).
Built for the invoicing of a French freelancer or small business (the French
e-invoicing reform), and also shipped as a Claude Code plugin with the
creer-facture skill.
Verbatim embedding — important. The XML is embedded byte for byte. An assembler that re-serializes it through its own model loses extended fields, in particular the PDP electronic routing addresses (BT-34/BT-49). gofact never touches the XML it has produced.
A browser, and that's it.
Auto-detected on Linux, macOS and Windows (where Edge is preinstalled, so
nothing to do). Sandboxed packages — snap, flatpak — are skipped: they cannot
read the temporary files gofact hands them. To point at a specific executable:
GOFACT_CHROME or -chrome.
The PDF/A-3 assembly is done in Go (pdfcpu): no Ghostscript, no Java, no first-run download. The sRGB ICC profile is embedded in the binary.
Two checks, at two different moments:
BR-50, BR-CO-15…) and the field to fix./AF, /OutputIntents, XMP, /EmbeddedFiles) and
the embedded XML is compared byte for byte with the one that was generated.Deep PDF/A-3b compliance is verified by veraPDF, via Mustang, in continuous integration — never on the user's machine:
No identity and no secret is hard-coded. The invoice issuer, the payment IBAN and the PDP credentials come from the environment.
gofact loads, in order and without ever overwriting an already-defined
variable: the file passed to -env, otherwise ./.env, then
$XDG_CONFIG_HOME/gofact/.env (~/.config/gofact/.env by default). The .env
is git-ignored — never commit it.
| Variable | Purpose |
|---|---|
GOFACT_SELLER_NAME | Seller name. Required unless the JSON carries a seller block. |
GOFACT_SELLER_SIRET / GOFACT_SELLER_SIREN | French legal identifier (BT-30). The SIREN is derived from the SIRET. |
GOFACT_SELLER_VAT_NUMBER | Intra-community VAT number (BT-31). Empty under the 293 B franchise ⇒ BT-32 = SIREN. |
GOFACT_SELLER_EMAIL | Seller e-mail. |
GOFACT_SELLER_ADDRESS / _POSTAL_CODE / _CITY / _COUNTRY | Postal address (country defaults to FR). |
GOFACT_SELLER_ELECTRONIC_ADDRESS / _SCHEME | Peppol routing BT-34. Empty ⇒ SIREN + scheme 0225. |
GOFACT_PAYEE_IBAN | Payment IBAN (BT-84). Empty ⇒ omitted from the invoice. |
GOFACT_VAT_EXEMPTION_MENTION / _CODE | Default exemption mention and code (293 B). |
SUPERPDP_CLIENT_ID / SUPERPDP_CLIENT_SECRET / SUPERPDP_BASE | PDP credentials (secrets), for -send only. |
With no seller configured, gofact fails explicitly rather than issuing an
incomplete invoice. Every value can still be overridden per invoice via the JSON.
gofact mcp exposes invoicing as a local MCP server (stdio): from Claude
Desktop, Claude Code, LM Studio or any MCP client, saying "make me an invoice
for ACME, 2 days at €600" is enough. The AI is the interface; gofact
guarantees the numbering (continuous legal sequence, locked and transactional
allocation), EN 16931 compliance and archiving — locally.
Tools: list_organizations, get_organization, init_organization,
update_organization,
search_client, get_invoice_template, preview_next_number, list_invoices,
create_invoice, send_invoice (the only destructive tool — PDP submission,
explicit confirmation required), get_invoice_status. Prompt: nouvelle-facture.
An organization (issuing entity) = a self-contained directory: identity in
its .env, numerotation.json registry, journal.ndjson audit log, invoice
template frozen at first issuance, and the invoices themselves. CLI
management: gofact org list | init | show. No secret ever leaves a tool
response.
Exit code 0 if the Factur-X is generated (and compliant when -validate).
gofact submits the Factur-X PDF to SuperPDP (OAuth2 client credentials).
The PDP requires that the invoice seller = the company of the authenticated account (legal identifier BT-30) and an electronic routing address (BT-34/BT-49, scheme
0225) for both the issuer and the recipient. Seeelectronic_addressbelow.-pollshows the lifecycle (fr:200submitted →fr:201issued →fr:202received).
All amounts are in cents (integers). The seller, the IBAN, the VAT regime and the French legal mentions have default values (environment) — the JSON only carries what varies.
Optional fields: due_date (defaults to "on receipt" = issue date),
delivery_date (defaults to issue date), currency (defaults to EUR), vat
(defaults to 293 B exemption; set {"exempt": false, "rate_pct": "20.00"} for
standard VAT), seller, iban, title (the invoice subject, recorded in the
registry), notes.
Notes: the three French legal mentions — late-payment penalties (PMD),
recovery fee (PMT), discount (AAB) — are always emitted (BR-FR-05). notes
adds to them: a note without subject_code goes out as general information
(AAI); a note carrying PMD, PMT or AAB replaces the default mention with
that code. No spec can drop them: generation refuses.
PDP routing: seller/buyer accept electronic_address (BT-34/BT-49) and
electronic_address_scheme (e.g. "0225"). A PDP routes on these addresses,
not on the postal address. Without a declared address, each party is routed on
its SIREN (derived from the SIRET) with scheme 0225; the e-mail (EM) is
only used when no legal identifier is known — it is not in the directory, and
send_invoice then refuses the deposit. Example (seller override):
Precompiled binary (GitHub release, no toolchain required):
gofact install detects Claude Desktop, Claude Code, LM Studio and Cursor,
shows what it intends to write (dry-run by default), backs up every file before
modifying it and never overwrites a diverging entry without -force. Windows:
install.ps1.
Package managers — the cask and the manifest live in this repository, hence
the explicit URLs (Homebrew's short brew tap form requires a homebrew-*
repository name; Homebrew core and the main Scoop bucket both gate on a
popularity threshold gofact has not reached):
Claude Code plugin — the repository is also a plugin: creer-facture skill
From source: go build -o gofact .
Organizations live in local directories (identity, registry, invoices) —
never versioned here: they contain real data. GOFACT_INVOICES_DIR is still
honored for compatibility with the historical skill.
No reviews yet — be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/gofact)<a href="https://allmcps.com/mcp/gofact"><img src="https://allmcps.com/api/badge/gofact?style=directory" alt="Gofact on AllMCPs" /></a>