Once expanded to production-safe logic, it became 19 steps.
First 6:
Verify webhook signature (STRIPE_WEBHOOK_SECRET)
Extract event.id, subscription.customer, price.id
Ensure price.id === pro_annual_price_id
Check processed_events for event.id
Insert event.id before side effects
Fetch full customer via Stripe SDK
Snippet:
7 comments
[ 3.2 ms ] story [ 20.2 ms ] threadIncludes: - Express server + full routes - Watchdog (API drift detection, CVE scans via npm run apcher:full-scan) - Retries, idempotency, peter-evans/create-pull-request@v6 for auto PRs - `npm install && npm start` ready
$59/workflow. No subs, deploy anywhere.
Try it: apcher.dev Give me you feedback
`npm run apcher:full-scan` catches CVEs + deps upfront.
Stripe customer.subscription.created → verify → idempotency → Postgres → provision workspace → SendGrid → Slack → monitoring.
Once expanded to production-safe logic, it became 19 steps.
First 6: Verify webhook signature (STRIPE_WEBHOOK_SECRET) Extract event.id, subscription.customer, price.id Ensure price.id === pro_annual_price_id Check processed_events for event.id Insert event.id before side effects Fetch full customer via Stripe SDK Snippet:
Js id="j3m4zl"
if (!Stripe.verifyWebhookSignature(req.body, signature, process.env.STRIPE_WEBHOOK_SECRET)) { return { success: false, error: 'Invalid webhook signature' }; }
const [existingEvent] = await PostgreSQL.query( 'SELECT * FROM processed_events WHERE id = $1', [eventId] );
if (existingEvent) { return { success: true, message: 'Event already processed' }; } Generated structure: Id="s2x9pq"
my-workflow/ ├── integration.js ├── scripts/ ├── .env.example ├── apcher.lock ├── github/ └── README.md
The surprising part wasn’t the API calls — it was how much production scaffolding each “simple webhook” really needs.
Curious how others here handle idempotent webhook pipelines in production.
Current "Solution": Rent proprietary runtimes. Swap plumbing for vendor lock-in + exec tax.
Apcher: Generate resilience directly into your Node.js repo. Atomic SQL, native retries, Watchdog drift PRs.
$0 exec fees. Full export—deploy anywhere, run locally, live in your repo.
Who's brittle today?
Raw Stripe → 3x retries + idempotency + conflict DOs + rollbacks.
Apcher injects resilience into your Node.js repo. Try it for free. Test chaos locally.
What broke your last payment flow? apcher.dev