ACACHY

Webhooks

Como configurar webhooks para eventos de conteúdo.

Webhooks enviam eventos do CMS para URLs externas por POST com JSON.

Eventos

  • entry.created
  • entry.updated
  • entry.deleted
  • entry.published
  • entry.unpublished

Criar Webhook

{
  "name": "Revalidate website",
  "url": "https://example.com/api/revalidate",
  "event": "entry.published",
  "active": true
}

Payload Enviado

{
  "event": "entry.published",
  "data": {
    "entry": {}
  },
  "timestamp": "2026-01-01T00:00:00.000Z"
}

Logs

Cada execução registra:

  • URL.
  • Status HTTP.
  • Resposta truncada.
  • Sucesso ou falha.
  • Data de criação.
GET /api/admin/webhooks/:id/logs

Segurança SSRF

A API bloqueia URLs internas ou privadas, incluindo:

  • localhost
  • 127.0.0.1
  • 10.0.0.0/8
  • 172.16.0.0/12
  • 192.168.0.0/16
  • endereços link-local e loopback IPv6
  • hostnames que resolvem por DNS para IP privado

Teste Manual

POST /api/admin/webhooks/test
{
  "url": "https://example.com/api/hook",
  "event": "entry.published"
}

On this page