Repository navigation
Conversation
config/services.yaml redefines mcp.server.builder as iTopBuilder with its own list of calls. The bundle's definition of that service starts with setServerInfo(mcp.app, mcp.version, mcp.description, mcp.icons, mcp.website_url); the redefinition left that call out, so it was never made. initialize then answered with the SDK defaults, "app" and "dev", whatever config/packages/mcp.yaml says, and the configured description, icon and website URL were never sent. Clients name the server after serverInfo.name (VS Code prefixes every tool with it), so two iTop MCP servers configured in the same client could not be told apart. iTopBuilder::setServerInfo() already exists and forwards to the SDK builder: this only adds the missing call. ServerInfoTest posts a real initialize to /_mcp and checks the reported name and version against the configuration.
There was a problem hiding this comment.
🟡 Changes recommended
Icon configuration needs normalization so responses expose the protocol’s mimeType field.
1 open issue
What changed in this PR
Connects configured server metadata to the MCP builder so initialize reports the application identity instead of SDK defaults.
Changes:
- Adds the missing
setServerInfo()service call. - Adds an HTTP regression test for the configured server name and version.
| File | Description |
|---|---|
| tests/phpunit/ServerInfoTest.php | Tests server identity returned by initialize. |
| config/services.yaml | Passes configured server metadata to the builder. |
Review effort: Balanced
| # you CAN still use autowiring: we just want to show what it looks like without | ||
| autowire: true | ||
| calls: | ||
| - setServerInfo: ['%mcp.app%', '%mcp.version%', '%mcp.description%', '%mcp.icons%', '%mcp.website_url%'] |
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.

Fixes #27.
Adds the missing
setServerInfo()call to themcp.server.builderdefinition inconfig/services.yaml, soinitializereports the name, version, description, icon and website URL configured inconfig/packages/mcp.yamlinstead of the SDK'sapp/dev.ServerInfoTestposts a realinitializeto/_mcpand checks the reported name and version against the configuration. It fails without the fix.