BRLaw
A MCP (Model Context Protocol) server for agent-driven research on Brazilian law using official sources
What is BRLaw?
BRLaw is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp (model context protocol) server for agent-driven research on brazilian law using official sources
A MCP (Model Context Protocol) server for agent-driven research on Brazilian law using official sources
This server falls under the Knowledge & Memory category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- A MCP (Model Context Protocol) server for agent-driven resea
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx brlaw-mcp-serverConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use BRLaw
BRLaw MCP Server is a Python-based MCP server that provides AI-driven legal research against official Brazilian court databases, including the STJ (Superior Court of Justice), TST (Superior Labor Court), and STF (Supreme Federal Court). It uses browser automation via Patchright to query each court's official search portal and return real legal precedents matching the specified criteria. Brazilian legal professionals, law firms, and developers building AI legal assistants for the Brazilian jurisdiction will find this a reliable bridge to authoritative primary sources.
Prerequisites
- Python 3.12+ installed on your system
- uv package manager installed (recommended): pip install uv
- Google Chrome installed (required by Patchright browser automation)
- Git for cloning the repository
- An MCP-compatible client such as Claude Desktop
Clone the repository
Clone the brlaw_mcp_server repository to your local machine.
git clone https://github.com/pdmtt/brlaw_mcp_server.git
cd brlaw_mcp_serverInstall Python dependencies
Use uv to install the project and its dependencies into an isolated environment.
uv syncInstall the Patchright browser
Patchright requires a browser installation step to set up the patched Chromium used for automation. Run this after syncing dependencies.
uv run patchright installConfigure Claude Desktop
Add the BRLaw server to your Claude Desktop configuration, specifying the directory where you cloned the repository.
{
"mcpServers": {
"brlaw_mcp_server": {
"command": "uv",
"args": [
"--directory",
"/path/to/brlaw_mcp_server",
"run",
"serve"
]
}
}
}Restart Claude Desktop and test
Relaunch Claude Desktop and ask it to search for a Brazilian legal precedent to confirm the server connects and the browser automation functions correctly.
BRLaw Examples
Client configuration
Full claude_desktop_config.json entry for the BRLaw MCP server using uv to run the serve command.
{
"mcpServers": {
"brlaw_mcp_server": {
"command": "uv",
"args": [
"--directory",
"/Users/yourname/brlaw_mcp_server",
"run",
"serve"
]
}
}
}Prompts to try
Legal research queries you can ask Claude once the BRLaw server is connected.
- "Search for STJ precedents on 'responsabilidade civil' in consumer law cases"
- "Find recent TST decisions about teletrabalho (remote work) and overtime compensation"
- "Look up STF precedents related to constitutional rights in criminal procedure"
- "Search the STJ for cases involving 'dano moral' and social media platforms"
- "Find STF rulings from 2023 on the constitutionality of mandatory vaccination"Troubleshooting BRLaw
Patchright install fails or Chrome not found
Ensure Google Chrome is installed on your system. Patchright uses Chrome for automation — install it from google.com/chrome. Then re-run 'uv run patchright install' from inside the repository directory.
Server fails to start with uv errors
Confirm uv is installed ('uv --version') and that you ran 'uv sync' inside the cloned repository. The --directory argument in the config must point to the exact path where you cloned brlaw_mcp_server.
Legal searches return no results or time out
The server queries live court websites which can be slow or temporarily unavailable. Try rephrasing your query to use simpler legal terms. Check your internet connection and verify the court portals (stj.jus.br, tst.jus.br, stf.jus.br) are accessible from your machine.
Frequently Asked Questions about BRLaw
What is BRLaw?
BRLaw is a Model Context Protocol (MCP) server that mcp (model context protocol) server for agent-driven research on brazilian law using official sources It connects AI assistants to external tools and data sources through a standardized interface.
How do I install BRLaw?
Follow the installation instructions on the BRLaw GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with BRLaw?
BRLaw works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is BRLaw free to use?
Yes, BRLaw is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
BRLaw Alternatives — Similar Knowledge & Memory Servers
Looking for alternatives to BRLaw? Here are other popular knowledge & memory servers you can use with Claude, Cursor, and VS Code.
MemPalace
★ 52.6kA local AI memory system that stores all conversations verbatim and organizes them into navigable structures. It provides 19 MCP tools for AI assistants to search and retrieve past decisions, debugging sessions, and architecture debates automatically
Kratos
★ 25.7k🏛️ Memory System for AI Coding Tools - Never explain your codebase again. MCP server with perfect project isolation, 95.8% context accuracy, and the Four Pillars Framework.
Context Mode
★ 15.4kAn MCP server that preserves LLM context by intercepting large data outputs and returning only concise summaries or relevant sections. It enables efficient sandboxed code execution, file processing, and documentation indexing across multiple programm
Memu
★ 13.7kMemory for 24/7 proactive agents like OpenClaw.
MemOS
★ 9.3kMemOS (Memory Operating System) is a memory management operating system designed for AI applications. Its goal is: to enable your AI system to have long-term memory like a human, not only remembering what users have said but also actively invoking, u
Everos
★ 5.4kBuild, evaluate, and integrate long-term memory for self-evolving agents.
Browse More Knowledge & Memory MCP Servers
Explore all knowledge & memory servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up BRLaw in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use BRLaw?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.