• DATA
  • CLINICAL
  • DEMOGRAPHIC
  • HUMAN

How to extract patient cohorts with your AI

Connect your AI to Epic once. After that, you can pull specific patient lists using natural language.

Ask AI about this page

Short answer

How can I find specific patient groups in Epic?

Your AI uses the Epic Fhir connection to search for patients and list their clinical conditions. You can define a cohort by asking for patients with specific diagnoses or demographic traits. You'll get a filtered list of patients ready for your review.

The results you get

Where your data lands

The AI processes your request and organizes the data into these outcomes.

DATA

Patient lists

The AI pulls specific patient records that match your criteria. You get a clean list of names or IDs.

CLINICAL

Diagnosis groups

The AI identifies patients based on their medical history. It looks through recorded conditions to find the exact matches you need.

DEMOGRAPHIC

Filtered populations

You can narrow down groups by age, gender, or other patient details. The AI handles the filtering logic for you.

HUMAN

Clinical validation

The AI provides the raw data, but you must verify the clinical accuracy. You decide if the cohort meets your medical requirements.

The workflow

What your AI does when the request arrives.

The AI translates your plain English into specific FHIR data requests.

  1. Identify the target

    The AI looks at your request to see if you are looking for specific people or a specific diagnosis.

    search_patients
  2. Filter by diagnosis

    If you need patients with a certain condition, the AI checks the clinical records.

    list_conditions
  3. Refine the group

    The AI uses patient data to narrow down the list based on the demographics you mentioned.

    search_patients
  4. Present the cohort

    The AI compiles the final list of patients that meet every part of your prompt.

    search_patientslist_conditions

Try it

Copy these to start.

Use these prompts to begin your search.

Starting points

Swap the bracketed text with the specific diagnoses or ages you are looking for.

Epic Fhir Connector

You're all set. Choose your MCP client and follow the setup instructions.

Connector linkhttps://edge.vinkius.com/vk_preview_07WMxq8my4NvzsZPkY6lYQ8jtiB06jHwWtJH34fM/mcp

Claude Desktop

Follow the steps below to connect in seconds.

  1. 1In Claude Desktop, open Settings → Connectors.
  2. 2Click “Add custom connector” and paste the connector link above as the remote MCP server URL.
  3. 3Click Add and start a new chat — Epic Fhir capabilities are ready to use.
Configuration · claude_desktop_config.jsonCopy
{
  "mcpServers": {
    "epic-fhir-mcp": {
      "url": "https://edge.vinkius.com/vk_preview_07WMxq8my4NvzsZPkY6lYQ8jtiB06jHwWtJH34fM/mcp"
    }
  }
}
Copy into chat04
  • Find all patients in Epic with a diagnosis of [Type 2 Diabetes].

  • List patients who are between the ages of [45 and 60].

  • Show me patients who have been diagnosed with [Hypertension].

  • Search for female patients in the [Pediatric] department.

  • Claude
  • ChatGPT
  • Cursor
  • VS Code
  • Windsurf
  • Claude Code
  • JetBrains
  • Cline

Start here

Connect Epic Fhir once, then ask.

You only need to link your Epic credentials once. The connection is encrypted and stays secure while you chat with your AI.

Connect Epic Fhir to your AI

FAQ

How this task behaves

  • 01

    Can the AI change patient records in Epic?

    No. The AI can only read data to find and list patients. It cannot edit, delete, or add any clinical information.

  • 02

    Can I export these lists to a spreadsheet?

    The AI can provide the list in the chat, but it does not have a tool to write directly to Excel or Google Sheets.

  • 03

    Does the AI see all my patient data?

    The AI only accesses the specific data required to answer your prompt through the provided tools.

  • 04

    Can the AI schedule appointments?

    No. There are no tools available in this MCP to create appointments or modify schedules.

  • 05

    How does the AI know which patients have which conditions?

    It uses the ability to list conditions for specific patients to verify their medical history.

  • More questions about Epic Fhir? See everything the Epic Fhir Connector can do

Connect Epic Fhir to Claude, Cursor, ChatGPT & more