Open jmorg85-isc opened 3 years ago
If you want to turn off query-style references, the easiest way to do that is to set exporter.fhir.transaction_bundle = false
.
That will make all Bundles have type collection, rather than type transaction, and it will create "normal" style references.
This will also duplicate all the Practitioner, Location, and Organization across all the Bundles -- so you will have duplicate data.
@jawalonoski the reported issue is that the syntax
"serviceProvider": {
"reference": "Organization?identifier=ABC"
}
is not valid per the spec. The "reference" element must contain a literal reference (doc), something like "Organization/42" or "https://github.com/synthetichealth/Organization/42".
It looks like Synthea wants to use logical references (doc) which allow you to use a query-style identifier (not id) to identify a resource. Those need to go in the Reference.identifier element. That'd result in reference objects like the following:
"serviceProvider": {
"identifier": {
"system": "https://github.com/synthetichealth/synthea",
"value": "91ea4431-fdfe-35a2-a773-71658028e5f5"
}
}
Actually, it is valid per the spec.
Please see https://www.hl7.org/fhir/http.html#trules under the heading "Conditional References" (which I cannot link to directly [no anchor]).
Well, you learn something new every day! Thanks for the pointer.
I was just reading the issue where logical references were added and saw your name pop up there too. Seems like even adding them was a bit contentious: https://jira.hl7.org/browse/FHIR-10659
I'll go back to my cave now :)
Downloading sample R4 bundles from https://synthetichealth.github.io/synthea/ is fantastic, and the generated samples pass FHIR validation without any issues.
Downloading this JAVA tool and generating R4 bundles produces resources that do not pass FHIR validation. My JAVA version is:
Example scenario and errors below:
A JSON bundle generated with command... java -jar synthea-with-dependencies.jar Minnesota -p 1000
Abdul218_Hayes766_ec62e6ac-6dba-16a9-e5b3-e81f9c3ae447.txt
...produces validation errors...
These are just a few of the errors I am getting from the data out of the generator. I have tried multiple different combinations of settings using a config file. The bundles are all generated with these malformed data values.
Any guidance would be greatly appreciated.