Integrating a FHIR resource

I am in the process of integrating a DeviceRequest resource for FHIR.

Using the custom skeleton module created by @adunsulag, I have set up the database and the functionality to access a GET request endpoint to pull all the DeviceRequest resources.

This is a sample bundle request.

I am having difficulty on how exactly to create the DeviceRequest data to associate with a patient, or a group or location. My higher level view is to integrate OpenEMR with a SMART app that is already created but I need to add the DeviceRequest data in OpenEMR first.

The way I’m seeing it right now is to possibly create some sort of UI in the Patient dashboard or elsewhere so that the practitioner or whoever is making the request can add the DeviceRequest data and store it. I’m having an issue as to where to look to create that UI for reference.

Any push in the right direction is appreciated.

from the Pt Dashboard go to Issues
image
then add the device
Screenshot from 2023-11-03 09-28-41
swagger FHIR device

Hmm, that is interesting. Are you suggesting that I add the medical devices there and pull them to the DeviceRequest resource? That would mean referencing the lists table, correct?

Another thing is, I am using HCPCS codes and I have imported them through the Codes option in the Admin menu.

These are the codes that I have imported. Now while adding a DeviceRequest to a patient, I add a medical device to the patient. Through your suggestion, I went to the Add/Edit issue under Medical devices and via “Show more fields”, there was an option to add the coding of the device. The options showed:

Now, this is what I’ve figured out. There must be a way to reference the HCPCS codes here, no?
So that the device can be referenced and automatically added.

Plus, I took a look at the code_types.inc.php, and in the collect_codetypes() function, I did not find the category referencing to “medical_device”. Could that be a reason?

I think I’m missing something here. Please point me in the right direction.

You can add or hide some codes, from Admin/Form/Lists-> Code Types

I tried using the list editor, but in order to get the HCPCS codes(which are the codes that I’m using for the devices), I’d have to classify them as a Diagnosis type, which they’re not. If I classify them as a diagnosis type, only then can I reference them while adding the Device.

Is there a workaround through that? The HCPCS codes are neither a Medical Problem nor a Drug.

Plus, I’m not sure if I can parse information for a FHIR DeviceRequest resource simply by referencing a medical device from the lists table.