
data-library
com.nysgpt/data-library
SQL over 52.8B public records: USAspending, OpenAlex, patents, LEHD jobs, SEC, EPA, FERC, Medicare.
Documentation
NYSgpt Data Library
52.8B public records in 6,396 SQL tables, queryable from Claude (or any MCP client) and over plain HTTP. Federal spending, patents, company filings, scholarly works, labor, census, energy, health, courts and more, already loaded and typed. Nothing to download or restore.
- Browse every dataset: https://nysgpt.com/data
- MCP server:
https://data.nysgpt.com/mcp(remote, streamable HTTP, no install; needs a key) - Access: by key, from $29: https://nysgpt.com/data#pricing. Free 20,000-row samples of ten datasets: https://huggingface.co/NYSgpt
What people use it for
- The full USAspending database in SQL without restoring the 177 GB PostgreSQL archive: transactions, awards, sub-awards, recipients and account balances.
- OpenAlex in SQL: 465 million works with authors, institutions, funders and topics.
- Every U.S. patent: PatentsView grants from 1976 and applications from 2001, claims, citations, assignments, examination history and office actions.
- Jobs by census block (LEHD LODES): home-to-work flows and job counts, 2002 to 2024, 15.6 billion rows.
- SEC financial statements, 13F holdings and insider transactions, EPA facility and emissions data, FERC electricity sales, Medicare payments and cost reports, IRS and Form 5500 filings, court opinions.
Connect
Claude (claude.ai or desktop): Settings, Connectors, Add custom connector, and paste https://data.nysgpt.com/mcp?key=YOUR_KEY.
Claude Code:
claude mcp add --transport http nysgpt-data https://data.nysgpt.com/mcp --header "X-Api-Key: YOUR_KEY"
Cursor, VS Code and other MCP clients (mcp.json):
{ "mcpServers": { "nysgpt-data": { "url": "https://data.nysgpt.com/mcp?key=YOUR_KEY" } } }
HTTP:
curl -s https://data.nysgpt.com/query -H 'X-Api-Key: YOUR_KEY' -H 'content-type: application/json' \
-d '{"sql":"SELECT publication_year, count(*) AS works FROM govblock_scholarly.openalex_works WHERE publication_year >= 2020 GROUP BY 1 ORDER BY 1"}'
Tools
| Tool | What it does |
|---|---|
list_databases | The databases, one per subject |
list_tables | Tables in a database, with row counts |
describe_table | Fields, types and description of a table |
query | One read-only SQL statement (Athena/Trino dialect), up to 1,000 rows |
HTTP equivalents: GET /databases, GET /tables?database=, GET /table?database=&table=, POST /query.
Example
SELECT awarding_toptier_agency_name AS agency, count(*) AS awards,
round(sum(try_cast(total_obligation AS double))/1e9, 1) AS obligated_billions
FROM govblock_awards.usaspending_db_rpt_award_search
WHERE fiscal_year = '2025'
GROUP BY 1 ORDER BY 3 DESC LIMIT 5
| agency | awards | obligated_billions |
|---|---|---|
| Department of Health and Human Services | 87,548 | 1,985.9 |
| Social Security Administration | 310,884 | 1,634.6 |
| Department of Defense | 3,950,955 | 903.7 |
| Department of Veterans Affairs | 491,843 | 289.4 |
| Department of Agriculture | 2,626,893 | 231.6 |
More in examples/.
Largest datasets
| Dataset | Subject | Records | Tables | Publisher |
|---|---|---|---|---|
| Jobs by census block (LEHD) | Labor | 15.6B | 4 | Census Bureau, Longitudinal Employer-Household Dynamics |
| American Community Survey | Census and Geography | 12.7B | 4 | Census Bureau |
| FERC electricity sales reports | Electricity Grid and Energy | 5.4B | 4 | Federal Energy Regulatory Commission, through the PUDL project |
| New York (NYISO) | Electricity Grid and Energy | 1.6B | 54 | New York Independent System Operator |
| PubMed | Health | 1.4B | 7 | National Library of Medicine |
| USAspending database | Federal Spending | 1.2B | 79 | U.S. Department of the Treasury, Bureau of the Fiscal Service |
| Hospital and facility cost reports | Health | 1.2B | 45 | Centers for Medicare and Medicaid Services |
| Power plant emissions | Environment | 1B | 2 | Environmental Protection Agency, Clean Air Markets |
| Patent Examination Research Dataset | Patents | 998M | 15 | USPTO Office of the Chief Economist |
| Texas (ERCOT) | Electricity Grid and Energy | 978M | 675 | Electric Reliability Council of Texas |
| Financial Statement and Notes data sets | Company Filings | 869M | 8 | SEC Division of Economic and Risk Analysis |
| PatentsView, granted patents | Patents | 821M | 41 | USPTO PatentsView |
| Care Compare quality and staffing | Health | 671M | 1073 | Centers for Medicare and Medicaid Services |
| OpenAlex | Scholarly Works | 586M | 21 | OpenAlex |
| Wind measurements and turbines | Electricity Grid and Energy | 581M | 53 | U.S. Geological Survey; published research datasets |
| Quarterly Census of Employment and Wages | Labor | 502M | 7 | Bureau of Labor Statistics |
| Medicare payments by provider | Health | 487M | 16 | Centers for Medicare and Medicaid Services |
| Monthly merchandise trade | Trade | 460M | 23 | Census Bureau |
| PatentsView, pre-grant publications | Patents | 394M | 30 | USPTO PatentsView |
| Trademark case files | Trademarks | 384M | 17 | USPTO Office of the Chief Economist |
| Claims | Patents | 325M | 6 | USPTO Office of the Chief Economist |
| Home Mortgage Disclosure Act | Mortgage Lending and Banks | 312M | 6 | Consumer Financial Protection Bureau; Federal Financial Institutions Examination Council |
| Licences and applications | Consumer Protection and Communications | 304M | 115 | Federal Communications Commission |
| Precinct returns | Elections | 269M | 4 | MIT Election Data and Science Lab; OpenElections; Voting and Election Science Team; local election offices |
| EIA bulk series | Electricity Grid and Energy | 261M | 41 | U.S. Energy Information Administration |
| Financial Statement Data Sets | Company Filings | 241M | 4 | SEC Division of Economic and Risk Analysis |
| Award files by fiscal year | Federal Spending | 228M | 2 | U.S. Department of the Treasury, Bureau of the Fiscal Service |
| Employee benefit plans (Form 5500) | Nonprofits and Benefit Plans | 197M | 94 | U.S. Department of Labor, Employee Benefits Security Administration |
| Opinions and citations | Courts | 143M | 8 | Free Law Project |
| Classification master files | Patents | 142M | 2 | USPTO bulk data |
| Medicaid drug utilization and prices | Health | 141M | 12 | Centers for Medicare and Medicaid Services |
| Assignments | Patents | 136M | 8 | USPTO assignment records |
| Company facts | Company Filings | 127M | 2 | SEC EDGAR |
| Institutional holdings (Form 13F) | Company Filings | 126M | 7 | SEC |
| Common Core of Data | Education | 110M | 200 | National Center for Education Statistics |
| USAspending database, publisher's subset | Federal Spending | 106M | 79 | U.S. Department of the Treasury, Bureau of the Fiscal Service |
| Open Payments | Health | 95.9M | 5 | Centers for Medicare and Medicaid Services |
| Office actions | Patents | 86.5M | 4 | USPTO Office of the Chief Economist and USPTO bulk data |
| Health plans | Health | 86.3M | 127 | Centers for Medicare and Medicaid Services |
| FERC financial forms | Electricity Grid and Energy | 82.2M | 1139 | Federal Energy Regulatory Commission, through the PUDL project |
| Bulk files | Federal Campaign Finance | 79.5M | 7 | Federal Election Commission |
| Dockets | Courts | 74.1M | 2 | Free Law Project |
| Artificial intelligence patent dataset | Patents | 61.8M | 2 | USPTO Office of the Chief Economist |
| Filing index and company histories | Company Filings | 57.1M | 4 | SEC EDGAR |
| Drug and device safety | Health | 57M | 31 | Food and Drug Administration |
All 132 datasets, with every table and field: https://nysgpt.com/data
Limits and plans
| Plan | Price | Queries a day | Data scanned a day |
|---|---|---|---|
| Day pass | $29 | 300 | 100 GB |
| Monthly | $149 a month | 2,000 | 200 GB |
| Institution | $1,500 a month | 20,000 | 1 TB |
Every call needs a key: add ?key=YOUR_KEY to the MCP address or send the header X-Api-Key.
Notes
- Queries are read-only:
SELECT,WITH,SHOW,DESCRIBE. - Many source files are loaded as published, so numeric columns are often text; use
try_cast. - The data is public records as issued by each publisher. Each dataset page names its publisher. Check the publisher's terms for your use.
- Questions and requests for datasets: open an issue here.
No installation packages available.