rest_api_mcp_tools_generator
by harshrajsinha
Overview
Generates Model Context Protocol (MCP) servers from REST API specifications (Swagger/OpenAPI) to enable AI clients like Claude Desktop to interact with external APIs as tools.
Installation
python manage.py runserverEnvironment Variables
- REDIS_HOST
- REDIS_PORT
- REDIS_DB
- OPENAI_API_KEY
- AZURE_OPENAI_API_KEY
- AZURE_OPENAI_ENDPOINT
- AZURE_OPENAI_API_VERSION
- AZURE_OPENAI_DEPLOYMENT_NAME
- LLM_SERVICE_ENABLED
Security Notes
The project dynamically loads and executes Python code for generated MCP servers and uses subprocess calls for package creation/installation. While necessary for its core functionality, this introduces risks if the input REST API specifications are untrusted or malicious, potentially leading to code injection. Default Django admin user credentials (`admin`/`admin@example.com`) are created during initialization, which must be changed for production environments. Sample API keys are present in example configurations but are intended for user modification.
Similar Servers
mcpo
Exposes Model Context Protocol (MCP) tools as OpenAPI-compatible HTTP servers for integration with LLM agents and other applications.
django-ai-boost
Provides a Model Context Protocol (MCP) interface for Django applications, allowing AI assistants to introspect project details like models, URLs, settings, and database schema.
django-rest-framework-mcp
Enables developers to quickly build Model Context Protocol (MCP) servers for existing Django REST Framework APIs, allowing AI agents and LLM clients to leverage these endpoints as tools.
MyMCP
Dynamically convert any OpenAPI v3 specification into a fully-functional Model Context Protocol (MCP) server, exposing external APIs as MCP tools.