mcp_server

mcp_server

3.2

This project provides a method to reference API documentation using an MCP server, implemented with the 'reference' feature.

The project is designed to facilitate the use of an MCP server to access API documentation. It includes scripts for crawling web pages and serving the crawled data through an MCP server. The main components are scripts that handle different types of documentation, such as Gemini, Anthropic, and OpenAPI. Users are required to set up their environment, install necessary dependencies, and configure the server settings to run the documentation servers. The project supports crawling of web pages to gather documentation data, which is then served via the MCP server.

Features

  • Supports crawling and serving of Gemini and Anthropic documentation.
  • Provides a method to serve OpenAPI documentation using YAML files.
  • Includes scripts for setting up and running MCP servers for different documentation types.
  • Allows customization of crawling settings through command-line options.
  • Facilitates integration with Claude through configuration updates.

Usage with Different Platforms

uv_installation

bash
curl -LsSf https://astral.sh/uv/install.sh | sh

virtual_environment_activation

bash
uv venv
source .venv/bin/activate

dependency_installation

bash
uv add "mcp[cli]" PyYAML

running_gemini_docs

bash
uv run gemini_docs.py

crawling_with_preset

bash
python crawl_all.py --preset gemini
python crawl_all.py --preset anthropic

custom_crawling

bash
python crawl_all.py \
  --base-url "https://example.com" \
  --start-path "/docs" \
  --output_file "document/example_docs.json" \
  --selector "main" \
  --path-pattern "^/docs/.*" \
  --delay 0.5 \
  --max-pages 100