Detalhes do Evento de Webhook
curl --request GET \
--url https://garu.com.br/api/v1/webhook-events/{uuid} \
--header 'Authorization: Bearer <token>'import requests
url = "https://garu.com.br/api/v1/webhook-events/{uuid}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://garu.com.br/api/v1/webhook-events/{uuid}', 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://garu.com.br/api/v1/webhook-events/{uuid}",
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://garu.com.br/api/v1/webhook-events/{uuid}"
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://garu.com.br/api/v1/webhook-events/{uuid}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://garu.com.br/api/v1/webhook-events/{uuid}")
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_bodyWebhooks e Exemplos
Detalhes do Evento de Webhook
Busque um evento de webhook pelo uuid com payload, tentativas e última resposta do endpoint
GET
/
api
/
v1
/
webhook-events
/
{uuid}
Detalhes do Evento de Webhook
curl --request GET \
--url https://garu.com.br/api/v1/webhook-events/{uuid} \
--header 'Authorization: Bearer <token>'import requests
url = "https://garu.com.br/api/v1/webhook-events/{uuid}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://garu.com.br/api/v1/webhook-events/{uuid}', 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://garu.com.br/api/v1/webhook-events/{uuid}",
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://garu.com.br/api/v1/webhook-events/{uuid}"
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://garu.com.br/api/v1/webhook-events/{uuid}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://garu.com.br/api/v1/webhook-events/{uuid}")
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_bodyVisão Geral
Retorna o evento completo — payload entregue, contador de tentativas e código HTTP da última resposta do seu endpoint. É a chamada que alimenta a página de detalhes do evento no dashboard.Exemplo de Requisição
curl https://garu.com.br/api/v1/webhook-events/a1b2c3d4-e5f6-7890-abcd-ef1234567890 \
-H "Authorization: Bearer sk_live_sua_chave_api"
import { Garu } from '@garuhq/node';
const garu = new Garu({ apiKey: process.env.GARU_API_KEY });
const event = await garu.webhookEvents.get('a1b2c3d4-e5f6-7890-abcd-ef1234567890');
console.log(event.status, event.attempts);
console.log(event.payload); // o objeto completo enviado ao seu endpoint
import os
import requests
response = requests.get(
"https://garu.com.br/api/v1/webhook-events/a1b2c3d4-e5f6-7890-abcd-ef1234567890",
headers={"Authorization": f"Bearer {os.environ['GARU_API_KEY']}"},
)
event = response.json()
print(event["status"], event["responseStatus"])
Parâmetros de Path
string
required
UUID do evento, devolvido por
GET /api/v1/webhook-events.Resposta
{
"uuid": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"webhookEndpoint": {
"id": 7,
"url": "https://example.com/webhooks/garu",
"description": "Produção",
"enabled": true,
"events": ["transaction.payment.succeeded"]
},
"eventType": "transaction.payment.succeeded",
"status": "failed",
"attempts": 6,
"lastAttemptAt": "2026-05-18T14:22:11.000Z",
"nextRetryAt": null,
"responseStatus": 503,
"responseBody": "Service Unavailable",
"manualResendOf": null,
"createdAt": "2026-05-18T14:22:00.000Z",
"payload": {
"id": "evt_1a2b3c",
"type": "transaction.payment.succeeded",
"timestamp": "2026-05-18T14:22:10Z",
"data": {
"object": {
"id": 999,
"value": 49.9,
"paymentMethod": "pix",
"customer": { "email": "joao@email.com" }
}
}
}
}
Campos
| Campo | Tipo | Descrição |
|---|---|---|
status | string | pending, success ou failed |
attempts | number | Quantas tentativas foram feitas até agora |
lastAttemptAt | string|null | ISO timestamp da última tentativa (sucesso ou falha) |
responseStatus | number|null | HTTP da última resposta (ex: 200, 503, 404) |
responseBody | string|null | Body da última resposta, truncado |
manualResendOf | string|null | uuid do evento original, quando este registro for um clone de reenvio manual (POST /resend). null em eventos originais. |
nextRetryAt | string|null | Próximo retry agendado, se status pending e ainda em janela de retry |
payload | object | Payload completo — o mesmo JSON que foi enviado ao seu endpoint |
Para reenviar este evento, prefira
POST /api/v1/webhook-events/:uuid/resend — clona o evento e preserva o original. Veja Reenviar (clonando). O endpoint /retry (legado) segue disponível.Was this page helpful?