Repository navigation
feat(mcp): Return structured output from search_replays - #2025
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
dcramer
force-pushed
the
feat/search-replays-structured-output
branch
from
November 5, 2026 21:46
ab45aed to
3aa4ec0
Compare
dcramer
force-pushed
the
feat/search-replays-structured-output
branch
from
November 5, 2026 22:20
3aa4ec0 to
d144e56
Compare
dcramer
force-pushed
the
feat/search-replays-structured-output
branch
from
November 5, 2026 22:35
d144e56 to
a4ef47e
Compare
dcramer
force-pushed
the
feat/search-replays-structured-output
branch
from
November 5, 2026 22:57
a4ef47e to
8b891ee
Compare
Base automatically changed from
feat/search-profiles-structured-output
to
main
November 5, 2026 23:19
search_replays now declares a dedicated outputSchema and returns structuredContent on every success path instead of throwing on the structured path. Replays have no requested fields or aggregates, so the payload lists replays[] with explicitly mapped fields: ID, replay URL, start time, duration in seconds, user, error/rage/dead click counts, environment, browser, releases, archive status, and previews of visited pages and trace IDs with their full counts. Leading warnings and empty-result guidance go in notes[]. Suggested actions open the first replay with get_replay_details and its first trace with get_sentry_resource, which covers the markdown's next steps. Co-Authored-By: David Cramer <[email protected]>
…ists Replace the upstream-computed user displayName (username, email, id, or IP) with explicit id, username, email, and ip fields, matching get_replay_details. The tool returns the user data Sentry stored; internal fields stay excluded. Preview at most 3 URLs, trace IDs, and releases per replay, with urlCount, traceCount, and the new releaseCount giving the totals. Co-Authored-By: David Cramer <[email protected]>
Archived replay rows carry placeholder user data ("Archived Replay" as
the id), so user is now null when isArchived is true, matching
get_replay_details. String user fields use || null so empty strings
read as missing. The mapping test pins its own user instead of reading
it from the shared replay-details fixture.
Co-Authored-By: David Cramer <[email protected]>
dcramer
force-pushed
the
feat/search-replays-structured-output
branch
from
November 5, 2026 23:20
8b891ee to
6367d24
Compare
Resolve the runSearchEvents overload conflict with #2035: keep the replays overload and use the generic runSearchEvents<TDataset> one in place of the PublicEventsDataset overload.
7 tasks done
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.
search_replaysnow declares anoutputSchemaand returnsstructuredContenton every success path, following the Structured Content policy indocs/contributing/tool-responses.md. The model now sees pretty JSON instead of markdown.Payload
searchReplaysOutputSchemaandbuildStructuredReplayResultsinreplays.tsmap replay fields explicitly:replayUrl, start time, durationisArchived{id, username, email, ip}, matching get_replay_details, instead of the upstream-computed display name. The tool returns the user data Sentry stored. Tags, SDK and other internal fields stay out, and a no-leak test checks this.useris null for archived replays, whose rows carry placeholder data ("Archived Replay" as the id).urlCount,traceCountandreleaseCountgive the totals.get_replay_detailsfor the first replay, plusget_sentry_resourcefor its first trace.runSearchEventsand exportstimeRangeSchemafromstructured.ts.Stack and merge order
feat/search-profiles-structured-output. Merge in that order; GitHub retargets each PR as its base merges.replay-details.jsonfixture. feat(tools): Add outputSchema to get_replay_details #2019 addsusername: "taylor"to that fixture, which would otherwise break this snapshot.git rebase --onto <new base> <old parent head> feat/search-replays-structured-output.toolDefinitions.jsonwill conflict along the stack and with the sibling structured-output PRs. Regenerate it on rebase withpnpm run --filter @sentry/mcp-core generate-definitions.Tokens
measure-tokenstotal is unchanged at 47,079. The description and input schema are unchanged, and the script doesn't countoutputSchema.outputSchemaadds ~629 tokens totools/list.Checks. All package-scoped, with
SENTRY_AUTH_TOKENunset:pnpm --filter @sentry/mcp-server-mocks run buildpnpm run --filter @sentry/mcp-core generate-definitions, thengit status; only the intended files changedpnpm --filter @sentry/mcp-core run tscpnpm run lintRoot
pnpm run tscwas not run because its cloudflare build uploads source maps. Evals were skipped because they need API keys.via @dcramer.
--
View Session [Sentry]