SII - Get the issued invoices book
GET https://{entorno}.ticketbaiws.eus/sii-envios/
The SII (Suministro Inmediato de Información, Immediate Supply of Information) requires large companies (turnover above 6 million euros), companies registered in the REDEME (monthly VAT refund register) and VAT groups to send every invoice to the AEAT (Spanish Tax Agency) within 4 working days. Ticketbai WS automatically records in the issued invoices book the invoices you create with POST tbai: corrections (zuzendu) are sent as modifications and cancellations as deletions. In the Basque Country and Navarre each invoice is recorded once the regional tax authority accepts it in TicketBAI.
This method is only available to companies with the SII enabled, using the sii parameter of New company and Edit company details. Once enabled, invoices issued from that day on are recorded. It is for companies in the common VAT territory (outside the Basque Country and Navarre): once enabled, their invoices are no longer sent to Verifactu, because SII companies are exempt from it. Basque companies under the State VAT rules can have it enabled through support. Each submission is also reported with the sii_envio webhook event.
Returns the last 100 records sent to the SII, newest first. All filters are optional and can be combined.
GET methods accept the parameters either in the body as a JSON payload or as a query string in the URL, as shown in the cURL example.
PARAMETERS
| serie string optional Invoice series | A |
| numero string optional Invoice number | 2026000245 |
| factura string optional Series and number as recorded in the SII | A2026000245 |
| estado string optional PENDIENTE (pending), CORRECTO (accepted), ACEPTADO_CON_ERRORES (accepted with errors), INCORRECTO (rejected), ERROR_TEMPORAL (retrying), BAJA (deleted), ESPERANDO_HACIENDA (waiting for the regional tax authority), SUSTITUIDO (superseded) or DESCARTADO (discarded) | INCORRECTO |
| desde / hasta string optional Issue date from / to (dd/mm/yyyy) | 01/11/2026 |
| limite integer optional Number of records (100 by default, maximum 1000) | 100 |
RESPONSE (return, one row per record)
| serie, numero, factura, fecha_emision Recorded invoice | A2026000245 |
| periodo string VAT period (yyyy-mm) | 2026-11 |
| operacion string alta (new), modificacion (correction) or baja (cancellation) | alta |
| estado string CORRECTO and ACEPTADO_CON_ERRORES are recorded by the AEAT; INCORRECTO was rejected (see errores); the rest are queued | CORRECTO |
| csv string Secure verification code (CSV) of the submission | GTUP7P9NT4S37CYV |
| errores / avisos array AEAT errors (codigo and descripcion) and Ticketbai WS warnings | |
| fecha_limite string Last day of the legal deadline (4 working days) | 30/11/2026 |
$ curl --request GET \
--url 'https://api-test.ticketbaiws.eus/sii-envios/?serie=A&numero=2026000245' \
--header 'Accept: application/json' \
--header 'Token: xxx' \
--header 'Nif: 00000014Z'
<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-test.ticketbaiws.eus/sii-envios/?serie=A&numero=2026000245",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => ["Accept: application/json", "Token: xxx", "Nif: 00000014Z"],
]);
$respuesta = json_decode(curl_exec($curl), true);
curl_close($curl);
print_r($respuesta["return"]);
$ python -m pip install requests
import requests
url = "https://api-test.ticketbaiws.eus/sii-envios/?serie=A&numero=2026000245"
headers = {"Accept": "application/json", "Token": "xxx", "Nif": "00000014Z"}
response = requests.request("GET", url, headers=headers)
print(response.text)
CURL *hnd = curl_easy_init();
curl_easy_setopt(hnd, CURLOPT_CUSTOMREQUEST, "GET");
curl_easy_setopt(hnd, CURLOPT_URL, "https://api-test.ticketbaiws.eus/sii-envios/?serie=A&numero=2026000245");
struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "Accept: application/json");
headers = curl_slist_append(headers, "Token: xxx");
headers = curl_slist_append(headers, "Nif: 00000014Z");
curl_easy_setopt(hnd, CURLOPT_HTTPHEADER, headers);
CURLcode ret = curl_easy_perform(hnd);
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://api-test.ticketbaiws.eus/sii-envios/?serie=A&numero=2026000245")
.get()
.addHeader("Accept", "application/json")
.addHeader("Token", "xxx")
.addHeader("Nif", "00000014Z")
.build();
Response response = client.newCall(request).execute();
HTTP/1.1 200 OK
{
"result": "OK",
"return": [
{
"id": 512,
"serie": "A",
"numero": "2026000245",
"factura": "A2026000245",
"fecha_emision": "24\/11\/2026",
"periodo": "2026-11",
"libro": "emitidas",
"operacion": "alta",
"estado": "CORRECTO",
"csv": "GTUP7P9NT4S37CYV",
"errores": [],
"avisos": [],
"fecha_limite": "30\/11\/2026",
"fecha_envio": "24\/11\/2026 10:12:03",
"intentos": 1
}
],
"msg": null
}
TicketBAI / Verifactu methods
- POST New invoice / resubmission (zuzendu) TicketBAI / Verifactu
- POST Complete a simplified invoice
- GET Get a TicketBAI / Verifactu invoice
- GET List TicketBAI / Verifactu invoices
- GET Download TicketBAI / Verifactu XML
- GET Download invoice in FacturaE format
- GET Download invoice as PDF
- GET System status
- DEL Cancel a TicketBAI / Verifactu invoice
- PUT Force TicketBAI / Verifactu resend
- POST Validate a NIF with the AEAT
- POST Validate a VAT number in VIES
Representation document
- GET Representation document - Download template
- POST Representation document - Upload document
- GET Representation document - Download uploaded document
- DELETE Representation document - Revoke uploaded document
BATUZ BIZKAIA specific methods
- GET List IAE activity codes
- POST LROE - Received invoices - Submit (BATUZ)
- PUT LROE - Received invoices - Update (BATUZ)
- GET LROE - Received invoices - Query (BATUZ)
- DEL LROE - Received invoices - Cancel (BATUZ)
- POST LROE - Expenses without invoice - Submit (BATUZ, form 140)
- PUT LROE - Expenses without invoice - Update (BATUZ, form 140)
- GET LROE - Expenses without invoice - Query (BATUZ, form 140)
- DEL LROE - Expenses without invoice - Cancel (BATUZ, form 140)
- POST LROE - Cash accounting COLLECTIONS - Submit (BATUZ)
- PUT LROE - Cash accounting COLLECTIONS - Update (BATUZ)
- GET LROE - Cash accounting COLLECTIONS - Query (BATUZ)
- DEL LROE - Cash accounting COLLECTIONS - Cancel (BATUZ)
- POST LROE - Cash accounting PAYMENTS - Submit (BATUZ)
- PUT LROE - Cash accounting PAYMENTS - Update (BATUZ)
- GET LROE - Cash accounting PAYMENTS - Query (BATUZ)
- DEL LROE - Cash accounting PAYMENTS - Cancel (BATUZ)
SII (AEAT)
Customers and products (invoicing tool)
- GET Customers - Search / get customers
- POST Customers - New customer
- PUT Customers - Update customer
- GET Products - Search / get products
