Resumen
Recibe eventos en tiempo real en tu backend.
Los webhooks te permiten recibir notificaciones en tiempo real cuando ocurren eventos en SouthGames. Configura endpoints en Configuracion > Webhooks en la consola.
Como funciona
- Configuras una URL de webhook en la consola
- Seleccionas los eventos que te interesan (o todos con
*) - SouthGames envia un POST a tu URL cuando ocurre un evento
- Tu servidor responde con un status 2xx
Formato del request
POST https://tu-servidor.com/webhooks/southgames
Content-Type: application/json
X-SouthGames-Signature: sha256=abc123...
X-SouthGames-Event: game.played
{
"event": "game.played",
"timestamp": "2025-01-15T10:30:00Z",
"data": {
"campaignId": "campaign_abc",
"externalUserId": "user_123",
"won": true
}
}
Reintentos
Si tu servidor no responde con 2xx, SouthGames reintenta hasta 3 veces con backoff exponencial:
| Intento | Delay |
|---|---|
| 1 | Inmediato |
| 2 | ~2 segundos |
| 3 | ~4 segundos |
Cada request tiene un timeout de 10 segundos.
Configuracion
- Ve a Configuracion > Webhooks en la consola
- Haz clic en "Crear webhook"
- Ingresa la URL y un secret
- Selecciona los eventos
- Guarda
El secret se usa para firmar los requests con HMAC-SHA256. Ver Verificacion.