如何将 Microsoft Learn 远程 MCP 连接到 Windsurf

约 1 分钟即可把 Microsoft 的远程 MCP 服务端接入 Windsurf。如需排查 OAuth / 401 问题,可先用 OAuth 2.1 调试器体检端点。

🛡️ Official✓ VerifiedStreamable HTTPPublic · No Auth🛡️ A+~971 tok3 tools
Streamable HTTPhttps://learn.microsoft.com/api/mcp

Add to ~/.codeium/windsurf/mcp_config.json:

{
  "mcpServers": {
    "microsoft-learn": {
      "serverUrl": "https://learn.microsoft.com/api/mcp"
    }
  }
}

接入步骤

  1. 打开配置文件 — 编辑 ~/.codeium/windsurf/mcp_config.json。
  2. 添加服务端 — 在 mcpServers 中加入 "microsoft-learn": { "serverUrl": https://learn.microsoft.com/api/mcp }。
  3. 完成认证 — 无需认证——Microsoft Learn 为免密公开端点。
  4. 验证 — 在 在线 Inspector 中粘贴 https://learn.microsoft.com/api/mcp 并运行 initialize + tools/list 验证连通性。

🧰 工具预览(3)

ToolSafetyDescriptionParameters
microsoft_docs_search
~245 tok
🟢 ReadidempotentSearch official Microsoft/Azure documentation to find the most relevant and trustworthy content for a user's query. This tool returns up to 10 high-quality content chunks (each max 500 tokens), extracted from Microsoft Learn and other official sources. Each result includes the article title, URL, and a self-contained content excerpt optimized for fast retrieval and reasoning. Always use this tool to quickly ground your answers in accurate, first-party Microsoft/Azure knowledge. ## Follow-up Pattern To ensure completeness, use microsoft_docs_fetch when high-value pages are identified by search. The fetch tool complements search by providing the full detail. This is a required step for comprehensive results.query: string
microsoft_code_sample_search
~385 tok
🟢 ReadidempotentSearch for code snippets and examples in official Microsoft Learn documentation. This tool retrieves relevant code samples from Microsoft documentation pages providing developers with practical implementation examples and best practices for Microsoft/Azure products and services related coding tasks. This tool will help you use the **LATEST OFFICIAL** code snippets to empower coding capabilities. ## When to Use This Tool - When you are going to provide sample Microsoft/Azure related code snippets in your answers. - When you are **generating any Microsoft/Azure related code**. ## Usage Pattern Input a descriptive query, or SDK/class/method name to retrieve related code samples. The optional parameter `language` can help to filter results. Eligible values for `language` parameter include: csharp javascript typescript python powershell azurecli al sql java kusto cpp go rust ruby phpquery*: stringlanguage: string
microsoft_docs_fetch
~321 tok
🟢 ReadidempotentFetch and convert a Microsoft Learn documentation webpage to markdown format. This tool retrieves the latest complete content of Microsoft documentation webpages including Azure, .NET, Microsoft 365, and other Microsoft technologies. ## When to Use This Tool - When search results provide incomplete information or truncated content - When you need complete step-by-step procedures or tutorials - When you need troubleshooting sections, prerequisites, or detailed explanations - When search results reference a specific page that seems highly relevant - For comprehensive guides that require full context ## Usage Pattern Use this tool AFTER microsoft_docs_search when you identify specific high-value pages that need complete content. The search tool gives you an overview; this tool gives you the complete picture. ## URL Requirements - The URL must be a valid HTML documentation webpage from the microsoft.com domain - Binary files (PDF, DOCX, images, etc.) are not supported ## Output Format markdown with headings, code blocks, tables, and links preserved.url*: string

更多连接指南