Skip to main content
GET
/
webhooks
/
list
Listar webhooks
curl --request GET \
  --url https://api.abacatepay.com/v2/webhooks/list \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://api.abacatepay.com/v2/webhooks/list"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.abacatepay.com/v2/webhooks/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.abacatepay.com/v2/webhooks/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.abacatepay.com/v2/webhooks/list"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.abacatepay.com/v2/webhooks/list")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.abacatepay.com/v2/webhooks/list")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "data": [
    {
      "id": "webh_abc123xyz",
      "name": "Webhook de Pagamentos",
      "endpoint": "https://meusite.com/webhooks/abacatepay",
      "events": [
        "checkout.completed",
        "subscription.renewed"
      ],
      "devMode": false,
      "v2": true,
      "createdAt": "2025-01-01T00:00:00.000Z",
      "updatedAt": "2025-01-01T00:00:00.000Z"
    }
  ],
  "success": true,
  "error": null,
  "pagination": {
    "hasMore": true,
    "next": "<string>",
    "before": "<string>"
  }
}
{
"error": "Token de autenticação inválido ou ausente."
}

Requer a permissão WEBHOOK:READ.

Authorizations

Authorization
string
header
required

Todas as requisições devem incluir sua chave de API no header Authorization usando o formato Bearer <abacatepay-api-key>. Sem esse header a requisição será rejeitada.

Saiba mais sobre como criar e usar chaves de API na documentação de autenticação.

Query Parameters

Busca por nome, ID ou endpoint do webhook

Example:

"pagamentos"

after
string

Cursor para buscar itens após este ponto

before
string

Cursor para buscar itens antes deste ponto

limit
integer
default:100

Quantidade de itens por página (1-100)

Required range: 1 <= x <= 100
Example:

100

id
string

Filtrar por identificador único do webhook

Example:

"webh_abc123xyz"

Response

Lista de webhooks retornada com sucesso.

data
object[]

Lista de webhooks.

success
boolean

Se a requisição obteve sucesso ou não.

Example:

true

error
string | null
Example:

null

pagination
object

Informações de paginação baseada em cursor.