Export Population-Level Data for a Client ID
After you get access to the FHIR Server and get your access token (Bearer token), you can use your access token to send a GET request or an EXPORT request to the 1up FHIR Server using the Bearer token method.
You can submit an EXPORT request for data for all FHIR resources or for a specific resource type. The base URL for all EXPORT requests at the population level is https://gateway.1up.health/v1/<customer-name>/.
You can use this base URL for the population-level endpoint with any of the other FHIR API requests.
Population-level export supports only GET and EXPORT requests to the 1up FHIR Server. PUT requests are supported only to retry a failed job. POST and DELETE requests are not supported.
If you try to submit a POST or DELETE request to the population-level endpoint, you'll receive a 403 error response.
Export All Resources
The following example request exports all FHIR resources for the specified 1upHealth customer using the base URL with bulk-export/bulk-data and $export included in the URL.
-
URL format
https://gateway.1up.health/v1/<customer-name>/bulk-export/bulk-data/r4/$export
-
URL example
https://gateway.1up.health/v1/ExampleCompany/bulk-export/bulk-data/r4/$export
curl --location 'https://gateway.1up.health/v1/<customer-name>/bulk-export/bulk-data/r4/$export' \
--header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJibGIwMjB3Y09zeWFza01rNnNJYmNPb3U1NnhYNTRvUFpEY0hVWG9XanZvIn0.eyJleHAiOjE3MTMzODk5NzksImlhdCI6MTcxMzM4NjM3OSwianRpIjoiZmFlZDJjMTYtMTc4ZS00ZWU5LTg0OGYtZTViMjljNmYwYzNhIiwiaXNzIjoiaHR0cHM6Ly9nYXRld2F5LjF1cGhlYWx0aGRldjIuY29tL2F1dGgvcmVhbG1zLzF1cGhlYWx0aGRldjIiLCJhdWQiOiJhY2NvdW50Iiwic3ViIjoiZWYyODBjN2UtMmJiZi00NWVjLThmZDEtMWY4NDcxMGEyMjZiIiwidHlwIjoiQmVhcmVyIiwiYXpwIjoiZ2Y2NC1vc2YzN3MtODIza2RhIiwiYWNyIjoiMSIsImFsbG93ZWQtb3JpZ2lucyI6WyJodHRwOi8vbG9jYWxob3N0OjgwMDAiXSwicmVhbG1fYWNjZXNzIjp7InJvbGVzIjpbIm9mZmxpbmVfYWNjZXNzIiwiZGVmYXVsdC1yb2xlcy0xdXBoZWFsdGhkZXYyIiwidW1hX2F1dGhvcml6YXRpb24iXX0sInJlc291cmNlX2FjY2VzcyI6eyJhY2NvdW50Ijp7InJvbGVzIjpbIm1hbmFnZS1hY2NvdW50IiwibWFuYWdlLWFjY291bnQtbGlua3MiLCJ2aWV3LXByb2ZpbGUiXX19LCJzY29wZSI6ImVtYWlsIHI0fHVzZXIvKi5ycyBwcm9maWxlIiwiZW1haWxfdmVyaWZpZWQiOmZhbHNlLCJjbGllbnRIb3N0IjoiNDQuMjM3LjI0OS4yMDQiLCJwcmVmZXJyZWRfdXNlcm5hbWUiOiJzZXJ2aWNlLWFjY291bnQtZ2Y2NC1vc2YzN3MtODIza2RhIiwiY2xpZW50QWRkcmVzcyI6IjQ0LjIzNy4yNDkuMjA0IiwiY2xpZW50X2lkIjoiZ2Y2NC1vc2YzN3MtODIza2RhIn0.FCWvw7SDNi9ZpEeP8pSADEj1_0F_DlS5uQ_IkI9ci1QvruSTD53e2V2J7jk39kxAX67e2JhDPzaa77Qxk3veOyf9T39yBp9EbRIUukwGUD7CatPqDswxkF6L_3peehnZj4De2KGRlK4a5wV5uZvnmAo_WMeZJlc2UheZqPqj0v3kfdhBeNCgjQGYeLNsQDSEh86QJv8lyU0EFwGlNr3aJNptuXq73LjqLgNhSUA30aT4me6YQj1iNStgzGZmMk9UPiHJo-GGK_SZmFibCJ5LYrwhyds511citfmBcNuITaVjrNxAbaIFw83D3ZLS9UJ1hPrJrs7Wp6knzTG9Uy8OmA'
Export a Specific Resource Type
If you only want to get data for a specific FHIR resource type, you can restrict your request to only that resource type. For this request type, you use the base URL and append the name of the resource type to the end of the URL.
-
URL format
https://gateway.1up.health/v1/<customer-name>/bulk-export/bulk-data/r4/<resource-type>
-
URL examples
https://gateway.1up.health/v1/ExampleCompany/bulk-export/bulk-data/r4/Patient
https://gateway.1up.health/v1/ExampleCompany/bulk-export/bulk-data/r4/ExplanationOfBenefit
curl --location 'https://gateway.1up.health/v1/<customer-name>/bulk-export/bulk-data/r4/Patient' \
--header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJibGIwMjB3Y09zeWFza01rNnNJYmNPb3U1NnhYNTRvUFpEY0hVWG9XanZvIn0.eyJleHAiOjE3MTMzODk5NzksImlhdCI6MTcxMzM4NjM3OSwianRpIjoiZmFlZDJjMTYtMTc4ZS00ZWU5LTg0OGYtZTViMjljNmYwYzNhIiwiaXNzIjoiaHR0cHM6Ly9nYXRld2F5LjF1cGhlYWx0aGRldjIuY29tL2F1dGgvcmVhbG1zLzF1cGhlYWx0aGRldjIiLCJhdWQiOiJhY2NvdW50Iiwic3ViIjoiZWYyODBjN2UtMmJiZi00NWVjLThmZDEtMWY4NDcxMGEyMjZiIiwidHlwIjoiQmVhcmVyIiwiYXpwIjoiZ2Y2NC1vc2YzN3MtODIza2RhIiwiYWNyIjoiMSIsImFsbG93ZWQtb3JpZ2lucyI6WyJodHRwOi8vbG9jYWxob3N0OjgwMDAiXSwicmVhbG1fYWNjZXNzIjp7InJvbGVzIjpbIm9mZmxpbmVfYWNjZXNzIiwiZGVmYXVsdC1yb2xlcy0xdXBoZWFsdGhkZXYyIiwidW1hX2F1dGhvcml6YXRpb24iXX0sInJlc291cmNlX2FjY2VzcyI6eyJhY2NvdW50Ijp7InJvbGVzIjpbIm1hbmFnZS1hY2NvdW50IiwibWFuYWdlLWFjY291bnQtbGlua3MiLCJ2aWV3LXByb2ZpbGUiXX19LCJzY29wZSI6ImVtYWlsIHI0fHVzZXIvKi5ycyBwcm9maWxlIiwiZW1haWxfdmVyaWZpZWQiOmZhbHNlLCJjbGllbnRIb3N0IjoiNDQuMjM3LjI0OS4yMDQiLCJwcmVmZXJyZWRfdXNlcm5hbWUiOiJzZXJ2aWNlLWFjY291bnQtZ2Y2NC1vc2YzN3MtODIza2RhIiwiY2xpZW50QWRkcmVzcyI6IjQ0LjIzNy4yNDkuMjA0IiwiY2xpZW50X2lkIjoiZ2Y2NC1vc2YzN3MtODIza2RhIn0.FCWvw7SDNi9ZpEeP8pSADEj1_0F_DlS5uQ_IkI9ci1QvruSTD53e2V2J7jk39kxAX67e2JhDPzaa77Qxk3veOyf9T39yBp9EbRIUukwGUD7CatPqDswxkF6L_3peehnZj4De2KGRlK4a5wV5uZvnmAo_WMeZJlc2UheZqPqj0v3kfdhBeNCgjQGYeLNsQDSEh86QJv8lyU0EFwGlNr3aJNptuXq73LjqLgNhSUA30aT4me6YQj1iNStgzGZmMk9UPiHJo-GGK_SZmFibCJ5LYrwhyds511citfmBcNuITaVjrNxAbaIFw83D3ZLS9UJ1hPrJrs7Wp6knzTG9Uy8OmA'
This example FHIR API request is for Patient resources.
Verify the Status of the Export Operation
You can send a request to the 1up FHIR Sever Status endpoint to get status updates on the export job.