jonashertner avatar

OpenCaseLaw — Swiss Caselaw, Statutes & Doctrine

jonashertner/caselaw-repo-1

Connects Claude to 972,000 Swiss court decisions and 21,000 federal and cantonal laws spanning 1875 to today. Exposes 38 remote tools for full-text search across trilingual case law, citation graph traversal with 8 million resolved edges, leading case discovery by citation authority, statute article lookup, legislative history via 84,000 Botschaft references, and appeal chain resolution. Search uses BM25 with synonym expansion and reranking. Pulls federal laws directly from Fedlex SPARQL and scrapes all 26 cantonal portals. Reach for it when you need primary source grounding for Swiss legal research, want to trace jurisprudence evolution, or need to query the relationship between decisions and specific statute articles without hallucination.

tools
42
transport
HTTP, SSE
last updated
Jul 30, 2026

Install

From registry metadata
$ npx add-mcp https://mcp.opencaselaw.ch/mcp --name swiss-caselaw

Run in your terminal. add-mcp asks which agents to add it to (Claude Code, Codex, Cursor and more). Add -g to install it for every project.

Review the command, arguments and environment values before installing. MCP servers run with your local permissions.

Other ways

Claude Code

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

Run in your terminal. Add --scope user to make it available in every project.

Tools

Verified live · 42 tools

Verified live against the running server on Nov 6, 2026.

searchMinimal search tool following the deep-research search/fetch convention. Returns a ranked list of Swiss court decisions matching a query, each as {id, title, url, snippet}. Pair with `fetch` to retrieve a decision's full text by id. General (non-deep-research) clients should p...2 params

Minimal search tool following the deep-research search/fetch convention. Returns a ranked list of Swiss court decisions matching a query, each as {id, title, url, snippet}. Pair with `fetch` to retrieve a decision's full text by id. General (non-deep-research) clients should p...

Parameters* required
limitinteger
Max results (default 10, max 50).default: 10
query*string
Natural-language or keyword query.
fetchMinimal fetch tool following the deep-research search/fetch convention. Fetches one Swiss decision's full text by id, returning {id, title, text, url, metadata}. The id comes from a `search` result (a decision_id like bger_6B_1234_2025; a docket number or BGE reference also re...1 params

Minimal fetch tool following the deep-research search/fetch convention. Fetches one Swiss decision's full text by id, returning {id, title, text, url, metadata}. The id comes from a `search` result (a decision_id like bger_6B_1234_2025; a docket number or BGE reference also re...

Parameters* required
id*string
Decision id from a search result (decision_id, docket, or BGE reference).
search_decisionsUse this tool to find COURT DECISIONS (Rechtsprechung): 1,050,000+ Swiss federal and cantonal decisions plus ~2,800 ECtHR decisions concerning Switzerland. Full-text search with keywords, phrases (in quotes), Boolean operators (AND, OR, NOT), prefix matching (word*), docket lo...15 params

Use this tool to find COURT DECISIONS (Rechtsprechung): 1,050,000+ Swiss federal and cantonal decisions plus ~2,800 ECtHR decisions concerning Switzerland. Full-text search with keywords, phrases (in quotes), Boolean operators (AND, OR, NOT), prefix matching (word*), docket lo...

Parameters* required
cantonstring
Filter by canton (CH for federal, ZH, BE, GE, etc.)
chamberstring
Filter by chamber/division (substring match). Examples: 'Abteilung V' (BVGer asylum), 'Zivilrechtliche', 'CASSO', 'Strafrechtliche'
courtstring
Filter by court code. Federal: bger, bge, bvger, bstger, bpatger, mkg. European Court of Human Rights: bge_egmr (BGE-published DE translations, Swiss cases), hudoc_ch (HUDOC Switzerland-tagged), ec...
date_fromstring
Decided on or after this date (YYYY-MM-DD): decision_date, not publication_date.
date_tostring
Decided on or before this date (YYYY-MM-DD): decision_date, not publication_date.
fieldsstring
Response detail level: 'full' (default) includes snippet/regeste/URL, 'compact' returns only docket, date, court, language, decision_id.one of full · compact
include_pinpointboolean
Attach a pinpoint Erwägung citation to the top results when a confident match exists (BM25 over the per-decision Erwägungen FTS5 index, gap-confidence ≥ medium). Defaults true; set false to skip th...default: true
languagestring
OPTIONAL filter. Restricts results to ONE language. Omit (recommended default) to search across all languages — Swiss federal decisions are issued in DE, FR, or IT depending on the case, so a langu...one of de · fr · it · rm · en
limitinteger
Max results to return (max 2000). Omit to use default of 50. Do not set low values like 5 or 10 unless the user explicitly asked for fewer results.default: 50
marked_for_publicationboolean
If true, return only Federal Supreme Court rulings flagged for the official BGE collection (the Neuheiten '*' marker, 'für die Publikation vorgesehen') — future leading cases, flagged before the BG...
offsetinteger
Skip this many results (for pagination). Default 0.default: 0
published_fromstring
Only decisions the court PUBLISHED on or after this date (YYYY-MM-DD) — publication_date, not decision_date. Use this, not date_from, for a 'what is newly published' alert: the Federal Supreme Cour...
published_tostring
Only decisions published on or before this date (YYYY-MM-DD, inclusive). Requires published_from.
querystring
Search query. Best results: 3-8 precise terms, one search per legal issue — never paste document text. Max 4,000 chars; input over 500 chars is auto-condensed to its citations + key terms. Examples...
sortstring
Sort order: 'relevance' (default for FTS), 'date_desc' / 'date_asc' (decision_date), 'published_desc' (newest publication_date first; decisions without one last).one of relevance · date_desc · date_asc · published_desc
get_decisionFetch a single court decision with full text. Look up by decision_id (e.g., bger_6B_1234_2025), docket number (e.g., 6B_1234/2025), or partial match. Full text is truncated at 200,000 characters for very long decisions. Set full_text=false to get only metadata and regeste.2 params

