Repository navigation
feat: accept refs filters as HTTP query parameters - #15
Merged
Merged
Conversation
GET /v1/repo/refs now accepts kind, query, author, title, since, until, sort and first alongside repo and after; other routes keep rejecting them. The INVALID_REVISION message names what resolve accepts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Background
GET /v1/repo/refsfilters were rejected by the HTTP query-parameter allowlist (INVALID_QUERY_PARAMETERS); the MCPrefstool was unaffected. Resolving a branch name with characters the service does not accept still returned a message saying tags are unsupported.Changes
internal/httpserver: the refs route also acceptskind/query/author/title/since/until/sort/first; other routes keep rejecting them, and repeated parameters are still rejected.internal/service: theINVALID_REVISIONmessage states what resolve accepts and what is rejected.docs/interfaces.md: names with unsupported characters.Risks
Only fixed parameter names on the refs route are added; values are still validated by the service.
Backward compatibility
No behavior change other than refs HTTP filters becoming usable; the error code is unchanged, only its message.
Testing
TestRefsRouteAcceptsItsFilters: filters reach service validation, repeated and unknown parameters are rejected, other routes do not accept these names.make checkand theinternal/httpserver,internal/serviceandinternal/mcpservertests pass.🤖 Generated with Claude Code