NIF management API
The Verifacti NIF management API is the common layer you share across regulations: with it you register, activate and deactivate your customers’ NIFs, manage their representation form and set up webhooks, once. Then each regulation (Verifactu, TicketBAI or SII) connects through its own submission integration.
[{
"nif": "B86561412",
"entorno": "test",
"hacienda": "verifactu",
"nombre": "Mi empresa SL",
…
}][{
"nif": "B86561412",
"activo": true,
"representacion": "Inexistente",
…
}]What the NIF management API does
Three pieces you integrate once and that every compliance API shares. It is not a sequence: you use each one when you need it.
NIF management
Register, activate and remove your customers’ NIFs by API, one by one or in batches, each with its environment, its treasury and its own API key.
- Invoicing software and SaaS: you register each customer from your product, without going through a dashboard.
- ERPs and groups: you manage hundreds or thousands of NIFs and only pay for those active in production.
- Integrators and consultancies: all your projects in one account.
Representation form
The document that authorises Verifacti to submit on behalf of each NIF. You generate it pre-filled, upload it signed and check its status by API.
- The same document for the AEAT and the three foral treasuries.
- The holder can also sign it online, without a digital certificate.
Webhooks
The result of each submission to the AEAT or the foral treasury reaches your system, without polling the status.
- Per environment: test or production.
- For all your NIFs or only some.
Registering, activating and removing NIFs
verifactu, alava, vizcaya, guipuzcoa or sii. The same NIF can be in several treasuries.Registration and lookup
POST /nifsto register andGET /nifsto list, filtering by environment and status.Activate and deactivate
Deactivate a NIF that stops invoicing and reactivate it when it comes back. You only pay for NIFs active in production.One API key per NIF
Each NIF has its own submission API key, which you can look up and rotate by API.Data and labels
Edit each NIF’s data and organise them with labels.
| Function | Endpoints | Used for |
|---|---|---|
| Registering, looking up, editing, deactivating, reactivating and deleting NIFs | POST /nifs, GET /nifs; GET, PUT and DELETE /nifs/{entorno}/{nif}; PUT /nifs/activate/{entorno}/{nif}; DELETE /nifs/{entorno}/{nif}/permanent | Verifactu API, TicketBAI API and SII API |
| API keys of each NIF | GET /nifs/keys/{entorno}/{nif}; POST /nifs/keys/{entorno}/{nif}/rotar | Every available API |
| Representation form | /representacion/generar, /enviar, /estado, /descargar, /cancelar and /firma_remota | AEAT (Verifactu and SII) and the foral treasuries of Álava, Bizkaia and Gipuzkoa (TicketBAI): the same document |
| Webhooks | /webhooks and /webhooks/{webhook_id}/nifs/{nif} | Responses from the AEAT and the foral treasuries |
| Validation | POST /nifs/validar, /nifs/validar_lotes and /nifs/validar/vies | Recipients under any regulation |
curl -X POST https://api.verifacti.com/nifs \
-H "Authorization: Bearer $VERIFACTI_USER_API_KEY" \
-H "Content-Type: application/json" \
-d '[{
"nif": "B86561412",
"entorno": "test",
"hacienda": "verifactu",
"nombre": "Mi empresa SL",
"direccion": "Calle Mayor 15",
"cp": "28040",
"poblacion": "Madrid",
"provincia": "Madrid"
}]'
# Response
[{
"nif": "B86561412",
"entorno": "test",
"hacienda": "verifactu",
"nombre": "Mi empresa SL",
"activo": true,
"representacion": "Inexistente",
"fecha_creacion": "2026-11-17T10:18:21.671Z",
"webhooks": []
}]Representation form by API
Webhooks
NIF validation
POST /nifs/validar), up to 20,000 NIFs per call (POST /nifs/validar_lotes), and the intra-EU VAT number in VIES (POST /nifs/validar/vies).One common layer for every regulation
You integrate NIF management once. Each regulation adds its own submission integration.
Built to integrate at scale
Built for developers
Public documentation with examples for every call, quick start guide, Postman collections, llms.txt and a free account with a test environment.
Typical integration: one to three developer daysSpecialists in Spain
Common and foral territory: Verifactu, TicketBAI and SII with one provider.
TicketBAI guarantor software in Álava, Bizkaia and GipuzkoaProven reliability
Hundreds of companies and software vendors in production with Verifacti. Data hosted in the EU and an SLA in the terms of use.
AEAT social collaboratorPricing
The NIF management API is included in the subscription: you pay for the NIFs active in production of each regulation. With the free account you can test sending in the test environment.
See pricingNIF management API documentation
Questions about NIF management
More FAQCan I register NIFs in bulk and receive webhooks?
Do I have to integrate NIF management for each regulation?
Can I deactivate a NIF that is not invoicing?
Can I validate the recipient’s NIF before invoicing?
Is the NIF management API in the free account?
vfn_ keys) and production webhooks require a subscription. With the free account you test sending invoices with test keys and test webhooks.Start integrating today
Try it for free with the test environment.