openfec-mcp-server

v0.4.12 pre-1.0

Access FEC campaign finance data through MCP. Query data about candidates, money trails, and election filings. STDIO & Streamable HTTP.

openfec.caseyjhand.com/mcp
claude mcp add --transport http openfec-mcp-server https://openfec.caseyjhand.com/mcp
codex mcp add openfec-mcp-server --url https://openfec.caseyjhand.com/mcp
{
  "mcpServers": {
    "openfec-mcp-server": {
      "url": "https://openfec.caseyjhand.com/mcp"
    }
  }
}
gemini mcp add --transport http openfec-mcp-server https://openfec.caseyjhand.com/mcp
{
  "mcpServers": {
    "openfec-mcp-server": {
      "command": "bunx",
      "args": [
        "mcp-remote",
        "https://openfec.caseyjhand.com/mcp"
      ]
    }
  }
}
{
  "mcpServers": {
    "openfec-mcp-server": {
      "type": "http",
      "url": "https://openfec.caseyjhand.com/mcp"
    }
  }
}
curl -X POST https://openfec.caseyjhand.com/mcp \
  -H "Content-Type: application/json" \
  -H "MCP-Protocol-Version: 2025-11-25" \
  -d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-11-25","capabilities":{},"clientInfo":{"name":"curl","version":"1.0.0"}}}'

Tools

9

openfec_search_candidates

Find federal candidates by name, state, office, party, or cycle. Retrieve a specific candidate by FEC ID with financial totals. Candidate IDs start with H (House), S (Senate), or P (President) followed by digits.

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_search_candidates",
    "arguments": {}
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "query": {
      "description": "Full-text candidate name search.",
      "type": "string"
    },
    "candidate_id": {
      "description": "FEC candidate ID (e.g., P00003392, H2CO07170). Get IDs from openfec_search_candidates results. When provided, returns a single candidate with full detail.",
      "type": "string"
    },
    "state": {
      "description": "Two-letter US state code (e.g., AZ, CA).",
      "type": "string"
    },
    "district": {
      "description": "Two-digit district number for House candidates.",
      "type": "string"
    },
    "office": {
      "description": "Filter by office: H=House, S=Senate, P=President.",
      "type": "string",
      "enum": [
        "H",
        "S",
        "P"
      ]
    },
    "party": {
      "description": "Three-letter party code (e.g., DEM, REP, LIB).",
      "type": "string"
    },
    "cycle": {
      "description": "Two-year election cycle (even year, e.g., 2024).",
      "type": "number"
    },
    "election_year": {
      "description": "Specific election year the candidate ran in.",
      "type": "number"
    },
    "incumbent_challenge": {
      "description": "Incumbent status: I=incumbent, C=challenger, O=open seat.",
      "type": "string",
      "enum": [
        "I",
        "C",
        "O"
      ]
    },
    "candidate_status": {
      "description": "Candidate status: C=present, F=future, N=not yet, P=prior.",
      "type": "string",
      "enum": [
        "C",
        "F",
        "N",
        "P"
      ]
    },
    "has_raised_funds": {
      "description": "Only candidates whose committee has received receipts.",
      "type": "boolean"
    },
    "include_totals": {
      "description": "Include financial totals (receipts, disbursements, cash on hand). Defaults to true when fetching by candidate_id.",
      "type": "boolean"
    },
    "page": {
      "default": 1,
      "description": "Page number (1-indexed).",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Results per page.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

openfec_search_committees

Find political committees (campaign, PAC, Super PAC, party) by name, type, candidate affiliation, or state. Retrieve a specific committee by FEC ID. Committee IDs start with C followed by digits (e.g., C00358796).

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_search_committees",
    "arguments": {}
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "query": {
      "description": "Full-text committee name search.",
      "type": "string"
    },
    "committee_id": {
      "description": "FEC committee ID (e.g., C00358796). Get IDs from openfec_search_committees results. Starts with 'C' followed by digits. Returns a single committee with full detail.",
      "type": "string"
    },
    "candidate_id": {
      "description": "Find committees linked to this candidate (authorized, leadership, joint fundraising). Get IDs from openfec_search_candidates results.",
      "type": "string"
    },
    "state": {
      "description": "Two-letter state code.",
      "type": "string"
    },
    "party": {
      "description": "Three-letter party code (e.g., DEM, REP).",
      "type": "string"
    },
    "committee_type": {
      "description": "Committee type code. Common: H (House), S (Senate), P (Presidential), O (Super PAC), N (PAC nonqualified), Q (PAC qualified), X (Party nonqualified), Y (Party qualified).",
      "type": "string"
    },
    "designation": {
      "description": "Committee designation. A (authorized), B (lobbyist PAC), D (leadership PAC), J (joint fundraiser), P (principal campaign), U (unauthorized).",
      "type": "string"
    },
    "cycle": {
      "description": "Two-year election cycle (even year).",
      "type": "number"
    },
    "treasurer_name": {
      "description": "Full-text treasurer name search.",
      "type": "string"
    },
    "page": {
      "default": 1,
      "description": "Page number (1-indexed).",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Results per page.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

openfec_search_contributions

Search itemized individual contributions (Schedule A) or get aggregate breakdowns by size, state, employer, or occupation. Use to answer "who is funding this committee?" Itemized mode requires a committee_id. Aggregate by_size/by_state can use candidate_id instead.

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_search_contributions",
    "arguments": {}
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "mode": {
      "default": "itemized",
      "description": "Query mode. \"itemized\" returns individual contribution records (keyset pagination). \"by_size\" aggregates by contribution size bucket. \"by_state\" aggregates by contributor state. \"by_employer\" aggregates by employer. \"by_occupation\" aggregates by occupation.",
      "type": "string",
      "enum": [
        "itemized",
        "by_size",
        "by_state",
        "by_employer",
        "by_occupation"
      ]
    },
    "committee_id": {
      "description": "Receiving committee ID (e.g., C00703975). Get IDs from openfec_search_committees results.",
      "type": "string"
    },
    "candidate_id": {
      "description": "Candidate ID (e.g., P00003392). Get IDs from openfec_search_candidates results. Enables by_size and by_state aggregates without a committee_id.",
      "type": "string"
    },
    "contributor_name": {
      "description": "Full-text donor name search. Itemized only.",
      "type": "string"
    },
    "contributor_employer": {
      "description": "Full-text employer search. Itemized only.",
      "type": "string"
    },
    "contributor_occupation": {
      "description": "Full-text occupation search. Itemized only.",
      "type": "string"
    },
    "contributor_city": {
      "description": "Contributor city. Itemized only.",
      "type": "string"
    },
    "contributor_state": {
      "description": "Two-letter state code (e.g., CA). Itemized only.",
      "type": "string"
    },
    "contributor_zip": {
      "description": "ZIP code prefix (starts-with match). Itemized only.",
      "type": "string"
    },
    "cycle": {
      "description": "Two-year election cycle (e.g., 2024). Even years only. Defaults to current cycle for itemized mode.",
      "type": "number"
    },
    "min_date": {
      "description": "Earliest contribution date (YYYY-MM-DD). Itemized only.",
      "type": "string"
    },
    "max_date": {
      "description": "Latest contribution date (YYYY-MM-DD). Itemized only.",
      "type": "string"
    },
    "min_amount": {
      "description": "Minimum contribution amount in dollars. Itemized only.",
      "type": "number"
    },
    "max_amount": {
      "description": "Maximum contribution amount in dollars. Itemized only.",
      "type": "number"
    },
    "is_individual": {
      "description": "Only individual contributions (excludes committee-to-committee transfers). Itemized only.",
      "type": "boolean"
    },
    "sort": {
      "description": "Sort field. Itemized only.",
      "type": "string",
      "enum": [
        "contribution_receipt_date",
        "contribution_receipt_amount"
      ]
    },
    "per_page": {
      "default": 20,
      "description": "Results per page.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    },
    "cursor": {
      "description": "Opaque pagination cursor from a previous response. Itemized mode only (keyset pagination).",
      "type": "string"
    }
  },
  "required": [
    "mode",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

openfec_search_disbursements

Search itemized committee spending (Schedule B) or get aggregate breakdowns by purpose or recipient. All modes require a committee_id. Use to answer "what is this committee spending money on?" or "who is receiving payments from this committee?"

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_search_disbursements",
    "arguments": {
      "committee_id": "<committee_id>"
    }
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "mode": {
      "default": "itemized",
      "description": "Query mode. \"itemized\" returns individual disbursement records (keyset pagination). \"by_purpose\" aggregates by purpose category. \"by_recipient\" aggregates by recipient name. \"by_recipient_id\" aggregates by recipient committee ID (committee-to-committee transfers).",
      "type": "string",
      "enum": [
        "itemized",
        "by_purpose",
        "by_recipient",
        "by_recipient_id"
      ]
    },
    "committee_id": {
      "type": "string",
      "minLength": 1,
      "description": "Spending committee ID (e.g., C00703975). Get IDs from openfec_search_committees results. Required for all modes."
    },
    "recipient_name": {
      "description": "Full-text payee name search. Itemized only.",
      "type": "string"
    },
    "recipient_state": {
      "description": "Recipient state. Itemized only.",
      "type": "string"
    },
    "recipient_city": {
      "description": "Recipient city. Itemized only.",
      "type": "string"
    },
    "recipient_committee_id": {
      "description": "Recipient committee ID (for committee-to-committee transfers). Itemized only.",
      "type": "string"
    },
    "disbursement_description": {
      "description": "Full-text description search (e.g., \"media buy\", \"consulting\"). Itemized only.",
      "type": "string"
    },
    "disbursement_purpose_category": {
      "description": "Purpose category code. Itemized only.",
      "type": "string"
    },
    "cycle": {
      "description": "Two-year election cycle (e.g., 2024). Even years only.",
      "type": "number"
    },
    "min_date": {
      "description": "Earliest disbursement date (YYYY-MM-DD). Itemized only.",
      "type": "string"
    },
    "max_date": {
      "description": "Latest disbursement date (YYYY-MM-DD). Itemized only.",
      "type": "string"
    },
    "min_amount": {
      "description": "Minimum amount in dollars. Itemized only.",
      "type": "number"
    },
    "max_amount": {
      "description": "Maximum amount in dollars. Itemized only.",
      "type": "number"
    },
    "sort": {
      "description": "Sort field. Itemized only.",
      "type": "string",
      "enum": [
        "disbursement_date",
        "disbursement_amount"
      ]
    },
    "per_page": {
      "default": 20,
      "description": "Results per page.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    },
    "cursor": {
      "description": "Opaque pagination cursor from a previous response. Itemized mode only (keyset pagination).",
      "type": "string"
    }
  },
  "required": [
    "mode",
    "committee_id",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

openfec_search_expenditures

Search independent expenditures (Schedule E) — outside spending supporting or opposing federal candidates. Covers Super PACs, party committees, and other groups. Use itemized mode for individual expenditure records, or by_candidate for aggregated totals per candidate.

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_search_expenditures",
    "arguments": {}
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "mode": {
      "default": "itemized",
      "description": "Query mode. \"itemized\" returns individual expenditure records (keyset pagination). \"by_candidate\" returns aggregated totals per candidate by committee (page-based).",
      "type": "string",
      "enum": [
        "itemized",
        "by_candidate"
      ]
    },
    "committee_id": {
      "description": "Spending committee ID (e.g., C00703975). Get IDs from openfec_search_committees results.",
      "type": "string"
    },
    "candidate_id": {
      "description": "Targeted candidate ID (e.g., P00003392). Get IDs from openfec_search_candidates results.",
      "type": "string"
    },
    "support_oppose": {
      "description": "S = support, O = oppose. Filter by whether the expenditure supports or opposes the candidate.",
      "type": "string",
      "enum": [
        "S",
        "O"
      ]
    },
    "payee_name": {
      "description": "Full-text payee name search. Itemized only.",
      "type": "string"
    },
    "candidate_office": {
      "description": "Office of the targeted candidate: H=House, S=Senate, P=President.",
      "type": "string",
      "enum": [
        "H",
        "S",
        "P"
      ]
    },
    "candidate_office_state": {
      "description": "Two-letter state code of the targeted race.",
      "type": "string"
    },
    "candidate_party": {
      "description": "Three-letter party code of the targeted candidate (e.g., DEM, REP).",
      "type": "string"
    },
    "cycle": {
      "description": "Two-year election cycle (e.g., 2024). Even years only.",
      "type": "number"
    },
    "min_date": {
      "description": "Earliest expenditure date (YYYY-MM-DD). Itemized only.",
      "type": "string"
    },
    "max_date": {
      "description": "Latest expenditure date (YYYY-MM-DD). Itemized only.",
      "type": "string"
    },
    "min_amount": {
      "description": "Minimum expenditure amount in dollars. Itemized only.",
      "type": "number"
    },
    "max_amount": {
      "description": "Maximum expenditure amount in dollars. Itemized only.",
      "type": "number"
    },
    "is_notice": {
      "description": "Only 24/48-hour notice filings (near-election spending). Itemized only.",
      "type": "boolean"
    },
    "most_recent": {
      "default": true,
      "description": "Only the most recent version of amended filings. Itemized only.",
      "type": "boolean"
    },
    "sort": {
      "description": "Sort field. Itemized only.",
      "type": "string",
      "enum": [
        "expenditure_date",
        "expenditure_amount",
        "office_total_ytd"
      ]
    },
    "per_page": {
      "default": 20,
      "description": "Results per page.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    },
    "cursor": {
      "description": "Opaque pagination cursor from a previous response. Itemized mode only (keyset pagination).",
      "type": "string"
    }
  },
  "required": [
    "mode",
    "most_recent",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

openfec_search_filings

Search FEC filings and reports by committee, candidate, form type, or date range. Covers financial reports (F3/F3P/F3X), statements of candidacy (F2), organizational filings (F1), 24-hour IE notices (F24), and amendments.

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_search_filings",
    "arguments": {}
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "committee_id": {
      "description": "Filing committee ID (e.g., C00358796). Get IDs from openfec_search_committees results.",
      "type": "string"
    },
    "candidate_id": {
      "description": "Associated candidate ID (e.g., P00003392). Get IDs from openfec_search_candidates results.",
      "type": "string"
    },
    "filer_name": {
      "description": "Full-text filer name search.",
      "type": "string"
    },
    "form_type": {
      "description": "FEC form type. Common: F3 (House/Senate quarterly), F3P (Presidential), F3X (PAC/party), F24 (24-hour IE notice), F1 (statement of organization), F2 (statement of candidacy), F5 (IE by persons).",
      "type": "string"
    },
    "report_type": {
      "description": "Report type code. Common: Q1/Q2/Q3 (quarterly), YE (year-end), M3-M12 (monthly), 12G/12P/30G (pre/post election).",
      "type": "string"
    },
    "report_year": {
      "description": "Filing year.",
      "type": "number"
    },
    "cycle": {
      "description": "Two-year election cycle (even year).",
      "type": "number"
    },
    "is_amended": {
      "description": "Filter to original or amended filings only.",
      "type": "boolean"
    },
    "most_recent": {
      "default": true,
      "description": "Only the most recent version (filters out superseded amendments).",
      "type": "boolean"
    },
    "min_receipt_date": {
      "description": "Earliest date FEC received the filing (YYYY-MM-DD).",
      "type": "string"
    },
    "max_receipt_date": {
      "description": "Latest FEC receipt date (YYYY-MM-DD).",
      "type": "string"
    },
    "page": {
      "default": 1,
      "description": "Page number (1-indexed).",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Results per page.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "most_recent",
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

openfec_lookup_elections

Look up federal election races and candidate financial summaries. Find who's running in a race with fundraising totals, or get an aggregate race summary.

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_lookup_elections",
    "arguments": {
      "office": "<office>",
      "cycle": "<cycle>"
    }
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "mode": {
      "default": "search",
      "description": "search = candidates in a race with financial totals. summary = aggregate race financial summary.",
      "type": "string",
      "enum": [
        "search",
        "summary"
      ]
    },
    "office": {
      "type": "string",
      "enum": [
        "H",
        "S",
        "P"
      ],
      "description": "Office sought: H=House, S=Senate, P=President."
    },
    "cycle": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "Election cycle year (even years only, e.g. 2024)."
    },
    "state": {
      "description": "Two-letter US state code (e.g., AZ, CA). Required for senate/house unless zip is provided.",
      "type": "string"
    },
    "district": {
      "description": "Two-digit district number (e.g. \"07\"). Required for house unless zip is provided.",
      "type": "string"
    },
    "zip": {
      "description": "ZIP code — finds races covering this ZIP. Search mode only.",
      "type": "string"
    },
    "election_full": {
      "default": true,
      "description": "Expand to full election period (4yr president, 6yr senate, 2yr house). Default true. Ignored for ZIP-based searches.",
      "type": "boolean"
    }
  },
  "required": [
    "mode",
    "office",
    "cycle",
    "election_full"
  ],
  "additionalProperties": false
}
view source ↗

openfec_lookup_calendar

Look up FEC calendar events, filing deadlines, and election dates. Use to find upcoming filing windows for a committee, locate when a federal election occurred, or scope FEC events by date range and category.

read
invocation
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "openfec_lookup_calendar",
    "arguments": {}
  }
}
schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "mode": {
      "default": "events",
      "description": "events = FEC calendar events. filing_deadlines = report due dates. election_dates = upcoming/past elections.",
      "type": "string",
      "enum": [
        "events",
        "filing_deadlines",
        "election_dates"
      ]
    },
    "state": {
      "description": "Two-letter state code (e.g., AZ, CA). Primarily for election_dates mode.",
      "type": "string"
    },
    "office": {
      "description": "Office sought (H=House, S=Senate, P=President). Election dates mode.",
      "type": "string",
      "enum": [
        "H",
        "S",
        "P"
      ]
    },
    "report_type": {
      "description": "Report type code (e.g. \"Q1\", \"Q2\"). Filing deadlines mode only.",
      "type": "string"
    },
    "report_year": {
      "description": "Report year. Filing deadlines mode.",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    },
    "category": {
      "description": "Calendar category ID. 20=Commission Meetings, 21=Reporting Deadlines, 22=Conferences and Outreach, 23=AOs and Rules, 24=Other, 25=Quarterly, 26=Monthly, 27=Pre and Post-Elections, 28=EC Periods, 29=IE Periods, 32=Open Meetings, 33=Conferences, 34=Roundtables, 36=Election Dates, 37=Federal Holidays, 38=FEA Periods, 39=Executive Sessions, 40=Public Hearings. Events mode only.",
      "type": "string",
      "enum": [
        "20",
        "21",
        "22",
        "23",
        "24",
        "25",
        "26",
        "27",
        "28",
        "29",
        "32",
        "33",
        "34",
        "36",
        "37",
        "38",
        "39",
        "40"
      ]
    },
    "election_year": {
      "description": "Election year. Election dates mode.",
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991
    },
    "description": {
      "description": "Full-text event description search. Events mode.",
      "type": "string"
    },
    "min_date": {
      "description": "Earliest date (YYYY-MM-DD).",
      "type": "string"
    },
    "max_date": {
      "description": "Latest date (YYYY-MM-DD).",
      "type": "string"
    },
    "page": {
      "default": 1,
      "description": "Page number (1-indexed). Default 1.",
      "type": "integer",
      "minimum": 1,
      "maximum": 9007199254740991
    },
    "per_page": {
      "default": 20,
      "description": "Results per page. Default 20, max 100.",
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  },
  "required": [
    "mode",
    "page",
    "per_page"
  ],
  "additionalProperties": false
}
view source ↗

