PDex $davinci-data-export FHIR API Specification
Service Overview
InterSystems Payer Services Payer Data Exchange (PDex) APIs support the sharing of patient health data and are designed in compliance with the CMS-0057-F regulationsOpens in a new tab. The APIs allow providers to access clinical data for patients they have a relationship with, and payers to access health information held by a member's previous payer. These APIs use a REST-based FHIR endpoint.
The $davinci-data-export operation allows providers and payers to request a bulk data export for members in a specified Group.
Refer to the Getting Started section for information on connectivity, authentication and how to get help. To use the APIs, you will need to know the server URL of the FHIR server you will be connecting to.
Workflow
A provider or payer can use the $davinci-data-export operation to request the health data for a Group of members
A typical workflow for a payer involving this API might be:
-
The requesting payer uses the $bulk-member-match operation to generate a Group of matched members.
-
The requesting payer uses the returned Group ID to invoke the $davinci-data-export operation to retrieve the members' data from the previous payer.
-
The requesting payer uses the status method to poll for updates on the original data export request.
-
Once the data export request is complete, the requesting payer can download the NDJSON files containing the exported data.
Endpoint: $davinci-data-export
Base URL
The base URL of the $davinci-data-export operation is:
<server url>/csp/healthshare/<namespace>/app/api/responder/FHIRResponderService
where <server url> and <namespace> have been provided to you by the payer organization you are connecting with.
Optional Capabilities
None.
Endpoint Prerequisites
You have the FHIR Group ID for the set of patients or members whose data you want to retrieve.
Required Header Settings
-
Content-Type: application/fhir+json (if body content is included)
-
Accept: application/fhir+json
-
Prefer: respond-async (for the initial data export request)
Request Methods
where <groupId> is the FHIR identifier of the Group you are retrieving data for.
Initiates an asynchronous Da Vinci PDex bulk data export for the members of a group.
where <sessionId > is the session identifier for the data export you initiated.
You can use this to poll for the status of a data export request.
where <sessionId > is the session identifier for the data export you initiated and <fileName> identifies the NDJSON file you want to download.
You can use this to download the NDJSON files created for the data export request.
where <sessionId > is the session identifier for the data export you initiated.
You can use this to cancel an export operation that is currently in progress, or to delete the NDJSON files for an export session that has completed.
Query Parameters
For information about the parameters supported for provider-initiated data export requests, see Data Export Parameter HandlingOpens in a new tab in the Provider Access API section of the PDex Implementation Guide (IG).
For information about the parameters supported for payer-initiated data export requests, see ExportType and the sections that followOpens in a new tab in the Payer-to-Payer Exchange (bulk) section of the PDex IG.
Request Body
Initial Data Export Request Body
If included, exportType must be appropriate for the requester type (provider or payer). Here is a sample payer request for one patient:
{
"resourceType": "Parameters",
"parameter": [
{
"name": "exportType",
"valueCanonical": "hl7.fhir.us.davinci-pdex#payertopayer"
},
{
"name": "patient",
"valueReference": {
"reference": "Patient/100000001"
}
},
{
"name": "_since",
"valueInstant": "2021-07-20T00:00:00Z"
},
{
"name": "_until",
"valueInstant": "2025-07-20T00:00:00Z"
},
{
"name": "_type",
"valueString": "Patient,Coverage,Observation,Condition,Encounter,ExplanationOfBenefit"
}
]
}
Status Request Body
None. Use the sessionId from the response to your initial data export request as a path parameter to get the export request status.
Data Export Files Request Body
None. Use the sessionId and the fileName that was returned by the status response as path parameters to download the data export resource files.
Success Responses
Initial Data Export Response
The request was accepted.
The response header includes a ContentLocation entry that gives the endpoint that can be used for subsequent status requests. The sessionId is given in the last part of the URL path.
Status of Data Export Response
The request was successful.
The response body includes an output property with entries for each type of resource that is included in the export. Each resource has an associated url entry that includes the name of the NDJSON file containing the exported data for that resource type. A response might look something like this:
{
"transactionTime": "2026-08-13T13:28:11Z",
"request": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/Group/159/$davinci-data-export",
"output": [
{
"type": "Encounter",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Encounter_Encounter-0001.ndjson"
},
{
"type": "Location",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Location_Location-0001.ndjson"
},
{
"type": "Observation",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Observation_Observation-0001.ndjson"
},
{
"type": "Organization",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Organization_Organization-0001.ndjson"
},
{
"type": "Patient",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Patient_Patient-0001.ndjson"
},
{
"type": "Practitioner",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Practitioner_Practitioner-0001.ndjson"
},
{
"type": "Provenance",
"url": "<server url>/csp/healthshare/hp-pdex/app/api/responder/FHIRResponderService/davinci-data-export/file/106/Provenance_Provenance-0001.ndjson"
}
],
"error": [],
"requiresAccessToken": "true"
}
The request was accepted.
This code indicates the data export session is still in progress. The response contains a RETRY-AFTER header with an integer in seconds. This indicates how long a requester must wait before making another status polling request
Data Export File Response
The request was successful.
The NDJSON file content is included in the response body.
Error Responses
The following response error codes may be returned, depending on the method invoked:
Possible causes include:
-
Missing required fields
-
Unsupported parameter
-
Invalid export type for the requester type
Possible causes include:
-
No valid token found
-
No requester ID present in the JWT
Possible causes include:
-
Token does not include required OAuth scopes
Possible causes include:
-
Accept header does not include application/fhir+json
Possible causes include:
-
Content-Type header is not application/fhir+json
Possible causes include:
-
The requester has polled the status endpoint too frequently
Possible causes include:
-
The requested patient was not found
-
Your system has missing configuration
Possible causes include:
-
An error in a downstream system
Possible causes include:
-
An internal request in the process timed out