Skip to content

Conversation

joelverhagen
Copy link
Contributor

What does this PR do?

The server.json schema has changed a couple of times since the initial release to NuGet.org. This updates to the latest schema, now with a working $schema URL :).

Docs: https://github.com/modelcontextprotocol/registry/blob/main/docs/reference/server-json/generic-server-json.md
Examples: https://github.com/modelcontextprotocol/registry/blob/main/docs/reference/server-json/generic-server-json.md#examples
Template update: dotnet/extensions#6888

NuGet.org is

GitHub issue number?

#870

Pre-merge Checklist

  • Required for All PRs
    • Read contribution guidelines
    • PR title clearly describes the change
    • Commit history is clean with descriptive messages (cleanup guide)
    • Added comprehensive tests for new/modified functionality
    • Updated servers/Azure.Mcp.Server/CHANGELOG.md and/or servers/Fabric.Mcp.Server/CHANGELOG.md for product changes (features, bug fixes, UI/UX, updated dependencies)
  • For MCP tool changes:
    • One tool per PR: This PR adds or modifies only one MCP tool for faster review cycles
    • Updated servers/Azure.Mcp.Server/README.md and/or servers/Fabric.Mcp.Server/README.md documentation
    • Validate README.md changes using script at eng/scripts/Process-PackageReadMe.ps1. See Package README
    • Updated command list in /servers/Azure.Mcp.Server/docs/azmcp-commands.md and/or /docs/fabric-commands.md
    • For new or modified tool descriptions, ran ToolDescriptionEvaluator and obtained a score of 0.4 or more and a top 3 ranking for all related test prompts
    • For new tools associated with Azure services or publicly available tools/APIs/products, add URL to documentation in the PR description
  • Extra steps for Azure MCP Server tool changes:
    • Updated test prompts in /servers/Azure.Mcp.Server/docs/e2eTestPrompts.md
    • 👉 For Community (non-Microsoft team member) PRs:
      • Security review: Reviewed code for security vulnerabilities, malicious code, or suspicious activities before running tests (crypto mining, spam, data exfiltration, etc.)
      • Manual tests run: added comment /azp run mcp - pullrequest - live to run Live Test Pipeline

@Copilot Copilot AI review requested due to automatic review settings October 17, 2025 20:20
@joelverhagen joelverhagen requested review from a team as code owners October 17, 2025 20:20
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Updates server.json template and build packaging logic to align with the latest MCP Registry server.json schema and introduce an explicit MCP registry server name property.

  • Adds McpRegistryServerName property to server project files and passes it into the packing target.
  • Updates PackServerJson.targets to serialize the new property and adjusts the template placeholders (intended) for schema changes.
  • Rewrites the server.json template to the new schema fields (name, version, transport, registryType, identifier).

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
servers/Template.Mcp.Server/src/Template.Mcp.Server.csproj Adds McpRegistryServerName property for template server packaging.
servers/Fabric.Mcp.Server/src/Fabric.Mcp.Server.csproj Adds McpRegistryServerName property for Fabric server packaging.
servers/Azure.Mcp.Server/src/Azure.Mcp.Server.csproj Adds McpRegistryServerName property for Azure server packaging.
servers/Azure.Mcp.Server/CHANGELOG.md Documents the schema update in release notes.
eng/dnx/PackServerJson.targets Extends serialization and replacement logic for new property; updates doc link.
eng/dnx/.mcp/server.json Replaces template with latest schema structure and new field names.
Comments suppressed due to low confidence (1)

eng/dnx/.mcp/server.json:1

  • The template uses $(PropertyName) placeholders, but PackServerJson.targets replaces tokens in the form "%24(PropertyName)". Because the %24-encoded placeholders are absent, the Replace(...) calls will not run for these values, causing raw (unescaped) MSBuild-expanded strings to be inserted and bypassing JsonSerializer-based escaping. Update the template placeholders to "%24(PackageDescription)", "%24(McpRegistryServerName)", "%24(PackageVersion)", "%24(PackageId)", and "%24(RepositoryUrl)" (with surrounding quotes) OR adjust the Replace patterns in the target to match the new "$(...)" form so JSON escaping is preserved.
{

@joelverhagen joelverhagen marked this pull request as draft October 17, 2025 20:31
@joelverhagen joelverhagen marked this pull request as ready for review October 17, 2025 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Untriaged

Development

Successfully merging this pull request may close these issues.

1 participant