Read Data

How to GET or read data from 1up FHIR Server

Get All Resources for Specific Resource Type

The most basic form of a search is a search with no parameters, which matches all resources of a given type. For example, the following search returns all R4 Patient Resources in the system:
curl --location --request GET 'https://{baseUrl}/r4/Patient' \
--header 'Authorization: Bearer {accessToken}'

Get Single Resource by FHIR ID

curl --location --request GET 'https://{baseUrl}/r4/Patient/{fhirId}' \
--header 'Authorization: Bearer {accessToken}'

Get Particular Version of Resource

curl --location --request GET 'https://{baseUrl}/r4/Patient/{fhirId}/_history/{versionId}' \
--header 'Authorization: Bearer {accessToken}'

Get All Versions of Particular Resource

If you make a request to Patient/{{fhirId}}/_history without specifying the specific version, the response will be a bundle array of all available versions of that particular FHIR resource. For example this would return all historical versions of a particular Patient Resource:
curl --location --request GET 'https://{baseUrl}/r4/Patient/{fhirId}/_history' \
--header 'Authorization: Bearer {accessToken}'

Public Data

Some data in our FHIR server can be made public such that no authorization is required to access it. This data can be accessed with /public in the path. For example this request will return all public Practitioner resources:
curl --location --request GET 'https://{baseUrl}/r4/public/Practitioner'

Searching Data

For information on searching for FHIR resources matching particular search parameters see here.