Understanding how FHIR works and how to implement it in a healthcare app

663 views Asked by At

I have a project for University where we are developing a toy healthcare app and I am the backend developer. This app interacts with users, collecting their data. This data is used to make predictions for the user (data science) and can also be sent to doctors. Doctors can also update the data and send it back to the app.

What I do know:

  • The backend will be in Python, since that's the language of Data Science.
  • Probably will use Flask for ease of use
  • needs a database to store the data - probably start with SQLite also for quick ease of use

What I don't know:

  • since we are dealing with health data, I know that there are standards when it comes to transferring such data, such as using FHIR. But I have no idea where FHIR fits in in the app. I saw that Smart-on-FHIR has a fhirclient library with an example in Flask - is that the way to go?
  • I assume I need a FHIR server but how do I use one? I saw many available for testing, but how can I use those if the data needs to be private?

Basically, although I know which technologies to use, I don't know how to actually fit the pieces together. This question is asking for ideas on how to piece this project together. I need some clarity to get started and get things off the ground. I have a Flask server - how do I implement this FHIR in it so that I store the data properly, get the data for predictions and also send the data back and forth between the app and the doctor?

I appreciate any help!

1

There are 1 answers

2
Lloyd McKenzie On

FHIR is principally standard for sharing information between software systems - be that applications within a hospital, between EMRs and community pharmacies, clinical systems and research systems, etc. If your system isn't actually sharing data with other applications, there's no real need to use FHIR at all.

You could choose to use FHIR anyhow - you could download one of the FHIR open source servers and use that as your persistence layer. (You'd have your own instance running on your own hardware/cloud server, so your data would be your own.) The rationale for doing that is that it'll be good at storing healthcare data and will have most of the features you need (though it'll likely have a whole lot of features you don't). Also, if one of the objectives of your project is learning, then understanding how FHIR represents data will be useful as you move beyond a 'toy' application and start working with real systems that invariably need to share data.

SMART on FHIR is a mechanism to let you embed applications inside of electronic health record systems that have access to the EHR's data. It can also be used to create web applications that have access to EHR data. The key thing that SMART provides is an ability for a user to control what data the app has access to. (Just like you can control whether an app on your phone can access your address book or microphone, SMART lets you control whether a healthcare app can access your allergies or medications.) It's not obvious from your project description that there'd necessarily be a need for that functionality.

In short, you probably don't need FHIR, but you may find some of the open source tools developed by the FHIR community useful. Good luck with your project.