hapi-fhir-jpaserver-starter
hapi-fhir-jpaserver-starter copied to clipboard
Unable to perform bulk import
I'm attempting to bulk import a bundle of resources to a local HAPI-FHIR instance that I have running via Docker Hub as described here but am repeatedly running into the not-supported error below:
{'resourceType': 'OperationOutcome', 'text': {'status': 'generated', 'div': '<div xmlns="http://www.w3.org/1999/xhtml"><h1>Operation Outcome</h1><table border="0"><tr><td style="font-weight: bold;">ERROR</td><td>[]</td><td><pre>Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[$import] with parameters [[]]</pre></td>\n\t\t\t</tr>\n\t\t</table>\n\t</div>'}, 'issue': [{'severity': 'error', 'code': 'not-supported', 'diagnostics': 'Invalid request: The FHIR endpoint on this server does not know how to handle POST operation[$import] with parameters [[]]'}]}
This is occurring when I try to make a POST request to my local HAPI-FHIR instance at http://localhost:8080/fhir/$import with the headers {'Accept-Charset': 'utf-8', 'Accept': 'application/fhir+json;q=1.0, application/json+fhir;q=0.9', 'User-Agent': 'HAPI-FHIR/6.0.0 (FHIR Client; FHIR 4.0.0/R4; apache)', 'Accept-Encoding': 'gzip', 'Content-Type': 'application/fhir+json; charset=UTF-8', 'prefer': 'respond-async'}
Despite trying different payloads (the bundle to be imported on its own, the bundle wrapped within a Parameters resource), I'm getting the same error.
Not quite sure where I'm going wrong, could someone please help resolve this? Thank you!
I see that the BulkDataExportProvider is being imported here, and then registered here. I wonder if something similar needs to be done with a BulkDataImportProvider?
However, looking in the hapi-fhir repo, I don't see a providers folder in Import where I would expect, while there is such a provider for Export. Not sure where that leaves this