DataCommons

Provides an MCP interface to access Data Commons data via HTTP or stdio modes for querying indicators, observations, and chart-ready data.
  • python

0

GitHub Stars

python

Language

4 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "turnono-datacommons-mcp-server": {
      "command": "python",
      "args": [
        "-m",
        "datacommons_mcp.cli",
        "serve",
        "stdio"
      ],
      "env": {
        "GOOGLE_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

You can run the DataCommons MCP Server to access Data Commons API data through a flexible MCP interface using either HTTP transport or a local stdio workflow. It lets you search indicators and topics, retrieve observations and data, and configure charts and formats for client applications.

How to use

To use this server, start it in your preferred transport mode and connect with an MCP client. In HTTP mode, your client can send requests to localhost (or a public host) on the specified port. In stdio mode, your client communicates directly with the running process via standard input and output. You can perform common data queries such as searching indicators or topics, fetching observations, and requesting formatted data suitable for charts and dashboards.

How to install

Prerequisites you need before installing: Python 3.x and pip. You may also use Docker if you prefer containerized deployment.

# Install dependencies listed for development and runtime
pip install -r requirements.txt
pip install -e .

Additional setup steps

If you want to run the server locally using Docker, build and run the container with the following commands.

docker build -t datacommons-mcp .
docker run -p 8000:8000 datacommons-mcp

Environment variables

The server requires a Google API key to access Data Commons data. Provide this value to enable API access from your MCP client.

# Example usage when starting or configuring your client
export GOOGLE_API_KEY=YOUR_API_KEY

Development

For development workflows, install extra dependencies, run tests, and format the codebase.

pip install -e ".[dev]"
ppytest
black .
isort .

Notes

The server supports both HTTP and stdio transport modes. Use the HTTP mode to expose a network-accessible endpoint, or use stdio mode for local workflows driven by a client process.

Available tools

search_indicators

Search available indicators and topics within the Data Commons MCP data space.

get_observations

Retrieve observation data for selected indicators across specified time ranges.

format_data

Format responses for chart configurations and various data formats as requested by clients.

transport_http

Expose an HTTP endpoint that MCP clients can query over network protocols.

transport_stdio

Enable a local, process-driven communication channel via stdio for MCP clients.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational