Repository navigation
Add outbound webhooks - #1
Merged
Merged
Conversation
relay.outbound.{consumers,eventTypes,endpoints,messages,recoveryTasks}
for the /v1/outbound API, with camelCase aliases for endpoint and message
params, and examples/outbound.ts, which the tests run and the Webhook Relay
dashboard shows as its TypeScript snippet.
Regenerates the swagger and generated client from the backend. make openapi
now runs npm run openapi: it passed --extract-request-params, which
generates a client that the resources don't compile against.
rusenask
marked this pull request as ready for review
September 27, 2026 10:55
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_96bc4eaa-53a4-47d5-bb60-3f0eb1be3605) |
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 the outbound webhooks API (
/v1/outbound, pilot) to the SDK asrelay.outbound: send signed webhooks to your own customers.relay.outbound.consumers.upsert,relay.outbound.eventTypes.upsert, plus list/get/delete.relay.outbound.endpoints.create(returns the signing secret), update, pause/resume,rotateSecret/revealSecret, anddeliveries.retry/recover/replayMissingstart a background recovery task.relay.outbound.messages.publish(params, { idempotencyKey }),get(with deliveries and attempts),list.relay.outbound.recoveryTasks.getreports recovery progress.eventTypes,autoDisable,functionId,eventType,eventId) as well as snake_case.examples/outbound.tsis a runnable example.test/outbound.test.tsruns it, and the Webhook Relay dashboard shows its marked region as the TypeScript snippet.swagger/swagger.yamlandsrc/generated/api.tsare regenerated from the backend branch that adds these endpoints. Most of that diff is swagger drift that had built up since the last refresh.make openapinow callsnpm run openapi. It used to pass--extract-request-params, which generates a client the existing resources don't compile against.Keep this as a draft, and don't publish a release, until the backend change (rusenask/webhookrelay#1073) is deployed; the endpoints don't exist in production before that.
Checks run locally:
npm run typecheck,npm test(62 tests),npm run build, and a typecheck ofexamples/outbound.ts.🤖 Generated with Claude Code
Note
Medium Risk
Large new API surface touching signing secrets and idempotency, but changes are additive and depend on backend deployment before production use.
Overview
Adds outbound webhooks (pilot
/v1/outbound) to the public SDK asrelay.outbound, so apps can register customer consumers/endpoints, publish signed events, and inspect or recover deliveries.The new facade in
src/resources/outbound.tscovers consumers, event types, endpoints (create with signing secret, pause/resume, secret rotate/reveal, deliveries,retry/recover/replayMissing), messages (publishwith optionalIdempotency-Key), and recovery tasks. Request params accept camelCase via new helpers inparams.ts; response types live intypes.ts.WebhookRelayand the package barrel export the resource classes.Docs and examples: README section,
AGENTS.mdlayout notes, runnableexamples/outbound.ts(dashboard snippet region), andtest/outbound.test.tsasserting HTTP paths/bodies. Vitest resolves@webhookrelay/sdkto source so tests can import the example.Build:
make openapinow runsnpm run openapiinstead of invoking swagger-typescript-api directly (drops--extract-request-params, which broke the hand-written resources against the generated client).Reviewed by Cursor Bugbot for commit b822b13. Configure here.