HealthChain MCP
FHIR MCP tools for an agent: build, read and validate resources from a patient bundle with an actionable validation report.
- 231 ★ on the repository
- Last commit
- Apache-2.0
Broad access
Why this level
- The tools work with patient data; a bundle with real records must not go to a model without consent and a legal basis.
- The library connects to live FHIR servers using credentials from environment variables.
Install
- Works in
In your terminal, with SkillFoxx CLI
npx skillfoxx add mcp/healthchainDetects the agents on your machine, shows the access level and pins the version.
Other ways to install
Access and checks
How we reviewBroad accessThe tool can change data, run commands or handle secrets.
- The tools work with patient data; a bundle with real records must not go to a model without consent and a legal basis.
- The library connects to live FHIR servers using credentials from environment variables.
This is third-party code. Review the repository files before installing.
What it does
HealthChain is a Python library for FHIR work: it connects to live Epic, Cerner, Medplum and other FHIR R4 servers, builds and validates resources, and delivers output through REST, CDS Hooks, CDA, MCP or LangChain. For agents the repository publishes an MCP server and a plugin. The MCP server starts with `healthchain mcp --bundle patient_bundle.json` and serves `FHIRToolkit`: typed tools that build, read, validate and code FHIR resources from a patient bundle, with terminology lookup. Validation returns a structured report with failing field paths, so the agent fixes the resource and retries. The plugin for Claude Code and Codex adds a `healthchain` skill with the current API, CLI commands and recipes for Python code that works with FHIR.
Who it is for. Developers of clinical software and research systems who build FHIR resources and want to give an agent checkable tools.
Good fit when
- An agent builds an Observation resource from free text and must pick a valid code.
- Generated FHIR must be validated before delivery and corrected from the report.
- A developer writes a Python service for Epic and Cerner and asks the agent for help with the current API.
- You need to test on a patient bundle how an AI answer maps onto FHIR structure.
Not a fit when
- You need full profile and FHIRPath invariant conformance, which requires a server `$validate`.
- You need to make clinical decisions: the tools do not guess clinical codes and do not replace a specialist.
- Real patient data cannot be shown to an agent and a model.
Example request
Build a Condition resource from this description against the patient bundle, validate it and fix the errors in the report.MCP
- Transport
- stdio
- Authentication
- not required
Limitations
MCP tools install through the `healthchain[mcp]` extra. `validate_resource` checks structure and required primitive-code bindings and does not check profiles, FHIRPath invariants, `CodeableConcept` value-set bindings or reference integrity. Full conformance may need a server `$validate`. Licensed terminologies such as SNOMED need their own license to resolve display text. Clinical content of resources remains the caller's responsibility.
How to disable. Remove the server from the client's MCP configuration, disable the `healthchain` plugin in Claude Code or Codex and uninstall the `healthchain` package.
FAQ
How do I run the HealthChain MCP server?
With `healthchain mcp --bundle patient_bundle.json` over stdio. The `--bundle` option gives the patient bundle path the tools operate on and is optional.
How do I install the Claude Code plugin?
Run `/plugin marketplace add healthchainai/HealthChain`, then `/plugin install healthchain@healthchain`. Codex has `codex plugin marketplace add` and `codex plugin add healthchain@healthchain`.
What does the agent get on a validation error?
A structured `ValidationReport` with field paths and diagnostics. No exception is raised; the report arrives as data and the agent reads it in a build, validate and correct loop.
Can the same tools be used in LangChain?
Yes. `FHIRToolkit` also exposes them through `as_langchain()`.
Which extras does the package have?
`healthchain[mcp]`, `healthchain[langchain]`, `healthchain[cda]`, `healthchain[sandbox]` and `healthchain[examples]`.
Discussion
No questions or reviews yet.
Related
MCP serversLangCare MCP FHIR: agent access to medical records
LangCare MCP FHIR
A Go MCP server whose four FHIR R4 operations give an agent read and write access to Epic, Cerner, OpenEMR and GCP Healthcare API
Anthropic's official plugin for healthcare work: ICD-10-CM coding, prior authorization, FHIR access and PubMed search
Medical MCP
medical-mcp
MCP server for medical sources: FDA and EMA drug data, WHO statistics, PubMed and clinical trials without API keys.
AWS hcls-agents plugin gives Claude Code and Codex skills for genomics, clinical trials and biomarkers plus MCP servers.
A medical code reference for your agent: search, map and navigate SNOMED CT, ICD-10, RxNorm and LOINC concepts across vocabularies
BioMCP
biomcp
One binary and a single command grammar for 70 biomedical sources: PubMed, ClinVar, ClinicalTrials.gov, OncoKB. MCP mode starts with the serve command
README in short
The library puts one FHIR boundary around your Python code: live data in, your logic in the middle, validated FHIR out. The CLI has `healthchain new`, `serve`, `sandbox run` and `mcp`.