Skip to content
hookdeck avatar

Webhook Handler Patterns

Generic webhook handler guidance covering verification order, idempotency, retries, and Express, Next.js, and FastAPI gotchas.

CCM score
45 of 100
skills.sh installs
466
GitHub stars
104
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers the handler sequence: verify the signature on the raw body, parse the payload, then handle the event idempotently
  • Includes reference guides for idempotency, error handling and response codes, retry schedules, out-of-order and replayed events, and three frameworks
  • Provides a response-code table mapping 2xx, 4xx, 5xx, and 429 to provider retry behavior, plus a five-step idempotency checklist
  • Designed for developers building webhook handlers in Express, Next.js, or FastAPI, with links to provider-specific skills

Install

$ npx -y skills add hookdeck/webhook-skills --skill webhook-handler-patterns -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Webhook Handler Patterns

When to Use This Skill

  • Following the correct webhook handler order (verify → parse → handle idempotently)
  • Implementing idempotent webhook handlers
  • Handling errors and configuring retry behavior
  • Handling events that arrive out of order or are replayed after an outage
  • Understanding framework-specific gotchas (raw body, middleware order)
  • Building production-ready webhook infrastructure

Resources

Handler Sequence

Best Practices

Framework Guides

Details

Repository
github.com/hookdeck/webhook-skills
Category
Backend & APIs
First seen
Jun 3, 2026

Questions

What does the webhook-handler-patterns skill do?

webhook-handler-patterns gives an agent best practices for webhook handlers. It covers the handler sequence of verifying the signature first, parsing the payload second, and handling events idempotently third, plus idempotency, error handling, retry logic, and out-of-order or replayed events.

Which frameworks does webhook-handler-patterns cover?

webhook-handler-patterns includes framework guides for Express, Next.js App Router, and FastAPI. It covers framework-specific issues such as raw body handling and middleware order.

How do I install the webhook-handler-patterns skill?

Run npx -y skills add hookdeck/webhook-skills --skill webhook-handler-patterns -y in your project. Once installed, the agent can follow the handler sequence and idempotency checklist when you implement webhook handlers.

Which skills are related to webhook-handler-patterns?

webhook-handler-patterns links to provider-specific skills such as stripe-webhooks, shopify-webhooks, and github-webhooks, plus hookdeck-event-gateway for webhook infrastructure. Use those alongside it when you need provider signature verification or delivery handling.

More from hookdeck/webhook-skills

All 7

Similar to Webhook Handler Patterns

More Backend & APIs