MCPSERV.CLUB
mike-holcomb

Fhir Mcp Server Medagentbench

MCP Server

Simulate FHIR API calls for MedAgentBench testing

Stale(50)
0stars
2views
Updated Apr 12, 2025

About

A Python MCP server that intercepts MedAgentBench FHIR operations and returns textual representations of the HTTP requests that would be made, enabling agent testing without a live FHIR endpoint.

Capabilities

Resources
Access data sources
Tools
Execute functions
Prompts
Pre-built templates
Sampling
AI model interactions

Overview

The Fhir Mcp Server Medagentbench is a lightweight, Python‑based MCP server that emulates interactions with a FHIR API for the MedAgentBench environment. Instead of issuing real HTTP calls to a downstream FHIR server, it intercepts MCP requests and returns plain‑text descriptions of the HTTP request that would have been sent (e.g., or a formatted POST body). This approach lets developers prototype and test MedAgentBench agents in isolation, without the need for a live FHIR endpoint or network connectivity.

By providing a deterministic, read‑only simulation of the FHIR interface, the server removes external dependencies that could introduce latency or variability. Developers can focus on refining agent logic, prompt engineering, and workflow orchestration while still exercising the full MCP contract. The server also supports asynchronous operation, allowing it to scale with multiple concurrent agent sessions without blocking.

Key capabilities are exposed through standard MCP handlers:

  • Resource enumeration returns the simulated resource set (currently only a ), giving agents a sense of available endpoints.
  • Resource access simulates fetching a resource by URI, returning the corresponding HTTP GET string.
  • Tool discovery enumerates available FHIR simulation tools, and implements common operations such as searching, reading, or creating resources. Each tool call produces a textual representation of the HTTP request that would be issued against an actual FHIR server.

These features enable realistic testing scenarios: agents can construct search queries, interpret expected responses, and handle edge cases like missing resources or validation errors—all within a controlled simulation. The server’s integration with the library ensures seamless communication over standard input/output, matching the protocol expectations of MedAgentBench agents.

In practice, teams can use this server during early development cycles to validate agent prompts, debug tool invocation logic, and generate test cases for downstream integration. Once the agent behavior is stable, developers can swap in a real FHIR server or a more sophisticated mock without changing the MCP contract. This plug‑and‑play design gives MedAgentBench users a clear advantage: rapid iteration, reduced infrastructure overhead, and consistent test results across environments.