Fast Healthcare Interoperability Resources (FHIR) Integration

Yes, this update is huge news!
:fireworks::fireworks::fireworks:

After I get medex integration work completed, plan to dive in and help @sjpadgett on this. And would be great to get other folks to help on this.

I added a up for grabs demo to @sjpadgettā€™s PR (you can see the link to it on the PR).

2 Likes

I am wondering if maybe this should be integrated with the Care Coordination Module instead of having a new/separate manager for publishing and importing FHIR resources. Do we have any idea how much the CCM is used in our install base?

1 Like

@sjpadgett , I think the use is pretty minimal and only in cases of MU certification. Would avoid the CCM if possible. If needed, could always build in a hook to it after things are more worked out.

1 Like

Question: Should we auto update FHIR server from chart updates say new/edit encounter, medication, procedures save also sends to server if FHIR is turned on and patient has given permissions?

2 Likes

I think this would be a neat feature to support and would make it a global option (in case, for example, the instance does not always have access to internet).
For this and other FHIR pushes (and pulls in future), would also work into openemr log via the newEvent() function (and in that can enter whether is was a success or failure; for example, if the auto push above did not work)

2 Likes

@sjpadgett just brought in some more nice code on this here (nice examples of adding resources):

@sjpadgett, is there a list of required resources that we need to shoot for? If so, would be good to get a list going here, so others can chip in and join in on the FHIR bonanza :smile:

edit: per a prior message from Jerry, looks like a listing of resources are here: http://hl7.org/fhir/resourcelist.html

-brady

2 Likes

Thanks @brady.miller, Here are some thoughts.

I suppose the easiest is to take a look at a public test server to see what others are testing. You can go here: https://fhirtest.uhn.ca/

My goal is to get most of the informative resources that would cover our basic chart that is of use to patient or other providers. Medication Statement, Observation and Condition comes to mind(Patient, Encounters and Practitioner are mostly done). Remember when working a resource, end points to other resource may be required with that resource required to be already on the server, otherwise server will reject.

Iā€™m thinking that support resources such as Organization, Practitioner and Location be auto created/updated from the dashboard to support other Profiles.(Iā€™ve got this)

Another concern is coding systems( coding systems are closely tied to FHIR). We generally donā€™t record snomed that I can tell(I think even loading codes is optional) along with our encounter form is in need of updating to better support FHIR and Institutional with making it not so closely tied to billing for encounter status and disposition.

Once we have a working set of profiles and resources, we know how to set the conformance and capability statements for our implemented server.(I think we can also do that with the Dashboard provider client.).

I think we have a good start with a REST and HTTP class for clients, resource class and client endpoint class and iā€™m working on a library for auto sending resources from OpenEMR scripts such as appointments, encounters e.t.c, yet much too do.

2 Likes

My main initial goal for a provider client is to populate server with a close eye towards a capability for a provider report on a patient compiled from searches of other FHIR servers. Besides patient access, I believe this is a major goal of FHIR.

Question: Has anyone researched this capability who could enlighten us? If not, maybe somebody could take it on. I can do the search part but I have not had time to research the infrastructure of how this type of action takes place i.e how to get the registered server to search and more important, how is authorization for access handled. Does patient have to provide their access or is there some sort of provider access scheme? Unknowing minds want to know!

1 Like

Hi,

Not sure how helpful this will be to us, but been learning about HAPI FHIR and how to set up server etc. Nicely, there is a HAPI FHIR docker. Hereā€™s a docker-compose.yml script that I used to bring in HAPI FHIR, openemr(5.0.1), mysql, and phpmyadmin on a cloud instance (trying out google cloud so did this on a ubuntu instance there with just docker installed):

# admin/pass are default user/password credentials for openemr
# openemr is default mysql database
# openemr/openemr are default user/password credentials for mysql openemr database
version: '2.0'
services:
  mysql:
    restart: always
    image: mysql
    command: ['mysqld','--character-set-server=utf8']
    environment:
      MYSQL_ROOT_PASSWORD: root
  hapi-fhir:
    restart: always
    image: bradymiller/hapi-fhir-jpaserver-example
    ports:
    - 8080:8080
  openemr:
    restart: always
    image: openemr/openemr
    ports:
    - 80:80
    - 443:443
    environment:
      MYSQL_HOST: mysql
      MYSQL_ROOT_PASS: root
      MYSQL_USER: openemr
      MYSQL_PASS: openemr
      OE_USER: admin
      OE_PASS: pass
    links:
    - mysql
    - hapi-fhir
  phpmyadmin:
    restart: always
    image: phpmyadmin/phpmyadmin
    ports:
    - 81:80
    environment:
      PMA_HOST: mysql
    links:
    - mysql

Just to demonstrate that it works(already ā€˜publishedā€™ one patient from OpenEMR to HAPI FHIR), Iā€™ll leave it up on the google cloud instance for awhile:
OpenEMR is at http://35.229.69.20 (admin/pass credentials)
HAPI FHIR is at http://35.229.69.20:8080

And if just need a HAPI docker going locally without openemr and other stuff, then following docker-compose.yml script would suffice:

version: '2.0'
services:
  hapi-fhir:
    restart: always
    image: bradymiller/hapi-fhir-jpaserver-example
    ports:
    - 8080:8080

Note the hapi-fhir-jpaserver-example image is from my dockerhub (there appears to be no already built docker, so I built it and posted it to make it easier to use (and will plan to update it to most recent version every once in awhile)).

-brady

1 Like

Tho docker has an environment setup for mysql but I believe you also need to config the jpa app config for mysql because default is derby. Check your mysql for the tables(about 20).

1 Like

Been working on getting a HSPC FHIR server going. So far have the following docker-compose.yml going that includes a HSPC FHIR server:

# admin/pass are default user/password credentials for openemr
# openemr is default mysql database
# openemr/openemr are default user/password credentials for mysql openemr database
version: '2.0'
services:
  mysql:
    restart: always
    image: mysql
    command: ['mysqld','--character-set-server=utf8']
    environment:
      MYSQL_ROOT_PASSWORD: root
  hapi-fhir:
    restart: always
    image: bradymiller/hapi-fhir-jpaserver-example
    ports:
    - 8080:8080
  openemr:
    restart: always
    image: openemr/openemr:5.0.1
    ports:
    - 80:80
    - 443:443
    environment:
      MYSQL_HOST: mysql
      MYSQL_ROOT_PASS: root
      MYSQL_USER: openemr
      MYSQL_PASS: openemr
      OE_USER: admin
      OE_PASS: pass
    links:
    - mysql
  phpmyadmin:
    restart: always
    image: phpmyadmin/phpmyadmin
    ports:
    - 81:80
    environment:
      PMA_HOST: mysql
    links:
    - mysql
  hspc-fhir:
    restart: always
    image: bradymiller/hspc-reference-api-webapp-multitenant
    ports:
    - 8075:8075
    - 8076:8076
    - 8077:8077
    links:
    - mysql

Have these going on a google cloud instance here:
OpenEMR is at http://35.229.69.20 (admin/pass credentials)
HAPI FHIR is at http://35.229.69.20:8080
HSPC FHIR is at http://35.229.69.20:8075

I am still struggling with the HSPC FHIR, though. Even though I set hspc.platform.api.security.mode=open in the reference-api-webapp-multitenant/src/main/resources/application.yml script (I do this before the maven build, which I then used to build the docker), the open stuff does not work (just says itā€™s not authorized no matter what I try). It appears I am going to need to learn more about java and javaā€™s build/deployment tools, and I will keep plugging along on that.

-brady

1 Like

The HAPI docker seems to manage all this without any configuration(I havenā€™t looked into the docker in detail, but they must have the database integrated within it since it works out of the box with OpenEMR).

1 Like

It may be config is being missed by docker or using wrong port to access the tenant. Endpoint for stu3 open connect should be :8076/dstu3/open/ and port 8075 is for dstu2. Not sure if docker is configuring the oauth2 security: switch which is mode: secured by default where we want mode: open. Check out reference-api-webapp-multitenant\src\main\resources\application.yml. Also if running multi-tenant then depending on if running a dstu2, stu3 or R2 configā€™ed server determines the port it will run on. The application.yml is somewhat self explanatory.

1 Like

I see that now thanks, much easier with docker but poses problems for windows sometimes.

1 Like

yep,

Regarding hspc stuff, pretty much used the shotgun approach as I try to get it to work. See here for changes I made in config stuff before I ran the maven:

I know that something is working since the mysql stuff is working (if I donā€™t do this, then the server errors out because it canā€™t connect to mysql) and is connecting to the mysql docker to do its thing. Gonna keep at it though since I have lots to learn as I sort out how java/maven stuff works.

-brady

1 Like

Getting warmer (looks like need to use hspc5 in path or it looks for a nonexistant database):
http://35.229.69.20:8075/hspc5/data/metadata

1 Like

I configā€™ed my local HSPC for the dstu2 tenant on port 8075 and open security using spring boot and am able to get to work with :8075/dstu2/open/ endpoint. Of course iā€™m running localhost so, not really the same. One issue could be you may have to have created an empty database first. However, we want to run stu3 tenant so thatā€™s where I would focus. Also you may be aware that the default will try to populate with test resources(around 16.5k).

2 Likes

SMART on FHIR is a set of open specifications to integrate apps with Electronic Health Records:

Clean, structured data: FHIR
Easy-to-use, resource-oriented REST API for structured clinical data.
Scopes and permissions: OAuth2
Simple sign-in: OpenID Connect
Lightweight UI integration: HTML5

A significant ecosystem of Smart on FHIR tools and apps will be avalable on OpenEMR as soon as it supports SMART on FHIR standards.

What would be the resources & timeline required for OpenEMR development?

Sorry I missed this but for Smart on Fhir a server to support (HSPC) is being tested and can be implemented fairly soon but still need to profile to specific value set and terminologies to support OpenEMR. Regardless if we provide a server setup and install for OpenEMR or user wants to interface with a public/private server of their choosing, too me, the most critical part of implementing FHIR is integrating our patient data to the server. The current plan is to create libraries and classes that allow core chart resource data to automatically update the server as chart data is created/updated making the interface and translation of resources key. I think once this is finished the imaginations can run wild for the client goodies.
I further plan that as I create resource methods to populate the server, a companion method is created to import resource to OpenEMR thus edging closer to a HIE of sorts.(Also working a HL7 MLLP sender)
This is my take and hopefully not a naive one.
Regarding timeline: for the core resources, possibly two weeks when I hope to have at least demographic, encounters, procedures(observations), conditions(problems) and medication statement.

Good Brady,
What kind of support I you talking about? Is financial support or technical support? If it is financial support then currently I have no pemenent idea? But temporary a facility needs the FHIR platform.

And if it is ready for use, then I can find out from them how much one off financial support they contribute. Let hear from you.
Thanks