OpenFOIA
Local-first investigation toolkit for journalists, researchers, and citizens.
Anyone, anywhere, should be able to investigate power safely. Most of the world has no legal right to demand records from its government, and where the right exists, asking can be dangerous. OpenFOIA is built for the reporter in Istanbul, the researcher in Nairobi, the citizen in São Paulo: it runs on your machine, works offline, and can be wiped. Your data never leaves your machine unless you choose to send it.
One real government document, 45 entities, 166 relationships, extracted locally in seconds. No cloud. No API keys.


Install
With Claude Code (recommended)
If you use Claude Code, install the OpenFOIA plugin. You get the CLI plus a built-in copilot that knows every command:
/plugin marketplace add JordanCoin/openfoia
/plugin install openfoia@openfoia
/foia-install
The plugin ships a skill that teaches Claude how to run FOIA investigations, plus slash commands for the core loop: /foia-search, /foia-investigate, /foia-graph, /foia-install. The last one bootstraps the CLI on your machine.
With any MCP client (Claude Desktop, Claude Code, others)
openfoia mcp serve runs OpenFOIA as a local MCP server over stdin/stdout (no network port). After openfoia install-extras mcp:
{ "mcpServers": { "openfoia": { "command": "openfoia", "args": ["mcp", "serve"] } } }
or claude mcp add openfoia -- openfoia mcp serve. Agents get openfoia_search (the openfoia search code path: off unless you add --allow-network, and every search needs a confirmed second call after the warning) and read-only local tools over your cases, stored documents, entities and requests. No tool deletes, purges, sends requests or messages, or changes config. Whatever a tool returns goes to the client's model provider. Setup and details: GUIDE.md, AI agents over MCP.
Shell install (no Claude Code needed)
curl -fsSL https://raw.githubusercontent.com/JordanCoin/openfoia/main/install.sh | bash
Works on Linux, macOS, and Windows (WSL).
New to OpenFOIA? Run openfoia guide after installing.
What It Does
Find the records. Read them page by page. Record findings with citations. Draft the request to the body that actually holds the record, under the law that body answers to, and track its clock. All locally, all offline, all purgeable.
openfoia init # 53 federal agencies pre-loaded
openfoia case new "Gifted program, Detroit 1990s" # one question, one case
openfoia jurisdiction show us-mi # the law a Michigan school district answers under
openfoia agency add --name "Detroit Public Schools Community District" -j us-mi -l school_district --email [email protected]
openfoia records search "Palantir" --source documentcloud --json --rank police,contract # search 10M+ public documents, ranked
openfoia records fetch --from hits.json # pull every hit's text, page by page, into the case
openfoia records fetch CIA-RDP96-00789R002200230001-2 --source cia # CIA reading room PDF, OCR/ingest locally
openfoia docs grep '"school board" OR WISC' -C 120 # every passage, with page numbers, offline
openfoia case note "No document names minors" --doc 3f2a --page 51 --quote "..." --tier says
openfoia analyze graph --name investigation --no-text --view # graph scoped to the case
openfoia case export -f md -o report.md # findings with citations, sources, query log
openfoia request mark REQ-2026-001 denied # starts the appeal clock the statute sets
Features