All packsWebhook Durability & ReplaySolve
nextjs 16 route handler params promise await webhook
In Next 16, a route handler's params argument is a Promise -- awaiting it isn't optional
Next.js 16's route handler context.params is a Promise, not a plain object -- forgetting to await it is the most common Next 15/16 route error, and it silently breaks provider routing (D16).
This is one of the things Webhook Durability & Replay already handles. Receive webhooks without losing, duplicating or misordering them when the sender retries.
Is this you?
Code written against the pre-16 route handler signature -- destructuring params directly as a plain object -- either fails a type check or silently receives a Promise where a string was expected, breaking the [provider] segment the whole webhook route depends on to route Stripe, Shopify, Apple, Play, and Resend deliveries to the right adapter.
Why this one is easy to get wrong
Route handler params being a synchronous object was true for years across App Router versions, and a lot of indexed Next.js examples and a model's own training data still show it that way -- the change to a Promise in Next 16 is a framework-version fact that has to be read from the current docs, not inferred from how route handlers have always looked.
What you get instead
D16 pins the exact signature: POST(req: Request, ctx: { params: Promise<{ provider: string }> }), awaited before use. Route handlers additionally use only Web-standard Request/Response with no next/server import at all, specifically so the acceptance suite's route tests can invoke POST directly without spinning up a server -- the same reasoning email-deliverability's own Svix route handler is built around.
Source: ARCHITECTURE.md D16 — checkable in the pack you receive
How you actually use this
You don’t install a library or wire up an SDK. Your own coding agent builds the code in your project, and you keep it — no runtime dependency on us.
Step 1
Download and unzip
You get a folder: the docs that tell an agent what to build, a starting skeleton, and the test suite that decides when it's done.
Step 2
Open it in Claude Code or Cursor
Point your coding agent at the folder. Nothing to install, no account with us, no API key.
Step 3
Paste one prompt
The pack contains the exact prompt. Paste it as your first message and leave it alone — it works through the build itself, choosing a cheaper or stronger model per task.
Step 4
Run ./verify.sh
One command. It prints a pass or fail for every check. Green means the build is done — the same script we ran to produce the receipt on this page.
Typical build: about 40 minutes of your agent working, mostly unattended. Then you integrate the working module into your app the way you would any code you’d written yourself.
Why you can believe this
3 of 3 runs passedWe ran this pack from an empty folder 3 times and published exactly what happened — every check, the model, the token cost, the wall time. Not a testimonial, and not our opinion: the same verify.sh you run yourself. Read the full receipt →