简体   繁体   中英

Creating multiple bundles in Azure API for FHIR

Using Synthea i have generated 10 patient information. I have an azure account where i have setup "Azure API for FHIR" service. i did all the setup and tried pushing a sample patient (as mentioned in the official docs). i am able to retrieve the patient information by patient id as well.

However, the generated resource from Synthea are not just one resource type.. It has many entries like Patient, Organization, Claim etc.. everything bundled under one resource - bundle

Something like this.. but having more than 100 resource types for a patient. Its good that, it covers entire journey of the patient.

{
  "resourceType": "Bundle",
  "type": "transaction",
  "entry": [
   .....
   {
    ....
   "resourceType": "patient"
    ....
    },
   {
    ....
   "resourceType": "organization"
    ....
    },
]
}

Using post man i tried to insert this bundle with api below

https://XXXXXX.azurehealthcareapis.com/Bundle/

i was able to insert multiple bundles.. However, when i query the patients using the following api

https://XXXXXX.azurehealthcareapis.com/Patient/

All the patient information are not getting retrieved.

Here are my questions.

  1. Inserting bundle by bundle - Is that the right approach.. or
  2. Insert resource by resource.. Patient, Organization, Patient, Organization... But this looks meaningless. Because, if i need to find entire journey of a patient how would i be mapping it
  3. Is There any way i can convert this each bundle as CSV files.. i would like to extract information and run a machine learning model on it.

When you need to process bundles at the FHIR endpoint, you need to POST it to the root / of the FHIR server. This is all described in https://www.hl7.org/fhir/http.html#transaction .

That said, the managed Azure API for FHIR only supports "batch" bundles at the moment. Bundle type transaction is not currently supported on Azure API for FHIR.

Both batch and transaction are supported on the OSS FHIR Server for Azure ( https://github.com/Microsoft/fhir-server ) when deployed with the SQL server persistence provider.

If you want to convert the transaction bundle that Synthea produces to a batch bundle, then you could take a look at something like this: https://github.com/hansenms/FhirTransactionToBatch

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM