Faxed lab results charted after a Teams pick when the match isn't clean
Reads lab results faxed to Documo and matches the Healthie chart on name and birth date. When the match isn't clean, your intake coordinator picks the chart on a Teams card.
The prompt
When a fax comes in on our Documo line, read it. If it's a lab result, pull out the patient's name and birth date, the lab, the panel, the ordering provider, the accession number, the collection date and every value with its units, the lab's range and the flag the lab printed. Look for the patient in Healthie by name and birth date, then by last name and birth date, then by first and last name. If exactly one chart has the same name and birth date, use it. Otherwise send our intake coordinator a card in the intake Teams channel with what the fax says, the charts that come close and a button for each, and wait. Once there's a chart, record the result on it under the patient's assigned provider, file the PDF, and give that provider a review task. If the lab flagged any value, also post it in our results Teams channel. If the fax has no PDF or can't be read, tell the intake channel with the Documo fax ID. Never create a patient from a lab result.
FlowRunner Prompt to Flow built this flow from that request. Here it is as it opens in the editor.
The flow
Download the file, then in FlowRunner click + beside Flows, pick it under Import a Flow Version and click Create. How importing works
What each step does
- New fax received Starts when Documo finishes receiving a fax. If the PDF could not be saved, the intake channel in Teams gets the Documo fax ID to file it by hand.
- Read the lab result An AI agent decides whether the fax is a lab result. If it is, it copies the patient's name and birth date, the lab and panel, the ordering provider, the accession number, the collection date, and each value with its units, the lab's range and the flag exactly as the lab printed it. A fax that is plainly another kind of document stops here; one the agent can't read goes to the intake channel with its fax ID.
- Find the patient's chart Searches Healthie by name and birth date, then by last name and birth date, then by first and last name. Only one chart with the same name and birth date counts as a match.
- Ask the intake coordinator A near match, two charts with the same name and birth date, or no chart at all goes to the intake coordinator on a Teams card: what the fax says, its Documo fax ID, each chart that comes close with a link and the reason, a link to the fax, and a button for each chart.
- Wait for the coordinator's pick The run waits for the click. None of these records nothing and leaves the fax link and ID in the thread so the coordinator can file it by hand. A patient is never created from a lab result.
- Record the result on the chart Files the faxed PDF on the chart and records the lab order with each value, its units, the lab's range and the lab's flag, under the patient's assigned provider.
- Task: review the result Gives the patient's assigned provider a review task naming the ordering provider on the fax and listing the values the lab flagged. If the lab printed no flags it says so, and if no values could be read it says to check the PDF. Flagged or unread results are high priority.
- Post the lab flags in the results channel Any value the lab flagged is also posted in the results channel in Teams right away, with the patient and a link to the chart.
Before you turn it on
This flow assumes every service in it, FlowRunner included, has signed a business associate agreement (BAA) with you. Its messages to your staff include the patient details they need to decide.
- Enter your Documo and Healthie API keys, and connect your Microsoft Teams account.
- Add your Anthropic key in the flow setting Anthropic key.
- Copy the URL of the block Wait for the coordinator's pick into the flow setting Answer link. The card's buttons open it.
- Fill in the flow settings Teams team ID, Intake channel ID and Results review channel ID, and set Default provider ID to the Healthie provider a result is recorded under, and whose task it becomes, when the chart has no assigned provider.
- Pick your receiving fax number in New fax received if the account has more than one, and your lab results folder in Record the result on the chart if you file results in one.