$dump-csv
Dump resource in CSV format
$dump-csv operation dumps resource data in Aidbox format as CSV (RFC4180). In this format, columns are paths to JSON values and Rows are values. It includes the header.
Neither the specific order of columns nor the order of rows is guaranteed.
Request format
1
GET [base]/<resourceType>/$dump-csv
Copied!
URL Parameter
Description
resourceType
Type of the resource to dump

Examples

Dump patients in CSV
Request
Response

Rest Console

1
GET /Patient/$dump-csv
Copied!

Curl

1
$ curl "$AIDBOX_BASE/\$dump-csv" \
2
-H 'authorization: Basic YnVsay1jbGllbnQ6c2VjcmV0'
Copied!

Status

200 OK

Headers

Header
Value
Content-Type
text/csv
Transfer-Encoding
chunked

Body

1
citizenship.0.code.text,id,name.0.given.0,resourceType
2
,pt-1,Alice,Patient
3
,pt-2,Bob,Patient
4
ru,pt-3,Charles,Patient
Copied!

Body as table

citizenship.0.code.text
id
name.0.given.0
resourceType
pt-1
Alice
Patient
pt-2
Bob
Patient
ru
pt-3
Charles
Patient
Dump Appointments in CSV
Request
Response

REST Console

1
GET /Appointment/$dump-csv
Copied!

Curl

1
curl -u bulk-client:secret $AIDBOX_BASE_URL/Patient/\$dump-csv
Copied!

Status

200 OK

Headers

Header
Value
Content-Type
text/csv
Transfer-Encoding
chunked

Body

1
id,participant.0.actor.id,participant.0.actor.resourceType,participant.0.status,resourceType,status
2
ap-1,pt-1,Patient,accepted,Appointment,fulfilled
3
ap-2,pt-1,Patient,accepted,Appointment,booked
4
ap-3,pt-2,Patient,accepted,Appointment,fulfilled
Copied!

Body as table

id
participant.0.actor.id
participant.0.actor.resourceType
participant.0.status
resourceType
status
ap-1
pt-1
Patient
accepted
Appointment
fulfilled
ap-2
pt-1
Patient
accepted
Appointment
booked
ap-3
pt-2
Patient
accepted
Appointment
fulfilled
Copy link
Contents
Examples