Menu

1 / 2

I Built a Stripe-Grade Webhook Delivery System for NestJS (Open Source)

DEV Community·Saifuddin Tipu·6 months ago
#YX5keufj
#nestjs#node#typescript#webdev#webhook
Reading 0:00
15s threshold

Every SaaS app eventually needs to send webhooks. And every team eventually learns the hard way that "just HTTP POST it" isn't enough.

I've seen it go wrong the same way every time:

A customer's endpoint is down at 2am. The webhook fires once, gets a 503, and silently disappears.

A developer hardcodes the same signing secret for every customer. One leak exposes all of them.

Support opens a ticket: "We never received the payment webhook." Nobody can prove whether it was sent, what the response was, or whether it should be retried.

So I built nestjs-webhook-sender — a production-ready NestJS module that handles all of this properly.

What it does

Your Service │ │ webhookSenderService.send({ url, payload, secret }) ▼ ┌──────────────────────────┐ │ BullMQ Queue │ ← persisted in Redis, survives restarts └──────────────────────────┘ │ │ Worker picks up job ▼ ┌──────────────────────────┐ │ Signs payload (HMAC) │ │ POSTs via axios │ │ Checks response status │ └──────────────────────────┘ │ ├── 2xx → ✅ Logged…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.