Skip to content

fix(webhooks): acknowledge delivery after all subscribers succeed - #1731

Open
sam-goodwin wants to merge 1 commit into
mainfrom
fix/shared-webhook-delivery
Open

sam-goodwin wants to merge 1 commit into
mainfrom
fix/shared-webhook-delivery

Conversation

@sam-goodwin

Copy link
Copy Markdown
Contributor

Make the Worker's application HTTP handler a fallback for requests that no event-source listener accepts. Preserve the existing listen API and non-HTTP listener fan-out.

GitHub and Stripe subscriptions sharing an endpoint now use one signature check, one decoder, and one acknowledgement decision:

yield* Stripe.consumeEvents(
  "Events",
  { events: [Stripe.CustomerCreated] },
  sendReceipt,
);
yield* Stripe.consumeEvents(
  "Events",
  { events: [Stripe.CustomerCreated, Stripe.InvoicePaid] },
  updateLedger,
);
  • Combine event selections into the endpoint's desired configuration.
  • Run all matching subscribers and acknowledge only after every subscriber succeeds.
  • Return 503 on subscriber failure or a 30-second processing timeout. Retries can repeat successful subscribers; side effects must be idempotent.
  • Reject conflicting endpoint IDs, repositories, signing secrets, and generated binding identities instead of silently sharing incompatible receivers.

The shared acknowledgement implementation is internal. This adds no new Worker listener hook and changes neither GitHub Secrets nor Forgejo resources.

@alchemy-version-bot

Copy link
Copy Markdown
Contributor

Install the packages built from this commit:

alchemy

pnpm install https://pkg.alchemy.run/alchemy/pr:1731:a7c84fb
@alchemy.run (6)
pnpm install https://pkg.alchemy.run/@alchemy.run/better-auth/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@alchemy.run/cloudflare-runtime/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@alchemy.run/frontend-frameworks/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@alchemy.run/node-utils/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@alchemy.run/floci/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@alchemy.run/pkg/pr:1731:a7c84fb
@distilled.cloud (14)
pnpm install https://pkg.alchemy.run/@distilled.cloud/core/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/acme/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/aws/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/axiom/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/cloudflare/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/fly-io/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/github/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/hetzner/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/neon/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/prisma/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/planetscale/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/railway/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/stripe/pr:1731:a7c84fb
pnpm install https://pkg.alchemy.run/@distilled.cloud/zerossl/pr:1731:a7c84fb

Published Sep 20, 2026, 1:23 AM UTC. Expires Sep 27, 2026, 1:23 AM UTC, extended while this pull request is open.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant