Skip to main content
Webhooks are delivered via HTTPS POST requests. If delivery fails, Tesouro retries webhook delivery using an exponential backoff strategy. Events are retried until delivery succeeds or the 12-hour retry limit is reached. After this period, the event is permanently marked as failed. Webhook events are delivered at least once; consumers should be idempotent.

Retry schedule

AttemptDelay (from previous)Cumulative time
1Immediate0 min
21 minute1 min
35 minutes6 min
415 minutes21 min
530 minutes51 min
61 hour1h 51min
7+2 hoursContinues at 2-hour intervals (capped)

Best practices

  1. Implement idempotency – Retries may deliver the same event multiple times. Use the applicationEventId to detect and discard duplicates. The attemptCount field indicates whether a redelivery has occurred.
  2. Respond quickly – Your endpoint must return a 200 OK within 30 seconds. For longer processing, acknowledge the webhook immediately and hand off work to an asynchronous queue.
  3. Order events correctly – Due to network latency and retries, events may arrive out of chronological order. Use the attributes.updatedTimestamp field to correctly sequence events.
  4. Verify signatures – Always verify webhook signatures before processing events.