# eCFR API

> eCFR workflow and API: regulation. Returns sections, link, text and agency as JSON.

eCFR data from ecfr.gov: regulation.

- Page: https://fous.com/tools/ecfr
- Handle: `@ecfr`
- Category: [Legal](https://fous.com/tools/category/legal)
- Source website: https://ecfr.gov
- Last verified: Sep 29, 2026

## Methods

### Get regulation

Operation `get_regulation`, version 1. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.

Find current eCFR regulation sections for a topic or exact citation, with section text, amendment date, and the date through which the title is current. Topic matches are ranked by relevance; text is limited to 50,000 characters per section.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `query` | string | yes | `"FMLA eligibility"` | Topic or CFR section citation, for example OSHA ladder rules, FMLA eligibility, or 29 CFR 1910.23. |
| `max_sections` | integer | no | `2` | Maximum sections to return, for example 3. |

**Input schema**

```json
{
  "type": "object",
  "required": [
    "query"
  ],
  "properties": {
    "query": {
      "type": "string",
      "description": "Topic or CFR section citation, for example OSHA ladder rules, FMLA eligibility, or 29 CFR 1910.23.",
      "examples": [
        "FMLA eligibility",
        "OSHA ladder rules",
        "29 CFR 9999.9999"
      ]
    },
    "max_sections": {
      "type": "integer",
      "default": 3,
      "maximum": 10,
      "minimum": 1,
      "description": "Maximum sections to return, for example 3.",
      "x-fous-developer": true,
      "examples": [
        2
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {
      "query": "FMLA eligibility",
      "max_sections": 2
    },
    {
      "query": "OSHA ladder rules"
    },
    {
      "query": "29 CFR 9999.9999"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `sections` | array |  | Matching regulation sections, best first. |
| `sections[].link` | string | `"https://www.ecfr.gov/current/title-29/section-825.110"` |  |
| `sections[].text` | string |  |  |
| `sections[].agency` | string or null | `"Wage and Hour Division, Department of Labor"` |  |
| `sections[].citation` | string | `"29 CFR 825.110"` |  |
| `sections[].part_name` | string | `"Part 825 - The Family and Medical Leave Act of 1993"` |  |
| `sections[].truncated` | boolean | `false` |  |
| `sections[].title_name` | string | `"Title 29 - Labor"` |  |
| `sections[].last_amended` | string or null | `"2016-12-01"` |  |
| `sections[].section_heading` | string | `"Eligible employee."` |  |
| `sections[].up_to_date_as_of` | string | `"2026-09-25"` |  |

**Example input**

```json
{
  "query": "FMLA eligibility",
  "max_sections": 2
}
```

**Example output**

```json
{
  "sections": [
    {
      "link": "https://www.ecfr.gov/current/title-29/section-825.110",
      "text": "(a) An eligible employee is an employee of a covered employer who:\n\n(1) Has been employed by the employer for at least 12 months, and\n\n(2) Has been employed for at least 1,250 hours of service during …",
      "agency": "Wage and Hour Division, Department of Labor",
      "citation": "29 CFR 825.110",
      "part_name": "Part 825 - The Family and Medical Leave Act of 1993",
      "truncated": false,
      "title_name": "Title 29 - Labor",
      "last_amended": "2016-12-01",
      "section_heading": "Eligible employee.",
      "up_to_date_as_of": "2026-09-25"
    },
    {
      "link": "https://www.ecfr.gov/current/title-42/section-435.911",
      "text": "(a) This section implements sections 1902(a)(4), (a)(8), (a)(10)(A), (a)(19), and (e)(14) and section 1943 of the Act.\n\n(b)(1) Except as provided in paragraph (b)(2) of this section, applicable modifi…",
      "agency": "Centers for Medicare & Medicaid Services, Department of Health and Human Services",
      "citation": "42 CFR 435.911",
      "part_name": "Part 435 - Eligibility in the States, District of Columbia, the Northern Mariana Islands, and American Samoa",
      "truncated": false,
      "title_name": "Title 42 - Public Health",
      "last_amended": "2026-07-31",
      "section_heading": "Determination of eligibility.",
      "up_to_date_as_of": "2026-09-25"
    }
  ]
}
```

## Quick start

Replace `YOUR_API_KEY` with a Fous API key. To create one, open Developers at the bottom of Fous Studio, turn on Developer mode, then go to API keys (https://app.fous.com/keys). Change the values in `input` to run the same tool on new data.

```bash
curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 180 \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@ecfr",
  "visibility": "public",
  "operation": "get_regulation",
  "version": 1,
  "input": {
    "query": "FMLA eligibility",
    "max_sections": 2
  },
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
import json
import urllib.error
import urllib.request

api_key = "YOUR_API_KEY"

body = json.loads("{\n  \"api\": \"@ecfr\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_regulation\",\n  \"version\": 1,\n  \"input\": {\n    \"query\": \"FMLA eligibility\",\n    \"max_sections\": 2\n  },\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=180) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
const apiKey = "YOUR_API_KEY";

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(180_000),
  body: JSON.stringify({
  "api": "@ecfr",
  "visibility": "public",
  "operation": "get_regulation",
  "version": 1,
  "input": {
    "query": "FMLA eligibility",
    "max_sections": 2
  },
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

## Use from an AI assistant

Connect this tool to Claude Code, Claude Desktop, Cursor, VS Code, Codex and any MCP client as its own MCP server. Each method is a typed tool whose arguments are the method’s input.

- Server URL: `https://api.fous.com/mcp/tools/ecfr`
- Authorization: `Authorization: Bearer <Fous API key>`

**Tools**

- `get_regulation`: Get regulation. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.
- `fous_get_run`: the result of a run that was still going, by its `request_id`. Free.

Claude Code:

```bash
claude mcp add --scope user --transport http fous-ecfr https://api.fous.com/mcp/tools/ecfr --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"
```

To give the assistant every tool, connect `https://api.fous.com/mcp`: it finds one with `fous_search_tools` and runs it with `fous_run_tool`. Setup for other clients: https://fous.com/llms-full.txt.

## FAQ

### Can I run it with my own inputs?

Yes. Change the inputs in Studio and press Run, or send new inputs from your code, or ask a connected AI assistant.

### Can I call this eCFR tool as an API?

Yes. Send a POST request to /v1/query with your Fous API key and the inputs, and get JSON back.

### How much does it cost?

Each completed run costs 1 credit. Failed runs without a completed receipt are free; completed work can remain charged if delivery is interrupted. With pay as you go, a credit costs 1¢. Monthly plans cost less per credit.

### Do I need a eCFR account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from ecfr.gov when you run it. Some results are reused for up to 24 hours, and results that use your account or key are never reused. It was last verified on Sep 29, 2026.

## Related

- [Federal Register API](https://fous.com/tools/federal-register.md): Search United States federal rules, proposed rules, notices, and presidential documents.
- [EUR-Lex API](https://fous.com/tools/eur-lex.md): EUR-Lex provides official EU legislation, relevance-ranked filtered searches, and article text from the latest consolidation when available, with stated general application dates.
- [legislation.gov.uk API](https://fous.com/tools/legislation-gov-uk.md): legislation.gov.uk provides official legislation, latest available revised section text or contents, and title or topic search results; some older Acts lack structured text.
- [SEC EDGAR API](https://fous.com/tools/sec-edgar.md): SEC EDGAR provides filings, annual and quarterly financials, exact-phrase matches, up to 200 insider trades, and quarterly 13F manager holdings; older filings appear when available.
- [Congress.gov API](https://fous.com/tools/congress-gov.md): Congress.gov returns federal bills and resolutions matching topic, Congress, status, or chamber, and provides an individual bill’s status, summary, titles, actions, and related bills; summaries may be unavailable.
- [Grants.gov API](https://fous.com/tools/grants-gov.md): U.S. federal grant opportunities and application information.
- [FDA API](https://fous.com/tools/fda.md): FDA provides drug safety data, latest matching drug labels, common reported side effects, and newest-first drug, food, and device recalls; recent drug and device recalls may be missing, and weekly food statuses may lag.
- [IRS API](https://fous.com/tools/irs.md): IRS provides tax information and public organization records, including charity status and current-directory forms, instructions, and publications with revision and posting dates.
- [All Legal tools](https://fous.com/tools/category/legal)