Fetch a single court decision with full text. Look up by decision_id (e.g., bger_6B_1234_2025), docket number (e.g., 6B_1234/2025), or partial match. Full text is truncated at 200,000 characters for very long decisions. Set full_text=false to get only metadata and regeste.

Parameters* required
decision_id*string
Decision ID, docket number, or partial docket
full_textboolean
Include full text in response (default true). Set false to get only metadata and regeste.default: true
get_decisionsUse this tool to fetch SEVERAL decisions at once (1-10 ids) instead of calling get_decision repeatedly. Same data per decision — canonical citation strings, Markdown link, Regeste, metadata — in ONE call. Prefer this whenever you are about to read more than one decision from a...3 params

Use this tool to fetch SEVERAL decisions at once (1-10 ids) instead of calling get_decision repeatedly. Same data per decision — canonical citation strings, Markdown link, Regeste, metadata — in ONE call. Prefer this whenever you are about to read more than one decision from a...

Parameters* required
decision_ids*array
Decision ids, docket numbers or BGE references (e.g. ['bge_BGE_140_III_86', '6B_1234/2025']).
full_textboolean
Include an excerpt of each decision's full text (default false — Regeste + metadata only).default: false
max_chars_per_decisioninteger
Per-decision text cap when full_text is true (default 20,000; total response stays under connector limits).default: 20000
list_courtsList all available courts with decision counts, decision-date ranges, and language coverage. Use this to discover what data is available. A court's latest decision date is not its last update: courts publish weeks to months after deciding, and this corpus is updated daily.

List all available courts with decision counts, decision-date ranges, and language coverage. Use this to discover what data is available. A court's latest decision date is not its last update: courts publish weeks to months after deciding, and this corpus is updated daily.

No parameters. Call it with no arguments.

get_statisticsGet aggregate statistics about the dataset. Optionally filter by court, canton, or year. by_year counts decision years: the latest years keep rising for months as courts publish, so their lower counts are publication lag, not missing data.3 params

Get aggregate statistics about the dataset. Optionally filter by court, canton, or year. by_year counts decision years: the latest years keep rising for months as courts publish, so their lower counts are publication lag, not missing data.

Parameters* required
cantonstring
Filter by canton code
courtstring
Filter by court code
yearinteger
Filter by year
find_citationsGiven a decision_id, show what it cites and what cites it. Uses the reference graph database with 9.65M citation edges. Returns resolved citations with confidence scores and unresolved references.5 params

Given a decision_id, show what it cites and what cites it. Uses the reference graph database with 9.65M citation edges. Returns resolved citations with confidence scores and unresolved references.

