
scimorph/eur-lex-mcp
Developer toolsЭта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал
Enable AI agents and applications to query up-to-date EU regulation
Обзор
This server acts as a modern, AI-friendly bridge to the official EUR-Lex SOAP webservice. It exposes the complex EUR-Lex API as a simple and powerful server, making the entire body of European Union law accessible to modern AI agents, developer tools, and applications. By wrapping the legacy SOAP API, this server unlocks use cases in automated legal research, compliance monitoring, policy analysis, and more, without requiring AI agents to understand the complexities of WSDL or XML. * : Runs over for secure, local integration with desktop applications (like Claude Desktop, Cursor) and over for remote access by AI agents and web services. * : Provides an expert_search tool that allows for powerful, flexible querying using the native EUR-Lex expert search syntax. * : Includes a get_document_by_celex resource template for fetching specific legal documents directly via a clean URI (resource://eurlex/document/{celex_number}).
README
Показан фрагмент оригинального README. Открыть оригинал.
EUR-LEX MCP Server
This server acts as a modern, AI-friendly bridge to the official EUR-Lex SOAP webservice. It exposes the complex EUR-Lex API as a simple and powerful Model Context Protocol (MCP) server, making the entire body of European Union law accessible to modern AI agents, developer tools, and applications.
By wrapping the legacy SOAP API, this server unlocks use cases in automated legal research, compliance monitoring, policy analysis, and more, without requiring AI agents to understand the complexities of WSDL or XML.
✨ Features
- Dual-Mode Transport: Runs over STDIO for secure, local integration with desktop applications (like Claude Desktop, Cursor) and over HTTP for remote access by AI agents and web services.
- Expert Search Tool: Provides an
expert_searchtool that allows for powerful, flexible querying using the native EUR-Lex expert search syntax. - Direct Document Access: Includes a
get_document_by_celexresource template for fetching specific legal documents directly via a clean URI (resource://eurlex/document/{celex_number}). - Clean, Structured Output: Automatically parses the verbose SOAP/XML responses into a clean, easy-to-use JSON format, perfect for LLM consumption.
- Easy Installation: Can be easily installed into compatible clients using the
fastmcpcommand-line tool.
🔌 Prerequisites
Before you begin, ensure you have the following:
- Python 3.11+ and the
uvpackage manager. If you don’t haveuv, install it with:pip install uv - EUR-LEX Webservice Credentials. You must register for a webservice account to get a username and password. You can do this by following the “Webservice registration” link on the EUR-Lex website after logging in.
🚀 Setup & Installation
Follow these steps to get the server up and running on your local machine.
1. Clone the Repository (This is only necessary if you want to install it to Claude Desktop with the practical fastmcp install command)
Clone this project to your local machine.
git clone https://github.com/scimorph/eur-lex-mcp.git
cd eur-lex-mcp
2. Set Up the Environment
Create and activate a virtual environment, then install the required dependencies using uv.
# Create and activate the virtual environment
uv venv
# On macOS/Linux
source .venv/bin/activate
# On Windows
.venv\Scripts\activate
# Install dependencies
uv pip install -r pyproject.toml
3. Configure Credentials
The server requires your EUR-LEX webservice username and password. The most secure way to provide them is through a .env file.
Установка
npx -y -p fastmcp -p zeep -p python-dotenv fastmcp run https://scimorph/eur-lex-mcp/main/server/server.pyКонфигурация
{
"mcpServers": {
"eurlex-search": {
"command": "npx",
"args": [
"-y",
"-p", "fastmcp",
"-p", "zeep",
"-p", "python-dotenv",
"fastmcp", "run", "https://scimorph/eur-lex-mcp/main/server/server.py"
],
"env": {
"EURLEX_USERNAME": "YOUR_EURLEX_USERNAME",
"EURLEX_PASSWORD": "YOUR_WEBSERVICE_PASSWORD"
}
}
}
}