Skip to content

[WAF tool] Enhance get command to act as list#2020

Merged
sriramkakara merged 11 commits intomainfrom
users/skakara/waf-service-list
Mar 13, 2026
Merged

[WAF tool] Enhance get command to act as list#2020
sriramkakara merged 11 commits intomainfrom
users/skakara/waf-service-list

Conversation

@sriramkakara
Copy link
Copy Markdown
Member

@sriramkakara sriramkakara commented Mar 12, 2026

What does this PR do?

Enhance wellarchitectedframework_serviceguide_get command to:

  1. Act as a list command as well similar to existing patterns. This reduces the number of tools.
  2. Add a service layer to read from the resources files.

Screenshots of the behavior

First made a GET call without any --service param to discover the available service names.

image

Then made parallel GET calls with specific --service param values.

image

GitHub issue number?

Issue 1927

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
    • Run .\eng\scripts\Update-AzCommandsMetadata.ps1 to update tool metadata in azmcp-commands.md (required for CI)
    • 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 tools with new names, including new tools or renamed tools, update consolidated-tools.json
    • For renamed tools, follow the Tool Rename Checklist and tag the PR with the breaking-change label
    • 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

@sriramkakara
Copy link
Copy Markdown
Member Author

/azp run mcp - pullrequest - live

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Copy Markdown
Contributor

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

Adds a new wellarchitectedframework_serviceguide_list MCP command to return Azure Well-Architected Framework service-guide links for multiple services, sharing lookup logic via a new IServiceGuideService.

Changes:

  • Introduces ServiceGuideListCommand (+ options) and wires it into the WellArchitectedFramework area setup.
  • Extracts service guide URL resolution / supported-services listing into IServiceGuideService + ServiceGuideService, and updates ServiceGuideGetCommand to use it.
  • Adds unit tests and updates server docs/metadata (consolidated-tools.json, azmcp-commands.md, e2e prompts, README) for the new tool.

Reviewed changes

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

Show a summary per file
File Description
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/Commands/ServiceGuide/ServiceGuideListCommand.cs New list subcommand implementation producing guidance/not-available sections.
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/Options/ServiceGuide/ServiceGuideListOptions.cs Options model for list command (--services).
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/Options/WellArchitectedFrameworkOptionDefinitions.cs Adds --services option + refines help text.
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/Services/ServiceGuide/IServiceGuideService.cs New abstraction for service guide URL lookup and supported service listing.
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/Services/ServiceGuide/ServiceGuideService.cs New embedded-resource-backed implementation with static caching + normalization.
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/Commands/ServiceGuide/ServiceGuideGetCommand.cs Refactors get command to use IServiceGuideService and updated messaging.
tools/Azure.Mcp.Tools.WellArchitectedFramework/src/WellArchitectedFrameworkSetup.cs Registers the new service + list command with DI and command group.
tools/Azure.Mcp.Tools.WellArchitectedFramework/tests/.../Commands/ServiceGuide/ServiceGuideListCommandTests.cs Unit tests for list command behavior and input parsing.
tools/Azure.Mcp.Tools.WellArchitectedFramework/tests/.../Services/ServiceGuide/ServiceGuideServiceTests.cs Unit tests for lookup normalization, mapping, and basic concurrency safety.
tools/Azure.Mcp.Tools.WellArchitectedFramework/tests/.../Resources/ServiceGuides/ServiceGuidesJsonSchemaTests.cs Validates embedded service-guides.json schema and invariants (URLs/variations).
tools/Azure.Mcp.Tools.WellArchitectedFramework/tests/.../Commands/ServiceGuide/ServiceGuideGetCommandTests.cs Updates get tests for injected service + revised response wording.
servers/Azure.Mcp.Server/src/Resources/consolidated-tools.json Adds the new tool name to consolidated tool list.
servers/Azure.Mcp.Server/docs/e2eTestPrompts.md Adds e2e prompts for wellarchitectedframework_serviceguide_list.
servers/Azure.Mcp.Server/docs/azmcp-commands.md Documents the new CLI surface for serviceguide list.
servers/Azure.Mcp.Server/README.md Updates example prompts for Well-Architected Framework usage.

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 12, 2026

@sriramkakara I've opened a new pull request, #2021, to work on those changes. Once the pull request is ready, I'll request review from you.

Comment thread servers/Azure.Mcp.Server/docs/azmcp-commands.md Outdated
@sriramkakara sriramkakara changed the title Add wellarchitectedframework_serviceguide_list command Enhance wellarchitectedframework_serviceguide_get command to act as a list command as well Mar 13, 2026
@sriramkakara sriramkakara changed the title Enhance wellarchitectedframework_serviceguide_get command to act as a list command as well Enhance WAF get command to act as list Mar 13, 2026
@sriramkakara sriramkakara changed the title Enhance WAF get command to act as list [WAF tool] Enhance get command to act as list Mar 13, 2026
@sriramkakara sriramkakara requested a review from Copilot March 13, 2026 02:51
Copy link
Copy Markdown
Contributor

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

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

Comment thread servers/Azure.Mcp.Server/README.md Outdated
Copy link
Copy Markdown
Contributor

@alzimmermsft alzimmermsft left a comment

Choose a reason for hiding this comment

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

Please add a CHANGELOG entry by using /eng/scripts/New-ChangelogEntry.ps1 from the root of the repo.

Comment thread servers/Azure.Mcp.Server/docs/e2eTestPrompts.md
Comment thread servers/Azure.Mcp.Server/README.md
@github-project-automation github-project-automation Bot moved this from Untriaged to In Progress in Azure MCP Server Mar 13, 2026
@sriramkakara sriramkakara merged commit 09d84c1 into main Mar 13, 2026
15 checks passed
@sriramkakara sriramkakara deleted the users/skakara/waf-service-list branch March 13, 2026 21:22
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Azure MCP Server Mar 13, 2026
colbytimm pushed a commit to colbytimm/microsoft-mcp that referenced this pull request Apr 20, 2026
* Add wellarchitectedframework_serviceguide_list command

* Add wellarchitectedframework_serviceguide_list command

* Address copilot comments

* Remove list command

* Make --service param optional

* Address copilot comments

* Address copilot comments

* Addressed comments

* Fix lint

* Add changelog entry for WAF tool enhancement

* Add changelog entry for WAF tool enhancement

---------

Co-authored-by: Sriram Kakara <skakara@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants