Everything held about one user, as one zip file
The answer to a data portability request: one zip file streamed in a single response
(Content-Disposition: attachment) holding manifest.json (user, generation time,
instance version, record count of each file, a description of each folder),
user.json (the user and its provider connections, never a token),
canonical/<list>.ndjson (every record of samples, category-samples, sleep,
sleep-phases, workouts, workout-routes, nutrition and daily, the same JSON as the list
items, one per line), fhir/bundle.json (a FHIR R4 collection Bundle of every
Observation), omh/data-points.ndjson (the Open mHealth data points) and raw/...
(every raw payload of the user, byte for byte, under its path below the user). A
tenant key reads any user of the tenant; a user token with scope read reads only its
own user, and another user is a 404. A failure once the file has started cuts the
connection, so a truncated archive never looks complete. See docs/exports.md.
AuthorizationBearer <token>Tenant API key, ohs_sk_ + 43 base62 characters.
id*stringuuidThe archive.
response?fileapplication/zipbinarycurl -X GET 'http://localhost:8080/v1/users/497f6eca-6276-4993-bfeb-53cbbbba6f08/archive' \ -H 'Authorization: Bearer ohs_sk_...'"string"