MCP Server 建立指南
MCP Server 建立指南
設計 MCP Server 的工具介面、schema 與外部服務連接。
Microsoft · 官方來源 · AI 與 Agents
來源狀態
可用來源
資源類型
Skill
與類似 Skill 有什麼不同?
- MCP 整合
MCP Integration 著重連接與配置既有 MCP 服務;MCP Builder 著重實作服務端工具與 schema。
來源描述的能力
這些是來源描述的可能操作,不代表 2lus 已授予權限或已測試。
尚未列出能力,請審查原始來源。
這個 Skill 是什麼?
從服務契約建立 Agent 可用的 MCP tools;與把既有 server 接入 plugin 的 MCP Integration 不同。
可以做什麼?何時適合使用?
- 提供內部庫存查詢工具。
- 為既有 API 設計 MCP schema。
- 改善工具錯誤訊息與分頁結果。
如何使用
- 列出外部 API、資料敏感度與授權方式。
- 選語言和 transport,設計命名、input/output schema 及錯誤契約。
- 先建立最小唯讀工具與驗收計畫,再依批准範圍實作。
使用前你需要準備
- Agent 使用情境
- 服務契約與授權範圍
你可以替換:
[agent]、[tool name]
環境與相依需求
- 來源涵蓋 TypeScript MCP SDK、Python FastMCP 與 C#/.NET SDK;需相應工具鏈及獲准的服務存取。
使用範例與 Prompt
以下是 2lus 撰寫的示範需求;請替換為你有權處理的檔案與專案,不代表已執行或保證結果。
入門
為內部庫存查詢草擬一個唯讀 MCP tool,列必要輸入和錯誤。
實務
設計 inventory server 的 tools、schema、分頁和最小權限,不連線正式系統。
進階
比較 stdio 與 Streamable HTTP 的部署和認證需求,規劃可漸進探索的工具組及跨租戶拒絕案例。
實用提醒
- 讓工具名稱描述動作,輸出保留分頁和明確錯誤。
限制與注意事項
- Client 的工具探索能力不同;建立 server 不等於所有 Agent 已相容。
安全注意事項
- 授權與租戶邊界須在 server 強制執行,不能只靠描述文字。
使用與設定
README 的選擇式安裝方式;只選需要的 Skill。此處只能複製,並非安裝 SDK 相依套件。
npx skills add microsoft/skills官方文件 ↗
支援平台
GitHub Copilot — 文件記載,未做實機相容性測試 官方文件 ↗
來源與授權
來源查核日期(非安全認證): 2026-09-29
MIT
原始來源 ↗ 授權條款 ↗ 官方文件 ↗相關 Skills
使用第三方 Skill 前,請先檢查來源、權限與執行內容。安裝指令只供查看與複製,不會由 2lus 執行。
2lus AI Skills Library 提供 Skill 的整理與使用導覽。第三方 Skill 的內容、授權與可用性以原始來源為準。使用或安裝前,請自行確認其權限與執行內容。
MCP Builder
Design MCP server tools, schemas and external-service contracts.
Microsoft · Official source · AI & Agents
Source status
Active source
Resource type
Skill
How is this different from similar skills?
- MCP Integration
MCP Integration connects and configures existing services; MCP Builder implements server tools and schemas.
Documented capabilities
These are operations described upstream, not permissions granted or tested by 2lus.
Capabilities not declared here; review the original source.
What is this skill?
Build tools exposed by a server, distinct from configuring an existing server inside a plugin through MCP Integration.
Use cases and when to use it
- Expose read-only inventory lookup.
- Wrap existing APIs with MCP schemas.
- Improve pagination and actionable errors.
How to use it
- List APIs, data sensitivity and authorization.
- Choose language/transport and define names, schemas and errors.
- Start with a minimal read-only tool and acceptance plan before authorized implementation.
What you need
- Agent use cases
- Service contracts and authorized scope
You can replace:
[agent], [tool name]
Environment and dependencies
- Source covers TypeScript MCP SDK, Python FastMCP and C#/.NET SDK; matching toolchains and authorized service access are required.
Usage and prompt examples
These example requests were written by 2lus. Substitute files and projects you may use; examples are not executed results or guarantees.
Beginner
Draft a read-only inventory MCP tool with required inputs and errors.
Practical
Design inventory tools, schemas, pagination and least privilege without contacting production.
Advanced
Compare stdio and Streamable HTTP deployment/authentication. Plan discoverable tool groups and cross-tenant denial cases.
Tips
- Use action-oriented names, bounded results and explicit errors.
Limitations
- Tool discovery varies by client; a server is not automatically compatible with every agent.
Security notes
- Enforce authorization and tenant boundaries in the server, not just tool descriptions.
Usage and setup
README installer with skill selection. Copy only; this does not install SDK dependencies.
npx skills add microsoft/skillsDocumentation ↗
Supported agents
GitHub Copilot — Documented; not runtime-tested Documentation ↗
Sources and license
Source check date (not a safety certification): 2026-09-29
MIT
Original source ↗ License terms ↗ Documentation ↗Related skills
Before using a third-party skill, review its source, permissions and executable content. Commands are for viewing and copying only; 2lus does not execute them.
2lus AI Skills Library provides curated educational guides. Third-party content, licenses and availability are governed by their original sources. Review permissions and executable content before use or installation.