Prototype · Preview: every server in the official registry, synced every 30 minutes. Sign in with Google to write reviews.Prototype · updated every 30 min
PopNx MCPMCP servers for people who use AI · explained in plain words Sign in

US Government Data Analyst

by zsuversion 0.11.2i★ 0iRuns on your computerOfficial site ↗
Registry nameio.github.zsu/data-analyst-mcp

How to install

What it does

U.S. government economic data (FRED, BLS, BEA, Census, Treasury and more), cited and audited.

  • Connects Runs on your computer
  • Account or key No key needed
  • Category Law & government data

Why it ranks here

Lists are ordered by a usage score (out of 100) built from these parts

Popularity0/80GitHub stars or weekly downloads: the larger counts 60, the smaller 20
Freshness12/12Full marks for a release or code change within 30 days
Still answering0/8The cloud endpoint answered at the last check
Usage score12/100

Quality: Passed 3/3 basic checks (shown, not used for ordering) · Momentum: No data yet (Used only on the Trending tab)

Install

Pick the AI app you use, then copy the settings.

Let your AI install it with one sentence

Please install US Government Data Analyst. Follow https://mcp.popnx.com/i/zsu-data-analyst-mcp.md, show me the commands and wait for my OK before running them.

Paste it into an AI that can work on your computer (such as Claude Code or Cursor). It reads our steps, shows you the commands and waits for your OK. No key, no sign-up. · See the full text your AI reads

Passed 3/3 checks · Runs on your computer · ✓ Commands checked Nov 21, 2026

First: which AI do you use?

Pick your app and the steps appear below.

Works with Claude, with some setup first

Install Node.js on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone

Let AI install it

