MCP server for Saudi economic & social statistics (GASTAT / DataSaudi) — query GDP, inflation, trade, population in plain English or Arabic from Claude, Cursor, and other AI clients. Keyless, no database.
Project description
datasaudi-mcp
Ask Claude, Cursor, or any MCP client about the Saudi economy — in plain English or Arabic. No API key. No database.
GDP, inflation, trade, population, the real‑estate price index — 277 official GASTAT datasets, live from DataSaudi, answered right inside your AI client. You never name a dataset; the model finds it.
Here it is in Claude Desktop — one plain‑English question, and the model finds the dataset, pulls Riyadh's real‑estate price index against the national trend, and charts it:
https://github.com/user-attachments/assets/99c0433c-91fb-4815-94a5-349c589ad4ec
[!NOTE] The PyPI package is publishing now. Until it lands, install from source (see Contributing). The
uvxcommand below works the moment it's live.
Ask it anything
Connect it in about 2 minutes (Install), then just ask:
💬 "What was the real‑estate price index in Riyadh by quarter, and how does it compare to the national trend?"
💬 "Who are Saudi Arabia's top trading partners? Break foreign trade down by country and exports vs. imports."
🇸🇦 "اعرض الرقم القياسي لأسعار العقارات في الرياض حسب الربع" — ask in Arabic, get Arabic back (
الرياض,مكة المكرمة). See Arabic support.
The model discovers the right dataset, pulls the numbers, and answers. You don't need to know any dataset names or query syntax.
More example prompts
- "Show me inflation and the CPI by province for the latest year — which regions were highest?"
- "How has the real‑estate price index differed between villas and apartments over time?"
- "What's the population by province, split by sex and nationality (Saudi vs. non‑Saudi)?"
- "Show me real GDP by economic sector, quarter over quarter, with year‑on‑year growth."
- "Compare average monthly wages: Saudi vs. non‑Saudi, and men vs. women."
What you can ask about
277 curated GASTAT / DataSaudi datasets. Every query hits the live API, so the numbers are as current as GASTAT publishes.
|
📈 Economy GDP (sector / expenditure / activity), CPI & inflation (national + by province), the Producer Price Index, FDI, foreign trade (country / product / flow), the trade balance, business & consumer confidence. |
👥 Society Population (province / sex / nationality / age), households & dwellings, wages, employment & participation rates, education, health, disability. |
|
🏗️ Real estate The price index by province and property type (villa / apartment / land), building permits, the construction cost index, housing tenure & type. |
🌍 More Tourism & hotel occupancy, energy & water, Hajj & Umrah, SAMA financial series, internationally‑reported (World Bank / UN) indicators. |
[!IMPORTANT] Where it stops — on purpose. A data tool you can trust tells you its edges.
- Serves the real‑estate price index (base‑year 100) — not per‑deal prices in riyals (those live in MoJ / Srem).
- No MoJ transaction volumes, no REGA, no municipal / ZATCA / CMA data, no microdata. This is the ~277‑series headline‑indicator layer, not the full national corpus.
- Geographic detail stops at the province level for most series — no city / district breakdown.
Ask for something outside this and the server says so plainly, rather than guessing.
Install
No API key, nothing to configure — DataSaudi is keyless. You'll need
uv installed.
Claude Code — one line, no file editing:
claude mcp add datasaudi -- uvx datasaudi-mcp
Claude Desktop
Settings → Developer → Edit Config, add the block below, then completely quit and reopen
Claude Desktop (fully quit from the tray — not just close the window):
{
"mcpServers": {
"datasaudi": {
"command": "uvx",
"args": ["datasaudi-mcp"]
}
}
}
Cursor
Settings → Tools & MCP → New MCP Server (or edit ~/.cursor/mcp.json), same block:
{
"mcpServers": {
"datasaudi": {
"command": "uvx",
"args": ["datasaudi-mcp"]
}
}
}
Then ask one of the questions above.
Arabic support
Saudi data in Arabic, as a first‑class feature — not an afterthought.
- Ask in Arabic, get Arabic back. Member names return in Arabic script:
الرياضfor Riyadh,مكة المكرمةfor Makkah,المنطقة الشرقيةfor the Eastern Region. - Catalog search works in Arabic too — an Arabic term matches the datasets' Arabic topic / source annotations.
- Numbers and structure are identical across languages — only the human‑readable captions change.
The tools
Three tools do the work; the model calls them for you.
| Tool | What it does |
|---|---|
list_cubes |
Search the 277‑dataset catalog by keyword (English or Arabic). |
describe_cube |
Show one dataset's breakdown dimensions and measures. |
query_cube |
Run a validated query and return tidy rows — with the query echoed back and honest paging. |
Troubleshooting — "datasaudi" doesn't show up
- Did you fully quit and reopen the app? (Closing the window isn't enough — quit from the tray.)
- Is your config valid JSON? A stray comma breaks the whole file — paste it into a JSON validator.
- Is
uvinstalled and on your PATH? Runuvx --versionin a terminal. - Check the client's MCP / tools panel for an error message next to
datasaudi.
Data source & freshness
Data comes live from api.datasaudi.sa (the DataSaudi Tesseract API, operated by the
Ministry of Economy & Planning; data produced by GASTAT). The server holds no local copy
— every query is fetched fresh, so results are always as current as DataSaudi itself. Only
the lightweight dataset catalog is cached in memory for the session.
DataSaudi's data‑usage terms are set by its operator; this project is an independent open‑source client and attributes GASTAT / MEP as the source. Please review DataSaudi's terms for your use case.
Contributing
Contributions welcome — see CONTRIBUTING.md. To develop locally:
git clone https://github.com/mohsinmshabbir/datasaudi-mcp
cd datasaudi-mcp
uv sync --all-extras
uv run pytest -m "not live" # offline test suite
uv run pytest -m live # optional: hits the real API
License
MIT — see LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file datasaudi_mcp-0.1.0.tar.gz.
File metadata
- Download URL: datasaudi_mcp-0.1.0.tar.gz
- Upload date:
- Size: 965.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
27c3fb46a701129b2dd53964e647e0565e3cfb6be2d10ac3456045952af6a496
|
|
| MD5 |
3e4a6a69d5603fbbe585c3a495107f24
|
|
| BLAKE2b-256 |
73d61c89482cfca7c465e94f1a2218dd65852e5f71d5b30cd372289b3f5b5322
|
File details
Details for the file datasaudi_mcp-0.1.0-py3-none-any.whl.
File metadata
- Download URL: datasaudi_mcp-0.1.0-py3-none-any.whl
- Upload date:
- Size: 19.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6ad551a0935ae726cb409eadf03aceb3a34e7b4141ecaa0d62e9bd117b6c4759
|
|
| MD5 |
242f56e1cdd3e6e0e872ff8f47d39061
|
|
| BLAKE2b-256 |
3b927a4cb7380d4982b188b63053fc76195659f395fed21b4f1c315e56e32d3d
|