DataPrem MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@DataPrem MCP ServerLook up the cadastral data for Calle Gran Vía 28, Madrid"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
DataPrem MCP Server
A Model Context Protocol (MCP) server that exposes Spanish public-data sources to AI agents (Claude Desktop, Cursor, ChatGPT, …).
It is a thin client of the DataPrem REST API: each MCP tool maps to an HTTPS call against api.dataprem.com using your API key.
Requires the MCP Python SDK 2.x (mcp>=2.0.0,<3).
Tool status (0.4.0)
Tool | Status | Source |
| Live | Sede Electrónica del Catastro |
| Planned | Boletín Oficial del Registro Mercantil |
| Planned | Centro de Documentación Judicial |
| Planned | Plataforma de Contratación del Sector Público |
Planned tools are in the catalogue so an agent can discover them, and they call the API like every other tool. Until a connector ships the API answers not_implemented, so no tool ever returns data that is not real.
Related MCP server: eRegulations MCP Server
Getting an API key
Every tool requires a Bearer token from api.dataprem.com:
Request access by email to
info@dataprem.com, describing your use case.You will receive a token prefixed
dpa_…along with the API URL.Configure it in your MCP client (next section).
Installation
Requires Python 3.11+.
# Via PyPI (recommended for MCP clients)
uvx dataprem-mcp
# Or local install for development
pip install -e ".[dev]"Claude Desktop configuration
Edit claude_desktop_config.json (Mac: ~/Library/Application Support/Claude/claude_desktop_config.json):
{
"mcpServers": {
"dataprem": {
"command": "uvx",
"args": ["dataprem-mcp"],
"env": {
"DATAPREM_API_KEY": "dpa_YOUR_TOKEN_HERE",
"DATAPREM_API_URL": "https://api.dataprem.com"
}
}
}
}Restart Claude Desktop. The four tools should show up as available to the model.
Server-side HTTP transport
For clients that cannot spawn the server as a subprocess (e.g. a multi-request web app) there is a streamable-http transport that runs the server as a long-lived process listening for JSON-RPC over HTTP.
# Without Docker
python -m dataprem_mcp --transport streamable-http --host 0.0.0.0 --port 8080
# With Docker
docker compose up dataprem_mcp # local image build; exposed only on the internal networkThe MCP endpoint is /mcp (no trailing slash). The standard handshake (initialize → tools/list → tools/call) works with Content-Type: application/json and Accept: application/json, text/event-stream. Each conversation receives an mcp-session-id that the client must echo back on subsequent requests.
# Example: initialize handshake
curl -sL -X POST http://127.0.0.1:8080/mcp \
-H 'Content-Type: application/json' \
-H 'Accept: application/json, text/event-stream' \
-d '{
"jsonrpc": "2.0",
"id": 1,
"method": "initialize",
"params": {
"protocolVersion": "2025-03-26",
"clientInfo": {"name": "smoke", "version": "1"},
"capabilities": {}
}
}' -iBy default the compose service does not publish the port to the host: place it on a Docker network shared with your client and reach it as http://dataprem_mcp:8080/mcp.
Alternative configuration (local development)
{
"mcpServers": {
"dataprem-dev": {
"command": "python",
"args": ["-m", "dataprem_mcp"],
"cwd": "/path/to/dataprem-mcp",
"env": {
"DATAPREM_API_KEY": "dpa_dev_token",
"DATAPREM_API_URL": "http://localhost:8000"
}
}
}
}Environment variables
Variable | Default | Description |
| (empty) | Bearer token ( |
|
| API base URL. Override to point at a development environment. |
Tools — reference
dataprem_catastro_lookup ✅ Live
Looks up cadastral data for a property. Two modes are supported:
By cadastral reference:
Parameter | Type | Description |
| string | Cadastral reference (14, 18 or 20 characters) |
By address:
Parameter | Type | Required | Description |
| string | yes | Literal address (street type + name + number) |
| string | yes | Municipality |
| string | no | Province |
Returns the normalised cadastral record (class, use, surfaces, year of construction, address with INE codes, breakdown of constructions by floor and use). Does not expose the owner for LOPD/GDPR reasons.
dataprem_borme_search (planned)
Parameter | Type | Required |
| string | yes |
| string YYYY-MM-DD | no |
| string YYYY-MM-DD | no |
dataprem_cendoj_search (planned)
Parameter | Type | Required |
| string | yes |
| string | no |
| string YYYY-MM-DD | no |
dataprem_tenders_search (planned)
Parameter | Type | Required |
| string | yes |
| string | no |
|
| no |
Response shape
Every tool returns a dict marking success or failure with ok:
{ "ok": true, "data": { ... cadastral record ... } }
{ "ok": false, "error": "unauthorized", "message": "API key invalid or revoked..." }A planned source answers without data:
{ "ok": false, "error": "not_implemented", "message": "The borme source is not available yet.",
"source": "borme" }Error codes:
| Meaning |
|
|
| Required parameters are missing |
| Token revoked or expired |
| The upstream returned no match |
| The source rejected the input (malformed RC, unknown street, …) |
| Monthly quota exhausted |
| The source is in the catalogue but its connector has not shipped |
| The source or DataPrem temporarily unavailable |
|
|
Development
# Install dev dependencies
pip install -e ".[dev]"
# Run tests
pytest
# Start the installed console script over stdio and list its tools,
# the same way a desktop client does. The suite alone cannot catch a
# package that imports fine from the source tree but not once installed.
python scripts/smoke_stdio.py
# Run the server with a local API key
DATAPREM_API_KEY=dpa_xxx DATAPREM_API_URL=http://localhost python -m dataprem_mcpReleasing
Publishing runs from CI through PyPI trusted publishing, so no token lives on anyone's machine:
# bump the version in pyproject.toml and add the CHANGELOG entry, then
git tag 0.3.4
git push origin 0.3.4The release workflow builds, checks the artifact, installs the wheel, starts it over stdio, refuses to continue if the tag disagrees with the built version, and only then publishes.
License
MIT
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 Servers
- AlicenseAqualityDmaintenanceA Model Context Protocol server that connects AI assistants to Brazilian public data services, providing access to postal codes, company registrations, bank information, area codes, IBGE data, currency exchange rates, and domain registration status.Last updated11144MIT
- FlicenseDquality-maintenanceA Model Context Protocol server implementation that provides structured, AI-friendly access to eRegulations data, making it easier for AI models to answer user questions about administrative procedures.Last updated420
- Alicense-qualityAmaintenanceModel Context Protocol Server for European Parliament Open Data Providing AI assistants with structured access to parliamentary datasets and OSINT Intelligence CapabilitiesLast updated1,73122Apache 2.0
- AlicenseAqualityFmaintenanceMCP server for querying Spanish government open data APIs including grants, legislation, company registry, statistics, and open data catalog. Enables LLMs to access Spanish public information on-the-fly.Last updated265MIT
Related MCP Connectors
A Model Context Protocol server for Wix AI tools
MCP server for Mireye Earth — federal-source-cited geospatial data for any MCP-aware agent.
MCP server exposing the Backtest360 engine API as tools for AI agents.
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/tekniadev/dataprem-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server