Repository navigation
feat(mcp): Add approve_snapshot tool - #2861
Merged
Merged
Conversation
Let agents approve a preprod snapshot's visual changes through
POST /organizations/{org}/preprodartifacts/{id}/approve/ when a user
asks. A 400 from the API becomes a UserInputError with its detail.
Refs EME-1369
Co-Authored-By: Nico Hinderling <9902528+NicoHinderling@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
Contributor
📊 MCP Server Token Cost ReportSummary
Per-Tool Breakdown
Note: This measures the static overhead of tool definitions sent to LLM clients with every request. Lower is better. MCP Apps viewsEach
The budget applies to raw bytes, and the view's generator fails over it. |
Keep the triage skill unchanged and gate approve_snapshot behind a new "snapshots" skill that is off by default. Refs EME-1369 Co-Authored-By: Nico Hinderling <9902528+NicoHinderling@users.noreply.github.com>
approve_snapshot pushes the bundle to 3,954,128 bytes, about 1 KB over the 3.77 MiB budget. Raise it to 3.78 MiB, which leaves about 9 KB.
The stdio server grants every active skill by default, so it now includes snapshots.
Let the shared error handling report Sentry's 400 reason, list the project:write scope the MCP's OAuth grant actually includes, and add get_snapshot to the snapshots skill so the approval check works when only that skill is enabled. Drop a skills test the existing ones cover. Refs EME-1369
NicoHinderling
approved these changes
Dec 3, 2026
14 of 16 tasks
This branch was successfully deployed
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
approve_snapshotso an agent can approve a preprod snapshot's visual changes when a user asks. It sits behind a newsnapshotsskill ("Approve Snapshots", off by default) and requiresproject:releases. This is the write half of EME-1369; the read half is #2857.It calls
POST /api/0/organizations/{org}/preprodartifacts/{artifact_id}/approve/with{"feature_type": "snapshots"}through a newSentryApiService.approveSnapshot.@sentry/apihas no wrapper for this endpoint.201 {"detail": "Approved"}returnsresult: "approved", and200 {"detail": "Already approved"}returnsresult: "already_approved".requestJSONonly exposes the body, so the tool maps ondetail, not the status code.400, such as "This build doesn't need approval", becomes aUserInputErrorwith the API'sdetail.defaultEnabled: falsemeans the remote server's OAuth consent screen leavessnapshotsunchecked. The stdio server (sentry mcp) still grants every active skill when no--skillsflag is given, sosnapshotsis on there by default, liketriageandproject-management.The CLI's copy of the skill list (
MCP_SKILL_NAMES) and its MCP config tests now includesnapshots. Tools available to every skill now listsnapshotsin the generated definitions. The regenerated definitions also add the tool to the plugin agents'allowedTools.The
@sentry/mcp-serverbundle budget goes from 3.77 to 3.78 MiB.mainwas only 677 bytes under the budget, and this tool adds about 1.7 KB, bringing the bundle to 3,954,128 bytes. The new budget leaves about 9 KB of headroom, which is what the budget's comment intends.Refs EME-1369
via @NicoHinderling.
--
View Session [Sentry]