Skip to main content
F

Facturapi

@codespar/mcp-facturapi Β· v0.2.2

πŸ‡²πŸ‡½ MexicoFiscalAuth Β· API Keybeta20 tools1 env vars

Mexican CFDI 4.0 e-invoicing: create, stamp, and cancel invoices with SAT validation. Your agent handles Mexican fiscal compliance.

Get started Β· freeView docs

MIT Β· runs locally or through the CodeSpar runtime

Limitations

  • The npm package ships no server.json manifest.
Package
@codespar/mcp-facturapi
Version
0.2.2
npm dist-tag
latest
Category
Fiscal
Auth
API Key
Country
πŸ‡²πŸ‡½ Mexico
License
MIT
Transport
stdio Β· streamable-http

Quickstart

Install, set the credentials, make the first call.

Pick your client. The server runs locally over stdio, or through the hosted runtime.

Add the server to your clientOne config entry. No build step, no SDK required.
Set the environment variables1 variable read by this server's code, listed below.
Restart and make the first callThe agent can call any of the 20 tools. Try create_invoice first.
terminal
# Claude Code claude mcp add facturapi -e FACTURAPI_API_KEY=… -- npx -y @codespar/mcp-facturapi@0.2.2 # then: /mcp to confirm the server is connected
Environment variables1 variable
FACTURAPI_API_KEYAPI key for FacturAPIrequiredsecret

Names read from the package code (@codespar/mcp-facturapi@0.2.2). Descriptions and flags come from its manifest. Self-hosted, you hold the credentials. On the CodeSpar runtime the credential you connect is stored encrypted (AES-256-GCM, key derived per organization), and the runtime adds it to the provider call itself; the agent never receives it.

First call democreate_invoice

"Create a CFDI invoice"

tools/callcreate_invoiceresult returned

Tools

What your agent can call.

20 tools, as the package's tools/list returns them.

create_invoice

Create a CFDI invoice

get_invoice

Get invoice by ID

list_invoices

List invoices with filters

cancel_invoice

Cancel an invoice

download_invoice_pdf

Download invoice as PDF (returns download URL)

download_invoice_xml

Download invoice as XML (returns download URL)

send_invoice_email

Send invoice (PDF + XML) by email to the customer or to specific recipients

create_customer

Create a customer for invoicing

get_customer

Get customer by ID

list_customers

List customers with optional filters

update_customer

Update an existing customer (partial update)

delete_customer

Delete a customer

Names and descriptions come from the package's tools/list (@codespar/mcp-facturapi@0.2.2). A kind (read, write, delete) is shown only when the package annotates its tools or each tool was verified one by one; neither exists for this server yet.

Compatibility

MCP is a protocol. Any client that speaks it can mount this server.

Through the CodeSpar runtime, codespar_discover finds this server's tools, and a tools/call runs with the credential connected in your project, a test key included.

hostedhttps://connect.codespar.dev/mcp15 meta-tools

Protocol

Any MCP client

stdio Β· streamable-http

Questions

Before you install.

How do I install the Facturapi MCP server?

Run npx -y @codespar/mcp-facturapi@0.2.2 and add the config block above to your MCP client: Claude Code, Cursor, Claude Desktop, VS Code, or any MCP-compatible client. No build step, no SDK required. Prefer hosted? Add the CodeSpar endpoint with a test key and connect Facturapi in your project; codespar_discover finds its tools.

What can my agent do with Facturapi?

Facturapi exposes 20 tools for fiscal. Your agent calls them directly; the full list is above.

How does Facturapi authenticate, and how are credentials stored?

Facturapi uses API Key. Self-hosted, you hold the credentials: the server reads them from its environment variables. On the CodeSpar runtime the credential you connect is stored encrypted for your organization, and the runtime adds it to each provider call, so the agent never handles it.

How does Facturapi handle upstream API changes?

Every server is versioned independently on npm. The command on this page pins 0.2.2, the version whose tools are listed here; your agent keeps running it until you change the version.

Is Facturapi open source? How do I report a bug?

Yes. Facturapi is MIT-licensed and published on npm as @codespar/mcp-facturapi, source on GitHub (link in the Details panel). Report issues on the package repository; security issues go to security@codespar.dev, and we respond within 24 hours.

Start in seconds.

On the CodeSpar runtime, the credential you connect stays encrypted for your organization and the runtime adds it to each call. You just call the tool.

Start in seconds demo
Create an account and copy a test key.
Add the hosted endpoint to your client with the config above.
Connect Facturapi in your project and ask your agent for the first call.
Facturapi β€” MCP server Β· 20 tools | CodeSpar