Repository navigation
[factory] hookgres/mcp-events: MCP Events webhook delivery (SEP-3415) — pr-open - #61
Open
NickolasBenakis wants to merge 2 commits into
Open
NickolasBenakis wants to merge 2 commits into
NickolasBenakis wants to merge 2 commits into
Conversation
Handles events/list, events/subscribe and events/unsubscribe for webhook mode, verifies callback endpoints with a signed challenge, and emit() queues an event per matching subscription inside the caller's transaction. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e-limit Fixes from review: an advisory lock stops concurrent subscribes from creating duplicate endpoints and unsubscribe removes all of them; the fetch passthrough is no longer allowed (it would skip delivery-time address checks); the challenge response is read with a size cap; verification POSTs are rate-limited per host; arguments are capped at 4 KB; deleteExpired uses deleteEndpoint; deliveryStatus.active reflects suspension; invalid callback addresses map to InvalidParams. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
NickolasBenakis
marked this pull request as ready for review
November 13, 2026 21:34
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
hookgres/mcp-events: the server side of webhook delivery for MCP Events (SEP-3415, draft). Stacked on #60.handle()answersevents/list,events/subscribeandevents/unsubscribe. Poll and push answerUnsupported.whsec_and the event name is known. The subscription id is derived from(principal, url, name, arguments).verificationchallenge, cached per(principal, url)and rate-limited per host, or with an allowlist (verify).deliveryStatus.emit(name, data, { client })queues one message per matching subscription, inside the caller's transaction if one is passed. Delivery is Hookgres: Standard Webhooks signatures,X-MCP-Subscription-Id, 5 attempts over about 8 minutes,410/413final, no redirects, private addresses blocked at delivery time.docs/guides/mcp-events.md, including what isn't covered yet (cursor replay,gap/terminatedenvelopes,inputSchemavalidation).Verification
pnpm typecheck,pnpm lint,pnpm test: 364 tests pass, 17 of them intest/mcp-events.test.ts.SIGKILLand restart.Decision Log
hookgres_mcp_events), with the subscription id astenantId, sowebhook-idis unique per subscription.disableEndpointAfterMs: null): disabling fails queued deliveries, while the SEP's suspension pauses them. TTL expiry does the cleanup.hookgrespassthrough excludesfetch, because a custom fetch would turn off delivery-time address checks.arguments, anddeleteExpired()going throughdeleteEndpoint.Follow-ups
gapandterminatedenvelopes.inputSchemavalidation ofarguments.🤖 Generated with Claude Code