# Verifactu API for your invoicing software

The Verifacti Verifactu API connects your invoicing software with the Spanish Tax Agency (AEAT): you send each invoice as JSON, get the QR code instantly, and Verifacti generates the invoicing record, chains it and submits it to the AEAT on the taxpayer’s behalf, without you needing a digital certificate. You can try it with a free account, which includes a test environment and a test NIF.

## How the Verifactu API works

1. **You send the invoice as JSON.** Your software calls the API with the invoice data and the issuing NIF’s API key.
2. **You get the QR instantly.** The response includes the QR in Base64, ready to print on the invoice.
3. **Verifacti submits the record to the AEAT.** We generate the invoicing record, compute its fingerprint (hash), chain it to the previous one and submit it to the AEAT in the background.

Submission to the AEAT does not block issuing the invoice: the result reaches you by webhook or by checking the record’s status.

## Example: create an invoice with the Verifactu API

A full invoice (F1) against the test environment. Copy the request, add your test API key and it works.

```bash
curl -X POST https://api.verifacti.com/verifactu/create \
  -H "Authorization: Bearer $VERIFACTI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "serie": "A",
    "numero": "1",
    "fecha_expedicion": "19-11-2026",
    "tipo_factura": "F1",
    "descripcion": "Factura normal",
    "nif": "A15022510",
    "nombre": "Nombre cliente",
    "lineas": [{
      "base_imponible": "200",
      "tipo_impositivo": "21",
      "cuota_repercutida": "42"
    }],
    "importe_total": "242"
  }'
```

```json
{
  "uuid": "b018ced3-b362-4494-8776-9eefff1c160c",
  "estado": "Pendiente",
  "url": "https://prewww2.aeat.es/wlpl/TIKE-CONT/ValidarQR?nif=…",
  "qr": "iVBORw0KGgoAAAANSUhEUgAA…",
  "huella": "B11F3A015173AD99075E2720F61E2DE1…"
}
```

## What the Verifactu API includes