Copy this message into a Claude chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server US Government Data Analyst for Claude on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "data-analyst": { "command": "npx", "args": [ "-y", "data-analyst-mcp" ] } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the US Government Data Analyst tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Node.js (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    node -v
    • A version number such as v26.13.1 = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed

    Open the Node.js download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v

    Install once; it works for everything that needs Node.js

  2. Open the Claude desktop app’s settings file

    SettingsDeveloperEdit Config

  3. Paste these settings and save the file

    {
      "mcpServers": {
        "data-analyst": {
          "command": "npx",
          "args": [
            "-y",
            "data-analyst-mcp"
          ]
        }
      }
    }
  4. Quit Claude and open it again

  5. Try it

    Use US Government Data Analyst and tell me what you can do for me, then show me one thing

    ✓ If Claude says it is using US Government Data Analyst or shows a US Government Data Analyst tool in the answer, you are connected

5 optional setting(s) (works without them)

The command above works without these. Add them only if you want to change something, following the maker’s description.

  • DATA_GOV_API_KEY Free api.data.gov key (Congress.gov, FDA, FEC, GovInfo and 6 more); optional
  • FRED_API_KEY Free FRED key for search, vintages and GeoFRED; optional
  • BLS_API_KEY Free BLS key for higher limits and annual averages; optional
  • BEA_API_KEY Free BEA key for the API-only datasets; optional
  • CENSUS_API_KEY Free Census key; without it Census offers a manual download; optional

Descriptions are as written by the maker.

Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version

ChatGPT cannot connect US Government Data Analyst yet

US Government Data Analyst runs on your computer, but ChatGPT can only connect servers that run on the web

What you can do instead

A · Use an app that can connect US Government Data Analyst

  • Install Node.js on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone
  • Install Node.js on your computer first (one time)
  • Install Node.js on your computer first (one time)
  • Install Node.js on your computer first (one time)

B · Others in Law & government data that work with ChatGPT

Picked from the most used in the same category, only ones that connect by address with no key

Works with Claude Code, with some setup first

Install Node.js on your computer first (one time)

Let AI install it

Copy this message into a Claude Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server US Government Data Analyst for Claude Code on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): claude mcp add --scope user data-analyst -- npx -y data-analyst-mcp 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the US Government Data Analyst tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Node.js (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    node -v
    • A version number such as v26.13.1 = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed

    Open the Node.js download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v

    Install once; it works for everything that needs Node.js

  2. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: open PowerShell

  3. Paste this command and press Enter

    claude mcp add --scope user data-analyst -- npx -y data-analyst-mcp
  4. Type /mcp in Claude Code

    You should see US Government Data Analyst listed as connected

  5. Try it

    Use US Government Data Analyst and tell me what you can do for me, then show me one thing

    ✓ If Claude Code says it is using US Government Data Analyst or shows a US Government Data Analyst tool in the answer, you are connected

5 optional setting(s) (works without them)

The command above works without these. Add them only if you want to change something, following the maker’s description.

  • DATA_GOV_API_KEY Free api.data.gov key (Congress.gov, FDA, FEC, GovInfo and 6 more); optional
  • FRED_API_KEY Free FRED key for search, vintages and GeoFRED; optional
  • BLS_API_KEY Free BLS key for higher limits and annual averages; optional
  • BEA_API_KEY Free BEA key for the API-only datasets; optional
  • CENSUS_API_KEY Free Census key; without it Census offers a manual download; optional

Descriptions are as written by the maker.

Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Works with Cursor, with some setup first

Install Node.js on your computer first (one time)

Let AI install it

Copy this message into a Cursor chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server US Government Data Analyst for Cursor on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "data-analyst": { "command": "npx", "args": [ "-y", "data-analyst-mcp" ] } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the US Government Data Analyst tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Node.js (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    node -v
    • A version number such as v26.13.1 = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed

    Open the Node.js download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v

    Install once; it works for everything that needs Node.js

  2. Click this button to open Cursor

    Open in Cursor

    Cursor asks you to confirm; click Install

  3. Open the AI chat in Cursor in Agent mode

  4. Try it

    Use US Government Data Analyst and tell me what you can do for me, then show me one thing

    ✓ If Cursor says it is using US Government Data Analyst or shows a US Government Data Analyst tool in the answer, you are connected

5 optional setting(s) (works without them)

The command above works without these. Add them only if you want to change something, following the maker’s description.

  • DATA_GOV_API_KEY Free api.data.gov key (Congress.gov, FDA, FEC, GovInfo and 6 more); optional
  • FRED_API_KEY Free FRED key for search, vintages and GeoFRED; optional
  • BLS_API_KEY Free BLS key for higher limits and annual averages; optional
  • BEA_API_KEY Free BEA key for the API-only datasets; optional
  • CENSUS_API_KEY Free Census key; without it Census offers a manual download; optional

Descriptions are as written by the maker.

Menu names checked against Cursor’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Works with VS Code, with some setup first

Install Node.js on your computer first (one time)

Let AI install it

Copy this message into a VS Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server US Government Data Analyst for VS Code on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "servers": { "data-analyst": { "type": "stdio", "command": "npx", "args": [ "-y", "data-analyst-mcp" ] } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the US Government Data Analyst tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Node.js (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    node -v
    • A version number such as v26.13.1 = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed

    Open the Node.js download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v

    Install once; it works for everything that needs Node.js

  2. Click this button to open VS Code

    Open in VS Code

    VS Code asks you to confirm; click Install

  3. Open the AI chat in VS Code in Agent mode

  4. Try it

    Use US Government Data Analyst and tell me what you can do for me, then show me one thing

    ✓ If VS Code says it is using US Government Data Analyst or shows a US Government Data Analyst tool in the answer, you are connected

5 optional setting(s) (works without them)

The command above works without these. Add them only if you want to change something, following the maker’s description.

  • DATA_GOV_API_KEY Free api.data.gov key (Congress.gov, FDA, FEC, GovInfo and 6 more); optional
  • FRED_API_KEY Free FRED key for search, vintages and GeoFRED; optional
  • BLS_API_KEY Free BLS key for higher limits and annual averages; optional
  • BEA_API_KEY Free BEA key for the API-only datasets; optional
  • CENSUS_API_KEY Free Census key; without it Census offers a manual download; optional

Descriptions are as written by the maker.

Menu names checked against VS Code’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Other apps that use MCP, such as Windsurf, Zed or Gemini CLI, each add servers differently. See how in the app list.

See every app that uses MCP →

JSON settings are under “For developers” below

Stuck? Ask people who use US Government Data Analyst💬 Discussion →
For developers: Terminal commands and JSON settings

Installed on your computer

Claude Code

claude mcp add --scope user data-analyst -- npx -y data-analyst-mcp

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "data-analyst": {
      "command": "npx",
      "args": [
        "-y",
        "data-analyst-mcp"
      ]
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "data-analyst": {
      "command": "npx",
      "args": [
        "-y",
        "data-analyst-mcp"
      ]
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "data-analyst": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "data-analyst-mcp"
      ]
    }
  }
}

Values you fill in

  • DATA_GOV_API_KEY secret env
    Free api.data.gov key (Congress.gov, FDA, FEC, GovInfo and 6 more); optional
  • FRED_API_KEY secret env
    Free FRED key for search, vintages and GeoFRED; optional
  • BLS_API_KEY secret env
    Free BLS key for higher limits and annual averages; optional
  • BEA_API_KEY secret env
    Free BEA key for the API-only datasets; optional
  • CENSUS_API_KEY secret env
    Free Census key; without it Census offers a manual download; optional

Descriptions are as written by the maker.

These settings are generated from the maker’s registry entry. If the README says otherwise, follow the README.

At a glance

Downloads per weeki
226/wk
Connection
Runs on your computer
Latest versioni
0.11.2
Published to registryi
Nov 21, 2026
Code last changedi
Nov 21, 2026
Maker
zsu
Packages
npm: data-analyst-mcp
Registry status
Active

Which apps can use it

Based on how this server connects and on each app’s own docs, checked Nov 10, 2026.

Run on your computer in

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

All apps, with pros and cons →

Related guides

What it can do

Runs on your computer; the tool list appears in your AI app after you install it.

Basic checksi

We check information anyone can see; we have not read the code. Checks that do not apply are left out of the count. · Checked Nov 21, 2026

  • ✓ Pass

    Maker matches the repo

    The registry name was verified with the GitHub account zsu, which owns the repo

  • ✓ Pass

    Still maintained

    Code last changed today

  • ✓ Pass

    Has a licence

    Uses MIT

  • – Not applicable

    Endpoint responds

    This one runs on your computer; there is no internet endpoint

  • – Not applicable

    Sign-in with OAuth

    Runs on your computer and uses local settings instead

  • … Not checked yet

    No hidden instructions in tool descriptions

    Runs on your computer; we can only read tool lists from internet endpoints

Published vulnerabilities (OSV.dev)

No entries on OSV.dev for data-analyst-mcp@0.11.2

Checks only this package version, not every dependency · checked Nov 21, 2026

What we check → · JSON

Makers: ask for a re-check or report wrong info
For makers: add a badge to your README

If you made this, paste this code into your README. The badge links back to this page.

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/zsu-data-analyst-mcp.svg)](https://mcp.popnx.com/en/servers/zsu-data-analyst-mcp)

Discussion

Ask, share a tip or report that it does not work. Sorted by what people marked helpful.

No posts yet. Be the first to ask or share.

Posts here are written by users, not the PopNx team.

Sign in to post

User reviews

No reviews yet

Sign in to write a review

Compared with others in Law & government datai

  • More stars than 0% of the other 1993 servers in this category
  • Published to the registry more recently than 99% of the other 1993 servers in this category
  • Basic checks equal to or better than 99% of the other 1993 servers in this category

Compared with every active server in this category in the registry. Stars count only when the publisher owns the repo.

Common questions

Is US Government Data Analyst safe?

It passed 3 of 3 applicable basic checks. We have not read the code. Before adding a key or token, see what access the server asks for and use a key with only the permissions you need.

What keys or codes does it need?

The registry does not list a required key, though some servers ask you to sign in on first use.

Does it run on my computer or in the cloud?

It runs on your computer. Your AI app starts it when needed, and data does not pass through the maker’s servers (unless it calls an online service itself).

Is it still maintained?

The GitHub repo last changed today, and the latest version (0.11.2) reached the registry today.

Which apps can use it?

Apps that support MCP, such as Claude Desktop, Claude Code, Cursor and VS Code. You also need Node.js on your computer.

What can I use instead?

In the same category: Global law, Open Legal Data (Germany), LibreJustice, InfraNode, Fedlex Connector

Similar alternatives

Same category, other makers, commands already checked. Official ones first, then by stars.

Reading a card:↓ Downloads per weeki★ GitHub starsiThree pillars: reviews · checks · usageiUpdated = latest version published to the registryi

Global law

The law of nearly every country on earth, any date: read it, see what changed it, check citations.

by lexifinaWidely used★ 2.2KUpdated 11 days ago

Runs in the cloud✓ lexifina.com

LibreJustice

Search French, European, Swiss, Belgian, Luxembourg, Dutch and African case law and legal texts.

by librejusticeEarly★ 38Updated today

Runs in the cloud✓ service owner · librejustice.fr

InfraNode

Keyless open data for 84 German cities: 12 lean read-only MCP tools covering 67 data types.

by street1983nkEarly★ 18Updated 5 months ago

Runs in the cloud✓ service owner · infranode.dev

Fedlex Connector

Search Swiss federal legislation: laws, articles, amendments via the Fedlex SPARQL endpoint.

by JayTheSkierEarly★ 8Updated 7 months ago

Runs in the cloud✓ service owner · fedlex-connector.ch
Compared with similar ones
This one
US Government Data Analyst
Global lawOpen Legal Data (Germany)LibreJusticeInfraNodeFedlex Connector
Runs whereInstalls on your computerRuns in the cloud, nothing to installRuns in the cloud, nothing to installRuns in the cloud, nothing to installRuns in the cloud, nothing to installRuns in the cloud, nothing to install
Needs a keyNoNoNoNoNoNo
Add with + in ClaudeNoNoNoNoNoNo
Basic checks3/34/44/44/44/44/4
LicenseMITNOASSERTIONMITApache-2.0Apache-2.0MIT
PriceNo cost listed in the registryNo cost listed in the registryNo cost listed in the registryNo cost listed in the registryNo cost listed in the registryNo cost listed in the registry

README from the maker

Open the README

Copied from the maker’s repo as written. PopNx MCP has not reviewed or endorsed it. HTML, images and scripts are removed. Links lead off this site.

US Economic Analysis MCP Server (data-analyst-mcp)

A Model Context Protocol (MCP) server for U.S. economic analysis and official U.S. government data across 77 federal agencies (FRED, BLS, BEA, Census, Treasury, Congress.gov, FDA, CDC, EPA, and more).

Install

Requires Node.js 22 or later. Most sources need no key, so steps 2 and 3 are optional.

1. Add the server to your client

Claude Code

claude mcp add data-analyst -- npx -y data-analyst-mcp

Add --scope user to make it available in every project. To pass a key here, put -e before the --, for example claude mcp add data-analyst -e DATA_GOV_API_KEY=your-key -- npx -y data-analyst-mcp.

Claude Desktop: claude_desktop_config.json, in ~/Library/Application Support/Claude/ (macOS) or %APPDATA%\Claude\ (Windows). Settings → Developer → Edit Config opens it. Restart Claude Desktop after editing.

{

"mcpServers": { "data-analyst": { "command": "npx", "args": ["-y", "data-analyst-mcp"], "env": { "DATA_GOV_API_KEY": "your-key" } } } }

Cursor: the same mcpServers block in ~/.cursor/mcp.json (every project) or .cursor/mcp.json (one project).

VS Code: .vscode/mcp.json uses servers instead of mcpServers. An inputs entry makes VS Code ask for the key once and store it, so the key is not written into a file you might commit.

{

"inputs": [ { "type": "promptString", "id": "data-gov-key", "description": "api.data.gov API key", "password": true } ], "servers": { "data-analyst": { "type": "stdio", "command": "npx", "args": ["-y", "data-analyst-mcp"], "env": { "DATA_GOV_API_KEY": "${input:data-gov-key}" } } } }

Codex: ~/.codex/config.toml

[mcp_servers.data-analyst]

command = "npx" args = ["-y", "data-analyst-mcp"]

[mcp_servers.data-analyst.env] DATA_GOV_API_KEY = "your-key"

Leave out the env block if you have no keys, or if you store them with setup (step 2).

To run from a clone instead of npm, build it and point the client at the build:

git clone https://github.com/zsu/data-analyst-mcp.git
cd data-analyst-mcp && npm install && npm run build

Then use "command": "node", "args": [" /data-analyst-mcp/dist/bin/cli.js"] in the configs above, and node dist/bin/cli.js setup in place of npx -y data-analyst-mcp setup below.

2. Add keys (optional)

Each key is free. Without a key, a source either falls back to a keyless route with lower limits, or offers a manual download (manual_bundle): the user downloads the files in a browser, and the server packages them.

VariableSourcesWithout itFree key
AQS_API_KEY + AQS_EMAILepa-aqsmanual download onlyaqs.epa.gov
BEA_API_KEYbeabulk files for the main tables; the API-only datasets need the keyapps.bea.gov
BLS_API_KEYbls25 queries a day, 25 series and 10 years each; no annual averages or catalog titlesdata.bls.gov
CENSUS_API_KEYcensusmanual download onlyapi.census.gov
DATA_GOV_API_KEYcollege-scorecard, congress, fbi, fda, fec, govinfo, nrel, regulations, usda-fooddata, usgsDEMO_KEY or keyless, at a few requests an hour (fda: 1,000 a day; usgs earthquakes never need a key)api.data.gov
DOL_API_KEYdolcatalog and field lists only; data queries need the keydataportal.dol.gov
EIA_API_KEYeiaDEMO_KEY, about 10 requests an houreia.gov
FRED_API_KEYfredobservations only; search, vintages, revision history and GeoFRED need the keyfredaccount.stlouisfed.org
HUD_USER_TOKENhudmanual download onlyhuduser.gov
IPUMS_API_KEYipumsbuild the extract on the IPUMS website (free account)account.ipums.org
LDA_API_KEYsenate-lobbying15 requests a minute instead of 120lda.gov
NOAA_API_KEYnoaathe keyless data and station-search endpoints; Climate Data Online v2 needs the keyncei.noaa.gov
USDA_NASS_API_KEYusda-nassmanual download onlyquickstats.nass.usda.gov
USPTO_API_KEYusptomanual download onlydata.uspto.gov

Two settings are not keys. SEC asks every client to identify itself, so set SEC_USER_AGENT to your name and email ("Jane Doe jane@example.com"). NWS_USER_AGENT is optional and does the same for the weather service.

Store a key with `setup` (recommended). It shows the signup link, reads the key with hidden input, and writes it to ~/.config/data-analyst/keys.json. The key stays out of client config files, and every client reads it. It works mid-session, with no restart.

npx -y data-analyst-mcp setup congress

setup takes any source that uses the key: setup congress stores DATA_GOV_API_KEY, and all 10 api.data.gov sources use it. setup epa-aqs also asks for AQS_EMAIL. Or put the variables in the client's env block, as in step 1. API keys lists every place the server looks.

3. Check it

Ask your assistant: *"Is my api.data.gov key set up?"* The check_key tool reports whether the key was found and where, never its value. For census, eia, epa-aqs, noaa, usgs, bea, fred and ipums it also tests the key with one small call to the agency's own site and says whether it was accepted, rejected or the site could not be reached. To list only the sources you can use, start the server with --hide-unconfigured (see Options).

4. Try it
  • *"How has the unemployment rate compared with CPI inflation since 2020?"*
  • *"What is the median household income in each county of Ohio?"*
  • *"Which drugs had the most reported adverse events last year?"*
  • *"How much did each federal agency spend in fiscal year 2024?"*
  • *"How many unhealthy air-quality days did Phoenix have in 2023?"*

The assistant asks the questions that change the answer first (which measure, which years, which population), then fetches, computes and cites.

To host the server for claude.ai or a team, see docs/hosting.md.

How it works

ToolWhat it does
guidethe method: framing, asking only critical questions, the accuracy checklist, combining sources
find_sourcesranks the sources for a question, or lists them all
source_briefone source's playbook, its questions_to_ask, key status, rules and request index
request_schemafull parameters of the requests to use; searches a source's catalog
record_decisionshow each critical question was settled (answered, Don't know, skipped, not asked and why)
fetchdownloads into the session workspace; returns a summary, the files, the citation and notes
manual_bundle, ingesta one-command download for the user's own computer, then packaging what they downloaded
computebuilds exhibits from the full tables with declarative steps (a whitelisted expression language, no eval); the steps are recorded for rerun
facts, write_table, citeregister the numbers cited, write the benchmark and sensitivity tables, snapshot cited pages
audit_answer, rerunthe release gate: every number in the answer is a registered fact, the method record is complete, and the analysis reproduces
build_report, style_check, audit_reportan HTML report and replication ZIP, only when asked
handoffthe per-source data hand-off
check_keywhether a key is set up (never shows it), and tested live where the source allows
read_filea small text file from the workspace
open_workspaceafter a server restart (which starts a new, empty workspace), lists the earlier workspaces and reopens one (local server only)

Asking before fetching is enforced, not just suggested. fetch returns gate_blocked until, for that source, the model has read source_brief and the schemas of the requests it uses, and has recorded how each critical question was settled. The model asks the questions in chat, in one round. A blocking question that the user skips is asked once more. The server also exposes an analyze prompt and source:// resources, for clients that let users pick prompts or attach resources.

Results have one shape. Success: {status: "ok" | "partial", summary, files, citation, notes}. Failure: {status: "error", code, message, fix, retry_after_s?}. The codes are invalid_request, not_found, not_supported, agency_rejected, agency_unavailable, key_missing, key_rejected, rate_limited, gate_blocked, in_progress and server_error. in_progress comes from a rerun (rerun, or an audit with rerun: true) that needs longer than a client waits for one call: the replay continues in a worker thread, the same call made again waits on that same replay, and the finished result is kept until the workspace changes. DATA_ANALYST_RERUN_WAIT_S sets how long a call waits first (default 45 seconds). The replay gets its own heap, DATA_ANALYST_RERUN_HEAP_MB (default: 60 percent of the memory the process may use, a container's limit when it has one); if it runs out, the audit reports that, and the server keeps running.

Options

Option (flag / environment)What it does
--sources fred,treasury / DATA_ANALYST_SOURCESserve only these sources
--domains economy,health / DATA_ANALYST_DOMAINSserve only the sources in these domains
--hide-unconfigured / DATA_ANALYST_HIDE_UNCONFIGURED=1leave out of listings the sources whose required key is not set up
--workspace / DATA_ANALYST_WORKSPACE(stdio) one fixed analysis folder, so a fetch is reused after a restart
{ "mcpServers": { "data-analyst": { "command": "npx", "args": ["-y", "data-analyst-mcp", "--domains", "economy,health"] } } }

The tool list stays the same size whatever is enabled: sources are found with find_sources, not loaded as tools.

Every result lists its upstream requests (requests: method, credential-free URL, status, cached, time), and citation names the publisher, page and retrieval date. Requests are rate-limited per host (a token bucket), retried with backoff on 429 and 5xx (honoring Retry-After), and kept within each agency's per-minute budgets.

Caching follows each source's terms.

  • A source whose policy allows persistent copies (cache.mode: persistent) can be cached on disk in DATA_ANALYST_CACHE (default ~/.cache/data-analyst). census and bea do; opm's terms allow it, but its port downloads again for now.
  • Most sources allow reuse only inside the analysis folder, and FRED none at all. For those, a fixed --workspace gives reuse across restarts without keeping copies anywhere else.

As a library

import { route, brief, fetchSource, compute, registerFacts } from "data-analyst-mcp";

const r = await fetchSource("cdc", { description: "NY deaths 2017", requests: [{ name: "ny", endpoint: "query", params: { dataset: "leading_death", $where: "state = 'New York' AND year = '2017'" } }] }, { out: "./out/ny" }); console.log(r.summary.tables[0].rows, r.citation.text);

  • The functions: the same sources, engine, analysis and audits as the server. The exports are listSources, route, brief, requestSchema, fetchSource, ingest, manualBundle, compute,

Only the beginning is shown; read the rest in the repo