eCFR

io.github.1102tools由 GitHub 账号 1102tools 发布v0.2.6更新于 Oct 28, 2026

Electronic Code of Federal Regulations including FAR and DFARS. 13 tools.

发布方自己的服务:eCFR.io Federal Regulations

概览

AI 生成的概览

免费的 MCP 服务器,让助手无需 API 密钥即可读取和检索 eCFR(含 FAR、DFARS 及各机构 FAR 补充条款)法规文本。

可以做什么
  • 读取法规文本与结构:获取条、子部分或部分的正文,浏览层级目录,获取层级路径
  • 检索与列举:带层级筛选的全文检索,列出各机构及其 CFR 引用,列出 FAR/DFARS 某一部分的全部条款
  • 版本追踪:查询修订历史,对比两个日期的文本,查找某日期之后被修改的条款,获取编辑性更正
  • 联邦采购快捷工具:一次调用查询 FAR/DFARS 条款原文,检索 FAR 2.101 中的定义
适用场景
适合需要引用或核对现行联邦采购法规原文、条款措辞、定义,或了解两个日期之间变化情况的场景,无需离开对话。面向联邦采购、合规与政策研究,而非一般法律意见。
运行要求
以 Python 包 ecfr-mcp 形式通过 uvx 或 pip 在桌面 AI 应用中本地运行;无需 API 密钥、注册或认证头。需要访问公开的 eCFR API 网络。推荐的 uvx 命令每次启动都会检查 PyPI,可能需要调高客户端的 MCP 启动超时。
安装前请注意
仅对公开政府 API 做只读查询,不索取任何凭据。数据来自 ecfr.gov,并非官方法律版本,正式引用应参照 GPO 发布的年度 CFR。内容比联邦公报滞后 1-2 个工作日,且服务器不会自动更新。

安装

在 SourceWeft 中

  1. 打开 控制台中的 eCFR,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

ecfr-mcp

[price: free] [license: MIT] [tools: 13] [regression tests]

Free, open-source MCP server for the eCFR (Electronic Code of Federal Regulations) API. Read FAR, DFARS, and all agency FAR supplement text with no authentication required.

Overview, demo video and hosted setup: https://1102tools.com/mcp/ecfr

No API key required, locally or hosted. See Local or hosted.

Regression tests, including live checks against the eCFR API and a check that every piece of text in ten saved eCFR responses comes out exactly once and in order. The October 2026 releases were also checked with realistic contracting questions (clause lookups, FAR definitions, version history, recent changes). See testing.md.

Local or hosted

Local (desktop)Claude (hosted)ChatGPT (hosted)
Local setupInstallInstall
  • Local runs it on your computer, inside the Claude or ChatGPT desktop app or another AI app. You get your own full rate limits, and it relies only on the government service. It doesn't update itself, so ask your AI to update it. You don't have to set it up by hand: give your AI this page's link and ask it to set it up or walk you through it.
  • Hosted is always up to date, needs no setup or keys, and works in Claude or ChatGPT anywhere.

Compare local and hosted · Matching prompts

What it does

Exposes the eCFR API as 13 MCP tools covering regulatory text, structure, search, version history, and common acquisition workflows:

Core endpoints

  • get_latest_date - Get the most recent available date for a CFR title (call before other tools)
  • get_cfr_content - Get parsed regulatory text for a section, subpart, or part
  • get_cfr_structure - Hierarchical table of contents
  • get_version_history - Amendment history for a section or part
  • get_ancestry - Breadcrumb hierarchy path
  • search_cfr - Full-text search with hierarchy filters
  • list_agencies - All agencies with their CFR references
  • get_corrections - Editorial corrections for a title

Workflow convenience

  • lookup_far_clause - One-call FAR/DFARS clause text lookup (auto-resolves date)
  • compare_versions - Side-by-side text comparison at two dates
  • list_sections_in_part - All sections in a FAR/DFARS part
  • find_far_definition - Search FAR 2.101 for a term definition
  • find_recent_changes - Sections modified since a given date

No authentication required

The eCFR API is fully public. No API key, no registration, no auth headers. Just install and use.

Installation

Via uvx (recommended)

bash
uvx --refresh-package ecfr-mcp --from ecfr-mcp ecfr-mcp

Via pip

bash
pip install ecfr-mcp

From source

bash
git clone https://github.com/1102tools-dev/federal-contracting-mcps.gitcd federal-contracting-mcps/servers/ecfr-mcppip install -e .

Configuration

Use the configuration below as the server definition and adapt its placement to your compatible MCP client. For practical requests using this source, see the prompt library.

json
{  "mcpServers": {    "ecfr": {      "command": "uvx",      "args": ["--refresh-package", "ecfr-mcp", "--from", "ecfr-mcp", "ecfr-mcp"]    }  }}

The --refresh-package flag tells uv to check PyPI for a newer release each time your client launches the server, so fixes arrive automatically; without it, uv keeps serving whatever version it first cached. It adds a moment of network time at startup, so raise your platform's MCP startup timeout if it enforces a short one.

Restart the client. The ecfr server appears with 13 tools.

Example prompts

  • "Pull the current text of FAR 15.305 (Proposal Evaluation) and summarize what it requires."
  • "List all sections in FAR Part 19 (Small Business Programs)."
  • "Look up the FAR definition of 'commercial product' in 2.101."
  • "What FAR sections were amended in the last 6 months?"
  • "Compare FAR 52.212-4 between 2024-01-01 and 2025-01-01 and show me what changed."
  • "Get the current text of DFARS 252.227-7014 (Rights in Noncommercial Computer Software)."
  • "Search Title 48 for 'organizational conflict of interest' and show me the relevant sections."
  • "Which agency owns Chapter 8 in Title 48? Get their FAR supplement structure."

Design notes

  • XML parsed server-side. The eCFR content endpoint returns raw XML. This server parses it into clean text (headings, paragraphs, citations) before returning to the model, saving significant context tokens.
  • Automatic date resolution. eCFR lags 1-2 business days behind the Federal Register. Using today's date on versioner endpoints causes 404 errors. All content tools auto-resolve to the latest available date unless you specify one.
  • Search defaults to current text. Without date=current, eCFR search returns ALL historical versions including superseded. Default current_only=True prevents duplicate results.
  • Structure endpoint limitation. The eCFR structure endpoint does not support section-level filtering (returns 400). list_sections_in_part works around this by fetching the part structure and walking the tree.
  • FAR 2.101 optimization. The definitions section is ~109KB of XML. find_far_definition parses the full section server-side and returns only matching paragraphs with context.

CFR Title 48 quick reference

ChapterRegulationParts
1FAR1-99
2DFARS200-299
3HHSAR300-399
4AGAR400-499
5GSAR500-599
6DOSAR600-699
7AIDAR700-799
8VAAR800-899
9DEAR900-999
18NFS1800-1899

Data source

All data from ecfr.gov, the continuously updated online Code of Federal Regulations maintained by the Office of the Federal Register. Updated daily, typically 1-2 business days after Federal Register publication. Not an official legal edition; for official citations reference the annual CFR from GPO.

Part of

federal-contracting-mcps: monorepo of 9 MCP servers for federal contracting data. Pair these sources with the MCP prompt library.

License

MIT

来源:servers/ecfr-mcp/readme.md,提交 7ff19f1

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v0.2.6最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分

其他 Ecfr 集成