# Data Bahrain [Health: Active]

**Category:** 💻 Developer Tools  
**Repository:** https://github.com/pipeworx-io/mcp-data-bahrain  
**GitHub Stars:** 0  
**npm Downloads (last month):** 1022  
**Views:** 0  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/data-bahrain

## Description
Bahrain government open data — population and census statistics, education, GDP and labor market…

## Tools
Capabilities this server exposes over MCP:

- **search_datasets** — Search Bahrain government open data for datasets by keyword (population, census, education, GDP, labor market, industry). Returns dataset_ids (pass to query/dataset_info), titles and record counts.
- **dataset_info** — Get metadata for one Bahrain government open data dataset (field schema, record count, description) — call before query to learn the column names.
- **query** — Query records from a Bahrain government open data dataset with ODSQL. Filter (where), aggregate (group_by/select), sort (order_by), paginate (limit/offset).

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "data-bahrain": {
    "command": "npx",
    "args": ["-y","@pipeworx/mcp-data-bahrain"]
  }
}
```

## Documentation

## What Data Bahrain does

Data Bahrain exposes selected datasets from Bahrain’s national open data portal as MCP tools. The available subject areas include population and census statistics, education, GDP, labor markets, and industry. The source endpoint is Bahrain’s official open data API at `data.gov.bh/api/explore/v2.1/`.

The integration is independent and unofficial. It is provided through Pipeworx, which also operates a broader gateway for many other data sources. Data Bahrain is intended for agents that need to locate and query structured public datasets, not for writing data back to the portal.

## How it works

The hosted MCP endpoint is:

```text
https://gateway.pipeworx.io/data-bahrain/mcp
```

An MCP client can connect to that URL and invoke the pack’s tools. The normal workflow is to search for a relevant dataset, inspect its schema and record count, then query records or aggregations using the dataset identifier.

The endpoint also exposes shared Pipeworx meta-tools, including `ask_pipeworx`, `discover_tools`, `search_within`, and `remember`/`recall`. These are listed alongside the pack-specific tools. `ask_pipeworx` can route a plain-language request across the wider Pipeworx catalog, including sources beyond Bahrain data. The full gateway is available at `https://gateway.pipeworx.io/mcp` when direct access to all catalog packs is preferred.

HTTP callers can invoke tools directly through the gateway’s `/v1/tools/` API. A local npm bridge is also available; it forwards MCP calls to the same hosted endpoint and requires network access.

## Setup and configuration

For a hosted connection, add the following MCP entry:

```json
{
  "mcpServers": {
    "data-bahrain": {
      "url": "https://gateway.pipeworx.io/data-bahrain/mcp"
    }
  }
}
```

The local option starts the bridge with `npx`:

```json
{
  "mcpServers": {
    "data-bahrain": {
      "command": "npx",
      "args": ["-y", "@pipeworx/mcp-data-bahrain"]
    }
  }
}
```

The hosted connection is keyless. The local bridge allows up to 50 anonymous calls per day; a free Pipeworx account and `PIPEWORX_API_KEY` raise that limit to 200 calls per day. Set `PIPEWORX_META_TOOLS=1` in the local configuration to include the shared gateway tools in its listed tool set. The bridge must be able to reach the network and has no offline mode.

## Tools and capabilities

- `search_datasets(query?, limit?, offset?)` finds dataset identifiers by keyword.
- `dataset_info(dataset_id)` returns a dataset’s description, field schema, and record count.
- `query(dataset_id, query?, where?, select?, group_by?, order_by?, limit?, offset?)` retrieves records or performs aggregations with ODSQL options.
- `ask_pipeworx` can accept a plain-language question and select tools across the wider gateway when shared meta-tools are enabled or when using the hosted pack endpoint.

The tools support progressive discovery: identify a dataset first, examine its fields, and then construct a focused query using the available columns and query options.

_Full upstream README: https://allmcps.com/mcp/data-bahrain/readme_