Resources

5

Fetch a federal candidate profile with current financial totals. Candidate IDs start with H (House), S (Senate), or P (President) followed by digits.

uri openfec://candidate/{candidate_id} mime application/json

Fetch a political committee profile with type, designation, and financial summary. Committee IDs start with C followed by digits (e.g., C00358796).

uri openfec://committee/{committee_id} mime application/json

Fetch a presidential election race with candidate financial totals. For senate races use openfec://election/{cycle}/S/{state}. For house races use openfec://election/{cycle}/H/{state}/{district}.

uri openfec://election/{cycle}/{office} mime application/json

Fetch a senate race, or a house at-large race in a single-district state, with candidate financial totals.

uri openfec://election/{cycle}/{office}/{state} mime application/json

Prompts

2

Multi-step framework for tracing the flow of money around a candidate or race — direct fundraising, PAC support, independent expenditures, and party spending.

  • candidate_name — Candidate name to investigate. Provide this or candidate_id.
  • candidate_id — FEC candidate ID (e.g., P00003392). Provide this or candidate_name.
  • cycle — Election cycle year (e.g., 2024). Defaults to current cycle.

Structured analysis of a candidate's financial position — fundraising trajectory, burn rate, cash reserves, donor composition, and opponent comparison.

  • candidate_name — Candidate name to analyze. Provide this or candidate_id.
  • candidate_id — FEC candidate ID (e.g., P00003392). Provide this or candidate_name.
  • cycle — Election cycle year (e.g., 2024). Defaults to current cycle.