home / mcp / agent care mcp server

Agent Care MCP Server

Provides EMR integration, FHIR access, and medical research tools via an MCP server for Cerner and Epic.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "kartha-ai-agentcare-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/Users/your-username/Desktop"
      ],
      "env": {
        "FDA_API_KEY": "YOUR_FDA_API_KEY",
        "OAUTH_SCOPES": "user/Patient.read",
        "FHIR_BASE_URL": "https://fhir.example.com/r4",
        "OAUTH_AUDIENCE": "https://fhir.example.com",
        "PUBMED_API_KEY": "YOUR_PUBMED_API_KEY",
        "OAUTH_CLIENT_ID": "YOUR_CLIENT_ID",
        "OAUTH_TOKEN_HOST": "https://authorization.example.com",
        "OAUTH_TOKEN_PATH": "/token",
        "OAUTH_CALLBACK_URL": "http://localhost:3456/oauth/callback",
        "OAUTH_CALLBACK_PORT": "3456",
        "OAUTH_CLIENT_SECRET": "YOUR_CLIENT_SECRET",
        "OAUTH_AUTHORIZE_PATH": "/authorize",
        "CLINICAL_TRIALS_API_KEY": "YOUR_CLINICAL_TRIALS_API_KEY",
        "OAUTH_AUTHORIZATION_METHOD": "'header'"
      }
    }
  }
}

Agent Care MCP Server provides healthcare tools and prompts to interact with FHIR data on EMRs like Cerner and Epic. It integrates with SMART on FHIR, supports OAuth2 authentication, and offers medical research integrations and clinical analysis capabilities. This guide walks you through practical usage, installation steps, and essential configuration to run Agent Care on your environment.

How to use

You will run the MCP server locally and connect it to your preferred MCP client (for example Goose Desktop or Claude Desktop). The server exposes FHIR-related tools (find patients, get observations, labs, medications, care teams, and more) and medical research tools (PubMed searches, clinical trials, and drug interactions). You interact with the server by starting it as a local process and pointing your MCP client at the appropriate stdio entry. Use the included environment variables to configure your OAuth and API keys for Cerner or Epic connections.

How to install

Prerequisites: you need Node.js installed on your system, plus access to a terminal. You should also have a compatible MCP client ready to connect to a local stdio server.

1) Clone the Agent Care MCP project and install dependencies.

2) Build the server so you can run the built index. Run the following commands in order.

Additional sections

Configuration and MCP connections are defined in concrete code blocks below. Two local stdio servers are used to run the Agent Care MCP server and the filesystem provider for local data. Real values should be supplied via environment variables in your deployment or launch configuration.

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-filesystem",
        "/Users/your-username/Desktop"
      ]
    },
    "agent-care": {
      "command": "node",
      "args": [
        "/Users/your-username/{agentcare-download-path}/agent-care-mcp/build/index.js"
      ],
      "env": {
        "OAUTH_CLIENT_ID": "XXXXXX",
        "OAUTH_CLIENT_SECRET": "XXXXXXX",
        "OAUTH_TOKEN_HOST": "",
        "OAUTH_TOKEN_PATH": "",
        "OAUTH_AUTHORIZE_PATH": "",
        "OAUTH_AUTHORIZATION_METHOD": "",
        "OAUTH_AUDIENCE": "",
        "OAUTH_CALLBACK_URL": "",
        "OAUTH_SCOPES": "",
        "OAUTH_CALLBACK_PORT": "",
        "FHIR_BASE_URL": "",
        "PUBMED_API_KEY": "",
        "CLINICAL_TRIALS_API_KEY": "",
        "FDA_API_KEY": ""
      }
    }
  }
}

Security and credentials

Handle OAuth client IDs, secrets, and API keys securely. Do not commit credentials to source control. Use a secure secrets store or environment configuration in your deployment platform. Ensure redirection URIs for OAuth match the OAUTH_CALLBACK_URL in your environment.

Available tools

find_patient

Search for a patient by name, DOB, or other identifiers.

get_patient_observations

Retrieve patient observations and vital signs.

get_patient_conditions

Get patient's active conditions.

get_patient_medications

Get patient's current medications.

get_patient_encounters

Get patient's clinical encounters.

get_patient_allergies

Get patient's allergies and intolerances.

get_patient_procedures

Get patient's procedures.

get_patient_careteam

Get patient's care team members.

get_patient_careplans

Get patient's active care plans.

get_vital_signs

Get patient's vital signs.

get_lab_results

Get patient's laboratory results.

get_medications_history

Get patient's medication history.

clinical_query

Execute custom FHIR queries.

search-pubmed

Search PubMed articles related to medical conditions.

search-trials

Find relevant clinical trials.

drug-interactions

Check drug-drug interactions.