Migrate MCP registry from v0 to v0.1 API specification#11960
Merged
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
This was referenced Jan 26, 2026
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Review MCP registry lookup and package resolution support
Migrate MCP registry from v0 to v0.1 API specification
Jan 26, 2026
Contributor
|
@copilot add tests against live registry. |
- Add TestMCPRegistryClient_LiveSearchServers with subtests: - search_all_servers: validates fetching and parsing all servers - search_with_query: tests filtering servers by query string - verify_transport_types: checks support for different transport types - Add TestMCPRegistryClient_LiveGetServer with subtests: - get_github_server: retrieves and validates actual server from registry - get_nonexistent_server: verifies error handling for missing servers - Add TestMCPRegistryClient_LiveResponseStructure with subtests: - validate_v0.1_fields: confirms parsing of packageArguments, environmentVariables, runtimeHint, repository - validate_transport_parsing: validates transport type extraction All tests skip gracefully on network restrictions and pass with live API Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Contributor
Author
Added comprehensive live integration tests in commit 6b3982b. The new test file TestMCPRegistryClient_LiveSearchServers:
TestMCPRegistryClient_LiveGetServer:
TestMCPRegistryClient_LiveResponseStructure:
All tests skip gracefully on network restrictions and pass with the live v0.1 API. |
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.
The MCP registry client was using the deprecated v0 API endpoint. The v0.1 specification introduces a significantly different response structure and field naming conventions per the official OpenAPI schema.
Changes
API Endpoint
https://api.mcp.github.com/v0→https://api.mcp.github.com/v0.1Response Structure
Before (v0):
{ "servers": [{ "name": "example/server", "status": "active", "packages": [{ "registry_type": "npm", "transport": {"type": "stdio"} }] }] }After (v0.1):
{ "servers": [{ "server": { "name": "example/server", "packages": [{ "registryType": "npm", "transport": {"type": "stdio"} }] }, "_meta": { "io.modelcontextprotocol.registry/official": { "status": "active" } } }] }Type System Updates (
mcp_registry_types.go)ServerResponsewrapper withserverand_metafieldsregistry_type→registryType,runtime_hint→runtimeHint, etc.Transportfrom string to objectRepositoryandTransportArgumenttype with additional fields from specParsing Logic (
mcp_registry.go)SearchServersandGetServerto unwrap nested response structurestatusto_meta["io.modelcontextprotocol.registry/official"]["status"]Tests
mcp_registry_live_test.go) that validate against the production registry:TestMCPRegistryClient_LiveSearchServers: Tests fetching and filtering servers from live APITestMCPRegistryClient_LiveGetServer: Tests retrieving specific servers with complete metadataTestMCPRegistryClient_LiveResponseStructure: Validates v0.1 field parsing with real dataOriginal prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.