capacitor-mcp
Unofficial MCP server for the Capacitor documentation, plugin list and blog.
我該用這個嗎
品質與安全性
發現項目(4)
- HIGH
- MEDIUM在 search_docs 中
- MEDIUM在 get_doc_page 中
- MEDIUM在 list_plugins 中
根據工具定義與協定合規性的自動化分析。
上下文成本
這是每次將伺服器的工具載入模型上下文時所消耗的約略 token 數量。數量越高,可用於其他工作的注意力就越少。
安裝
一鍵安裝
將以下內容加入你的 `claude_desktop_config.json` 檔案:
{
"mcpServers": {
"capacitor-mcp": {
"command": "npx",
"args": [
"@capawesome/capacitor-mcp"
]
}
}
}可執行的套件
0.0.1stdio遠端端點
https://capacitor-mcp.capawesome.io/mcpstreamable-http它能做什麼
工具清單
工具(4)
🟢search_docs(query, section, version, limit)
Search the official Capacitor documentation from capacitorjs.com by keyword. Use this first for any question about Capacitor itself — the CLI, the `capacitor.config` file, the native Android and iOS projects, the official plugin APIs, or upgrading to a newer major version — because guessing an API, a configuration option or a CLI flag produces broken code. Returns the best matching page sections with `title`, `url`, `snippet`, `section` and `version`, plus the `parentTitle` and `parentUrl` of the page a section belongs to. The same results are attached as structured content. Do not use this to read a whole page (call `get_doc_page` with a `url` from these results), to look up Capawesome plugins such as @capawesome/capacitor-file-picker or Capawesome Cloud services such as Live Updates, Native Builds and App Store Publishing (use the Capawesome MCP server at https://mcp.capawesome.io/mcp instead), or to look up Ionic Framework UI components (use the Ionic Framework MCP server at https://ionic-framework-mcp.capawesome.io/mcp instead).
輸入結構描述
{
"type": "object",
"properties": {
"query": {
"type": "string",
"minLength": 1,
"description": "The search terms, e.g. \"camera permissions android\" or \"live reload\". Plain keywords work best; no search operators are supported."
},
"section": {
"description": "Restrict the search to one part of the documentation, e.g. \"apis\" for the official plugin references or \"ios\" for the native iOS guides. Defaults to searching every section.",
"type": "string",
"enum": [
"getting-started",
"basics",
"guides",
"android",
"ios",
"web",
"plugins",
"apis",
"cli",
"reference",
"updating",
"cordova"
]
},
"version": {
"description": "Optional. Capacitor docs version. Defaults to v8. Match the major version of @capacitor/core in the user's package.json.",
"type": "string",
"enum": [
"v8",
"v7",
"v6",
"next"
]
},
"limit": {
"description": "The maximum number of items to return, e.g. 5. Defaults to 10, maximum 25.",
"type": "integer",
"minimum": 1,
"maximum": 25
}
},
"required": [
"query"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}輸出結構描述
{
"type": "object",
"properties": {
"results": {
"type": "array",
"items": {
"type": "object",
"properties": {
"title": {
"type": "string"
},
"url": {
"type": "string"
},
"snippet": {
"type": "string"
},
"section": {
"type": "string"
},
"version": {
"type": "string"
},
"parentTitle": {
"type": "string"
},
"parentUrl": {
"type": "string"
}
},
"required": [
"title",
"url",
"snippet",
"section",
"version"
],
"additionalProperties": false
}
}
},
"required": [
"results"
],
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false
}🟢get_doc_page(url, version)
Read the full markdown of a single page of the official Capacitor documentation. Use this after `search_docs` to read a page end to end before writing code against a plugin API, a CLI command or a native configuration, because search snippets are deliberately short and regularly omit required setup steps. Returns the page title, its URL, the documentation version and the complete page markdown including code samples. Do not use this to find a page: it needs an exact URL or path, so run `search_docs` first. Do not use it for pages outside capacitorjs.com — Capawesome plugins and Capawesome Cloud are covered by the Capawesome MCP server at https://mcp.capawesome.io/mcp, Ionic Framework UI components by the Ionic Framework MCP server at https://ionic-framework-mcp.capawesome.io/mcp.
輸入結構描述
{
"type": "object",
"properties": {
"url": {
"type": "string",
"minLength": 1,
"description": "The page URL or site-relative path, e.g. \"https://capacitorjs.com/docs/apis/camera\", \"apis/camera\" or \"ios/configuration\". An anchor is ignored; the whole page is returned."
},
"version": {
"description": "Optional. Capacitor docs version. Defaults to v8. Match the major version of @capacitor/core in the user's package.json.",
"type": "string",
"enum": [
"v8",
"v7",
"v6",
"next"
]
}
},
"required": [
"url"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢list_plugins(query, source, limit)
List Capacitor plugins: the official plugins maintained by the Capacitor team and community plugins from the awesome-capacitorjs list maintained by Capawesome. Use this to find a plugin for a native capability before writing custom native code, and to learn which package name and maintainer a capability belongs to. Returns `name`, `description`, `source`, `maintainer` and `url` per plugin, plus `core: true` for a plugin that ships with @capacitor/core and `experimental: true` for an experimental one. Results are ranked by relevance, with official Capacitor plugins ranked first, then plugins maintained by Capawesome, then other community plugins. Do not use this to read a plugin's API: call `get_doc_page` with the `url` of an official plugin, and use the Capawesome MCP server at https://mcp.capawesome.io/mcp for Capawesome plugins.
輸入結構描述
{
"type": "object",
"properties": {
"query": {
"description": "A free-text filter matching the package name or the description, e.g. \"camera\". Defaults to no filter. Optional.",
"type": "string",
"minLength": 1
},
"source": {
"description": "Which plugins to list: \"official\" for the plugins maintained by the Capacitor team, \"community\" for the awesome-capacitorjs entries, or \"all\" for both. Defaults to \"all\".",
"type": "string",
"enum": [
"official",
"community",
"all"
]
},
"limit": {
"description": "The maximum number of items to return, e.g. 5. Defaults to 25, maximum 100.",
"type": "integer",
"minimum": 1,
"maximum": 100
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢list_blog_posts
List the 10 most recent posts from the Capacitor tag of the official Ionic blog, newest first. Use this when the question is about what is new — recent releases, announcements or deprecations. The blog covers both Capacitor and Ionic Framework. Returns `title`, `date`, `tags`, `url` and `excerpt` per post. Do not use this to answer a documentation question: the feed only carries the newest posts, so search the documentation with `search_docs` instead.
輸入結構描述
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}社群
證據