diff --git a/advanced/mcp/cli.mdx b/advanced/mcp/cli.mdx new file mode 100644 index 000000000..403ab95d6 --- /dev/null +++ b/advanced/mcp/cli.mdx @@ -0,0 +1,69 @@ +--- +title: "The Mintlify MCP Server" +description: "Learn how to install and use the Mintlify's MCP Server" +--- + + This page is dedicated to the Mintlify MCP Server. If you are looking for information on generating your MCP, please refer to the [MCP Generator](/advanced/mcp/overview) page. + + +## Get started +To use the Mintlify MCP server you will need an [API key](https://mintlify.com/docs/advanced/rest-api/overview#authentication) from your Mintlify account. If you don't have one, navigate to `Settings > API Keys > Chat API Key` and create a new key. + +## Start the MCP server locally + + + Run the following command to install the server: + ```bash + npx mcp add mintlify + ``` + + + The following response will be given after running the previous command: + ``` + > What is the Authorization (basic token)? + ``` + Using your API chat key, copy the authentication token and paste it into the CLI. + + + + You can now run: + ```bash + npm --prefix ~/.mcp/mintlify start + ``` + + + +## Use your server with Claude + + Download the the [Claude Desktop App](https://claude.ai/download) + + +Once you have the Claude Desktop App installed, follow these steps: + + + + + Add the following to the `claude_desktop_config.json`: + ```json + { + "mcpServers": { + "mintlify": { + "command": "npm", + "args": [ + "--prefix", + "~/.mcp/mintlify", + "start" + ] + } + } + } + ``` + + + If you click on it, you should see the available MCP Tools in your server. + + Claude MCP + + + + diff --git a/advanced/mcp/generate.mdx b/advanced/mcp/generate.mdx new file mode 100644 index 000000000..8c870d7ee --- /dev/null +++ b/advanced/mcp/generate.mdx @@ -0,0 +1,38 @@ +--- +title: "Generate your MCP Server" +description: "Learn how to set up your own MCP Server" +--- + + + This page is dedicated to setting up your own MCP Server. If you are looking + for information on using the Mintlify MCP Server, please refer to the + [Installing and using the Mintlify MCP Server](/advanced/mcp/cli) page. + + +## Get started + +Run `npm i mcp` to install the `mcp` CLI. + +In the [dashboard](https://dashboard.mintlify.com/products/mcp) go to `MCP Server`, on this page toggle to see your unique installation command. This is the command to install your MCP Server with the `mcp` CLI. + + + Make sure to toggle OpenAPI access to allow the MCP server to access **all** + endpoints in your OpenAPI spec. + + +## Start the MCP server locally + + + + Run the following command to install the server: ```bash npx mcp add [your + subdomain] ``` + + + If your API requires an authentication token, tell your end-customer to get + it and apply it when given this response: ``` > What is the Authorization + (basic token)? ``` Otherwise, you can skip this step. + + + You can now run: ```bash npm --prefix ~/.mcp/[your subdomain] start ``` + + diff --git a/advanced/mcp/overview.mdx b/advanced/mcp/overview.mdx new file mode 100644 index 000000000..07495c245 --- /dev/null +++ b/advanced/mcp/overview.mdx @@ -0,0 +1,17 @@ +--- +title: "Overview" +description: "[MCP](https://modelcontextprotocol.io/introduction) simplifies how you provide tools to LLMs" +--- + +## MCP Generator + +The MCP Generator is a CLI tool that generates an MCP server based on your company's documentation & OpenAPI specification if available. It takes in your documentation and a OpenAPI spec and outputs an MCP server that can be used with any MCP client. The MCP Generator is delivered via [npm package](https://www.npmjs.com/package/mcp) and generates an MCP server that can be used with any MCP client. + +Mintlify enables you to create an MCP server that allows AI tools to interact with your docs in these key scenarios: + +1. **Docs Q&A**, similar to our AI Chat. This is automatically enabled for your docs, no setup required. +2. **Real-time API querying**, if you have an OpenAPI spec, head to the `Mintlify Dashboard > Products > MCP Server` and hit the toggle to enable your OpenAPI spec. + + By enabling the OpenAPI toggle, you are allowing the MCP server to access + **all** endpoints in your OpenAPI spec. + diff --git a/docs.json b/docs.json index 381cdcce0..6ee7d5d04 100644 --- a/docs.json +++ b/docs.json @@ -133,7 +133,19 @@ { "group": "Dashboard Access", "icon": "house-lock", - "pages": ["advanced/dashboard/sso", "advanced/dashboard/permissions"] + "pages": [ + "advanced/dashboard/sso", + "advanced/dashboard/permissions" + ] + }, + { + "group": "Model Context Protocol", + "icon": "server", + "pages": [ + "advanced/mcp/overview", + "advanced/mcp/cli", + "advanced/mcp/generate" + ] }, { "group": "REST API", @@ -205,7 +217,7 @@ "pages": [ "integrations/analytics/overview", "integrations/analytics/amplitude", - "integrations/analytics/clearbit", + "integrations/analytics/clearbit", "integrations/analytics/fathom", "integrations/analytics/google-analytics", "integrations/analytics/google-tag-manager", diff --git a/images/claude-mcp.png b/images/claude-mcp.png new file mode 100644 index 000000000..b8b6bf51e Binary files /dev/null and b/images/claude-mcp.png differ diff --git a/images/mcp-auth-token.png b/images/mcp-auth-token.png new file mode 100644 index 000000000..4c7282cd2 Binary files /dev/null and b/images/mcp-auth-token.png differ diff --git a/images/mcp-dash.png b/images/mcp-dash.png new file mode 100644 index 000000000..771a16640 Binary files /dev/null and b/images/mcp-dash.png differ diff --git a/images/mcp-with-claude.png b/images/mcp-with-claude.png new file mode 100644 index 000000000..6b3f62764 Binary files /dev/null and b/images/mcp-with-claude.png differ