us-gov-data-mcp
us-gov-data-mcp
미국 정부 데이터용 MCP 서버. AI 어시스턴트에게 어떤 연방 계약이 곧 만료되는지, 또는 지난해 매출이 가장 많았던 상장 기업이 어디인지 물어보세요 — 정부 공식 기록으로 검증할 수 있는 답변을 받을 수 있습니다.
미국 재무부의 USAspending API와 SEC의 EDGAR XBRL 데이터를 기반으로 구축되었습니다. 스크래핑 없음, API 키 없음, 계정 없음, 개인 데이터 없음.
왜 만들었는가
이 두 소스는 모든 것을 공개하지만, 거의 아무것도 조회할 수 없게 합니다.
usaspending.gov는 계약 종료일로 검색할 수 없습니다. 그러나 연방 계약의 수행 기간이 끝나면, 그 작업은 대개 재경쟁(re-compete)을 거쳐야 합니다 — 그리고 이러한 재경쟁은 정부 조달에서 가장 확률이 높은 기회로, 어떤 입찰 공고가 나타나기 몇 달 전에 공개 데이터에서 확인할 수 있습니다.
sec.gov는 한 번에 한 기업씩만 서류를 제공합니다. 사이트에서는 매출이 1,000억 달러를 초과하는 상장 기업이 어디인지, 또는 현금을 가장 많이 보유한 기업이 어디인지 물어볼 방법이 없습니다. SEC의 frames API는 XBRL 태그와 기간 형식을 이미 알고 있다면, 단 한 번의 호출로 전체 약 5,800개 신고 기업에 대해 답할 수 있습니다.
이 서버는 그 사이트들이 답할 수 없는 질문에 답합니다.
Related MCP server: sec-edgar-mcp
네 가지 도구
find_expiring_contracts — 재경쟁
재입찰이 임박한 연방 계약, 현 계약자(incumbent)와 남은 일수 정보. expiring_after_days는 입찰 준비 기간을 설정합니다. 다음 주에 끝나는 계약은 준비할 시간이 없으니까요.
{
"days_until_expiry": 120,
"recipient": "PERATON ENTERPRISE SOLUTIONS LLC",
"amount_usd": 682369225.00,
"awarding_agency": "General Services Administration",
"verify_url": "https://www.usaspending.gov/award/..."
}search_federal_contracts
기관, 키워드, 날짜 또는 금액 기준으로 체결된 계약 검색. 누가 연방 사업을 수주하고 있는지, 기관이 무엇에 지출하는지, 경쟁사의 이력.
screen_public_companies
보고된 재무 지표로 모든 미국 상장 기업을 순위화합니다.
"2023년 매출이 2,000억 달러를 초과한 기업은 어디인가?"
{ "company": "Walmart Inc.", "value": 648125000000, "unit": "USD",
"period_end": "2023-12-31", "period_type": "annual",
"verify_url": "https://www.sec.gov/Archives/edgar/data/104169/..." }company_financial_history
한 기업의 특정 지표 — 매출, 순이익, 자산, 현금 흐름 — 보고 이력을 중복 제거하여, 각 레코드에 서식 유형과 제출일을 포함해 제공합니다.
모든 것이 검증 가능합니다
각 레코드는 해당 데이터가 출처한 정부 서류로 연결되는 verify_url을 포함합니다. 열어서 비교해 보세요.
AI가 개입된 상황에서 이는 가장 중요합니다: 어시스턴트가 금액을 보고할 때, 일련의 과정을 신뢰하기보다 출처와 대조해 확인할 수 있어야 합니다. 값이 공식 기록과 일치하지 않는다면, 그것은 버그입니다 — 이슈를 열어 주세요.
이 서버가 처리해 주는 세 가지 함정
원시 SEC 데이터는 세 가지 특정한 방식으로 오해를 불러일으키며, 각각 조용히 발생합니다 — 오류가 아닌 그럴듯한 잘못된 숫자를 받게 됩니다.
10-Q는 분기와 연간 누계를 동일한 종료일로 보고합니다. 서로 다른 서류의 순이익을 비교하면 3개월 수치와 9개월 수치가 조용히 혼합됩니다. 모든 레코드는
period_type을 포함하며, 이를 기준으로 필터링할 수 있습니다.동일한 사실이 서로 다른 값으로 여러 서류에 반복됩니다. 올해의 10-K는 작년 수치를 재작성합니다. 기간당 하나의 레코드로 중복 제거되며, 가장 최근 서류가 우선합니다 — SEC 자체의 재작성 처리 방식입니다.
기업은 시간이 지나면서 XBRL 태그를 변경합니다. Microsoft는 2010년까지
Revenues를 사용했고 이후 다른 태그를 사용했습니다. 데이터가 반환되는 첫 번째 태그를 사용하면 오래된 부분 이력을 얻게 됩니다. 이 서버는 모든 태그를 병합합니다.
설치
uvx --from git+https://github.com/groundtruthtools/us-gov-data-mcp us-gov-data-mcpClaude Desktop — claude_desktop_config.json에 추가:
{
"mcpServers": {
"us-gov-data": {
"command": "uvx",
"args": [
"--from",
"git+https://github.com/groundtruthtools/us-gov-data-mcp",
"us-gov-data-mcp"
],
"env": { "SEC_USER_AGENT": "Your Name your@email.com" }
}
}
}모든 MCP 클라이언트에서 작동합니다: Claude Desktop, Claude Code, Cursor, VS Code.
SEC_USER_AGENT 설정을 권장합니다. SEC의 공정 접근 정책은 연락처 주소가 포함된 User-Agent를 요구하며, 이를 포함하지 않은 요청은 403을 받습니다. 기본값이 포함되어 있어 바로 작동하지만, 자신을 식별하는 것이 예의이며 공유 신원에서 벗어날 수 있습니다.
어렵게 배운 한 가지 특이점: 해당 문자열에 URL을 넣지 마세요. SEC는 URL이 포함된 User-Agent에 대해 403을 반환합니다. Your Name your@email.com은 작동하지만, github.com/...을 추가하면 작동하지 않습니다.
아직 PyPI에 없으므로 저장소에서 설치하세요. PyPI에 등록되면 uvx us-gov-data-mcp 한 줄로 설치할 수 있습니다.
솔직한 한계
계약: 체결된 계약이지 공개 입찰이 아닙니다. 게시된 입찰은 SAM.gov를 사용하세요.
계약: 연방 계약만 해당, 2008 회계연도 이전 데이터는 없음.
재경쟁 검색은 지난 1년간 활동이 있는 계약만 포함합니다. USAspending이 결과 페이지 깊이를 제한하기 때문입니다. 오랫동안 활동이 없던 계약은 나타나지 않을 수 있으며, 지나치게 광범위한 검색은 자신 있게 빈 목록을 반환하는 대신 그 사실을 알려줍니다.
SEC: XBRL 적용 범위는 약 2009년부터 시작하며, 기업이 실제로 태그한 개념만 포함합니다. 소규모 신고 기업은 태그를 덜 사용합니다.
보고만 하며 계산하지 않습니다. 비율, 성장률 또는 파생 지표는 없습니다 — 그것은 서류가 아닌 우리의 산술이 되며, 출처와 대조해 검증할 수 없기 때문입니다.
투자 조언이 아닙니다. 데이터 재포맷 도구입니다.
Apify에서도 제공
동일한 로직이 설치 없이 호스팅된 도구로 실행됩니다:
데이터 출처 및 라이선스
계약: USAspending.gov, 미국 재무부, DATA Act에 따라 공개. 재무 데이터: SEC EDGAR, 미국 증권거래위원회. 둘 다 공개 도메인. 코드: MIT.
Available Tools
4 toolscompany_financial_historyA
One company's reported history of a financial metric.
Deduplicated to one record per period, taking the most recent filing -- this year's 10-K restates last year's figures, so raw SEC data repeats periods with different values.
Every record carries the form type, filing date, and a verify_url.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | How many periods to return, 1-200. | |
| metric | No | revenue, net_income, assets, cash, operating_cash_flow, eps_diluted, and others. A raw XBRL tag also works. | revenue |
| company | Yes | Ticker like AAPL, or a CIK number. | |
| period_type | No | annual gives one figure per fiscal year; quarterly gives three-month figures. Use this -- a 10-Q reports both the quarter AND the year-to-date with the same end date, so 'any' mixes 3-month and 9-month numbers. | annual |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Without annotations, the description carries the transparency burden. It discloses two key behaviors: deduplication to the most recent filing per period, and the inclusion of form type, filing date, and verify_url in each record. This is solid but does not mention potential errors, rate limits, or data ordering.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is succinct, with three short paragraphs that directly convey purpose, deduplication logic, and record contents. No redundant or vague phrasing.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given there is no output schema, the description adequately explains what each record contains (form type, filing date, verify_url) and the deduplication rule. It lacks details on sorting, error handling, or metric value units, but the core context is covered.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
All four parameters have descriptions in the schema (100% coverage), so the baseline is 3. The tool description adds no new parameter-specific meaning beyond what the schema already states; it only reinforces the single-company scope implicitly via 'One company'.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: retrieving a single company's reported history of a financial metric. It is distinct from sibling tools (e.g., search_federal_contracts) by focusing on company financials, and the verb+resource structure is specific.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description does not provide explicit guidance on when to use this tool over alternatives. It implies single-company scope but never states conditions like 'use when you need historical financial data' or contrasts with sibling tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
find_expiring_contractsA
Find federal contracts expiring soon -- recompete opportunities.
When a federal contract's period of performance ends, the work usually has to be re-competed, and the incumbent is beatable. These are the highest-probability opportunities in government contracting, visible in public data months before any solicitation is published.
Each result includes days_until_expiry and the current incumbent.
Note: usaspending.gov itself cannot filter by end date. This walks the end-date-sorted results to find the window, so it takes a few seconds.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | How many contracts to return, 1-100. | |
| keyword | No | Free-text search across descriptions and recipients. | |
| agencies | No | Awarding agency names to restrict to. | |
| min_amount | No | Only contracts at or above this dollar amount. Strongly recommended: it narrows the search and makes it faster. | |
| expiring_after_days | No | Skip contracts ending sooner than this. A contract ending next week is too late to bid on; 120 is typical lead time. | |
| expiring_within_days | No | Return contracts whose period of performance ends within this many days. 365 is a typical planning horizon. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It discloses that each result includes days_until_expiry and the incumbent, that usaspending.gov cannot filter by end date, and that the tool walks end-date-sorted results and takes a few seconds. It also signals a read-only operation through 'Find'.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is about 90 words, front-loaded with the core purpose, then provides market context, result fields, and a performance note in separate short paragraphs. Every sentence adds useful context for selection and expectation-setting.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has 6 optional parameters and no output schema, but the description names the key result fields (days_until_expiry, current incumbent) and explains latency and data-source constraints. It is complete enough for a read-only search tool with richly documented params, though a full result-shape list would be even safer.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with each parameter already well-documented including defaults, ranges, and intent. The description reinforces the 'window' concept and output fields, but does not need to add parameter-level detail.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with 'Find federal contracts expiring soon' which clearly specifies the resource (expiring federal contracts) and action (find). The mention of 'recompete opportunities' distinguishes this from the general sibling search_federal_contracts by emphasizing the specific use case.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides strong context: federal contracts whose performance period ends must usually be re-competed, and incumbents are beatable. This explains why an agent would choose this tool, though it does not explicitly name alternative tools or state when not to use it.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
screen_public_companiesA
Rank every US public company by a financial metric.
Answers questions sec.gov structurally cannot: which companies had revenue over $100 billion last year, which hold the most cash, which reported the largest losses. EDGAR serves filings one company at a time; this compares all of them at once.
Every record carries a verify_url to the filing the figure came from.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | How many companies to return, 1-200. | |
| order | No | desc or asc. | desc |
| metric | No | revenue, net_income, assets, liabilities, equity, cash, operating_income, gross_profit, eps_diluted, operating_cash_flow, capex, long_term_debt, inventory, goodwill, rd_expense, shares_outstanding, and more. A raw XBRL tag such as 'Revenues' also works. | revenue |
| period | No | Calendar year like CY2024, or a quarter like CY2024Q1. Balance-sheet metrics are adjusted automatically. | CY2024 |
| max_value | No | Only companies at or below this figure. | |
| min_value | No | Only companies at or above this figure. Negative values are legal -- losses are real figures. | |
| period_type | No | Filter by reporting period length: any, quarterly, half_year, nine_month, annual, instant. | any |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It discloses a key behavioral trait: 'Every record carries a verify_url to the filing the figure came from.' It also establishes the scope (all US public companies) and implies read-only screening. It does not mention rate limits or error handling, but for a read-oriented tool these are not critical. The description adds meaningful context beyond what annotations would provide.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise: the first sentence states the purpose, the second paragraph gives concrete use cases, and the third adds one valuable detail (verify_url). It is front-loaded and every sentence earns its place. No wasted words or repetition of schema information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (7 params, no output schema), the description is fairly complete. It explains the tool's purpose, gives examples, and hints at output structure ('Every record carries a verify_url'). It doesn't detail all return fields, but that might be implied by the metric and ranking. The description is adequate for an agent to understand when and what to expect.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema covers 100% of parameters with descriptions, so the baseline is 3. The tool description does not add extra parameter semantics beyond what's already in the schema. The examples like 'revenue over $100 billion' reiterate the metric and period parameters but do not add new meaning. Therefore, it does not exceed the baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'Rank every US public company by a financial metric.' This is a specific verb+resource. It also distinguishes from siblings by emphasizing cross-company comparisons ('this compares all of them at once') and contrasts with SEC.gov/EDGAR. This differentiates it from company_financial_history, which likely focuses on individual company data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives clear context on when to use it: 'Answers questions sec.gov structurally cannot: which companies had revenue over $100 billion last year...' It implies this is for cross-company screening. However, it does not explicitly mention when not to use it or name alternatives like company_financial_history for single-company history, so it stops short of explicit exclusion. This earns a 4, not a 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
search_federal_contractsA
Search awarded US federal government contracts.
Returns contracts the government has already awarded, largest dollar value first. Use this to see who is winning federal work, what an agency spends, or a specific company's contract history.
For contracts coming up for re-bid, use find_expiring_contracts instead.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | How many awards to return, 1-100. | |
| keyword | No | Free-text search across award descriptions and recipient names, e.g. 'cybersecurity'. Omit to search all. | |
| agencies | No | Awarding agency names, e.g. ['Department of Defense']. | |
| end_date | No | Latest award action date, YYYY-MM-DD. | |
| min_amount | No | Only awards at or above this dollar amount. | |
| start_date | No | Earliest award action date, YYYY-MM-DD. No earlier than 2007-10-01. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations supplied, the description carries the behavioral disclosure burden. It discloses that results are limited to already-awarded contracts and that they are sorted 'largest dollar value first,' which goes beyond the schema. It does not mention pagination, output fields, or rate limits, but for a search/read tool the key behavioral traits are adequately surfaced.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise and front-loaded: the first sentence states the tool's purpose, the second adds result ordering and use cases, and the final sentence points to an alternative. Every sentence earns its place with no filler or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The tool has six optional, well-documented parameters and no output schema, so the description needs to convey scope and return behavior. It covers scope, sort order, and common use cases, but it does not enumerate the contract fields returned. Still, for selection and invocation, the description is sufficiently complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides thorough descriptions for all six parameters (e.g., 'Free-text search across award descriptions and recipient names'), so the description does not need to repeat them. It adds minimal parameter-level value beyond schema, but the schema coverage is 100%, meeting the baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool 'Search awarded US federal government contracts' and immediately distinguishes it from expiring-contract searches with 'Use this to see who is winning federal work.' It names specific use cases and references the sibling find_expiring_contracts, so an agent can tell this tool from alternatives.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit guidance is given on when to use this tool: for seeing who is winning federal work, what an agency spends, or a company's contract history. It also gives an explicit exclusion: 'For contracts coming up for re-bid, use find_expiring_contracts instead.' This clearly orients selection among siblings.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
4 tool updates
v1.0.0- First observed
company_financial_history - First observed
find_expiring_contracts - First observed
screen_public_companies - First observed
search_federal_contracts
TDQS
Scored across 4 tools
Each tool has a clearly distinct purpose: search_federal_contracts finds awarded contracts, find_expiring_contracts identifies expiring ones, screen_public_companies ranks companies by metrics, and company_financial_history retrieves a single company's historical financials. No overlapping functionality exists between the four tools.
The naming pattern is inconsistent. The first three tools use a verb-noun structure (search_, find_, screen_), but the fourth uses a noun-noun structure (company_financial_history). Additionally, the verbs 'search', 'find', and 'screen' are near-synonyms, which could confuse users about their exact purposes. The pattern is not uniform across the set.
With only 4 tools, the server is reasonably scoped for its niche of government contracts and public company financials. It is slightly on the low end but within the acceptable 3–15 range, and each tool serves a distinct query need without unnecessary bloat.
The tool surface covers the primary queries for the domain: searching awarded contracts, finding expiring ones, screening companies by financial metrics, and retrieving a company's financial history. There are minor gaps (e.g., no tool for detailed contract metadata or company fundamentals beyond history), but agents can accomplish core tasks without dead ends.
Maintenance
Related MCP Connectors
MCP access to the U.S. federal procurement graph: contracts, opportunities, entities, and more.
B2B, GovCon & LegalTech MCP server for live RFPs, contract parsing, compliance & proposal tools.
Query SEC EDGAR filings, XBRL financials, and company data via MCP. STDIO or Streamable HTTP.
USAspending MCP — Federal spending data from USAspending.gov API
Related MCP Servers
- AlicenseCqualityBmaintenanceMCP server for accessing SEC EDGAR filings. Connects AI assistants to company filings, financial statements, and insider trading data with exact numeric precision.211,051 PyPI373AGPL 3.0
- AlicenseNot gradedqualityDmaintenanceHosted MCP server that gives AI agents real-time access to SEC EDGAR filings search, 10-K/8-K reading, XBRL financial facts, and insider-trade (Form 4) alerts.6 npm1MIT
- AlicenseAqualityDmaintenanceAn MCP server that gives AI agents access to US business entity data, enabling searches across 9 state registries, SEC EDGAR filings, federal contracts, and lobbying disclosures.61MIT
- AlicenseAqualityDmaintenanceRead-only MCP server for exploring US federal spending data via the USAspending.gov API, enabling natural language queries on awards, agencies, recipients, and spending trends.12MIT