Skip to content

Connect Internal Docs to Claude Code MCP

2 min read

In this tutorial, you will learn how to configure a custom Model Context Protocol server so your coding agent can read your company's proprietary APIs and internal documentation directly. Connecting internal docs to Claude Code via MCP bridges the gap between public library knowledge and your team's specific internal architecture.

Why Use MCP for Internal Documentation

When you ask a coding agent to write code that interacts with an internal service, it typically guesses based on general patterns or fails because it lacks the schema definitions. Standard web scraping is slow and often blocked by internal networks.

The Model Context Protocol solves this by giving your agent a direct, structured tool to query data sources. By pointing a local MCP server at your internal API specs, markdown documentation, or database schemas, your agent can fetch exact endpoints, payload structures, and error codes without leaving the terminal session.

Step 1: Create a Simple Custom MCP Server

To let your agent read your internal documentation, you first need a script that serves that content through the MCP specification. Most custom servers are written in Node.js or Python using the official MCP SDKs.

Create a new directory for your server and initialize a basic project:

mkdir internal-docs-mcp
cd internal-docs-mcp
npm init -y

Install the required MCP dependencies. Check the tool's documentation for the exact package names and initialization flags, as versions may vary:

npm install @modelcontextprotocol/sdk

Next, write a server script (for example, server.js) that reads your local documentation files or queries an internal search endpoint whenever the agent calls the defined tool. Define a tool named search_internal_docs that accepts a query string and returns matching snippets from your proprietary markdown files or API definitions.

Step 2: Configure Your Agent to Load the Server

Once your script runs locally, you need to tell your coding agent where to find it. Configuration typically lives in a JSON settings file in your project or home directory.

Open your configuration file and add your new server under the mcpServers key. Point it to your local node runtime and the script path you just created:

{
  "mcpServers": {
    "internal-docs": {
      "command": "node",
      "args": ["/path/to/internal-docs-mcp/server.js"]
    }
  }
}

Save the file and restart your agent interface.

Step 3: Test and Verify the Integration

Start your coding agent in a terminal. If you are managing multiple agent sessions, you can keep your local dev server, API reference documentation, and terminal windows in view together using a workspace layout like the one in Tidepane.

Ask the agent a specific question that requires your proprietary API, such as:

How do we authenticate requests against the internal user-service API?

The agent should recognize that it has access to the internal-docs tool, execute a query against your custom server, and return the exact code snippet or endpoint URL from your documentation instead of generic boilerplate.

Next Step

Test your new server by asking your coding agent to write a complete integration test using your proprietary endpoints.

Tidepane brings terminals, a browser and your coding agents into one window. See what it does.