add-azure-mcp-tools
Add a new tool/command to any Azure MCP toolset. Full lifecycle from scaffolding through PR submission. USE WHEN: add new command, create tool, new MCP tool, scaffold command, implement operation, add azure service tool, create new toolset.
Choose how to use this skill
You do not need every option. Choose the path your AI client supports. The stable page stays the same; versioned files are immutable.
1. Native installer
This listing has no registered native installer command. Use the complete package or source fallback below, depending on what your client supports.
Do not guess an installer command or replace an existing version without reviewing the diff.
2. Complete package recommended
Download the ZIP when available. It includes SKILL.md plus the references, security notes and version metadata.
No complete ProSkills package is published for this listing yet.3. Prompt-only
Copy the prompt above when the agent can read the stable page or when you want to adopt the workflow without installing a skill.
Need only the instruction file?
Download SKILL.md only if your client requires a single file. The complete ZIP is safer for a full installation because it preserves the references and release context.
No path installs or executes anything by itself. Your agent still needs access to the project files. Before updating, compare the installed version and review the diff.
// RATINGS
Not yet listed on ClawHub or SkillsMP
// README
🌟 Microsoft MCP Servers
📘 What is MCP?
Model Context Protocol (MCP) is an open protocol that standardizes how applications provide context to large language models (LLMs). It allows AI applications to connect with various data sources and tools in a consistent manner, enhancing their capabilities and flexibility. MCP follows a client-server architecture:
- MCP Hosts: Applications like AI assistants or IDEs that initiate connections.
- MCP Clients: Connectors within the host application that maintain 1:1 connections with servers.
- MCP Servers: Services that provide context and capabilities through the standardized MCP.
For more details, visit the official MCP website.
📁 Which MCP Servers are built from this repository?
This repository contains core libraries, test frameworks, engineering systems, pipelines, and tooling for Microsoft MCP Server contributors to unify engineering investments; and reduce duplication and divergence:
| MCP Server | README | Source Code | CHANGELOG | Releases | Documentation | Troubleshooting | Support |
|---|---|---|---|---|---|---|---|
| Azure MCP | Azure MCP README | Azure MCP Source Code | Azure MCP CHANGELOG | Azure MCP Releases | Azure MCP Documentation | Azure MCP Troubleshooting | Azure MCP Support |
| Microsoft Fabric MCP | Fabric MCP README | Fabric MCP Source Code | Fabric MCP CHANGELOG | Fabric MCP Releases | Fabric Documentation | Fabric MCP Troubleshooting | Fabric MCP Support |
📚 Which MCP Servers are available from Microsoft?
Azure
- REPOSITORY: microsoft/mcp
- DESCRIPTION: All Azure MCP tools in a single server. The Azure MCP Server implements the MCP specification to create a seamless connection between AI agents and Azure services. Azure MCP Server can be used alone or with the GitHub Copilot for Azure extension in VS Code.
- CATEGORY:
CLOUD AND INFRASTRUCTURE - TYPE:
Local - INSTALL:
✨ Microsoft Foundry
- DOCUMENTATION: Get started with Foundry MCP Server
- DESCRIPTION: A Model Context Protocol server for Microsoft Foundry, providing a unified set of tools for models, knowledge, evaluation, and more.
- CATEGORY:
CLOUD AND INFRASTRUCTURE - TYPE:
REMOTE-https://mcp.ai.azure.com - INSTALL:
Azure Resource Manager
- REPOSITORY: Azure/Azure-Resource-Manager-MCP
- DESCRIPTION: A Model Context Protocol server with tools to use Azure Resource Graph to retrieve and filter information about Azure resources in a customer's subscription, and tools to manage ARM template deployments.
- CATEGORY:
CLOUD AND INFRASTRUCTURE - TYPE:
REMOTE-https://mcp.management.azure.com - INSTALL:
Azure DevOps
- REPOSITORY: Azure DevOps MCP Server
- DESCRIPTION: This TypeScript project provides a local MCP server for Azure DevOps, enabling you to perform a wide range of Azure DevOps tasks directly from your code editor.
- CATEGORY: `
// HOW IT'S BUILT
// FILES
2 files shipped with this skill. Inline text is the catalog copy. The upstream link is the source repository.
.github/skills/add-azure-mcp-tools/SKILL.md7.9 KBupstream ↗
--- name: add-azure-mcp-tools description: 'Add a new tool/command to any Azure MCP toolset. Full lifecycle from scaffolding through PR submission. USE WHEN: add new command, create tool, new MCP tool, scaffold command, implement operation, add azure service tool, create new toolset.' argument-hint: 'Describe the new tool (e.g., "add storage container delete command" or "create new KeyVault toolset with secret get command")' --- # Add a New Tool to Azure MCP ## Purpose Step-by-step workflow for adding a new command to any Azure MCP toolset. Each phase has an explicit **gate** — do not proceed until the gate passes. ## Decision: New Toolset or Existing? Before starting, determine: - **Adding to existing toolset?** → Skip to Phase 1. - **Creating a new toolset?** → Complete Phase 0 first. **⚠️ CRITICAL: Does your command interact with Azure resources?** | | Azure Service Commands | Non-Azure Commands | |---|---|---| | **Examples** | ACR Registry List, SQL Database List, Storage Account Get | CLI wrappers, Best Practices, Documentation tools | | **test-resources.bicep** | ✅ Required | ❌ Skip | | **test-resources-post.ps1** | ✅ Required (even if basic) | ❌ Skip | | **RBAC role assignments** | ✅ Required | ❌ Skip | | **Live tests** | ✅ Required (recorded) | ❌ Skip | | **Unit tests** | ✅ Required | ✅ Required | --- ## Security Requirements > **Terminology note:** In this repo, _tool_ refers to the MCP-exposed capability and _command_ refers to the underlying C# command class implementation. Both terms appear in the codebase and docs. **All tool inputs are untrusted.** These requirements apply at every phase and are not optional. ### Input Validation - Validate inputs against the **specific naming rules of the Azure resource** being targeted (length, allowed characters, casing). Do not apply a generic blocklist — Azure resource naming rules vary significantly by service. - Example: Storage account names are 3–24 lowercase alphanumeric characters only. - Example: Resource group names allow letters, digits, underscores, hyphens, and periods up to 90 characters. - Reference: [Azure naming rules and restrictions](https://learn.microsoft.com/azure/azure-resource-manager/management/resource-name-rules) - Use `ValidateOptions` for semantic constraints beyond nullability (name length, format, mutual exclusivity, and allowed value sets). Only reject characters that are provably invalid for the specific resource type. This applies to both the new two-generic `SubscriptionCommand` pattern and the legacy one-generic pattern — see the `ValidateOptions` override guidance in [Phase 1d](#1d-command-class). - Prefer SDK/runtime validators and deterministic checks first (`Length`, explicit allowed-value sets, character/category checks). ### Secure Logging - **Never log raw option objects** (`{@Options}`) — they may contain secrets, connection strings, or PII. - Log only individually named, known-safe parameters. For example: `options.Subscription`, `options.ResourceGroup`, `Name`. - Do not include sensitive field values in error messages returned to callers. - Strip or redact secret values before surfacing exception details. ```csharp // ✅ Log only known-safe, individually named fields _logger.LogError(ex, "Error in {Operation}. Subscription: {Subscription}, ResourceGroup: {ResourceGroup}", Name, options.Subscription, options.ResourceGroup); // ❌ Never log the whole options object — it may contain keys, connection strings, or PII _logger.LogError(ex, "Error in {Operation}. Options: {@Options}", Name, options); // ❌ Never surface raw exception bodies to callers — they may contain tokens or account metadata return $"Request failed: {requestFailedException.Message}"; // may include auth headers ``` ### Safe Downstream Interactions - **Never concatenate user input directly without prior validation** into URLs, shell commands, resource identifiers, query strings, etc. - Use `EndpointValidator` from `Microsoft.Mcp.Core.Helpers` to guard all endpoint usage — choose the method that matches your scenario: - **Azure service data-plane endpoint** (endpoint derived from a resource name, e.g. storage account, ACR, App Config): call `EndpointValidator.ValidateAzureServiceEndpoint(endpoint, serviceType, AzureService.CloudConfiguration.ArmEnvironment, executingToolNamespaceName)` before constructing the client. Pass the command's top-level tool namespace (which may differ from `serviceType`) so the namespace-scoped emergency override can be applied. This enforces the correct per-cloud domain suffix (e.g. `.blob.core.windows.net` / `.blob.core.chinacloudapi.cn`) and HTTPS. - **User-supplied URL to a known external service** (e.g. a GitHub URL the user provides): call `EndpointValidator.ValidateExternalUrl(url, allowedHosts)` with an explicit allowlist of permitted hosts. - **User-supplied target URL with no known domain** (e.g. a load-test target the user controls): call `EndpointValidator.ValidatePublicTargetUrl(url, logger, executingToolNamespaceName)`, which enforces HTTPS/HTTP-only schemes, rejects private/reserved IP ranges, rejects reserved hostnames, and resolves DNS to catch hostnames that map to internal IPs. Pass the command's top-level tool namespace so the namespace-scoped emergency override can be applied. - For services that *construct* the endpoint internally (not from user input), use the cloud-type switch pattern (see [Phase 1c: Service Implementation](#1c-service-interface-and-implementation)) — `EndpointValidator` is not required in that case but `ValidateAzureServiceEndpoint` can be added as a defense-in-depth layer. - **Control-plane operations** (ARM resource creation, RBAC assignments, policy etc.) do not need `EndpointValidator` because they go through the typed Azure SDK ARM client. Construct ARM resource IDs using `ResourceIdentifier` or collection helpers — never by string-interpolating subscription/resource-group/resource-name directly into a raw ARM path. - For new commands and services, always pass `CancellationToken` as the final parameter to all async downstream calls and propagate it throughout — never substitute `CancellationToken.None` or `default` at call sites. - Fail closed: if tenant, subscription, or resource context is ambiguous, return an explicit validation error and require the caller to specify the value. Do not silently pick a default. ### Secure Resource Provisioning Defaults Tools that create or create-or-update Azure resources must produce a secure configuration when the caller omits security-related options. Do not rely on an Azure service's current defaults. Explicitly set every supported security property in the typed SDK request model so a service-side default change cannot make the tool less secure. - Disable public network access, public endpoints or IPs, and anonymous access by default where the service supports it. Do not add public connectivity merely to make a newly created resource immediately reachable. - Require encrypted transport by default: enable HTTPS-only access, disable non-TLS endpoints or ports, and set the minimum TLS version to the service's current secure recommendation (at least TLS 1.2). A weaker transport setting requires an explicit opt-in. - Prefer Managed Identity and RBAC for authentication. Enable a system-assigned identity or accept a user-assigned identity where supported, and disable local or key-based authentication when possible. For service-to-service access, do not make connection strings, account keys, or API keys the default path. - For create-or-update operations, omitted security options must never weaken an existing resource. Apply secure defaults when creating a resource; when updating one, preserve its current security settings unless the caller explicitly requests a supported downgrade. A tool may expose a less secure behavior for a legitimate compatibility or development scenario, but only as a deliberate caller choice: - Use a narrowly scoped option whREADME.mdupstream ↗
Contents are not inlined in the catalog. Open the upstream file.
Plain-text copy, no login: /skill-bundles/microsoft-mcp-github-skills-add-azure-mcp-tools.md