About Numerador de facturas
Numerador de facturas is a local MCP server for batch-numbering PDF invoices. It stamps every page, writes numbered copies, and leaves the originals unchanged; PDF contents are not sent to the server.
Key features
- 01Number batches of PDF invoices
- 02Stamp each page with a sequential label
- 03Choose numbering and layout options
- 04Preview numbering with `dry_run`
- 05Avoid overwriting existing files
Use cases
- 01Number invoices in a local folder
- 02Preview a numbering sequence before writing
- 03Create numbered copies while keeping originals
MCP support
Exposes the `number_invoices` tool to MCP clients. The local server receives file paths and returns generated file names; it does not send PDF contents over the network.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
Tools
1Saved tool list · updated 1w ago
| Parameter | Type | Required | Description |
|---|---|---|---|
| end | integer | No | Last number. Given alone, the first is worked out from the file count |
| zip | boolean | No | Also write a ZIP of the numbered PDFs |
| font | enum | No | Courier | Courier-Bold | Courier-Oblique | Courier-BoldOblique | Helvetica | Helvetica-Bold | Helvetica-Oblique | Helvetica-BoldOblique | Times-Roman | Times-Bold | Times-Italic | Times-BoldItalic |
| x_mm | number | No | Distance from that edge, in mm |
| y_mm | number | No | Distance from that edge, in mm |
| color | string | No | Number color, #rrggbb |
| merge | boolean | No | Also write one PDF with every invoice joined |
| paths | array | Yes | Absolute paths of PDF files, or folders whose PDFs are all taken (not recursive) |
| start | integer | No | First number. Defaults to 1 |
| from_x | enum | No | Horizontal reference edgeleft | right |
| from_y | enum | No | Vertical reference edgetop | bottom |
| dry_run | boolean | No | Report which number each file would get, writing nothing |
| size_pt | number | No | Font size in points |
| sort_by | enum | No | name: natural order (2 before 10). date: oldest modified first. given: as listedname | date | given |
| password | string | No | Password of protected PDFs. It passes through the chat: ask only if the tool reports locked files. Numbered copies come out unprotected |
| template | string | No | Number format with one marker: {n:4} pads to 4 digits (0007), {n} does not pad |
| box_color | string | No | Box color, #rrggbb |
| background | boolean | No | Draw a box behind the number |
| box_pad_mm | number | No | Margin between number and box edge |
| output_dir | string | No | Absolute folder for the results. Defaults to 'numeradas' beside the first file |
Details
From the project READMEnumerador-facturas-mcp
Servidor MCP para que un LLM numere facturas PDF en lote:
estampa F-0001, F-0002… en todas las páginas de cada factura y escribe copias numeradas.
Es el mismo código que la web, sin UI.
Privado y sin red. Se ejecuta en tu equipo como proceso local. El LLM le pasa rutas, no el contenido de los PDFs, y solo recibe la lista de archivos generados. No necesita cuenta ni conexión, y los originales no se modifican. Si le pides al LLM que lea una factura, ese contenido sí pasa por tu proveedor de LLM.
Instalar
Claude Desktop: descarga
numerador-facturas.mcpb
y ábrelo.
Claude Code:
claude mcp add --scope user numerador-facturas -- npx -y numerador-facturas-mcp
Otros clientes MCP:
{
"mcpServers": {
"numerador-facturas": { "command": "npx", "args": ["-y", "numerador-facturas-mcp"] }
}
}
Requiere Node 20 o superior. El servidor no tiene dependencias en tiempo de ejecución y no hace
peticiones de red. npx sí consulta npm al arrancar para buscar versiones nuevas, sin enviar
nada de tus facturas; si no quieres ni eso, usa el .mcpb.
Usar
Pídelo con normalidad: «numera las facturas de esta carpeta desde la F-0500».
La herramienta number_invoices acepta las mismas opciones que la web (plantilla, inicio o
fin, orden, posición, fuente, recuadro, PDF unido, ZIP), más dry_run para ver la numeración
sin escribir nada.
A diferencia de la web, si un archivo está protegido, o detecta que está dañado o incompleto, no numera ninguno, para no dejar huecos en la serie. La comprobación mira la estructura del PDF: un daño dentro del contenido de una página puede pasar sin detectarse. Tampoco sobrescribe archivos existentes, y si falla al escribir borra lo que haya escrito. Rechaza una posición que caiga fuera de alguna página, pero no comprueba que el número quepa entero. Las copias de un PDF protegido salen sin contraseña.
Publicar
La versión vive en package.json, manifest.json y server.json, y un test exige que coincidan.
La primera vez, desde mcp/ y con sesión en npm:
npm publish --access public
Después configura en npm el trusted publisher (repositorio nuncaeslupus/numerador-facturas,
workflow release-mcp.yml). Las siguientes versiones salen al empujar un tag mcp-vX.Y.Z, que
publica en npm y en el registro de MCP. La primera no llega al registro por sí sola: empuja
también su tag, con la publicación en npm ya hecha. Publica en npm antes de fusionar a main:
la web anuncia este nombre de paquete, y hasta entonces cualquiera podría registrarlo.
Licencia
MIT
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.