mcp-isap
This server provides access to over 96,000 Polish legal acts (1918–present) from Dziennik Ustaw (DU) and Monitor Polski (MP) via the Sejm ELI API. You can:
Search for acts by title fragment, publication year, publisher (DU/MP), act type, in-force status, and limit results (1–50).
Get detailed metadata for a specific act using its ELI identifier (e.g.,
DU/2018/1000), including title, type, status, keywords, entry into force, and links to HTML/PDF text and the ISAP page.Retrieve the full text of an act, paginated at 5,000 characters per page, with support for searching within the text. Indicates whether the text is consolidated or original, and provides PDF fallback links when plain text is unavailable. All responses include structured citations with title, URL, ELI, display address, publisher, year, document type, status, and promulgation date for easy integration.
mcp-isap
Installation (one command)
Published on npm + MCP Registry (io.github.matematicsolutions/mcp-isap). Run without cloning:
npx -y @matematicsolutions/mcp-isapMCP client configuration (stdio):
{ "mcpServers": { "mcp-isap": { "command": "npx", "args": ["-y", "@matematicsolutions/mcp-isap"] } } }(Building from source - below.)
MCP server for Polish legislation - Dziennik Ustaw (Journal of Laws, DU) + Monitor Polski (MP)
via the official Sejm ELI API (api.sejm.gov.pl/eli).
Related MCP server: mcp-nsa
Why
mcp-saos (general courts) + mcp-nsa (administrative) + mcp-eu-sparql (EU)
cover the case-law side. mcp-isap adds legislation - statutes, regulations,
official announcements, international agreements. This closes the triad:
STATUTE + CASE LAW + EU LAW
↓ ↓ ↓
ISAP SAOS+NSA EUR-Lex
↓ ↓ ↓
law firm asks about GDPR
→ 4 connectors in parallel
→ 4 citation sections in the panelCoverage: 96,000+ acts from 1918 to today. Full ELI support (European Legislation Identifier).
Tools
search_acts(title?, year?, publisher?, type?, in_force?, limit?)- search by title fragment / year / publisher / act type / in-force status.publisher:DU(Dziennik Ustaw) orMP(Monitor Polski).get_act(eli)- act details by ELI (DU/2018/1000). Returns title, type, status, entry into force, keywords, links to HTML/PDF text and the ISAP page.get_act_text(eli, page?, search_text?)- the act's plain text (no HTML tags), paginated at 5000 characters per page. IteratepagewhilestructuredContent.pagination.has_moreis true, or passsearch_text(e.g."Art. 118.") to get the fragment around the first hit in one call.structuredContent.text_versionsays whether this is a consolidated text or the wording as promulgated - Sejm ELI serves the original wording for base acts, so for the law in force fetch the newest consolidated-text announcement listed inconsolidated_text_eli. Acts published only as PDF return thetext_unavailable_use_pdferror with links, never prose standing in for the provision.
Every response includes structuredContent.citations with fields:
title, url (ISAP UI), eli, display_address (Dz.U. 2018 poz. 1000),
publisher, year, document_type, status, in_force, promulgation.
Patron reads this field automatically and renders it in the UI panel as the section "Polish legal acts (Dz.U. / M.P. - Sejm ELI)".
Stack
Node 18+ (built-in
fetch)@modelcontextprotocol/sdkStdio transport
500 ms throttle between requests (2 req/s)
No scraping - pure REST JSON API
Build + run
npm install
npm run build
node dist/index.jsWiring into Patron
In patron/backend/mcp-servers.json:
{
"name": "isap",
"transport": "stdio",
"command": "node",
"args": ["C:/Users/<YOUR-USER>/mcp-isap/dist/index.js"],
"enabled": true
}Smoke test
echo '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"s","version":"0"}}}
{"jsonrpc":"2.0","method":"notifications/initialized"}
{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"get_act","arguments":{"eli":"DU/2018/1000"}}}' \
| node dist/index.jsShould return the Personal Data Protection Act of 10 May 2018,
status IN_FORCE, a link to ISAP and a structured citation.
Lineage
API contract derived from legal-data-hunter/sources/PL/DziennikUrzedowy
(Python + REST, MIT). TS implementation from scratch - no source code imported.
License
MIT.
Part of the MateMatic legal stack
This server is one of five MCP connectors covering Polish jurisdiction + EU law, used by Patron (AGPL-3.0) and any other MCP-aware legal AI agent.
mcp-isap (this repo) - Polish legislation (Dz.U. + M.P. via Sejm ELI)
mcp-saos - common courts, SN, TK, KIO
mcp-nsa - NSA + 16 WSA administrative courts
mcp-krs - Polish company registry (KRS)
mcp-eu-sparql - EU law + CJEU (EUR-Lex)
All five MCP servers share the same structuredContent.citations
contract: each tool returns an array of {title, url, snippet?, ...metadata}
that legal agents can render directly in their citation panel.
See matematicsolutions/.github for the full org profile.
Available Tools
3 toolsget_actARead-onlyIdempotent
Pobiera szczegoly aktu po identyfikatorze ELI (np. 'DU/2018/1000' dla Ustawy o ochronie danych osobowych z 2018 r.). Zwraca pelne metadane: tytul, typ, status obowiazywania, wejscie w zycie, slowa kluczowe, linki do tekstu HTML/PDF i strony ISAP.
| Name | Required | Description | Default |
|---|---|---|---|
| eli | Yes | Identyfikator ELI w formacie PUBLISHER/YEAR/POSITION, np. 'DU/2018/1000'. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already provide readOnlyHint, idempotentHint, etc. Description adds valuable behavioral context: what metadata is returned (title, type, status, dates, keywords, links to HTML/PDF/ISAP). No contradictions.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences, no redundancy. Every word adds value: states action, gives example, lists returned data.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given simplicity (1 param, no output schema, annotations present), description is fully adequate. Explains purpose, input format, and return content comprehensively.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Single parameter 'eli' has 100% schema coverage. Description adds an example and format specification ('PUBLISHER/YEAR/POSITION') beyond the schema, clarifying the expected input.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description uses specific verb 'Pobiera' and resource 'aktu', provides an example ELI identifier, and lists returned metadata (title, type, status, dates, keywords, links). Clearly distinguishes from siblings 'get_act_text' and 'search_acts'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Clearly indicates usage when an ELI identifier is known. Does not explicitly state when not to use or mention alternatives, but the context is clear and the sibling tools provide implicit differentiation.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_act_textARead-onlyIdempotent
Pobiera tekst aktu w formacie HTML (jesli dostepny). Zwraca pierwsze 5000 znakow czystego tekstu (bez tagow) plus link do pelnego HTML/PDF. Uzywaj po get_act zeby ocenic czy akt jest tym, czego szuka uzytkownik.
| Name | Required | Description | Default |
|---|---|---|---|
| eli | Yes | ELI aktu, np. 'DU/2018/1000'. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations are already strong (readOnlyHint, idempotentHint, destructiveHint). The description adds that it returns first 5000 chars of plain text and a link, which is helpful behavioral context. No contradictions.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences efficiently convey purpose and usage guidelines without waste. Front-loaded with the primary action.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple retrieval tool with one parameter, complete annotations, and no output schema, the description fully covers what is returned and when to use it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with a clear description for the single 'eli' parameter. The description does not add additional meaning beyond the schema, so baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool retrieves the text of an act in HTML format, returning first 5000 characters of plain text plus a link to full HTML/PDF. It also specifies usage after get_act, distinguishing it from sibling tools get_act and search_acts.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicitly instructs to use after get_act to evaluate if the act is what the user searches for, providing clear context for when and why to use this tool.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_actsARead-onlyIdempotent
Wyszukiwanie aktow prawa polskiego (Dziennik Ustaw + Monitor Polski) przez oficjalne Sejm ELI API. Pokrycie: 96 000+ aktow od 1918. Filtry: fragment tytulu, rok, publisher (DU/MP), typ aktu, status obowiazywania. Bledy: upstream_error.
| Name | Required | Description | Default |
|---|---|---|---|
| type | No | Typ aktu (po polsku, dokladnie jak w bazie). | |
| year | No | Rok publikacji aktu. | |
| limit | No | Maks liczba wynikow (1-50). Domyslnie 10. | |
| title | No | Fragment tytulu (po polsku, z odmiana - np. 'ochronie' znajdzie 'ustawa o ochronie...'). | |
| in_force | No | true = tylko obowiazujace akty. Pomin zeby objac wszystkie. | |
| publisher | No | DU = Dziennik Ustaw (ustawy, rozporzadzenia), MP = Monitor Polski (uchwaly Sejmu, postanowienia Prezydenta, obwieszczenia). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations indicate readOnlyHint=true, openWorldHint=true, idempotentHint=true, and destructiveHint=false. The description adds that errors return 'upstream_error', which provides behavioral context beyond annotations. No contradictions between description and annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise, with key information front-loaded. It covers purpose, source, coverage, and filters in a few sentences. However, it could be better structured (e.g., bullet points) for quick scanning.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 6 parameters and no output schema, the description covers the tool's purpose, source, coverage, and filters. However, it does not describe the return format (e.g., list of acts with fields), which is important for a search tool. Missing information on pagination or default limit behavior.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with each parameter described in the schema. The description lists filters but does not add significant meaning beyond the schema. For high coverage, a baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states the verb 'Wyszukiwanie' (search) and the resource 'aktow prawa polskiego' (Polish legal acts). It specifies the source (Sejm ELI API) and coverage (96,000+ acts since 1918), and lists filters. It distinguishes from siblings 'get_act' and 'get_act_text' which are retrieval tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description mentions filters but does not provide explicit guidance on when to use this tool versus alternatives or when not to use it. Usage context is implied through filter descriptions but no exclusions or prerequisites are stated.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
3 tool updates
v1.1.1- First observed
get_act - First observed
get_act_text - First observed
search_acts
TDQS
Each tool has a distinct purpose: get_act retrieves metadata by ID, get_act_text gets content, and search_acts performs filtered search. No overlap or ambiguity.
All tools follow a consistent verb_noun pattern in snake_case (get_act, get_act_text, search_acts), making it predictable.
Three tools is minimal but appropriate for a focused read-only legal lookup service. Could potentially include more, but the count is reasonable.
Covers the core workflow: search, get metadata, get text. Minor gaps like batch operations or version history, but sufficient for the stated purpose.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Polish law: search statutes (ISAP), court rulings, verify citations. Free tier + paid plans + x402.
Japan Law MCP — Japanese national laws & ordinances via the e-Gov Law API.
MCP for CanLII: Canadian case law and legislation metadata (federal, provincial, territorial).
MCP server for 3M+ Polish companies — KRS & CEIDG financials, ownership, and industry search.
Related MCP Servers
- AlicenseAqualityBmaintenanceEnables AI-powered legal research and analysis of Polish legal acts from the Sejm API. Provides comprehensive search, document retrieval, metadata analysis, and content access for legal documents from Dziennik Ustaw and Monitor Polski.1319MIT
- AlicenseAqualityCmaintenanceMCP server for Polish administrative case-law (NSA + regional administrative courts, CBOSA) with ECLI and verifiable citations.6387MIT
- AlicenseAqualityAmaintenanceMCP server for EU law via the EUR-Lex / Cellar SPARQL endpoint — legislation (ELI/CELEX) and CJEU case-law (ECLI) with verifiable citations.3681MIT
- AlicenseNot gradedqualityCmaintenanceEnables semantic search over Polish court judgments and legislative acts via MCP. Allows LLMs to retrieve legal documents using natural language queries.Apache 2.0
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/matematicsolutions/mcp-isap'
If you have feedback or need assistance with the MCP directory API, please join our Discord server