rhr-mcp
MCP server that gives AI agents structured access to Public Procurement Registry data, allowing natural language queries for planned procurements, open tenders, contract awards, buyers, and winning suppliers.
README
RHR MCP
MCP server that gives AI agents structured access to Public Procurement Registry data. Query procurements, awards, buyers, and winning suppliers using natural language through any MCP-compatible client.
Tech Stack
- Runtime — Bun >= 1.4.0
- Language — TypeScript 7
- Database — PostgreSQL
- Query builder — Kysely
- Validation — Zod
- Tooling — Oxfmt and Oxlint
Prerequisites
Download open data
Download the public datasets from:
https://riigihanked.riik.ee/rhr-web/#/open-data
Place the unzipped files directly in the data/ folder at the project root. For example, a full year looks like:
HT_2025_1.xmlHT_2025_2.xmlHT_2025_3.xmlHT_2025_4.xmlHT_2025_5.xmlHT_2025_6.xmlHT_2025_7.xmlHT_2025_8.xmlHT_2025_9.xmlHT_2025_10.xmlHT_2025_11.xmlHT_2025_12.xmlHLST_2025_1.xmlHLST_2025_2.xmlHLST_2025_3.xmlHLST_2025_4.xmlHLST_2025_5.xmlHLST_2025_6.xmlHLST_2025_7.xmlHLST_2025_8.xmlHLST_2025_9.xmlHLST_2025_10.xmlHLST_2025_11.xmlHLST_2025_12.xml
HT_*.xml files are contract notices. HLST_*.xml files are contract award notices. Add any year the same way (HT_2024_1.xml, HT_2027_1.xml, and so on) — ingest picks up every matching file in data/.
Getting Started
git clone https://github.com/margusliinev/rhr-mcp.git
cd rhr-mcp
cp .env.example .env
bun install
docker compose up -d
bun run migrate
bun run ingest
bun run dev
The MCP endpoint is available at http://localhost:3002/mcp.
Use with Cursor
With the server running, add this to your Cursor MCP config (.cursor/mcp.json):
{
"mcpServers": {
"RHR": {
"url": "http://localhost:3002/mcp"
}
}
}
Then restart MCP / reload Cursor so the RHR server shows up.
Available tools
| Tool | Description |
|---|---|
get-organization |
Get an organization by id or registry code |
get-procurement |
Get a procurement with buyers, lots, and award summaries |
get-award |
Get an award with suppliers, lot, and procurement summary |
list-organization-procurements |
List procurements where an organization is a buyer |
list-organization-awards |
List awards where an organization is a winning supplier |
list-procurement-lots |
List lots for a procurement, with award summaries linked by lot id |
search-organizations |
Search organizations by name or registry code |
search-procurements |
Search and filter procurements by text, status, CPV, value, and more |
search-awards |
Search awards by amount, date, CPV, result, and supplier |
Scripts
| Command | Description |
|---|---|
bun run dev |
Start development server |
bun run start |
Start production server |
bun run migrate |
Apply database migrations |
bun run ingest |
Load RHR data from data/ into Postgres |
bun run format |
Format code |
bun run lint |
Lint code |
bun run typecheck |
Typecheck |
License
MIT
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.
E2B
Using MCP to run code via e2b.