A community-driven registry for Claude, Cursor, Windsurf, Cline & more. Not affiliated with Anthropic.
Are you the author? Sign in to claim
This is an MCP (Model Context Protocol) server that provides tools to search and retrieve Magento 2 REST API documentati
A local STDIO MCP server that provides tools to search and retrieve Magento 2 REST API documentation from OpenAPI (swagger) specifications.
cd magento-api-mcp
pip install -e .
magento-api-mcp
The server starts immediately and parses the swagger.json file on first run or when the file has been modified.
~/.mcp/magento-api/database.db
MAGENTO_API_DB_PATH environment variabledata/swagger.json in the package directory
MAGENTO_API_SWAGGER_PATH environment variableConfigure your MCP client to run the magento-api-mcp command:
{
"mcpServers": {
"magento-api": {
"command": "magento-api-mcp"
}
}
}
Or with custom swagger file:
{
"mcpServers": {
"magento-api": {
"command": "magento-api-mcp",
"env": {
"MAGENTO_API_SWAGGER_PATH": "/path/to/your/swagger.json"
}
}
}
}
search_endpointsSearch for API endpoints using keywords.
Parameters:
queries: List of 1-3 short keyword queries (e.g., ["cart", "customer"])filter_by_method: Optional HTTP method filter (GET, POST, PUT, DELETE)filter_by_tag: Optional category filter (e.g., "carts/mine")Example:
search_endpoints(queries=["cart operations"], filter_by_method="GET")
get_endpoint_detailsGet complete documentation for a specific endpoint.
Parameters:
path: Exact API path (e.g., "/V1/carts/mine")method: Optional HTTP method (if omitted, returns all methods for this path)Example:
get_endpoint_details(path="/V1/carts/mine", method="GET")
Returns:
list_tagsList all available API category tags.
Returns: Hierarchical list of all endpoint categories with counts.
search_schemasSearch for data schemas/models by keyword.
Parameters:
query: Keyword to search forExample:
search_schemas(query="customer")
get_schemaGet complete definition of a schema/model.
Parameters:
schema_name: Exact schema name (e.g., "quote-data-cart-interface")Returns: Full schema with type, description, and all properties in JSON format.
Test each component independently:
# Test the OpenAPI parser
python3 tests/verify_parser.py
# Test database ingestion
python3 tests/verify_db.py
# Test MCP server and all tools
python3 tests/verify_server.py
The server uses SQLite with the following tables:
| Query | Tool | Purpose |
|---|---|---|
["cart"] | search_endpoints | Find all cart-related endpoints |
["customer", "authentication"] | search_endpoints | Find customer auth endpoints |
/V1/carts/mine | get_endpoint_details | Get complete cart endpoint docs |
customer | search_schemas | Find customer-related schemas |
quote-data-cart-interface | get_schema | View cart data structure |
magento-api-mcp/
├── magento_api_mcp/
│ ├── __init__.py
│ ├── config.py # Configuration
│ ├── parser.py # OpenAPI parser
│ ├── ingest.py # Database ingestion
│ └── server.py # MCP server with tools
├── tests/
│ ├── verify_parser.py # Parser verification
│ ├── verify_db.py # Database verification
│ └── verify_server.py # Server verification
├── data/
│ └── swagger.json # OpenAPI specification
├── pyproject.toml
└── README.md
To add new MCP tools, edit magento_api_mcp/server.py and use the @mcp.tool() decorator.
The server can work with any OpenAPI 3.0 swagger file. Simply set the MAGENTO_API_SWAGGER_PATH environment variable:
export MAGENTO_API_SWAGGER_PATH=/path/to/different-api-swagger.json
magento-api-mcp
MIT
Contributions welcome! Please test all changes with the verification scripts before submitting.
For issues or questions, please check:
Run Claude Code as an MCP server so any agent can delegate coding tasks to it
Browser automation using accessibility snapshots instead of screenshots
MCP server integration for DaVinci Resolve Studio
A Jetbrains IDE IntelliJ plugin aimed to provide coding agents the ability to leverage intelliJ's indexing of the codeba