Skip to main content
Glama

MCP FHIR Server

by flexpa

@flexpa/mcp-fhir

[!警告] 这是一个实验性的演示,不适用于生产用途。

这是一个基于 TypeScript 的 MCP 服务器,用于连接到 FHIR 服务器。它通过以下方式提供与 FHIR 资源交互的核心 MCP 功能:

  • 通过 URI 访问 FHIR 资源
  • 提供 FHIR 资源的搜索功能

特征

资源

此处的“资源”指的是 MCP 定义*,而非*FHIR 定义。MCP 资源是模型上下文协议 (MCP) 中的核心原语,允许服务器公开可供客户端读取并用作 LLM 交互上下文的数据和内容。

  • 通过fhir:// URI 列出并访问 FHIR 资源
  • 资源以 FHIR JSON 格式返回
  • 支持 FHIR 服务器 CapabilityStatement 中可用的所有 FHIR 资源类型

工具

  • search_fhir - 搜索 FHIR 资源
    • resourceTypesearchParams作为参数
    • 返回 FHIR 搜索结果
  • read_fhir - 读取单个 FHIR 资源
    • uri作为参数
    • 以 JSON 格式返回 FHIR 资源

配置

服务器需要以下环境变量:

  • FHIR_BASE_URL :FHIR 服务器的基本 URL
  • FHIR_ACCESS_TOKEN :用于身份验证的 FHIR 访问令牌上的 SMART

发展

安装依赖项:

npm install

构建服务器:

npm run build

对于使用自动重建的开发:

npm run watch

安装

要与 Claude Desktop 一起使用,请添加服务器配置:

在 MacOS 上: ~/Library/Application Support/Claude/claude_desktop_config.json在 Windows 上: %APPDATA%/Claude/claude_desktop_config.json

{ "mcpServers": { "fhir": { "command": "/path/to/@flexpa/mcp-fhir/build/index.js" }, "env": { "FHIR_BASE_URL": "<FHIR_BASE_URL>", "FHIR_ACCESS_TOKEN": "<FHIR_ACCESS_TOKEN>" } } }

调试

由于 MCP 服务器通过 stdio 进行通信,调试起来可能比较困难。我们推荐使用MCP Inspector ,它以包脚本的形式提供:

npm run inspector

检查器将提供一个 URL 来访问浏览器中的调试工具。

-
security - not tested
A
license - permissive license
-
quality - not tested

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

基于 TypeScript 的 MCP 服务器连接到 FHIR 服务器,允许通过 fhir:// URI 访问医疗保健数据并提供 FHIR 资源的搜索功能。

  1. 特征
    1. 资源
    2. 工具
  2. 配置
    1. 发展
      1. 安装
        1. 调试

      Related MCP Servers

      • -
        security
        A
        license
        -
        quality
        An MCP server that provides healthcare tools for interacting with FHIR data and medical resources on EMRs like Cerner and Epic
        Last updated 3 months ago
        28
        JavaScript
        MIT License
        • Apple
      • -
        security
        F
        license
        -
        quality
        This is a TypeScript-based MCP server that provides integration with ERPNext/Frappe API. It enables AI assistants to interact with ERPNext data and functionality through the Model Context Protocol.
        Last updated 3 months ago
        4
        JavaScript
        MIT License
        • Apple
      • -
        security
        F
        license
        -
        quality
        A Model Context Protocol server that connects AI tools to Electronic Health Records using SMART on FHIR, allowing secure searching, querying, and analysis of patient data from compatible EHRs.
        Last updated 16 days ago
        38
        TypeScript
      • A
        security
        A
        license
        A
        quality
        MCP Server for Google Cloud Healthcare API enables Agentic AI for a variety of FHIR-based digital health solutions, from smarter clinical workflows for Health Systems to Pre-Auth frameworks for Payers!
        Last updated a month ago
        15
        3
        JavaScript
        MIT License
        • Apple

      View all related MCP servers

      MCP directory API

      We provide all the information about MCP servers via our MCP API.

      curl -X GET 'https://glama.ai/api/mcp/v1/servers/flexpa/mcp-fhir'

      If you have feedback or need assistance with the MCP directory API, please join our Discord server