InvoiceXML

by invoicexml

Not rated
GitHub

About

Global e-invoicing compliance: Factur-X, Peppol UBL, CII & more

Details

Author
invoicexml
Categories
Finance, Security, Other

Setup

Install InvoiceXML in your MCP client (Claude Desktop, Cursor, Windsurf, and others).

Repository: https://github.com/invoicexml/invoicexml-mcp

Follow the installation instructions in the repository README, then restart your MCP client.

AModel Context Protocolserver that exposes theInvoiceXML APIto AI agents. Covers Factur-X, ZUGFeRD, XRechnung, UBL / CII, and Peppol BIS Billing 3.0.

The same codebase runs in two deployment shapes, selected at startup by one environment variable:

Both run the same binary; only the configuration differs. The repository is platform-independent — it knows nothing about where or how you host it.

+----------------------+ ProjectReference +----------------------+ | InvoiceXml.Mcp.Core | -------------------> | InvoiceXml.Mcp.Host | | (SDK: client+tools) | | (the deployable) | +----------------------+ +----------------------+

InvoiceXml.Mcp.Coreis a small, transport-agnostic SDK:

- IInvoiceXmlClient— typed client over the public REST API
- HttpInvoiceXmlClient— the only implementation; consumes anHttpClientfromIHttpClientFactory
- InvoiceXmlClientOptions— base URL, timeout (no auth)
- AddInvoiceXmlMcpCore(IServiceCollection, IConfiguration)— DI entry point; returns theIHttpClientBuilderso the host attaches auth as aDelegatingHandler

The SDKnever sees credentials. The host applies them through the HTTP pipeline. That seam is what lets one codebase serve both deployment modes.

InvoiceXml.Mcp.Hostis an ASP.NET Core 10 app:

- ReadsMcp:AuthMode(ApiKeyorOAuth) at startup
- Wires the matchingDelegatingHandleronto the Core HTTP client viaAddHostAuth(...)
- Serves the MCP endpoint atPOST /, a human-friendly welcome page atGET /, and/health

Adding a new auth mode = one arm inAuthExtensions.csplus a small folder underAuth/<Mode>/. Adding a new tool = one[McpServerTool]class. Nothing else changes.

invoicexml-mcp/ ├── src/ │ ├── InvoiceXml.Mcp.Core/ # the SDK: client, models, tools │ │ ├── Enums/ Interfaces/ Models/ Options/ Services/ Tools/ Extensions/ │ └── InvoiceXml.Mcp.Host/ # the deployable host │ ├── Auth/{ApiKey,OAuth}/ # the two auth modes │ ├── Configuration/ │ ├── Program.cs │ └── appsettings.json # safe defaults, no secrets ├── tests/ │ ├── InvoiceXml.Mcp.Core.Tests/ │ └── InvoiceXml.Mcp.Host.Tests/ ├── Directory.Build.props # repo-wide MSBuild defaults ├── Directory.Packages.props # Central Package Management ├── global.json # pins the .NET SDK └── InvoiceXml.Mcp.slnx

You need a .NET 10 SDK and an InvoiceXML API key.

# 1. Provide your API key (pick one): # A. dotnet user-secrets (recommended — kept outside the repo) dotnet user-secrets --project src/InvoiceXml.Mcp.Host set "Mcp:ApiKey:Value" "your-key" # B. environment variable $env:INVOICEXML_API_KEY = "your-key" # 2. Run dotnet run --project src/InvoiceXml.Mcp.Host

GET http://localhost:5004/shows a welcome page in a browser; the MCP endpoint isPOST http://localhost:5004/;GET /healthreturns{ "status": "ok" }.

