Quran.com API integration for verse search, translation and tafsir
MCP server to interact with Quran.com corpus via the official REST API v4.
This is a Model Context Protocol (MCP) server generated from the OpenAPI specification.
The following endpoints from the API have been made available as tools, that LLMs can use via compatible clients.
Before using the Docker-based production mode, you need to build the Docker image:
# Build the Docker image
docker build -t quran-mcp-server .
To use this MCP server with Claude Desktop, add the following configuration to your claude_desktop_config.json
file (typically located at ~/Library/Application Support/Claude/claude_desktop_config.json
on macOS or %APPDATA%\Claude\claude_desktop_config.json
on Windows):
{
"mcpServers": {
"quran-api": {
"command": "docker",
"args": ["run", "-i", "--rm", "--init", "-e", "API_KEY=your_api_key_if_needed", "-e", "VERBOSE_MODE=true", "quran-mcp-server"],
"disabled": false,
"autoApprove": []
}
}
}
{
"mcpServers": {
"quran-api": {
"command": "node",
"args": ["/path/to/quran-mcp-server/dist/src/server.js"],
"env": {
"API_KEY": "your_api_key_if_needed",
"VERBOSE_MODE": "true" // Set to "true" to enable verbose logging
},
"disabled": false,
"autoApprove": []
}
}
}
{
"mcpServers": {
"quran-api": {
"command": "npx",
"args": ["ts-node", "/path/to/quran-mcp-server/src/server.ts"],
"env": {
"API_KEY": "your_api_key_if_needed",
"VERBOSE_MODE": "true" // Set to "true" to enable verbose logging
},
"disabled": false,
"autoApprove": []
}
}
}
Important Notes:
/path/to/quran-mcp-server
with the actual path to this repository on your systemnpm run build
or docker build -t quran-mcp-server .
if using the production mode configurationyour_api_key_if_needed
with an actual API key if required by the Quran.com APImcpServers
objectAPI_KEY
: API key for authenticationPORT
: Server port (default: 8000 or 3000 depending on language)VERBOSE_MODE
: Set to 'true' to enable verbose logging of API requests and responses (default: false)When VERBOSE_MODE
is set to 'true', the server will log detailed information about API requests and responses to the console. This is useful for debugging and monitoring API interactions.
The verbose logging includes:
Each log entry is timestamped and prefixed with the log type (REQUEST, RESPONSE, or ERROR) for easy identification.
# Run tests
npm test
This project is licensed under the MIT License.