AI · MCP server

Connect AI agents

OpenCaseLaw's public MCP server gives language models direct access to 1,050,000+ Swiss court decisions, the citation graph, federal laws and cantonal acts. 41 specialized tools, no sign-up, no API keys.

§01 Operating modes

Two operating modes

Remote recommended

Immediately available, always up to date. No download required. Server endpoint:

https://mcp.opencaselaw.ch

Local offline

Full control, works offline. ~65 GB storage, one-time setup approx. 30-60 minutes. See README.

§02 Setup

Setup per client

Endpoint https://mcp.opencaselaw.ch · Streamable HTTP (recommended) and SSE · no authentication · tools are read-only.

Claude.ai (Web) & Claude Desktop

Customize (Anpassen · Personnaliser · Personalizza) → Connectors → "+" → "Add custom connector" → paste the URL. Or direct: claude.ai/settings/connectors. Available on Free (max. 1 connector), Pro, Max, Team, Enterprise. On Team/Enterprise the Owner must first enable it via Organization Settings → Connectors → Add → Custom → Web.

https://mcp.opencaselaw.ch

Claude Code (CLI)

claude mcp add --transport http swiss-caselaw https://mcp.opencaselaw.ch

ChatGPT (Business / Enterprise / Edu)

Settings → Connectors → "Create" (if needed: Advanced settings → enable Developer mode). Name "Swiss Caselaw" and paste the URL, auth: None. ChatGPT Web on Business / Enterprise / Edu only; the model must support MCP tool calls.

https://mcp.opencaselaw.ch

Cursor

Settings → Features → MCP → "+ Add new MCP server", or in ~/.cursor/mcp.json:

{
  "mcpServers": {
    "swiss-caselaw": {
      "url": "https://mcp.opencaselaw.ch"
    }
  }
}

Gemini CLI

CLI command or ~/.gemini/settings.json. The web app gemini.google.com does not currently support custom MCP servers — only Gemini CLI, Gemini Enterprise, Android Studio and Firebase Studio do.

gemini mcp add --transport http swiss-caselaw https://mcp.opencaselaw.ch

Microsoft Copilot Studio

Agent → Tools → Add a tool → New tool → "Model Context Protocol". Server name "Swiss Caselaw" and URL, auth: None. Streamable HTTP only (SSE no longer supported since August 2025).

https://mcp.opencaselaw.ch

Other MCP clients

Works with any MCP-capable client (Continue, Zed, Cody, Windsurf, …) over Streamable HTTP at https://mcp.opencaselaw.ch. SSE is also reachable at /sse but is deprecated by the MCP spec.

§03 Tools

41 public tools at a glance (+ 2 local admin tools)

Each tool is optimised for a specific research use case. Full schemas via the MCP protocol tools/list, grouped here by function.

Search & retrieve decisions

  • search_decisions
  • get_decision
  • get_case_brief
  • list_courts
  • get_statistics

Decision structure (federal)

  • get_decision_structure
  • get_erwaegung
  • get_regeste
  • find_relevant_erwaegung

Citation graph

  • find_citations
  • find_appeal_chain
  • find_leading_cases
  • analyze_legal_trend

Statute text

  • get_law
  • search_laws
  • get_legislation
  • search_legislation
  • browse_legislation_changes
  • get_article_history
  • get_article_purpose

Doctrine & commentary

  • get_doctrine
  • get_commentary
  • search_commentaries

Legal scholarship (open access)

  • search_scholarship
  • get_scholarship
  • get_scholarship_full_text
  • list_scholarship_sources
  • find_scholarship_citing_statute
  • find_scholarship_citing_decision

Preparatory materials (dispatches)

  • get_materialien
  • search_materialien
  • search_botschaft

Verification & citation

  • check_claim_support
  • attest_response
  • cite

Administrative practice (federal)

  • search_practice
  • get_practice

Drafting & study

  • generate_exam_question
  • draft_mock_decision

ChatGPT Deep Research (aliases)

  • search
  • fetch

Local mode (maintenance)

  • update_database
  • check_update_status

§04 Technical

Technical details

  • Transport: Server-Sent Events (SSE) + Streamable HTTP, compatible with every common MCP client
  • TLS via Let's Encrypt, nginx rate limiting, health endpoint: /health
  • 4× uvicorn workers behind a load balancer, automatic failover
  • Backend: 1,050,000+ decisions in SQLite FTS5 with BM25+RRF ranking, citation graph of 8.9M edges (8.3M resolved)
  • Data from public sources (federal courts, cantonal courts, Fedlex, LexFind), updated daily