{ // Required in OAuth mode. The public origin where this MCP server is reachable. // Used in the protected-resource metadata response. "McpUri": "https://mcp.example.com", "InvoiceXml": { "BaseUrl": "https://api.invoicexml.com", // override for staging / local "Timeout": "00:01:40" }, "Mcp": { "AuthMode": "ApiKey", // "ApiKey" | "OAuth" "ApiKey": { "Value": "" // ApiKey mode: NEVER commit a real key }, "OAuth": { "AuthorizationServer": "https://invoicexml.com", "ScopesSupported": [ "api_token.read" ] }, "FileInput": { // limits for the URL-fetch input mode "MaxFileSizeBytes": 5242880, "FetchTimeout": "00:00:30" } } }

Environment variable equivalents (double underscore = nesting):

WhenMcp:AuthMode=OAuththe host stops accepting a static API key and instead:
- Returns401withWWW-Authenticate: Bearer resource_metadata="…"for anyPOST /that has no Bearer token.
- ServesGET /.well-known/oauth-protected-resourcepointing MCP clients atinvoicexml.comas the authorization server.
- Forwards the inbound Bearer token verbatim on every outbound call to the InvoiceXML API (the API is the source of truth for token validity; the MCP server does not validate tokens locally).

client → MCP POST / → 401 + resource_metadata client → /.well-known/oauth-protected-resource → { authorization_servers: [invoicexml.com] } client → invoicexml.com/.well-known/oauth-authorization-server → { authorize, token, register endpoints } client → invoicexml.com/oauth/register → client_id + client_secret (DCR) client → invoicexml.com/oauth/authorize → user consents, gets code client → invoicexml.com/oauth/token → access_token (= user's API key) client → MCP POST / + Authorization: Bearer → 200, tool call flows through

The host is a standard ASP.NET Core app — run it however you run .NET services (systemd, a container, a PaaS, etc.; the repo doesn't prescribe one):

dotnet publish src/InvoiceXml.Mcp.Host -c Release -o ./publish # then run ./publish/InvoiceXml.Mcp.Host on your host

Set configuration via environment variables on the host (never commit secrets):

- ASPNETCORE_ENVIRONMENT=Production
- Mcp__AuthMode=ApiKey(orOAuth)
- Mcp__ApiKey__Value=…/INVOICEXML_API_KEY=…(ApiKey mode)
- McpUri=https://your-public-urlandMcp__OAuth__AuthorizationServer=https://invoicexml.com(OAuth mode)

Terminate TLS at your reverse proxy / load balancer and forward to the host's HTTP port. The server is stateless, so you can run multiple instances behind a load balancer.

Tamper-evident audit logging for AI decisions. Three tools (record_decision, verify_decision, list_decisions) write to a regulator-grade ledger built on AWS S3 Object Lock with 7-year retention. Designed for EU AI Act Article 12 and FCA SS1/23 evidence requirements. Try zero-config: npx audit-ledger-mcp boots in sandbox mode against a public hosted tenant.

Hosted MCP server for global e-invoice compliance: create, validate, embed, extract & convert Factur-X, Peppol UBL, CII & more

US LLC formation for non-residents: no SSN, plus EIN, banking, ITIN and annual renewals.

EU Corporate Sustainability Reporting Directive compliance — ESRS data points, double materiality assessments, audit trails, and XBRL-ready outputs for ESG reporting.

Cross-reference DORA and NIS2 requirements — gap analysis, mapping, and compliance overlap detection for financial services

MCP server for Poland's national e-invoicing system KSeF (Krajowy System e-Faktur). Provides 12 tools for complete KSeF API integration including session management, invoice querying/submission, export generation, and system monitoring. Built with Rust for reliability and performance. Perfect for Polish businesses automating e-invoicing processes and developers building KSeF compliance tools.

Attested healthcare-finance MCP. Scan medical bills, estimate appeal probability, generate state-specific appeal letters, benchmark commercial rates, look up ICD-10/CPT/NPI/DEA. Every response Ed25519-signed so LLMs can cite + verify.

AI-powered regulatory compliance checking for financial marketing content across multiple jurisdictions.

Personal wealth & portfolio tracker — 23 OAuth-scoped tools for holdings, performance, FIRE status, crypto P&L, and confirm-gated transaction writes across 20+ markets.

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.