Dk MCP Server

MCP server for Danish legislation (Retsinformation) with native ELI and verifiable citations.

Local serverstdioPython

What is the Dk MCP server?

Most developer tooling work still happens through a UI a human drives. Dk MCP server moves it into the conversation instead. MCP server for Danish legislation (Retsinformation) with native ELI and verifiable citations.

The short version

An MCP server for the Danish Retsinformation legal database (retsinformation.dk). It fetches Danish legislation as LexDania 2.1 XML behind native ELI URIs, with verifiable citations.

Getting it running

dk-eli-mcp on PyPI is all you need. Most clients run it directly, so configuration is a few lines and a restart.

The tools it exposes

The server publishes 3 tools. What each one is for:

  • dk_get_act — Metadata for a document by year + number, or by accession
  • dk_get_text — Full LexDania XML of a document (verbatim official text)
  • dk_recent_changes — Documents changed on a given date (harvest API)

What it needs from you

Configuration is passed through the environment: DK_ELI_BASE_URL, DK_ELI_API_URL. Treat anything key-shaped as a real credential — scope it to the minimum the server needs, and rotate it if it ever lands in a shared config.

Things to watch

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

How it compares

Plenty of developer tooling servers cover similar ground. The differences that matter in practice are scope of access and how much setup stands between you and a working tool call. Dk's toolset — dk_get_act, dk_get_text, dk_recent_changes — is a fair guide to whether it matches your workflow. It is maintained by matematicsolutions; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Available tools

ToolWhat it does
dk_get_actMetadata for a document by year + number, or by accession.
dk_get_textFull LexDania XML of a document (verbatim official text).
dk_recent_changesDocuments changed on a given date (harvest API).

How to install the Dk MCP server

{
  "mcpServers": {
    "dk-eli-mcp": { "command": "dk-eli-mcp" }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

VariableDescriptionRequired
DK_ELI_BASE_URLEndpoint or connection string the server talks to.Yes
DK_ELI_API_URLEndpoint or connection string the server talks to.Yes

Example prompts to try

  • Use Dk to dk get act.
  • Use Dk to dk get text.
  • Use Dk to dk recent changes.

Frequently asked questions

It connects Dk to MCP-compatible AI assistants such as Claude and Cursor, exposing 3 tools (dk_get_act, dk_get_text, dk_recent_changes) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Dk directly.