Parameters* required
decision_id*string
Decision ID (e.g., bger_6B_1_2025)
directionstring
Citation direction: 'both' (default), 'outgoing', or 'incoming'one of both · outgoing · incomingdefault: both
limitinteger
Max citations per direction per page (default 50, max 200)default: 50
min_confidencenumber
Minimum confidence score for resolved citations (0-1, default 0.3)default: 0.3
offsetinteger
Pagination offset per direction (default 0). The response reports *_total and *_has_more; when has_more is true, re-query with offset=next_offset to retrieve the rest (heavily-cited leading decisio...default: 0
find_appeal_chainTrace the appeal chain (Instanzenzug) for a decision. Shows prior instances (lower courts) and subsequent instances (appeals to higher courts). Reconstructs the full procedural path, e.g. Bezirksgericht → Obergericht → Bundesgericht. Uses the is_prior_instance flag from decisi...2 params

Trace the appeal chain (Instanzenzug) for a decision. Shows prior instances (lower courts) and subsequent instances (appeals to higher courts). Reconstructs the full procedural path, e.g. Bezirksgericht → Obergericht → Bundesgericht. Uses the is_prior_instance flag from decisi...

Parameters* required
decision_id*string
Decision ID (e.g., bger_6B_1_2025)
min_confidencenumber
Minimum confidence score (0-1, default 0.3)default: 0.3
find_leading_casesFind the most-cited decisions for a topic or statute. Authority ranking based on citation graph, so recent decisions rank low (not yet cited); for the newest use search_decisions(sort='date_desc'). A free-text topic ranks decisions whose regeste carries the query terms first (...8 params

Find the most-cited decisions for a topic or statute. Authority ranking based on citation graph, so recent decisions rank low (not yet cited); for the newest use search_decisions(sort='date_desc'). A free-text topic ranks decisions whose regeste carries the query terms first (...

Parameters* required
articlestring
Optional article number (requires law_code)
courtstring
Optional court filter (e.g., bger, bge, bvger)
date_fromstring
Optional start date (YYYY-MM-DD)
date_tostring
Optional end date (YYYY-MM-DD)
include_pinpointboolean
Attach a pinpoint Erwägung citation to the top 3 leading cases when a confident match exists. Defaults true.default: true
law_codestring
Optional law code (e.g., BV, OR, ZGB, EMRK, StGB)
limitinteger
Max results (default 20, max 100)default: 20
querystring
Optional text query to filter by topic (FTS search)
analyze_legal_trendYear-by-year decision counts showing jurisprudence evolution. Use with a statute reference (law_code + article), a text query, or both. Returns yearly counts with visual bar chart. Years are decision years: the latest one or two keep rising as courts publish weeks to months af...6 params

Year-by-year decision counts showing jurisprudence evolution. Use with a statute reference (law_code + article), a text query, or both. Returns yearly counts with visual bar chart. Years are decision years: the latest one or two keep rising as courts publish weeks to months af...

Parameters* required
articlestring
Article number (requires law_code)
courtstring
Optional court filter
date_fromstring
Optional start date (YYYY-MM-DD)
date_tostring
Optional end date (YYYY-MM-DD)
law_codestring
Optional law code (e.g., BV, OR, EMRK). Requires article.
querystring
Optional text query (FTS search)
draft_mock_decisionBuild a research-only mock decision outline from user facts. Combines relevant Swiss case law retrieval with statute references. If possible, enriches statutes with Fedlex text excerpts. IMPORTANT: The tool may return clarification questions (high/medium priority). High-priori...8 params

Build a research-only mock decision outline from user facts. Combines relevant Swiss case law retrieval with statute references. If possible, enriches statutes with Fedlex text excerpts. IMPORTANT: The tool may return clarification questions (high/medium priority). High-priori...

Parameters* required
clarificationsarray
Optional answers to prior clarification questions. Each item: {id, answer}. The tool withholds conclusion until high-priority clarifications are answered.
deciding_courtstring
Hypothetical deciding court (e.g., bger, bvger).
facts*string
Detailed facts of the hypothetical or real case.
fedlex_urlsarray
Optional Fedlex URLs used to fetch statute text. Useful when no built-in URL mapping is available.
limitinteger
Number of case-law exemplars (default 8, max 20).default: 8
preferred_languagestring
Output/analysis language preference.one of de · fr · it · rm · en
questionstring
Optional legal question to decide.
statute_referencesarray
Optional explicit statute list. Each item: {law_code, article, paragraph?}.
get_case_briefStructured case brief: regeste, Sachverhalt, key Erwägungen (first 12 only — for orientation, NOT a pinpoint ranking), Dispositiv, statutes, citation authority, related cases. Accepts BGE ref, decision_id, or docket. To pinpoint which Erwägung supports a specific claim, use fi...1 params

Structured case brief: regeste, Sachverhalt, key Erwägungen (first 12 only — for orientation, NOT a pinpoint ranking), Dispositiv, statutes, citation authority, related cases. Accepts BGE ref, decision_id, or docket. To pinpoint which Erwägung supports a specific claim, use fi...

Parameters* required
case*string
Any case reference: BGE ref ('BGE 133 III 121', '133 III 121'), decision_id ('bge_BGE_133_III_121'), or docket number.
get_decision_structureStructured decision fields: Sachverhalt (facts), Erwägungen as numbered paragraphs ('1', '1.1', '2.3'), Dispositiv (ruling), Regeste (BGE only). Federal decisions only; for cantonal use get_decision. Returns excerpts; for verbatim full text of one Erwägung, use get_erwaegung....1 params

Structured decision fields: Sachverhalt (facts), Erwägungen as numbered paragraphs ('1', '1.1', '2.3'), Dispositiv (ruling), Regeste (BGE only). Federal decisions only; for cantonal use get_decision. Returns excerpts; for verbatim full text of one Erwägung, use get_erwaegung....

Parameters* required
decision_id*string
decision_id ('bger_5A_42_2026', 'bge_140 III 86'), BGE reference, or docket number.
get_erwaegungVerbatim text of ONE numbered Erwägung — the citable unit in Swiss practice (e.g. 'BGE 136 III 513 E. 2.3'). Use when the user already gave an e_number. If only a claim was given (no e_number): use find_relevant_erwaegung — never guess. Returns text + sibling Erwägung numbers;...2 params

Verbatim text of ONE numbered Erwägung — the citable unit in Swiss practice (e.g. 'BGE 136 III 513 E. 2.3'). Use when the user already gave an e_number. If only a claim was given (no e_number): use find_relevant_erwaegung — never guess. Returns text + sibling Erwägung numbers;...

Parameters* required
decision_id*string
decision_id, BGE reference, or docket number.
e_number*string
Erwägung number to retrieve (e.g. '2', '2.3', '5.2.1'). Leading 'E.' is stripped if present.
find_relevant_erwaegungFind which Erwägung paragraph(s) match a legal claim. Server-side FTS5+BM25 over per-paragraph text; returns top-k with confidence labels (high/medium/low) and a highlighted_snippet wrapping the matched sentence in <mark>…</mark> (quote it verbatim). When no_match=true or conf...3 params

Find which Erwägung paragraph(s) match a legal claim. Server-side FTS5+BM25 over per-paragraph text; returns top-k with confidence labels (high/medium/low) and a highlighted_snippet wrapping the matched sentence in <mark>…</mark> (quote it verbatim). When no_match=true or conf...

Parameters* required
claim*string
Free-text legal claim or proposition the user wants to verify against the decision. The more specific, the higher the confidence.
decision_id*string
decision_id, BGE reference, or docket number. Must be a federal decision (structured Erwägungen).
top_kinteger
Number of top matches to return (default 3, max 10).default: 3
get_article_purposeReturn verbatim text from the Federal Council Botschaft (or Erläuterungsbericht) explaining the legislative purpose of a specific article. Joins the verbatim Botschaft corpus (post-2003 BBl publications, Akoma Ntoso XML where available, PDF fallback otherwise) with the article...4 params

Return verbatim text from the Federal Council Botschaft (or Erläuterungsbericht) explaining the legislative purpose of a specific article. Joins the verbatim Botschaft corpus (post-2003 BBl publications, Akoma Ntoso XML where available, PDF fallback otherwise) with the article...

Parameters* required
article*string
Article number, e.g. '41' for Art. 41 OR. Letter-suffixed forms like '41a' supported.
languagestring
Botschaft language (defaults to German).one of de · fr · itdefault: de
max_paragraphsinteger
Maximum paragraphs per Botschaft (default 8, max 20).default: 8
sr_number*string
SR (Systematische Rechtssammlung) number of the law, e.g. '220' for OR (Obligationenrecht), '101' for BV, '311.0' for StGB.
search_botschaftRetrieve and quote the VERBATIM text of federal Materialien: Federal Council Botschaften, Berichte and Stellungnahmen des Bundesrates, parliamentary committee reports, Erlassentwürfe — and the Vernehmlassung documents: Erläuternde Berichte, Vorlagen, Ergebnisberichte, Stellung...6 params

Retrieve and quote the VERBATIM text of federal Materialien: Federal Council Botschaften, Berichte and Stellungnahmen des Bundesrates, parliamentary committee reports, Erlassentwürfe — and the Vernehmlassung documents: Erläuternde Berichte, Vorlagen, Ergebnisberichte, Stellung...

Parameters* required
doc_typestring
OPTIONAL Fedlex document type. botschaft = Botschaft des Bundesrates (Message / Messaggio); bericht_bundesrat = Bericht des Bundesrates; stellungnahme_bundesrat = Stellungnahme des Bundesrates (Avi...one of botschaft · bericht_bundesrat · stellungnahme_bundesrat · bericht_kommission · erlassentwurf · vorentwurf_erlass
languagestring
OPTIONAL — only set when the user explicitly limits the search to one language. Leave unset to search the corpus the caller has (currently de only). Setting this without the user asking will hide a...one of de · fr · it
limitinteger
Max passages to return (default 20, max 50).default: 20
query*string
Search terms. FTS5 syntax supported — use quoted phrases for exact matches ('"Vaterschaftsurlaub"'), Boolean operators ('Klimaschutz AND Kanton'), and prefix queries ('Versicherungs*'). Stopwords a...
year_maxinteger
Latest publication year of the source Botschaft (inclusive).
year_mininteger
Earliest publication year of the source Botschaft (inclusive) — scope legislative history to an era.
get_article_historyChronological story of a single statute article: current text + every linked Botschaft (enacted + amendments) + leading court interpretations + doctrinal commentary, all ordered by date. Combines statutes.db, materialien.db, reference_graph.db, and ok_commentaries.db into one...4 params

Chronological story of a single statute article: current text + every linked Botschaft (enacted + amendments) + leading court interpretations + doctrinal commentary, all ordered by date. Combines statutes.db, materialien.db, reference_graph.db, and ok_commentaries.db into one...

Parameters* required
article*string
Article number, e.g. '41' for Art. 41 OR.
languagestring
one of de · fr · itdefault: de
leading_cases_limitinteger
Max leading cases (default 5, max 15).default: 5
sr_number*string
SR number of the federal law, e.g. '220' for OR.
get_regesteGet the official Regeste (head-note) of a Swiss court decision. The Regeste is the court's own formulation of the legal rule established — for BGEs especially, this is the canonical citation target. Often references specific Erwägungen via '(E. 5.2.1)' which can then be retrie...1 params

Get the official Regeste (head-note) of a Swiss court decision. The Regeste is the court's own formulation of the legal rule established — for BGEs especially, this is the canonical citation target. Often references specific Erwägungen via '(E. 5.2.1)' which can then be retrie...

Parameters* required
decision_id*string
decision_id, BGE reference, or docket number.
check_claim_supportVerify whether a Swiss court decision actually supports a legal claim. Uses an independent Sonnet judge to compare the claim against verbatim text from the decision (Erwägung if pinpoint given, else Regeste, else first portion of full text). Returns {supports: yes|partial|no|c...3 params

Verify whether a Swiss court decision actually supports a legal claim. Uses an independent Sonnet judge to compare the claim against verbatim text from the decision (Erwägung if pinpoint given, else Regeste, else first portion of full text). Returns {supports: yes|partial|no|c...

Parameters* required
claim*string
The legal proposition you want to verify (e.g., 'A landlord is liable for fire-police violations under Art. 256 OR.').
decision_id*string
Decision you intend to cite as authority.
pinpointstring
Optional Erwägung number ('2.3'). If given, only that paragraph is judged; more precise verdict.
attest_responseMANDATORY FINAL-STEP AUDIT of your draft answer. Checks five hallucination classes: (1) every case citation (BGE/BGer/BVGer/BStGer/BPatGer/MKGE, FR/IT forms) exists and any pinpoint (E. X.Y) resolves to a real Erwägung; (2) every 'Art. X LAW' statute reference resolves; (3) qu...3 params

MANDATORY FINAL-STEP AUDIT of your draft answer. Checks five hallucination classes: (1) every case citation (BGE/BGer/BVGer/BStGer/BPatGer/MKGE, FR/IT forms) exists and any pinpoint (E. X.Y) resolves to a real Erwägung; (2) every 'Art. X LAW' statute reference resolves; (3) qu...

Parameters* required
audit_groundingboolean
When true, additionally runs the LLM-judge grounding rail: for each verified case citation in the draft, the preceding claim sentence is checked against the cited Erwägung / Regeste / text by an in...
audit_quotesboolean
Verifies that every quoted passage (60-400 chars) within ~250 chars of a case citation or an 'Art. X LAW' reference appears verbatim in the cited decision or in that statute article (DE/FR/IT). On...default: true
draft_text*string
Your draft response text.
citeGet the canonical Swiss citation string for a decision reference. CALL THIS BEFORE writing any case citation in your response. Returns ready-to-embed citation_string (DE/FR/IT variants plus a canonical URL) and a verbatim rule_statement. If the reference doesn't exist, returns...3 params

Get the canonical Swiss citation string for a decision reference. CALL THIS BEFORE writing any case citation in your response. Returns ready-to-embed citation_string (DE/FR/IT variants plus a canonical URL) and a verbatim rule_statement. If the reference doesn't exist, returns...

Parameters* required
languagestring
Primary language for the citation_string field (all three variants always returned). Default: de.one of de · fr · it
pinpointstring
Optional Erwägung/consid. number ('2.3', '5.2.1'). Included in the citation and as a #e-2-3 URL anchor.
reference*string
Any form of Swiss case reference: decision_id, BGE ref, or docket number. E.g. 'BGE 140 III 86', '4A_747/2012', 'bger_4A_747_2012', 'MKGE 16 Nr. 1'.
get_doctrineGet statute text + leading cases + doctrinal timeline + Federal Council Botschaft (legislative intent) + scholarly commentary for a Swiss law article or legal concept. ALWAYS USE THIS for questions about the purpose, intent, or ratio legis of a provision — it returns the Botsc...1 params

Get statute text + leading cases + doctrinal timeline + Federal Council Botschaft (legislative intent) + scholarly commentary for a Swiss law article or legal concept. ALWAYS USE THIS for questions about the purpose, intent, or ratio legis of a provision — it returns the Botsc...

Parameters* required
query*string
Statute article ('Art. 41 OR', 'Art. 8 BV') or legal concept ('Tierhalterhaftung', 'culpa in contrahendo'). German preferred.
generate_exam_questionGenerate a Swiss law exam practice question (Fallbearbeitung) based on a real BGE. Returns a fact pattern (Sachverhalt) from a real court decision and a hidden analysis (applicable statutes, leading case, legal test, correct outcome). Workflow: present the fact_pattern and hin...2 params

Generate a Swiss law exam practice question (Fallbearbeitung) based on a real BGE. Returns a fact pattern (Sachverhalt) from a real court decision and a hidden analysis (applicable statutes, leading case, legal test, correct outcome). Workflow: present the fact_pattern and hin...

Parameters* required
exclude_idsarray
decision_ids already used in this session — avoids repetition.
topic*string
Legal area, statute, or concept. Examples: 'Haftpflichtrecht', 'Art. 41 OR', 'Mietrecht', 'Strafrecht', 'Vertragsrecht'.
get_lawAUTHORITATIVE LOOKUP for the text of any Swiss law article — federal OR cantonal. Federal (canton='CH', default): Fedlex mirror, all federal acts (OR, ZGB, StGB, ZPO, StPO, BV, SchKG, BGG, DBG, KVG …) in DE/FR/IT; names match in any language, case, dots or spaces (Cst, OPP2),...7 params

AUTHORITATIVE LOOKUP for the text of any Swiss law article — federal OR cantonal. Federal (canton='CH', default): Fedlex mirror, all federal acts (OR, ZGB, StGB, ZPO, StPO, BV, SchKG, BGG, DBG, KVG …) in DE/FR/IT; names match in any language, case, dots or spaces (Cst, OPP2),...

Parameters* required
abbreviationstring
Law abbreviation in DE, FR or IT ('BV'/'Cst'/'Cost', 'OR'/'CO', 'ZGB'/'CC', 'StGB'/'CP', 'BGG'/'LTF', 'OPP 2'), a treaty's common name ('EMRK', 'IPBPR', 'KRK', 'LugÜ', 'CISG') or a former name ('OG...
articlestring
Article number to retrieve (e.g., '8', '41a', '1bis'). For cantonal § laws (ZH, SH, AI, AR, BS, BL, AG), pass the § number without the § sign. If omitted, returns the full article list.
as_ofstring
Past date, ISO 'YYYY-MM-DD' (or Swiss 'DD.MM.YYYY'), to retrieve the HISTORICAL edition of a federal law in force on that date. The response names the edition (snapshot_date), the act's title and i...
cantonstring
Two-letter canton code (ZH, BE, LU, …) or 'CH' for federal. Default 'CH' preserves backward compat.default: CH
languagestring
Language for article text: de, fr, it. For cantonal laws, must match the canton's publication language (fr for FR/GE/JU/NE/VD, it for TI, de otherwise).one of de · fr · itdefault: de
sr_numberstring
Statute number. Federal: SR number ('210'=ZGB, '220'=OR, '101'=BV). Cantonal: the canton's systematic number — e.g. ZH 'LS' number '554.5' (Hundegesetz), '550.1' (Polizeigesetz). The `systematic_nu...
systematic_numberstring
Alias for sr_number — the cantonal-friendly name (LS / systematic number), matching get_legislation. Either field works.
search_lawsUse this tool to find STATUTE ARTICLES by topic — federal (Fedlex mirror) AND cantonal (all 26 cantons; LexFind with canton=, else a local copy), interleaved. Not for whole laws by name (search_legislation) or court decisions (search_decisions). BM25-ranked per corpus, merged...6 params

Use this tool to find STATUTE ARTICLES by topic — federal (Fedlex mirror) AND cantonal (all 26 cantons; LexFind with canton=, else a local copy), interleaved. Not for whole laws by name (search_legislation) or court decisions (search_decisions). BM25-ranked per corpus, merged...

Parameters* required
cantonstring
Two-letter canton code (ZH, BE, …) to restrict to one canton's statute corpus. 'CH' → federal only. Omit to search every jurisdiction.
jurisdictionstring
Explicit scope override: 'all' (default), 'federal', or 'cantonal'. Most callers should omit this and let sr_number/canton drive the scope.one of all · federal · cantonaldefault: all
languagestring
OPTIONAL filter. Restricts results to ONE language. Omit (recommended default) to search across all three official languages — most laws exist in DE/FR/IT and a filter silently hides valid hits in...one of de · fr · it
limitinteger
Maximum merged results (1-50).default: 10
query*string
Search query. Explicit syntax is supported and operators must be UPPERCASE: 'Miete OR Pacht', 'Kündigung AND Frist' (AND with an absent term returns 0), '"exakte Wortfolge"' for phrases, 'Verfahr*'...
sr_numberstring
Restrict search to a specific federal law by SR number. Implies jurisdiction='federal'.
get_commentaryLook up a commentary on a Swiss federal law article: OnlineKommentar.ch (CC-BY-4.0; BV, OR, ZGB, StGB, StPO, ZPO, DSG, SchKG and more) and, for the BV, OpenLegalCommentary.ch (CC BY-SA 4.0; AI-generated, de/fr/it), which yields to OnlineKommentar where both exist. Without arti...5 params

Look up a commentary on a Swiss federal law article: OnlineKommentar.ch (CC-BY-4.0; BV, OR, ZGB, StGB, StPO, ZPO, DSG, SchKG and more) and, for the BV, OpenLegalCommentary.ch (CC BY-SA 4.0; AI-generated, de/fr/it), which yields to OnlineKommentar where both exist. Without arti...

Parameters* required
abbreviationstring
Law abbreviation (e.g., 'OR', 'BV', 'ZGB', 'StGB'). Preferred over sr_number.
articlestring
Article number (e.g., '41', '8'). Omit to list available articles.
cantonstring
Two-letter canton code for a cantonal act (e.g. 'SH' with abbreviation 'VRG' or 'JG'). Omit for federal law.
languagestring
Preferred language (de, en, fr, it). Falls back to de if unavailable.default: de
sr_numberstring
SR number of the law (e.g., '220' for OR). Use if abbreviation unknown.
search_commentariesUse this tool ONLY for article-anchored commentary — doctrinal discussion tied to a specific statute article: OnlineKommentar.ch / OpenLegalCommentary.ch (federal law) and the Kommentar zur Schaffhauser Verwaltungsrechtspflege (Schaffhausen VRG and JG; abbreviation 'VRG SH' /...4 params

Use this tool ONLY for article-anchored commentary — doctrinal discussion tied to a specific statute article: OnlineKommentar.ch / OpenLegalCommentary.ch (federal law) and the Kommentar zur Schaffhauser Verwaltungsrechtspflege (Schaffhausen VRG and JG; abbreviation 'VRG SH' /...

Parameters* required
abbreviationstring
Filter by law abbreviation (e.g., 'OR', 'StGB'; 'VRG SH' or 'JG SH' for the Schaffhausen commentary).
languagestring
OPTIONAL filter (de/fr/it/en). Omit (recommended default) to search across all languages. Set ONLY when the user explicitly asks for one-language results; do NOT auto-apply based on conversation la...
limitinteger
Maximum results (1-50, default 10).default: 10
query*string
Search query (supports FTS5 syntax: quotes for phrases, OR for alternatives).
search_scholarshipUse this tool for open-access SCHOLARSHIP (Lehre): OA journal articles (sui generis et al.), OA legal commentaries (OnlineKommentar, OpenLegalCommentary — this tool SUBSUMES search_commentaries), dissertations and theses from Swiss university repositories, and federal legal-po...9 params

Use this tool for open-access SCHOLARSHIP (Lehre): OA journal articles (sui generis et al.), OA legal commentaries (OnlineKommentar, OpenLegalCommentary — this tool SUBSUMES search_commentaries), dissertations and theses from Swiss university repositories, and federal legal-po...

Parameters* required
authorstring
Filter by author (substring match on the authors field). May be used WITHOUT a query for a pure bibliographic browse (all works by an author).
languagestring
OPTIONAL filter by language (de/fr/it/en). Omit to search across all languages (recommended — the corpus is trilingual).
limitinteger
Maximum results (1-50, default 10).default: 10
pub_typestring
Filter by type: 'article', 'commentary', 'dissertation', 'book', 'chapter', 'master_thesis', 'working_paper', 'report'.
querystring
Topic query (FTS5 syntax: quotes for phrases, OR for alternatives). Optional — may be omitted when an `author` (or other) filter is given, which returns a bibliographic browse instead of a topical...
sortstring
Order: 'relevance' (BM25, default for a topic query), 'year' (newest first), 'year_asc' (oldest first). With no query the default is newest-first.one of relevance · year · year_asc
sourcestring
Filter by source slug (e.g. 'sui_generis', 'onlinekommentar', 'openlegalcommentary', 'zora_law').
year_maxinteger
Latest publication year.
year_mininteger
Earliest publication year.
get_scholarshipFetch a single OA legal publication (article, dissertation, commentary, etc.) by its pub_id. Returns full metadata + abstract + full text if available + cross-citations to statutes and decisions.1 params

Fetch a single OA legal publication (article, dissertation, commentary, etc.) by its pub_id. Returns full metadata + abstract + full text if available + cross-citations to statutes and decisions.

Parameters* required
pub_id*string
Canonical pub_id, e.g. 'sui_generis:article-1382' or 'onlinekommentar:<uuid>'.
find_scholarship_citing_statuteFind OA legal scholarship that cites a given Swiss statute article. Sourced from article-anchored commentaries (OnlineKommentar / OpenLegalCommentary) PLUS full-text citation extraction across the open-access journal corpus (~90k statute references resolved from 9k full-text r...3 params

Find OA legal scholarship that cites a given Swiss statute article. Sourced from article-anchored commentaries (OnlineKommentar / OpenLegalCommentary) PLUS full-text citation extraction across the open-access journal corpus (~90k statute references resolved from 9k full-text r...

Parameters* required
articlestring
Article number (e.g. '41'). Omit for all articles of the law.
limitinteger
Maximum results (1-100, default 20).default: 20
sr_number*string
Swiss SR number (e.g. '220' for OR, '210' for ZGB).
find_scholarship_citing_decisionFind OA legal scholarship that cites a specific Swiss court decision. Reverse direction of the scholarship↔caselaw bridge: given a decision_id (e.g. 'bge_BGE_140_III_86' or 'bger_4A_571_2008'), return open-access publications that cite it in their full text. Citations are extr...2 params

Find OA legal scholarship that cites a specific Swiss court decision. Reverse direction of the scholarship↔caselaw bridge: given a decision_id (e.g. 'bge_BGE_140_III_86' or 'bger_4A_571_2008'), return open-access publications that cite it in their full text. Citations are extr...

Parameters* required
decision_id*string
Canonical decision_id (e.g. 'bge_BGE_140_III_86', 'bger_4A_571_2008').
limitinteger
Maximum results (1-100, default 20).default: 20
list_scholarship_sourcesList the open-access legal scholarship sources currently indexed, with publication counts by source, type, and language. Use this to discover what corpora are available before searching.

List the open-access legal scholarship sources currently indexed, with publication counts by source, type, and language. Use this to discover what corpora are available before searching.

No parameters. Call it with no arguments.

get_scholarship_full_textFetch the full text of an OA legal publication by pub_id, on demand. Cached after first fetch so subsequent calls are instant. License-gated: only records under CC-BY-* (except CC-BY-ND), OA-Swiss-federal, or OA-author-permitted-reuse are extracted. ND/all-rights-reserved reco...1 params

Fetch the full text of an OA legal publication by pub_id, on demand. Cached after first fetch so subsequent calls are instant. License-gated: only records under CC-BY-* (except CC-BY-ND), OA-Swiss-federal, or OA-author-permitted-reuse are extracted. ND/all-rights-reserved reco...

Parameters* required
pub_id*string
Canonical pub_id (from search_scholarship results).
get_materialienLook up Materialien for a Swiss federal law article. Returns: `sources` = per-article digests of legislative intent (BV and BGFA only); `botschaft_documents` = the Bundesblatt documents that concern the article (Botschaften, Berichte, Stellungnahmen, committee reports, Erlasse...3 params

Look up Materialien for a Swiss federal law article. Returns: `sources` = per-article digests of legislative intent (BV and BGFA only); `botschaft_documents` = the Bundesblatt documents that concern the article (Botschaften, Berichte, Stellungnahmen, committee reports, Erlasse...

Parameters* required
articlestring
Article number (e.g., '1', '8', '10a'). Omit to get all articles.
doc_typestring
OPTIONAL: restrict `botschaft_documents` to one Fedlex document type (botschaft, bericht_bundesrat, stellungnahme_bundesrat, bericht_kommission, erlassentwurf, vorentwurf_erlass, vernehmlassung_ero...one of botschaft · bericht_bundesrat · stellungnahme_bundesrat · bericht_kommission · erlassentwurf · vorentwurf_erlass
law_code*string
Law abbreviation (e.g., 'BV', 'BGFA', 'OR', 'StGB').
search_materialienUse this tool for DIGESTED legislative history — per-article intent summaries and key arguments, not verbatim text. COVERAGE IS NARROW: BV and BGFA digests (167 articles) plus BV debate transcripts, and nothing else. For any other law this returns 0 hits, which means 'outside...4 params

Use this tool for DIGESTED legislative history — per-article intent summaries and key arguments, not verbatim text. COVERAGE IS NARROW: BV and BGFA digests (167 articles) plus BV debate transcripts, and nothing else. For any other law this returns 0 hits, which means 'outside...

Parameters* required
doc_typestring
Accepted for symmetry with search_botschaft / get_materialien, but a NO-OP here: the curated digest carries no Fedlex document type, so the filter does not narrow results (echoed back as doc_type_f...one of botschaft · bericht_bundesrat · stellungnahme_bundesrat · bericht_kommission · erlassentwurf · vorentwurf_erlass
law_codestring
Filter by law abbreviation (e.g., 'BGFA').
limitinteger
Maximum results (1-50, default 10).default: 10
query*string
Search query (natural language or FTS5 syntax).
search_legislationUse this tool to find WHOLE LAWS by name or subject — 33,000+ federal and cantonal enactments from LexFind.ch; the entry point for cantonal questions ('Hundegesetz Bern', 'loi sur l'énergie Vaud'). Not for article-level topic search (search_laws) or the core federal codes (get...7 params

Use this tool to find WHOLE LAWS by name or subject — 33,000+ federal and cantonal enactments from LexFind.ch; the entry point for cantonal questions ('Hundegesetz Bern', 'loi sur l'énergie Vaud'). Not for article-level topic search (search_laws) or the core federal codes (get...

Parameters* required
active_onlyboolean
Only show laws currently in force (default true).default: true
cantonstring
Two-letter canton code (ZH, BE, LU, UR, SZ, OW, NW, GL, ZG, FR, SO, BS, BL, SH, AR, AI, SG, GR, AG, TG, TI, VD, VS, NE, GE, JU) or 'CH' for federal. Omit to search all 26 cantons + federal at once.
fetch_top_n_textsinteger
If > 0, download + parse the full text of the top N results (max 10) and return each with full_text_preview, article_count, and sample_articles. Use 1-3 for natural-language questions so you can an...default: 0
languagestring
OPTIONAL filter. Restricts results to ONE language version. Omit (recommended default) to fan out across DE/FR/IT and merge results — LexFind's API is single-language per request, so omission trigg...one of de · fr · it
limitinteger
Max results (1-60, default 20).default: 20
query*string
Search query in natural language or keywords. Examples: 'Hundegesetz', 'loi sur l'énergie', 'Mietrecht Kanton Zürich', 'Baugesetz'.
search_in_contentboolean
Also search inside the law text, not just titles and keywords (slower).default: false
get_legislationRetrieve the FULL TEXT and article list of a specific Swiss law, federal or cantonal, by LexFind ID or SR/systematic number. For federal laws in the Fedlex mirror this is instant (local SQLite). For cantonal laws, the law is downloaded from LexFind as PDF, parsed with PyMuPDF,...5 params

Retrieve the FULL TEXT and article list of a specific Swiss law, federal or cantonal, by LexFind ID or SR/systematic number. For federal laws in the Fedlex mirror this is instant (local SQLite). For cantonal laws, the law is downloaded from LexFind as PDF, parsed with PyMuPDF,...

Parameters* required
cantonstring
Canton for systematic number lookup (default CH). Required for cantonal laws.default: CH
include_versionsboolean
Include full version history (default false).default: false
languagestring
Result language: de, fr, it.one of de · fr · itdefault: de
lexfind_idinteger
LexFind ID of the law (from search_legislation results). Positive integer; omit it when unknown rather than passing 0.
systematic_numberstring
SR/systematic number (e.g., '220' for OR, '210' for ZGB). Used when lexfind_id not available. One of lexfind_id or systematic_number is required.
browse_legislation_changesBrowse recent legislation changes for a canton or federal level. Shows new laws, amendments, and abrogations with dates.2 params

Browse recent legislation changes for a canton or federal level. Shows new laws, amendments, and abrogations with dates.

Parameters* required
cantonstring
Canton code (CH for federal, ZH, BE, etc.). Default: CH.default: CH
languagestring
OPTIONAL filter. Restricts results to ONE language version. Omit (recommended default) to fan out across DE/FR/IT and merge results — LexFind's API is single-language per request, so omission trigg...one of de · fr · it
search_practiceUse this tool for federal ADMINISTRATIVE PRACTICE (Verwaltungspraxis): Wegleitungen, Kreisschreiben, Weisungen, Rundschreiben — agency guidance, not court decisions. 10,500+ documents: BSV (AHV/IV/EL/EO/FamZ/BVG Wegleitungen, Kreisschreiben, Mitteilungen, every version), OAK B...8 params

Use this tool for federal ADMINISTRATIVE PRACTICE (Verwaltungspraxis): Wegleitungen, Kreisschreiben, Weisungen, Rundschreiben — agency guidance, not court decisions. 10,500+ documents: BSV (AHV/IV/EL/EO/FamZ/BVG Wegleitungen, Kreisschreiben, Mitteilungen, every version), OAK B...

Parameters* required
cantonstring
Restrict to one canton's SchKG documents (its supervisory authority's circulars and Existenzminimum guideline, in schkg_kantone and the older copies in bj_schkg). KBKS = the national conference of...one of ZH · BE · LU · UR · SZ · OW
doc_typestring
Filter by document type. wegleitung (SECO ArG 1,102 + BSV WEL/RWL…), rundschreiben (FINMA 1,017 + BSV/SEM), vollzugshilfe (297), kreisschreiben (ESTV 285 + BSV/BAG/BJ), rundschreiben_anhang (132 —...one of wegleitung · rundschreiben · vollzugshilfe · kreisschreiben · rundschreiben_anhang · mwst_branchen_info
include_supersededboolean
Return every retained version of a document (FINMA, BSV) instead of collapsing to the newest. Set for point-in-time questions.default: false
issuing_authoritystring
Filter by authority. FINMA (1,133), SECO (Arbeitsgesetz 1,102 + AVIG-Praxis), ESTV (438), BAFU (297), SEM (Weisungen 92 + Handbuch), BSV (6,083, social insurance practice), BAG (38), BJ (debt enfor...one of FINMA · SECO · ESTV · BAFU · SEM · BSV
languagestring
OPTIONAL filter (de/fr/it; en for UN and some FINMA documents). Omit (recommended default) to search across all languages. Set ONLY when the user explicitly asks for one-language results.
limitinteger
Maximum results (1-50, default 10).default: 10
query*string
Search query (FTS5 syntax: quotes for phrases, OR for alternatives, NEAR(term1 term2, N) for proximity).
sourcestring
Filter by source key. finma_rs (1,133), seco_arg (1,102), bafu_vollzug (297), estv_ks (285), estv_mwst (153), sem_weisungen (92), bsv_weisungen (BSV Wegleitungen/Kreisschreiben/Rundschreiben/Mittei...one of finma_rs · seco_arg · bafu_vollzug · estv_ks · estv_mwst · sem_weisungen
get_practiceRetrieve a single federal administrative-practice document by its doc_id (e.g. 'estv_ks_ks_nr_28', 'sem_weisungen_weisungen-aug-d', 'bsv_weisungen_6930_v20_de', 'seco_alv_avig_ale_de', 'un_uhri_3f3a9db7-5e9a-416f-ad28-8c8f97a8322c_en'). Returns the body text, title, date, issu...3 params

Retrieve a single federal administrative-practice document by its doc_id (e.g. 'estv_ks_ks_nr_28', 'sem_weisungen_weisungen-aug-d', 'bsv_weisungen_6930_v20_de', 'seco_alv_avig_ale_de', 'un_uhri_3f3a9db7-5e9a-416f-ad28-8c8f97a8322c_en'). Returns the body text, title, date, issu...

Parameters* required
doc_id*string
Document identifier returned by search_practice.
max_charsinteger
Characters of body text per part (default 50,000, max 150,000).default: 50000
offsetinteger
Character offset into the body text to start from (default 0); use next_offset from the previous part.default: 0

Sponsors

Readme

OpenCaseLaw

Open Swiss case law and legislation for legal research and AI.

1M+ decisions · all 26 cantons · 1875–today · citation graph · MCP + REST + CLI + Parquet · CC0 data · MIT code

Try the search · Chat with your AI · Automate research · Download the dataset · API documentation

What you can do

  • Find Swiss decisions across federal and cantonal courts, in German, French and Italian.
  • Trace citations between cases and identify the leading decisions on a question.
  • Query case law and legislation from Claude, ChatGPT-compatible clients, or any MCP client.
  • Save repeatable research scripts, inspect citation resolution, and preserve selected evidence with the research CLI.
  • Download the corpus for legal NLP, retrieval and graph research.

Connect in 30 seconds

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

View the full README on GitHub

Details

Repository
github.com/jonashertner/caselaw-repo-1
Website
opencaselaw.ch
Transport
HTTP, SSE
Registry
MCP registry, active
Tools verified
Nov 6, 2026