Legal Knowledge MCP Server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Legal Knowledge MCP Server
An MCP (Model Context Protocol) server that gives Claude access to 20 legal data tools across 9 jurisdictions - United States (federal + all 50 states), EU, Italy, Greece, UK, France, Germany, Spain, and Paraguay.
Ask Claude questions about regulations, tax law, company formation, and compliance - get answers sourced directly from official government databases.
Quick Start (5 minutes)
Prerequisites
Node.js 18+ installed
1. Install
npm install -g legal-knowledge-mcpVerify it works:
legal-knowledge-mcp
# Expected output: Legal Knowledge MCP server running on stdioNote for Italian law queries (Normattiva): This tool uses a headless browser. Install the browser once after package install:
npx playwright install chromiumAll other tools work without this step.
2. Configure Claude
Claude Desktop — Mac:
Edit ~/Library/Application Support/Claude/claude_desktop_config.json
Claude Desktop — Windows:
Edit %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"legal-knowledge": {
"command": "legal-knowledge-mcp"
}
}
}Claude Code CLI:
claude mcp add legal-knowledge -- legal-knowledge-mcpRestart Claude Desktop after editing the config.
3. Ask Claude
"What are the requirements to form an SRL in Italy?"
"Search UK legislation for data protection"
"Find German company law GmbHG"
"What are Greek IKE tax rates?"
"Search Paraguayan tax residency requirements"
"Find Paraguay income tax law"
"What does a foreign-owned Wyoming LLC have to file with the IRS?"
"Search Wyoming bills about limited liability companies"Related MCP server: Lextiva Compliance MCP Server
Supported Jurisdictions & Tools
Jurisdiction | Tool | Source | Data Type |
EU |
| EUR-Lex | Directives, regulations, case law |
EU |
| EU Open Data Portal | European datasets |
Italy |
| Normattiva.it | Laws, decrees, regulations |
Italy |
| INPS OpenData | Social security rates |
Italy |
| Agenzia Entrate | Tax guidance, circolari |
Italy |
| dati.gov.it | Public administration data |
Italy |
| Camera dei Deputati | Parliamentary bills, debates |
Italy |
| Senato della Repubblica | Senate legislation |
Greece |
| AADE | Tax guidance, IKE, EFKA |
UK |
| legislation.gov.uk | Acts, Statutory Instruments |
France |
| Legifrance | Codes, laws, decrets |
Germany |
| Gesetze im Internet | Federal laws (BGB, HGB, GmbHG) |
Spain |
| BOE | Official gazette, legislation |
Paraguay |
| SILpy (Congress) | Laws, bills, parliamentary activity |
Paraguay |
| DNIT | Tax law, RUC validation, residency rules |
Paraguay |
| datos.gov.py | Government open data, public finance |
US |
| Curated index + eCFR + Federal Register | Federal law & regulations, Wyoming/Delaware LLC law |
US |
| GovInfo | US Code, public laws, congressional bills |
US |
| Open States | Bills in all 50 states, DC, Puerto Rico (key) |
US |
| CourtListener | Federal and state court opinions (key) |
Use Cases
Startup Founders
"What legal structure options exist for a tech startup in Italy?"
"Compare UK Ltd vs German GmbH requirements"
"What are the GDPR requirements for storing user data?"Tax & Compliance
"Find Italian VAT rates for digital services"
"Search Greek tax guidance on foreign income"
"What are French employer social contributions?"Legal Research
"Search EU directives on artificial intelligence"
"Find UK Data Protection Act provisions"
"What does German commercial code say about partnerships?"Cross-Border Business
"What are the requirements to hire employees in Spain?"
"Search Italian labor law for remote work regulations"
"Find EU regulations on cross-border payments"Installation Options
Option 1: Global npm install (Recommended)
npm install -g legal-knowledge-mcpOption 2: From Source
git clone https://github.com/Angioz/MCP-LEGAL-ADVISOR.git
cd MCP-LEGAL-ADVISOR
npm install
npm run buildOption 3: npx (No install)
npx legal-knowledge-mcpConfiguration
Claude Desktop
Mac: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"legal-knowledge": {
"command": "legal-knowledge-mcp"
}
}
}Windows users: If
legal-knowledge-mcpis not found, use the full path:{ "mcpServers": { "legal-knowledge": { "command": "node", "args": ["C:\\Users\\YourName\\AppData\\Roaming\\npm\\node_modules\\legal-knowledge-mcp\\dist\\index.js"] } } }
Claude Code CLI (Recommended)
# Add to current project (one command)
claude mcp add legal-knowledge -- legal-knowledge-mcpProject-level (.mcp.json)
For project-specific configuration:
{
"mcpServers": {
"legal-knowledge": {
"command": "legal-knowledge-mcp"
}
}
}Legacy Claude Code CLI
# Add to current project
claude mcp add legal-knowledge-mcp
# Or specify path
claude mcp add legal-knowledge -- node /path/to/dist/index.jsTool Reference
EUR-Lex (legal_query_eurlex)
Query EU legislation via SPARQL endpoint.
Parameter | Type | Required | Description |
| string | Yes | Natural language query |
| enum | No | directive, regulation, decision, case_law, all |
| number | No | Max results (default: 10) |
| string | No | Raw SPARQL for advanced queries |
Normattiva (legal_search_normattiva)
Search Italian legislation.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| enum | No | legge, decreto_legislativo, decreto_legge, dpr, all |
| number | No | Year of act |
| number | No | Act number |
INPS (legal_query_inps)
Query Italian social security data.
Parameter | Type | Required | Description |
| string | Yes | Natural language query |
| string | No | Dataset ID or search term |
Agenzia Entrate (legal_search_circolari)
Search Italian tax guidance.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| enum | No | redditi, iva, registro, successioni, agevolazioni, all |
| number | No | Year |
| string | No | Circolare number (e.g., "33/E") |
AADE (legal_search_aade)
Search Greek tax authority guidance.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| enum | No | income_tax, vat, efka, ike, all |
dati.gov.it (legal_query_datigov)
Query Italian open data catalog.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| string | No | Publishing organization filter |
Camera dei Deputati (legal_query_camera)
Query Italian Chamber of Deputies.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| number | No | Legislature number (e.g., 19) |
| enum | No | atto, interrogazione, mozione, all |
| number | No | Max results (default: 10) |
Senato (legal_query_senato)
Query Italian Senate.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| number | No | Legislature number |
| enum | No | ddl, atto, interrogazione, all |
| number | No | Max results (default: 10) |
EU Open Data (legal_query_eudata)
Query EU Open Data Portal.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| string | No | Dataset category |
| string | No | Publishing organization |
| number | No | Max results (default: 10) |
UK Legislation (legal_search_uk)
Search UK legislation.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| enum | No | ukpga (Public Act), uksi (Statutory Instrument), asp (Scottish Act), all |
| number | No | Year of legislation |
| number | No | Max results (default: 10) |
Legifrance (legal_search_france)
Search French legislation.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| enum | No | loi, ordonnance, decret, arrete, code, all |
| string | No | Start date (YYYY-MM-DD) |
| string | No | End date (YYYY-MM-DD) |
| number | No | Max results (default: 10) |
Gesetze im Internet (legal_search_germany)
Search German federal laws.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| string | No | Law abbreviation (GmbHG, HGB, BGB, AktG) |
| number | No | Max results (default: 10) |
BOE (legal_search_spain)
Search Spanish legislation.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| string | No | Government department |
| string | No | Start date (YYYY-MM-DD) |
| string | No | End date (YYYY-MM-DD) |
| number | No | Max results (default: 10) |
SILpy - Paraguay Congress (legal_search_paraguay)
Search Paraguayan legislation and bills.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| enum | No | ley (law), proyecto (bill), all |
| number | No | Year of the law |
| enum | No | S (Senate), D (Deputies) |
| number | No | Max results (default: 10) |
DNIT - Paraguay Tax (legal_query_paraguay_dnit)
Query Paraguayan tax authority for tax law, RUC validation, and residency rules.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| string | No | RUC number to validate (triggers direct lookup) |
| enum | No | renta (income), iva (VAT), residencia_fiscal (tax residency), ruc (taxpayer ID), all |
datos.gov.py - Paraguay Open Data (legal_query_paraguay_opendata)
Query Paraguay government open data portal.
Parameter | Type | Required | Description |
| string | Yes | Search terms |
| string | No | Publishing organization filter |
| number | No | Max results (default: 10) |
United States (legal_search_us, legal_search_us_code, legal_search_us_states, legal_search_us_caselaw)
Tool | Parameters | API key |
|
| None |
|
| Optional |
|
|
|
|
|
|
Keys go in the env block of the server config:
"legal-knowledge": {
"command": "npx",
"args": ["-y", "legal-knowledge-mcp"],
"env": { "OPENSTATES_API_KEY": "...", "COURTLISTENER_API_TOKEN": "...", "GOVINFO_API_KEY": "..." }
}State statute text has no free 50-state API. The curated index covers Wyoming and Delaware business law with links to the official codes; legal_search_us_states covers new and pending state bills.
Agent Skill
skills/legal-knowledge/SKILL.md tells an AI agent which tool to use for which question, how to phrase searches, and how to cite results. It ships with the npm package.
Claude Code: copy it to
~/.claude/skills/legal-knowledge/SKILL.md(all projects) or.claude/skills/legal-knowledge/SKILL.md(one project).Other agents: paste its contents into the system prompt or custom instructions.
Troubleshooting
All tools return SOURCE_DISABLED
Cause: Configuration file not found and defaults not applied (affects v1.0.0 only — fixed in v1.0.1+).
Fix: Upgrade to the latest version:
npm install -g legal-knowledge-mcp@latestlegal_search_normattiva fails with browser/executable error
Cause: Playwright's Chromium browser is not installed on your machine.
Fix: Run once after installing the package:
npx playwright install chromium"MCP server not found" or "command not found"
Cause: npm global bin directory not in PATH.
Fix:
# Find npm global bin directory
npm config get prefix
# Add to PATH (Mac/Linux - add to ~/.bashrc or ~/.zshrc)
export PATH="$PATH:$(npm config get prefix)/bin"
# Windows - add to System Environment Variables
# Usually: C:\Users\{username}\AppData\Roaming\npm"Connection refused" or "Server not responding"
Cause: Server crashed or MCP configuration incorrect.
Fix:
Test the server directly:
legal-knowledge-mcp # Should output: "Legal Knowledge MCP server running on stdio"Check Claude settings JSON is valid (use jsonlint.com)
Restart Claude Desktop after config changes
"No results found" for queries
Cause: Query too specific or source temporarily unavailable.
Fix:
Try broader search terms
Check if the source website is accessible in your browser
Some sources (EUR-Lex, UK legislation) work best with English queries
Italian sources work best with Italian terms
"SPARQL endpoint timeout" (EU Data)
Cause: EU Open Data Portal occasionally has CDN issues.
Fix:
This is an external service issue, not a bug
Try again later or use
legal_query_eurlexfor EU law queries instead
Tools not appearing in Claude
Cause: MCP server not properly registered.
Fix:
Verify config file location is correct for your OS
Ensure JSON syntax is valid (no trailing commas)
Restart Claude Desktop completely (quit and reopen)
Check Claude's MCP panel shows "legal-knowledge" as connected
Windows-specific issues
Cause: Path separators or execution policy.
Fix:
# If npx doesn't work, try explicit path
node "C:\Users\{username}\AppData\Roaming\npm\node_modules\legal-knowledge-mcp\dist\index.js"
# Or set execution policy
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUserDevelopment
# Clone repository
git clone https://github.com/Angioz/MCP-LEGAL-ADVISOR.git
cd MCP-LEGAL-ADVISOR
# Install dependencies
npm install
# Build
npm run build
# Watch mode (auto-rebuild on changes)
npm run dev
# Run server
npm startArchitecture
src/
├── index.ts # Entry point
├── server.ts # MCP server setup
├── types.ts # TypeScript types
├── tools/
│ ├── index.ts # Tool registry
│ ├── schemas.ts # JSON schemas (16 tools)
│ ├── eurlex.ts # EU law (SPARQL)
│ ├── normattiva.ts # Italian law
│ ├── inps.ts # Italian social security
│ ├── agenzia-entrate.ts # Italian tax
│ ├── aade.ts # Greek tax
│ ├── datigov.ts # Italian open data
│ ├── camera.ts # Italian Parliament (Chamber)
│ ├── senato.ts # Italian Parliament (Senate)
│ ├── eudata.ts # EU Open Data
│ ├── uk-legislation.ts # UK law
│ ├── legifrance.ts # French law
│ ├── germany.ts # German law
│ ├── spain-boe.ts # Spanish law
│ ├── paraguay-congress.ts # Paraguayan law (SILpy)
│ ├── paraguay-dnit.ts # Paraguayan tax (DNIT)
│ └── paraguay-opendata.ts # Paraguayan open data
└── config/
├── index.ts # Config loader
└── sources.ts # Source definitionsContributing
Contributions welcome! See CONTRIBUTING.md for guidelines.
Areas of interest:
Additional jurisdiction support (US, Canada, Australia, etc.)
Improved parsing for complex legal documents
Caching optimizations
Additional language support
Roadmap
See ROADMAP.md for planned features.
Phase 1 (Current): Foundation - 16 tools, 8 jurisdictions Phase 2: LinkedIn launch, community building Phase 3: Global expansion to 50+ jurisdictions
Related Resources
Model Context Protocol - MCP specification
Claude Desktop - Claude desktop app
MCP Servers Directory - Other MCP servers
License
MIT License - see LICENSE for details.
Disclaimer
This tool provides access to public legal sources for informational purposes only. It does not constitute legal advice. Always verify information with qualified legal professionals before making legal or financial decisions.
The accuracy and completeness of data depends on the source government databases. This project is not affiliated with or endorsed by any government entity.
Support
GitHub Issues - Bug reports and feature requests
Discussions - Questions and community chat
Made with care for founders navigating legal complexity.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Deterministic European sovereign engine with 90 tools across 20 vertical suites for AI agents: EU Tax/KYB, FatturaPA/Peppol, AI Act, GDPR, DORA, NIS2, Italian Tenders (D.Lgs 36/2023), CBAM, EUDR, and Labour Law. Zero-Data-Retention with verifiable SHA-256 PDF/A audit certificates.
Form a US LLC or nonprofit from any AI agent with free intake tools, and search and cite US federal, state and municipal law from official sources.
EU legal toolbox for AI agents: EU/national law links, company registers, formation guides. Free.
U.S. civic data for AI agents: reps, votes, bills, finance, lobbying, cited gov sources. 47 tools.
Related MCP Servers
- AlicenseNot gradedqualityNot gradedmaintenanceEnables AI assistants to search and analyze legal documents from multiple jurisdictions including US federal and state law, case law, EU regulations, UK legislation, Canadian law, Congress bills, SEC filings, and FDA data through free government APIs.6MIT
- AlicenseAqualityDmaintenanceProvides AI agents with access to a structured compliance dataset covering privacy and AI regulations across jurisdictions, enabling verifiable answers to regulatory questions via tools and resources.12MIT
- AlicenseNot gradedqualityBmaintenanceProvides AI assistants with up-to-date legal documents from official sources, enabling accurate legal information retrieval and analysis.21AGPL 3.0
- AlicenseAqualityBmaintenanceEnables AI assistants and terminal users to search Korean statutes, court precedents, administrative rules, local ordinances, treaties, and legal interpretations through 10 tools backed by 42 Ministry of Government Legislation APIs. It also supports verifying citations in AI-generated answers against the official legal sources.105,181 npmMIT