API > Webhooks - Get webhooks

Webhooks - Get webhooks

GET  https://{entorno}.ticketbaiws.eus/webhooks/

GET  https://{entorno}.ticketbaiws.eus/webhooks/{codigo_webhook}/

Gets the status of a single webhook or lists the webhooks created for a NIF (Spanish tax ID).

Available in the test and production environments. The list includes the webhooks of both environments; the entorno field (test or real) shows which one each belongs to, and eventos the events it is subscribed to (see events).

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

solo_errores boolean optional
Filters the webhooks by whether the solo_errores option is enabled. Leave it out to get all results
true
activo boolean optional
Filters the webhooks by whether the activo option is enabled. Leave it out to get all results
true



GET https://{entorno}.ticketbaiws.eus/webhooks/
$ curl --request GET \
     --url https://api-test.ticketbaiws.eus/webhooks/ \
     --header 'Accept: application/json' \
     --header 'Content-Type: application/json' \
     --header 'Token: xxx' \
     --header 'Nif: 00000014Z'
	 --data '{"activo":"true"}'
$ composer require ticketbaiws/ticketbaiws-php
<?php
// Installation: composer require ticketbaiws/ticketbaiws-php
require 'vendor/autoload.php';

$tbai = new \TicketbaiWS\Client('xxx', '00000014Z', ['entorno' => 'test']);

$r = $tbai->listarWebhooks([
    'activo' => 'true',
]);

if ($r->isError()) {
    echo $r->getMessageText();
} else {
    print_r($r->getData());
}
$ python -m pip install requests
import requests

url = "https://api-test.ticketbaiws.eus/webhooks/?activo=true"
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/webhooks/?activo=true");

struct curl_slist *headers = NULL;
headers = curl_slist_append(headers, "Accept: application/json");
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/webhooks/?activo=true")
  .get()
  .addHeader("Accept", "application/json")
  .addHeader("Token", "xxx")
  .addHeader("Nif", "00000014Z")
  .build();
  
Response response = client.newCall(request).execute();
{ } Response JSON
HTTP/1.1 200 OK
{
    "result": "OK",
    "return": [
        {
            "codigo": "6904a3501884e",
            "url": "https://www.berein.com/",
            "entorno": "test",
            "secret": "xajky22kjasy",
            "solo_errores": true,
            "activo": true,
            "fecha_creado": "2025-10-31T12:53:52+01:00",
            "fecha_modificado": "2025-11-03T10:16:15+01:00",
            "eventos": ["cambio_estado", "spfe_envio", "spfe_recibida"],
            "nif": "B12346789"
        }
    ],
    "msg": ""
}

TicketBAI / Verifactu methods

Representation document

BATUZ BIZKAIA specific methods

SII (AEAT)

Customers and products (invoicing tool)

Other methods