Webhook retries
If your endpoint returns non-2xx or times out, HelaMesh retries with exponential backoff:
Attempt 1 โ immediately
Attempt 2 โ 2 seconds later
Attempt 3 โ 4 seconds later
Attempt 4 โ 8 seconds later
โฆ
Attempt 8 โ 256 seconds later
After 8 attempts โ marked FAILED
FAILED webhooks can be re-driven manually from the dashboard: Webhooks โ click Redrive.
Idempotency is your responsibilityโ
The same invoiceId may arrive more than once if you returned 2xx but HelaMesh didn't see it (network blip). Always check your DB for an existing record before applying the payment.
// Bad โ double-applies on retry
await db.orders.update({
where: { helamesh_invoice_id: event.invoiceId },
data: { payment_status: 'paid' }
});
// Good โ no-op on retry
await db.orders.update({
where: {
helamesh_invoice_id: event.invoiceId,
payment_status: { not: 'paid' }
},
data: { payment_status: 'paid' }
});
Timeoutsโ
HelaMesh considers a delivery failed if your endpoint doesn't respond within 10 seconds. Keep your webhook handler fast โ acknowledge the event immediately, then do fulfillment work asynchronously.