Skip to content

chore: marketplace api - #49

Merged
callicles merged 2 commits into
mainfrom
nicolas/api-marketeplace
Apr 6, 2026
Merged

chore: marketplace api#49
callicles merged 2 commits into
mainfrom
nicolas/api-marketeplace

Conversation

@callicles

@callicles callicles commented Apr 6, 2026

Copy link
Copy Markdown
Contributor

Note

Medium Risk
Introduces a new externally-facing webhook route and refactors signature verification logic; mistakes could allow spoofed events or drop valid deliveries in production.

Overview
Adds a new POST /api/webhook/marketplace handler for GitHub marketplace_purchase events that verifies signatures using GITHUB_MARKETPLACE_WEBHOOK_SECRET and records each accepted action to the audit trail (marketplace.*).

Refactors GitHub webhook signature validation by moving env-var lookup/normalization and error responses into verifyWebhookSignatureFromEnv (in lib/github/webhook-signature.ts), and updates the existing CLA bot webhook route to use this shared helper with GITHUB_WEBHOOK_SECRET (removing the route-local verification code).

Reviewed by Cursor Bugbot for commit 6b62b48. Bugbot is set up for automated code reviews on this repo. Configure here.

@vercel

vercel Bot commented Apr 6, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
v0-cla-bot-application Ready Ready Preview, Comment, Open in v0 Apr 6, 2026 0:17am

Request Review

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 70995a5. Configure here.

Comment thread app/api/webhook/marketplace/route.ts Outdated
@callicles
callicles marked this pull request as ready for review April 6, 2026 00:31
@callicles
callicles merged commit 061973e into main Apr 6, 2026
13 checks passed
@callicles
callicles deleted the nicolas/api-marketeplace branch April 6, 2026 00:32
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