Real-time patient flow across hospital networks, built on Medplum
What if a hospital could see patient movement the way air traffic control sees planes? In this webinar, Reshma Khilnani, co-founder and CEO of Medplum, and Pamella Bezerra, senior software engineer at Vinta, walk through the Transfer Center: a reference app that shows, in real time, which beds are taken and where there is room across a hospital network’s facilities.
This post covers what they showed, so you can follow it without watching the recording. The story of the project behind the app is in our Transfer Center case study.
Why real-time apps matter
Checking on the status of things slows work down and adds overhead and back-and-forth. In legacy healthcare systems, the canonical tool for this is still the pager.
Outside healthcare, real-time apps are everywhere:
- Uber: you see where your car is, instead of calling to ask if it will make it in time for the airport.
- Google Docs: you see who is writing where, so you don’t step on anyone’s changes.
- Slack: you see who is online right now.
People are used to this as consumers, but in healthcare these apps are generally not as good. Reshma showed two examples built on Medplum: a multiplayer chart, where several people work in the same record at once, and a dictation app that also reads HL7 measurements in real time.
How the pieces fit together
Clinical systems already have connection points, even when they are poorly documented: an EHR has HL7 v2 and FHIR interfaces, RIS and PACS speak HL7 and DICOM, and there are X12 and FHIR subscriptions.
Medplum connects to them through the Medplum Agent, a small piece of software that runs on the hospital’s site network and connects to the cloud over secure WebSockets. From there, an event goes through these steps:
- A system on the site network, such as the EHR, opens a TCP connection and sends an HL7 message.
- The agent passes it on to the cloud over its WebSocket.
- A Medplum bot, your own code, handles the event. It can also write files to storage.
- The reply goes back to the system that sent the message, and the app on top shows the change.
In the stack, the Transfer Center is the app at the top. Medplum provides the infrastructure and data handling, the bots hold the custom logic for each event, and the agent connects to whichever system is in the field.
The Medplum app has tools for all of it. You set up the agent from there, check its status, ping it and fetch its logs, then connect the bot that processes its events.
The demo: the Transfer Center
Medplum partnered with Vinta to support a hospital network with several facilities. It wanted better operational visibility: where patients are, which beds are free, and how patients move between facilities, all in one place. The goal was a real-time, FHIR-native dashboard showing bed availability, incoming transfers and patient status.
When someone needs to go from the emergency room to the ICU, or from one facility to another, the team has to know there is a place for them, and hand off all the relevant clinical data to whoever receives them.
Beds, updated as patients move
On the dashboard, each box is a wing of the hospital, a clinic or a facility, with its total beds and how many are taken or free. A click on a box opens the bed-by-bed detail.
Pamella sent HL7 ADT (admission, discharge and transfer) messages from a terminal, standing in for the hospital’s systems:
- an admission marked a bed as occupied, and the box’s count changed on the dashboard right away;
- a discharge freed it again, just as quickly.
The demo ran on test data. Its logs don’t show any PHI, so people working on the technical side don’t see it. The message events do carry it, and access policies can filter them by user type, so only people allowed to see PHI can.
Reshma added that Medplum has a sense of identity: in this app, a user might be signed in as a coordinator. Access policies can mask PHI or show it for some facilities and not others, so each person has what their job needs, without exposing PHI across organizations when the care plan doesn’t permit it.
Incoming transfers
The second part of the dashboard lists the latest transfers, with month-to-date totals of how they were resolved.
To bring in a transfer, staff fill in a questionnaire on the Transfer Center tab:
- demographics;
- vital signs;
- allergies;
- lab values;
- transfer details, including the facility the patient is coming from.
The app was built with Medplum’s React library, which made the form quick to build and easy to customize. With an MVP running early, the team could get as much feedback as possible from busy clinical staff on what to collect, what to require, and what could wait.
Reshma calls the form “Google Forms for FHIR”. It is built with a questionnaire builder, and when it is submitted, out come FHIR resources, not a table that needs ETL. It follows FHIR SDC (Structured Data Capture), and the type-ahead fields draw on standard code systems and value sets such as LOINC and SNOMED.
In the Medplum app, the result is standard, coded FHIR, ready to sync with other systems:
- the transfer is modeled as a
ServiceRequest, with its requisition ID, status, requester and a link back to the form’s answers; - each allergy is an
AllergyIntolerance, linked to the patient and coded in SNOMED, with its verification and clinical status.
Each transfer has its own page: a patient summary, the transfer’s details, tasks and notes that physicians can add. It has two main actions:
- Accept physician: the physician taking the patient, with their specialty, location and primary physician.
- Update status: consultation, completed transfer, declination, higher level of care or cancellation.
The app is a client application only, with no backend of its own. It runs in the browser, connects to the Medplum server and subscribes to its events over WebSockets. With no independent data store, its compliance footprint stays small, and all the data in it is FHIR.
Physicians and locations
Two admin pages complete the app.
Physicians: staff register physicians with their title, name, qualifications, specialty and phone number. In this project, the phone number mattered: a transfer can come in at midnight, and the physician has to be reachable to talk it through. A well-modeled provider directory (who is on staff, their qualifications, even who is available right now) is a key part of a Medplum implementation.
Each physician, or each specialty, can also have extra questions that must be answered before a transfer is accepted, built with the same questionnaire builder. Clinical staff often have strong opinions about what data to capture, and letting each department decide what is mandatory can raise clinical fidelity.
Locations: FHIR models locations as a hierarchy. Here, the top level is the wings or facilities and the level under them is the beds, but there could be many more levels. Each location has a name, a description and an operational status, and facilities can be enabled or disabled.
The census of a facility is a useful building block beyond transfers. Telehealth and call center apps, for example, can use it to know which beds are taken.
The Medplum Agent and traditional interface engines
If you have used Mirth or Corepoint, the Medplum Agent is the cloud version of those connectors. It connects to the cloud and handles the data there, which makes for simpler workflows and better uptime.
A mature implementation can have 20 to 50 agents connected to different systems. In the Medplum app you see the whole fleet: which agents are active, their status and how to troubleshoot them. For anyone in healthcare IT who has been woken at night because a connector is down, seeing at a glance that, say, the lab system is having an outage can save a lot of late-night calls.
The other difference from Mirth is where the logic lives. In Mirth, the connector does the translation and the connectivity. The Medplum Agent is small by design, with very little logic: the bots in the cloud do the handling and translation, in TypeScript, under source control. That is also where you normalize HL7, since systems put data in different places and each has its own dialect.
The same pattern, other use cases
The Transfer Center listens to an ADT feed, but with a few changes the same pattern fits other workflows that Medplum has seen in practice:
- A master schedule: connect to each system’s SIU (scheduling) feed to see the schedules of several EHRs, radiology and meeting rooms in one place. A managed services organization or a network with many facilities can use it as a control center.
- Order tracking: follow the order and result feeds to see where a radiology or lab order is, instead of sending an intern to check.
- Scribes: several scribes use Medplum as their backend and real-time layer, through FHIR and the MDM interface.
- Readmission tracking: get a notification when someone discharged, say from the ICU, is admitted again elsewhere.
- Radiology reporting: radiology often works in real time, given its workflow and how tech-savvy the field tends to be.
- Discharge to skilled nursing: know whether a skilled nursing facility has room.
- Claims: act as soon as a claim is denied, by connecting to the DFT feed.
- Clinical trials: check whether admitted patients with certain lab values or radiology results are eligible for a trial, and whether their consent forms are in place.
Frequently asked questions
The first six are the audience’s questions from the webinar, with the answers Reshma and Pamella gave. The last three come from the project behind the app.
Do teams use Medplum's MCP server?
The Transfer Center project didn’t, though another Vinta team was studying it. Medplum has its own implementation of MCP (Model Context Protocol, Anthropic’s standard for connecting LLMs to systems of record), enabled on its sandboxes. LLMs understand FHIR well because the standard has been public for a long time.
Has anyone built an ambulatory EHR on Medplum?
Quite a few teams have, often for one specialty: pediatrics, specific conditions, primary care and functional medicine. Several showed their work in videos at Medplum’s conference in August. At Vinta, we built Rewind’s own EHR on Medplum, after its move off an out-of-the-box one.
Where is the bots' code?
In the repository’s src/bots folder. Besides the bot that processes HL7 messages, bots also turn the patient intake answers into structured FHIR resources. Medplum’s docs explain how bots work, and we wrote about automating questionnaires with bots.
How would an organization that does complex care, but doesn't manage beds, adapt it?
By listening for the other side of the story: alerts when someone is admitted or discharged, for longitudinal care. A discharge can trigger scheduling a meeting with their care worker, and lab results, insurance changes or denied claims can trigger timely follow-up too. On Medplum, FHIR subscriptions are one way to react to those events.
Could this become a command center for a community?
That is the hope: a population-level view for an organization’s patients, driven by events and with the right access controls, so people get the right care at the right time.
Why did Medplum go open source?
Medplum is commercial open source, with a SaaS platform it supports. The best developers build with open source: Medplum’s code is public, and so is the Transfer Center’s, which welcomes pull requests.
Did the project use real patient data?
No. The HL7 ADT messages came from SimHospital, Google’s simulated hospital, instead of live hospital feeds. That kept patient data out of the project while each message still went through the path it would take in production, through the Medplum Agent to the dashboard.
How long did it take to build?
Medplum’s engineers started the app, and Vinta joined them for three months to finish the MVP. Clinical staff reviewed it between shifts, mostly through demo videos and structured feedback they could give when they had a moment. The Transfer Center case study tells that story.
Can ADT messages arrive as files instead?
Yes. Some systems drop HL7 messages as files on an SFTP server instead of sending them live. For that case, we built a demo bot for Medplum that reads ADT A01 (admission) and A08 (update) files over SFTP and turns each one into FHIR resources: the patient, the encounter, the physician and any allergies. It is in Medplum’s example bots.
Related articles

Article · 6 min read
5 things we took home from PlumCon 2026
Community, partnerships and what stuck with us from Medplum's yearly conference.
6 min read

Article · 19 min read
Building for the background: field notes on the clinical-tech gap from ViVE 2026
Our ViVE 2026 takeaways on interoperability, AI scribes and reducing clinical burden.
19 min read




