Aidbox
Search…
$import & /fhir/$import
$import is an implementation of the upcoming FHIR Bulk Import API. This is an asynchronous Operation, which returns url to monitor progress.
Keep in mind that $import does not validate inserted resources for the sake of performance. Pay attention to the structure of data you insert and use the correct URL for your data format, i.e.: use /fhir prefix for FHIR data.
Please consider using Asynchronous validation API to validate data after $import

Request
Response
POST /fhir/$import
Accept: text/yaml
Content-Type: text/yaml
id: synthea
contentEncoding: gzip
inputs:
- resourceType: Encounter
url: https://storage.googleapis.com/aidbox-public/synthea/100/Encounter.ndjson.gz
- resourceType: Organization
url: https://storage.googleapis.com/aidbox-public/synthea/100/Organization.ndjson.gz
- resourceType: Patient
url: https://storage.googleapis.com/aidbox-public/synthea/100/Patient.ndjson.gz
200
You can monitor progress by using id you provided in request body.
GET /BulkImportStatus/synthea
If you didn't provide id in request body, you can use content-location in response header.

Parameter
Description
id
Identifier of the import
contentEncoding
Supports gzip or plain (non-gzipped .ndjson files)
inputs
Resources to import
update
Update history for updated resources (false by default)

For performance reasons $import does raw upsert into resource table without history update. If you want to store the previous version of resources in history, please set update = true
With this flag Aidbox will update history for updated resources.

Copy link
Edit on GitHub
On this page
Example
Parameters
Note