C
cablenetai
API · Marketplace

Webhooks salientes

CablenetAI envía eventos HTTP firmados a tu endpoint cada vez que algo importante ocurre. Úsalos con Zapier, Make, n8n o tu backend propio.

Cómo funciona

1. Registra tu endpoint en /integraciones-mias → Webhooks (URL + secret).

2. CablenetAI envía POST con cuerpo JSON y cabecera X-CablenetAI-Signature (HMAC-SHA256 sobre el body, usando tu secret).

3. Tu endpoint debe responder 2xx en < 10s. Si no, reintentamos con backoff exponencial hasta 24h (cola webhook_deliveries).

4. Verifica la firma antes de procesar.

Verificación HMAC (Node.js)
import { createHmac, timingSafeEqual } from "crypto";

function verify(rawBody: string, header: string, secret: string) {
  const expected = createHmac("sha256", secret).update(rawBody).digest("hex");
  return header.length === expected.length &&
    timingSafeEqual(Buffer.from(header), Buffer.from(expected));
}

Eventos disponibles

lead.created
trigger

Se crea un nuevo lead (Meta Lead Ads, WhatsApp, formulario, portal inmobiliario, importación).

Ver payload
{
  "id": "uuid",
  "org_id": "uuid",
  "source": "meta | whatsapp | form | portal:<id> | import",
  "name": "string",
  "phone": "E.164 | null",
  "email": "string | null",
  "property_id": "uuid | null",
  "created_at": "ISO 8601"
}
lead.status_changed
trigger

Cambia la etapa de un lead en el pipeline.

Ver payload
{
  "id": "uuid",
  "from_status": "string",
  "to_status": "string",
  "changed_by": "uuid (user_id)",
  "changed_at": "ISO 8601"
}
contract.signed
trigger

Todas las partes firman un contrato digital.

Ver payload
{
  "id": "uuid",
  "contract_number": "string",
  "property_id": "uuid",
  "buyer_id": "uuid",
  "total_amount": "number",
  "currency": "USD | DOP | EUR | MXN | ...",
  "signed_at": "ISO 8601",
  "pdf_url": "string (signed URL, 24h)"
}
payment.received
trigger

Se confirma un pago (Stripe, Cardnet, Azul, transferencia manual).

Ver payload
{
  "id": "uuid",
  "contract_id": "uuid",
  "installment_id": "uuid | null",
  "amount": "number",
  "currency": "USD | DOP | EUR | MXN | ...",
  "method": "stripe | cardnet | azul | transfer | cash",
  "received_at": "ISO 8601"
}
appointment.scheduled
trigger

Se agenda una cita o visita.

Ver payload
{
  "id": "uuid",
  "type": "visit | meeting | call",
  "starts_at": "ISO 8601",
  "property_id": "uuid | null",
  "contact_id": "uuid"
}
mls.collaboration.created
trigger

Un agente de la red MLS solicita colaborar en una propiedad.

Ver payload
{
  "id": "uuid",
  "listing_id": "uuid",
  "requesting_agency_id": "uuid",
  "split_pct": "number 0-100",
  "created_at": "ISO 8601"
}

Zapier

Trigger "Webhooks by Zapier → Catch Hook"

Abrir Zapier

Make

Módulo "Custom Webhook"

Abrir Make

n8n

Self-hosted, nodo Webhook

Documentación

Empieza ahora

Registra tu primer webhook en menos de 2 minutos.