⚠️ Verificación Manual en Stripe Dashboard
Para verificar por qué el webhook NO está funcionando automáticamente:
- Ir a Stripe Dashboard → Developers → Webhooks
https://dashboard.stripe.com/test/webhooks↗ - Verificar URL del webhook endpoint:
https://api.base44.com/api/apps/693c982a83932a173e6ff588/functions/handleStripeWebhook
- Verificar eventos suscritos:
- checkout.session.completed ✅
- checkout.session.expired ✅
- Revisar "Recent deliveries" (logs recientes):
- ¿El evento checkout.session.completed se envió?
- ¿Qué HTTP status devolvió? (buscar: 200, 400, 500)
- ¿Hay errores de firma inválida (signature verification)?
- Verificar que STRIPE_WEBHOOK_SECRET coincida:
whsec_5CpDkrIqt2x4MDICFYan7GsU3mQ6bSbQ
(Debe coincidir con el "Signing secret" del webhook en Stripe)
🔍 Problemas comunes:
- 400 Bad Request: Firma de webhook inválida
→ Verificar que STRIPE_WEBHOOK_SECRET sea correcto - 500 Internal Server Error: Error en el código del webhook
→ Revisar logs de la función handleStripeWebhook - Timeout (sin respuesta): La función tarda más de 30 segundos
→ Optimizar la función para responder más rápido - No se envía ningún evento: URL incorrecta o webhook deshabilitado
→ Verificar que el webhook esté activo en Stripe