- **Validation before sending.** Every invoice is validated before it is sent to the AEAT, including the recipient’s NIF against the AEAT and VIES, and any error comes back with a code ([code catalogue](https://www.verifacti.com/openapi/codigos-verifactu.yaml)).
- **QR instantly.** In the response, in Base64, to print next to the VERI*FACTU legend. [QR size and position](https://www.verifacti.com/en/verifactu/qr).
- **Retries without duplicates.** With the `Idempotency-Key` header, repeating the same request returns the original response for 24 hours.
- **AEAT responses by webhook.** Or by checking the record’s status whenever you want.
- **Corrective invoices, cancellation and amendments.** Corrective invoices (R1–R5) and credit notes with the same create endpoint; cancellation and modification with their own. [Corrective invoice examples](https://www.verifacti.com/en/recursos/ejemplos/verifactu/rectificativas).
- **No digital certificate.** Verifacti is an AEAT social collaborator. Each taxpayer signs the [representation form](https://www.verifacti.com/en/api-gestion-nifs/modelo-de-representacion) once, also [online, without a certificate](https://www.verifacti.com/en/api-gestion-nifs/modelo-de-representacion/firma-online).
- **VERI*FACTU mode only.** Every record is sent to the AEAT in real time; the API does not cover the NO VERI*FACTU mode. [Verifactu modes](https://www.verifacti.com/en/verifactu/modalidades).
- **Your data, in the EU and exportable.** Data is hosted in the European Union and you can export your records at any time. The SLA is in the terms of use.

## One integration per regulation, on top of the NIF management API

You integrate the [NIF management API](https://www.verifacti.com/en/api-gestion-nifs) once: registering, activating and removing NIFs, representation and webhooks. Each regulation then adds its own submission integration, close to the target administration’s API. If a NIF is taxed in Álava, Bizkaia or Gipuzkoa, it uses the TicketBAI API with the same NIF management.

- [TicketBAI API](/en/api-ticketbai): For NIFs taxed in Álava, Bizkaia or Gipuzkoa.
- [SII API](/en/api-sii): SII (Immediate Supply of Information): issued-invoices record book, for large companies, VAT groups and REDEME.
- [E-invoicing API](/en/api-factura-electronica) (coming soon): B2B invoices between businesses and professionals.

## Verifactu: dates and who it applies to

Verifactu is the AEAT system that requires invoicing software to generate tamper-proof records and, in VERI*FACTU mode, send them in real time ([RD 1007/2023](https://www.boe.es/eli/es/rd/2023/12/05/1007/con)). It applies in common territory; businesses in the SII or taxed in foral territory are excluded.

| Who | Date | Status | Rule |
| --- | --- | --- | --- |
| Producers and resellers of invoicing software | Since 29 Jul 2025 | In force | [RD 1007/2023](https://www.boe.es/eli/es/rd/2023/12/05/1007/con), [Orden HAC/1177/2024](https://www.boe.es/eli/es/o/2024/10/17/hac1177/con) |
| Corporate Income Tax payers | 1 Jan 2027 | Published in the BOE, future date | [RDL 15/2025](https://www.boe.es/diario_boe/txt.php?id=BOE-A-2025-24446) |
| Everyone else, including the self-employed | 1 Jul 2027 | Published in the BOE, future date | [RDL 15/2025](https://www.boe.es/diario_boe/txt.php?id=BOE-A-2025-24446) |
| Postponement of the pending obligations | Oct 2028 | Announced, no rule published | [Nota de Hacienda, 5 oct 2026](https://www.hacienda.gob.es/sgt/gabsehacienda/nota-informativa-verifactu.pdf) |

This is not advice.

## Verifactu API pricing

From €14.99 /month per NIF active in production, excl. VAT

- The price per NIF goes down with every tier.
- Up to 3,000 invoicing records per month per NIF.
- Online signing of the representation form: €2.90 + VAT.
- Free test environment and test NIF.
- Annual plan with a 10% discount, no setup fees.
- Same price with the TicketBAI API.
- [Startup plan](https://www.verifacti.com/en/soluciones/startups) for companies under 12 months old, with under €100,000 in revenue and under €200,000 in funding.

[See all prices](/en/precios)

## Questions about the Verifactu API

### Do I need a digital certificate to send invoices to Verifactu with the API?

No. Verifacti is an AEAT social collaborator and submits with its own certificate once the taxpayer signs the representation form. It can be signed online, without a certificate.

### Is there a test environment for Verifactu?

Yes. The free account includes a test environment with `vf_test_` API keys, which submit to the AEAT test environment, and a test NIF. The API URLs are the same in test and production.

### Has Verifactu been postponed? Do I need to integrate now?

The dates in the BOE are still 1 January 2027 for Corporate Income Tax payers and 1 July 2027 for everyone else. The Spanish Treasury has announced a postponement to October 2028, with no rule published yet. For those who make or sell invoicing software, the obligation has been in force since 29 July 2025. [Verifactu deadlines](https://www.verifacti.com/en/verifactu/plazos).

### Can you help me with the statement of conformity?

Yes. Your software needs its own statement of conformity (declaración responsable), and Verifacti has its own as an external component. We give you a [Word template](https://storage.googleapis.com/verifacti_non_sensitive/Declaracion%20Responsable%20Clientes.docx) adapted from the AEAT example, with notes for the trickier sections and a section explaining Verifacti’s role. The current version of our software, which you must state, is returned by `GET /verifactu/declaracion`. More in [statement of conformity](https://www.verifacti.com/en/api-verifactu/declaracion-responsable).

### How long does it take to integrate the Verifactu API?

In most cases, one to three developer days, plus a few days of adjustments.

### I already integrated Verifactu. Will it work for B2B e-invoicing?

The NIF management API you already integrated will. E-invoicing will have its own submission integration, through the E-invoicing API, coming soon.

## Everything you need to integrate

- [Verifactu API documentation](/en/docs)
- [Quick start guide](/en/recursos/guia-rapida?api=verifactu)
- [Invoice examples](/en/recursos/ejemplos/verifactu)
- [Verifactu glossary](/en/recursos/glosario/verifactu)
- [OpenAPI specification](/openapi/verifactu.en.yaml)
- [llms.txt](/llms.txt)
