Replies: 3 comments 3 replies
-
There's no built-in support for any profiles other than US Core, and no ability for Synthea to load arbitrary IGs and create relevant data for them. What we do have though which hopefully addresses your needs is the "Flexporter". The basic idea is that you can define a mapping file that transforms the output from Synthea in common ways, such as creating new resource types or adding new fields to existing resources. See more about the flexporter here: https://github.com/synthetichealth/synthea/wiki/Flexporter and feel free to ask if you have further questions on how to use it. It's still experimental so certain things you want to do may be tricky, but when people actually use it then we do what we can to improve it. If that doesn't cover your needs, modifying the existing exporter can theoretically be done if you're willing to make changes to the java code, but I would save that for a last resort. |
Beta Was this translation helpful? Give feedback.
-
Thank you! Very interesting... I was already working to understand how to adapt the Java class :). |
Beta Was this translation helpful? Give feedback.
-
It's not only for extensions, but what you probably want is either the Here's an example mapping file with two actions to add extensions to existing resources: ---
name: Extensions
applicability: true
actions:
- name: Set QI Core Procedure Recorded
set_values:
- applicability: Procedure.performed.ofType(Period)
fields:
- location: Procedure.extension.where(url='http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-recorded').valueDateTime
value: $getField([Procedure.performed.start])
- applicability: Procedure.performed.ofType(dateTime)
fields:
- location: Procedure.extension.where(url='http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-recorded').valueDateTime
value: $getField([Procedure.performed])
- name: Set Patient birthdate.extension
set_values:
- applicability: Patient
fields:
- location: Patient.birthDate.extension.where(url='http://hl7.org/fhir/StructureDefinition/patient-birthTime').valueDateTime
value: $getField([Patient.birthDate])
transform: toDateTime The syntax is admittedly a little awkward for the extensions in these examples but hopefully it's clear enough what's happening. Please let us know if you run into any issues. |
Beta Was this translation helpful? Give feedback.
-
Hello All,
I'm trying to understand if it's possible to use FHIR profiles other than US Core to export resources that have, in example, specific extensions.
If it's not supported, how can the existing export be modified?
Thanks in advance for your support!
Beta Was this translation helpful? Give feedback.
All reactions