Da Vinci Clinical Data Exchange (CDex)
1.1.0 - STU1.1 US

This page is part of the Da Vinci Clinical Documentation Exchange (v1.1.0: STU1.1) based on FHIR R4. This is the current published version in its permanent home (it will always be available at this URL). For a full list of available versions, see the Directory of published versions

Direct Query

For Direct Query, the Data Consumer directly queries the Data Source for specific data using the standard FHIR RESTful search. Guidance for exchanging data with FHIR search is fully described in the base FHIR specification and the Da Vinci HRex Implementation Guide. Refer to the US Core Implementation guide for accessing the set of health data classes and data elements defined by the ONC United States Core Data for Interoperability (USCDI).

Benefits

  • “Out of the Box” FHIR transaction
  • Widely implemented
  • Simplest workflow
  • Authorization/Authentication protocols established
  • No human intervention is needed

Sequence Diagram

The sequence diagram in Figure 5 below outlines a successful interaction between the Data Consumer and Data Source to query and retrieve the requested data using a direct query:

Figure 5
search-sequencediagram.svg

Discovery of Patient FHIR IDs

The patient’s FHIR id is often a prerequisite to performing FHIR RESTful Direct Queries. Note that using a patient business identifier such as an MRN or Member ID is not widely supported as FHIR references in HIT systems today. Therefore, a patient lookup to determine the patient’s FHIR id on the server is typically required. One option is to use the Patient Match operation where it has been implemented. Another option is to find the FHIR id using the FHIR RESTful API. These are the most direct approaches to obtaining the FHIR id:

  1. FHIR RESTful search on the Patient resource using a combination of an identifier known by a Data Consumer. For example, a Payer may use a member_id and patient demographics.

    Get /Patient?identifier=[member_id]&birthdate=[date]&name=[name]&gender=[gender]

  2. FHIR RESTful search on Coverage resource using a combination of the payor’s FHIR id and identifier known by the Data Consumer. For example, a Payer may use a member id or subscriber id. The patient’s FHIR id is found in the beneficiary element (which references the patient).

    GET /Coverage?payor=[FHIR id]&identifier=[member_id] or GET /Coverage?payor=[FHIR id]&subscriber-id=[subscriber_id]

However, servers may or may not support identifier-based searches or searches based on member_id identifiers by HIT systems. In addition, the search semantics become more complex if effective dates of coverage are included in the search.

Direct Query Transaction Scenarios

The following example transactions show scenarios of using direct query to get clinical data from a Data Source(HIT).

Scenario 1

Payer A Seeks Insured Person/Patient B’s Active Conditions from Provider C to support a claims audit.

Preconditions and Assumptions:

  • Payer A is authorized and has the appropriate scopes to access the health records of Patient B from Provider C using FHIR RESTful queries
  • Payer A knows the FHIR id of the Patient resource for Patient B
  • Payer A knows the appropriate codes for searching for active conditions

Following the guidance in US Core, a search for all active conditions uses the combination of the patient and clinical-status search parameters:

GET [base]/Condition?patient=[FHIR id]&clinical-status=active,recurrance,remission

Request

GET [base]/Condition?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&clinical-status=active,recurrance,remission

Request Headers

Accept: application/fhir+json
Content-Type: application/fhir+json
...(other headers)

Response Headers

HTTP/1.1 200 OK
Server: nginx/1.14.0 (Ubuntu)
Date: Fri, 23 Oct 2020 04:54:56 GMT
Content-Type: application/fhir+json;charset=utf-8
...(other headers)

Response Body

{
  "resourceType": "Bundle",
  "id": "d88e2910-3c95-469d-b1f4-ab5553b471fb",
  "meta": {
    "lastUpdated": "2020-10-23T04:54:56.048+00:00"
  },
  "type": "searchset",
  "total": 1,
  "link": [ {
    "relation": "self",
    "url": "http://hapi.fhir.org/baseR4/Condition?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&clinical-status=active,recurrance,remission"
  } ],
  "entry": [ {
    "fullUrl": "http://hapi.fhir.org/baseR4/Condition/4ac41715-fcbd-421c-8796-9b2c9706dd3f",
    "resource": {
      "resourceType": "Condition",
      "id": "4ac41715-fcbd-421c-8796-9b2c9706dd3f",
      "meta": {
        "versionId": "10",
        "lastUpdated": "2020-04-28T20:28:00.008+00:00",
        "source": "#cabiJIK51sD2iz4N",
        "profile": [ "http://hl7.org/fhir/us/core/StructureDefinition/us-core-condition" ]
      },
      "clinicalStatus": {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/condition-clinical",
          "code": "active"
        } ]
      },
      "verificationStatus": {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/condition-ver-status",
          "code": "confirmed"
        } ]
      },
      "category": [ {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/condition-category",
          "code": "encounter-diagnosis",
          "display": "Encounter Diagnosis"
        } ]
      } ],
      "code": {
        "coding": [ {
          "system": "http://snomed.info/sct",
          "code": "1234",
          "display": "Examplitis"
        } ],
        "text": "Examplitis"
      },
      "subject": {
        "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b"
      },
      "encounter": {
        "reference": "Encounter/5fe62cd5-bfcf-4d3b-a1e9-80d6f75d6f82"
      },
      "onsetDateTime": "2018-10-21T21:22:15-07:00",
      "recordedDate": "2018-10-21T21:22:15-07:00"
    },
    "search": {
      "mode": "match"
    }
  } ]
}



Scenario 2

Payer A Seeks Insured Person/Patient B’s glycated hemoglobin (HbA1c) test results after 2020-01-01 from Provider C for Quality reporting requirements and quality care scoring.

Preconditions and Assumptions:

  • Payer A is authorized and has the appropriate scopes to access the health records of Patient B from Provider C using FHIR RESTful Queries
  • Payer A knows the FHIR id of the Patient resource for Patient B
  • Payer A knows the appropriate LOINC codes for searching for HbA1c test results (e.g.: 4548-5 Hemoglobin A1c/Hemoglobin.total in Blood)

Following the guidance in US Core searches for all HbA1c test results by a date range using the combination of the patient and code and date search parameters:

GET [base]/Observation?patient=[FHIR id]&code=[code]&date=gt[date]

Request

GET [base]/Observation?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&code=4548-4&date=gt2020-01-01

Request Headers

Accept: application/fhir+json
Content-Type: application/fhir+json
...(other headers)

Response Headers

HTTP/1.1 200 OK
Server: nginx/1.14.0 (Ubuntu)
Date: Fri, 23 Oct 2020 18:22:45 GMT
Content-Type: application/fhir+json;charset=utf-8
...(other headers)

Response Body

{
  "resourceType": "Bundle",
  "id": "3d4fdbbe-b73c-4c9f-89a0-4662506c4d25",
  "meta": {
    "lastUpdated": "2020-10-23T18:22:45.274+00:00"
  },
  "type": "searchset",
  "total": 4,
  "link": [ {
    "relation": "self",
    "url": "http://hapi.fhir.org/baseR4/Observation?code=4548-4&date=gt2020-01-01&patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b"
  } ],
  "entry": [ {
    "fullUrl": "http://hapi.fhir.org/baseR4/Observation/cdex-2020-01-23-hba1c-example",
    "resource": {
      "resourceType": "Observation",
      "id": "cdex-2020-01-23-hba1c-example",
      "meta": {
        "versionId": "1",
        "lastUpdated": "2020-10-23T18:18:25.154+00:00",
        "source": "#ObC36PK40pQM6y5M",
        "profile": [ "http://hl7.org/fhir/us/core/StructureDefinition/us-core-observation-lab" ]
      },
      "status": "final",
      "category": [ {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/observation-category",
          "code": "laboratory",
          "display": "Laboratory"
        } ],
        "text": "Laboratory"
      } ],
      "code": {
        "coding": [ {
          "system": "http://loinc.org",
          "code": "4548-4",
          "display": "Hemoglobin A1c/Hemoglobin.total in Blood"
        }, {
          "system": "http://www.ama-assn.org/go/cpt",
          "code": "83036",
          "display": "Hemoglobin; glycosylated (A1c)"
        }, {
          "system": "http://example.org/lab-results",
          "code": "HBA1C",
          "display": "Hglycated hemoglobin (HbA1c)"
        } ],
        "text": "glycated hemoglobin (HbA1c)"
      },
      "subject": {
        "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b",
        "display": "Elden718 Halvorson124"
      },
      "effectiveDateTime": "2020-01-23T10:21:08-07:00",
      "valueQuantity": {
        "value": 6.0,
        "unit": "%",
        "system": "http://unitsofmeasure.org/",
        "code": "%"
      }
    },
    "search": {
      "mode": "match"
    }
  }, {
    "fullUrl": "http://hapi.fhir.org/baseR4/Observation/cdex-2020-04-23-hba1c-example",
    "resource": {
      "resourceType": "Observation",
      "id": "cdex-2020-04-23-hba1c-example",
      "meta": {
        "versionId": "1",
        "lastUpdated": "2020-10-23T18:17:49.885+00:00",
        "source": "#n7aoEe76sAQUBlns",
        "profile": [ "http://hl7.org/fhir/us/core/StructureDefinition/us-core-observation-lab" ]
      },
      "status": "final",
      "category": [ {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/observation-category",
          "code": "laboratory",
          "display": "Laboratory"
        } ],
        "text": "Laboratory"
      } ],
      "code": {
        "coding": [ {
          "system": "http://loinc.org",
          "code": "4548-4",
          "display": "Hemoglobin A1c/Hemoglobin.total in Blood"
        }, {
          "system": "http://www.ama-assn.org/go/cpt",
          "code": "83036",
          "display": "Hemoglobin; glycosylated (A1c)"
        }, {
          "system": "http://example.org/lab-results",
          "code": "HBA1C",
          "display": "Hglycated hemoglobin (HbA1c)"
        } ],
        "text": "glycated hemoglobin (HbA1c)"
      },
      "subject": {
        "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b",
        "display": "Elden718 Halvorson124"
      },
      "effectiveDateTime": "2020-04-23T10:21:08-07:00",
      "valueQuantity": {
        "value": 7.2,
        "unit": "%",
        "system": "http://unitsofmeasure.org/",
        "code": "%"
      }
    },
    "search": {
      "mode": "match"
    }
  }, {
    "fullUrl": "http://hapi.fhir.org/baseR4/Observation/cdex-2020-10-23-hba1c-example",
    "resource": {
      "resourceType": "Observation",
      "id": "cdex-2020-10-23-hba1c-example",
      "meta": {
        "versionId": "1",
        "lastUpdated": "2020-10-23T18:16:54.549+00:00",
        "source": "#fuIEQP7SJ9NfAlPN",
        "profile": [ "http://hl7.org/fhir/us/core/StructureDefinition/us-core-observation-lab" ]
      },
      "status": "final",
      "category": [ {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/observation-category",
          "code": "laboratory",
          "display": "Laboratory"
        } ],
        "text": "Laboratory"
      } ],
      "code": {
        "coding": [ {
          "system": "http://loinc.org",
          "code": "4548-4",
          "display": "Hemoglobin A1c/Hemoglobin.total in Blood"
        }, {
          "system": "http://www.ama-assn.org/go/cpt",
          "code": "83036",
          "display": "Hemoglobin; glycosylated (A1c)"
        }, {
          "system": "http://example.org/lab-results",
          "code": "HBA1C",
          "display": "Hglycated hemoglobin (HbA1c)"
        } ],
        "text": "glycated hemoglobin (HbA1c)"
      },
      "subject": {
        "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b",
        "display": "Elden718 Halvorson124"
      },
      "effectiveDateTime": "2020-10-23T10:21:08-07:00",
      "valueQuantity": {
        "value": 7.0,
        "unit": "%",
        "system": "http://unitsofmeasure.org/",
        "code": "%"
      }
    },
    "search": {
      "mode": "match"
    }
  }, {
    "fullUrl": "http://hapi.fhir.org/baseR4/Observation/cdex-2020-07-23-hba1c-example",
    "resource": {
      "resourceType": "Observation",
      "id": "cdex-2020-07-23-hba1c-example",
      "meta": {
        "versionId": "1",
        "lastUpdated": "2020-10-23T18:16:17.687+00:00",
        "source": "#X2hXINwPYymTmEJc",
        "profile": [ "http://hl7.org/fhir/us/core/StructureDefinition/us-core-observation-lab" ]
      },
      "status": "final",
      "category": [ {
        "coding": [ {
          "system": "http://terminology.hl7.org/CodeSystem/observation-category",
          "code": "laboratory",
          "display": "Laboratory"
        } ],
        "text": "Laboratory"
      } ],
      "code": {
        "coding": [ {
          "system": "http://loinc.org",
          "code": "4548-4",
          "display": "Hemoglobin A1c/Hemoglobin.total in Blood"
        }, {
          "system": "http://www.ama-assn.org/go/cpt",
          "code": "83036",
          "display": "Hemoglobin; glycosylated (A1c)"
        }, {
          "system": "http://example.org/lab-results",
          "code": "HBA1C",
          "display": "Hglycated hemoglobin (HbA1c)"
        } ],
        "text": "glycated hemoglobin (HbA1c)"
      },
      "subject": {
        "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b",
        "display": "Elden718 Halvorson124"
      },
      "effectiveDateTime": "2020-07-23T10:21:08-07:00",
      "valueQuantity": {
        "value": 7.0,
        "unit": "%",
        "system": "http://unitsofmeasure.org/",
        "code": "%"
      }
    },
    "search": {
      "mode": "match"
    }
  } ]
}



Scenario 3

Payer A Seeks Insured Person/Patient B’s latest Progress notes from Provider C to support a claim submission.

Preconditions and Assumptions:

  • Payer A is authorized and has the appropriate scopes to access the health records of Patient B from Provider C using FHIR RESTful Queries
  • Payer A knows the FHIR id of the Patient resource for Patient B
  • Payer A knows the appropriate LOINC codes for searching for Progress note CCDA documents (11506-3 History & Physical Note)
  • Provider C supports the standard FHIR search parameters, _search and _count (if this is not the case, then the Payer can search using the date parameter and select the most recent Progress notes for the query results.)

Getting the latest Progress note is typically a two-step process:

  1. Query DocumentReference which references the actual notes file
  2. Fetch the notes file

Following the US Core Clinical Notes Guidance section, Payer searches for Progress note CCDA documents using the combination of the patient and type search parameters. In addition, the combination of _sort and _count is used to return only the latest resource that meets particular criteria. With _sort=-period (sort by the date parameter in descending order) and _count=1 the last matching resource will be returned.

GET [base]/DocumentReference?patient=[FHIR id]&type=[type-code]&_sort=-period&_count=1

The actual CCDA document is referenced in DocumentReference.content.attachment.url and can be fetched using a RESTful GET.

GET [base]/[url]

Step 1 - Search for DocumentReference

Request

GET [base]/DocumentReference?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&type=34117-2&_sort=-period&_count=1`

Request Headers

Accept: application/fhir+json
Content-Type: application/fhir+json
...(other headers)

Response Headers

HTTP/1.1 200 OK
Server: nginx/1.14.0 (Ubuntu)
Date: Fri, 23 Oct 2020 18:22:45 GMT
Content-Type: application/fhir+json;charset=utf-8
...(other headers)

Response Body

{
  "resourceType": "Bundle",
  "id": "041a1b5c-87b7-482c-8c80-637965d2d4bb",
  "meta": {
    "lastUpdated": "2020-10-23T20:29:25.663+00:00"
  },
  "type": "searchset",
  "total": 1,
  "link": [ {
    "relation": "self",
    "url": "http://hapi.fhir.org/baseR4/DocumentReference?_count=1&_sort=-period&patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&type=34117-2"
  } ],
  "entry": [ {
    "fullUrl": "http://hapi.fhir.org/baseR4/DocumentReference/cdex-HP-example1",
    "resource": {
      "resourceType": "DocumentReference",
      "id": "cdex-HP-example1",
      "meta": {
        "versionId": "1",
        "lastUpdated": "2020-10-23T20:27:18.976+00:00",
        "source": "#XOrE2IwfLwl5C1RV",
        "profile": [ "http://hl7.org/fhir/us/core/StructureDefinition/us-core-documentreference" ]
      },
      "identifier": [ {
        "system": "urn:ietf:rfc:3986",
        "value": "urn:oid:2.16.840.1.113883.19.5.99999.2"
      } ],
      "status": "current",
      "type": {
        "coding": [ {
          "system": "http://loinc.org",
          "code": "34117-2",
          "display": "History & Physical Note"
        } ],
        "text": "History & Physical Note"
      },
      "category": [ {
        "coding": [ {
          "system": "http://hl7.org/fhir/us/core/CodeSystem/us-core-documentreference-category",
          "code": "clinical-note",
          "display": "Clinical Note"
        } ],
        "text": "Clinical Note"
      } ],
      "subject": {
        "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b",
        "display": "Elden718 Halvorson124"
      },
      "date": "2020-10-23T10:21:08-07:00",
      "author": [ {
        "reference": "Practitioner/0000016f-57cb-cdac-0000-00000000014a",
        "display": "Janeth814 Jakubowski832, MD"
      } ],
      "description": "Pulmonology clinic acute visit",
      "content": [ {
        "attachment": {
          "contentType": "text/plain",
          "url": "/Binary/cdex-example-hpnote",
          "title": "Uri where the data can be found: [base]/Binary/1-note"
        },
        "format": {
          "system": "urn:oid:1.3.6.1.4.1.19376.1.2.3",
          "code": "urn:hl7-org:sdwg:ccda-structuredBody:2.1",
          "display": "Documents following C-CDA constraints using a structured body"
        }
      } ],
      "context": {
        "period": {
          "start": "2020-10-23T10:21:06-07:00",
          "end": "2020-10-23T10:21:08-07:00"
        }
      }
    },
    "search": {
      "mode": "match"
    }
  } ]
}

Step 2 - Fetch Document

Request

GET [base]/Binary/cdex-example-hpnote`

Request Headers

...(other headers)

Response Headers

HTTP/1.1 200 OK
Server: nginx/1.14.0 (Ubuntu)
Date: Fri, 23 Oct 2020 22:02:15 GMT
Content-Type: application/pdf
...(other headers)

Response Body = PDF


Provenance

To the extent that the Provider keeps a record of the provenance for the source of the data, the FHIR Provenance Resource can be requested as documented on US Core’s Basic Provenance page. When returning provenance the HRex Provenance Profile should be used. An example illustrating this transaction is shown below.

Example of Direct Query Response Including Provenance

This example is the same as Scenario 1 above except that it also includes the corresponding Provenance records.

GET [base]/Condition?patient=[FHIR id]&clinical-status=active,recurrance,remission&_revinclude=Provenance:target

Request

GET [base]/Condition?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&clinical-status=active,recurrance,remission&_revinclude=Provenance:target

Request Headers

Accept: application/fhir+json
Content-Type: application/fhir+json
...(other headers)

Response Headers

HTTP/1.1 200 OK
Server: nginx/1.14.0 (Ubuntu)
Date: Fri, 23 Oct 2020 04:54:56 GMT
Content-Type: application/fhir+json;charset=utf-8
...(other headers)

Response Body

{
  "resourceType": "Bundle",
  "id": "d88e2910-3c95-469d-b1f4-ab5553b471fb",
  "meta": {
    "lastUpdated": "2020-10-23T04:54:56.048+00:00"
  },
  "type": "searchset",
  "total": 1,
  "link": [
    {
      "relation": "self",
      "url": "http://hapi.fhir.org/baseR4/Condition?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&clinical-status=active,recurrance,remission&_revinclude=Provenance:target"
    }
  ],
  "entry": [
    {
      "fullUrl": "http://hapi.fhir.org/baseR4/Condition/4ac41715-fcbd-421c-8796-9b2c9706dd3f",
      "resource": {
        "resourceType": "Condition",
        "id": "4ac41715-fcbd-421c-8796-9b2c9706dd3f",
        "meta": {
          "versionId": "10",
          "lastUpdated": "2020-04-28T20:28:00.008+00:00",
          "source": "#cabiJIK51sD2iz4N",
          "profile": [
            "http://hl7.org/fhir/us/core/StructureDefinition/us-core-condition"
          ]
        },
        "clinicalStatus": {
          "coding": [
            {
              "system": "http://terminology.hl7.org/CodeSystem/condition-clinical",
              "code": "active"
            }
          ]
        },
        "verificationStatus": {
          "coding": [
            {
              "system": "http://terminology.hl7.org/CodeSystem/condition-ver-status",
              "code": "confirmed"
            }
          ]
        },
        "category": [
          {
            "coding": [
              {
                "system": "http://terminology.hl7.org/CodeSystem/condition-category",
                "code": "encounter-diagnosis",
                "display": "Encounter Diagnosis"
              }
            ]
          }
        ],
        "code": {
          "coding": [
            {
              "system": "http://snomed.info/sct",
              "code": "1234",
              "display": "Examplitis"
            }
          ],
          "text": "Examplitis"
        },
        "subject": {
          "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b"
        },
        "encounter": {
          "reference": "Encounter/5fe62cd5-bfcf-4d3b-a1e9-80d6f75d6f82"
        },
        "onsetDateTime": "2018-10-21T21:22:15-07:00",
        "recordedDate": "2018-10-21T21:22:15-07:00"
      },
      "search": {
        "mode": "match"
      }
    },
    {
      "fullUrl": "http://hapi.fhir.org/baseR4/Provenance/b2ce4584-b213-411b-bdc9-d515dc92eadf",
      "resource": {
        "resourceType": "Provenance",
        "id": "b2ce4584-b213-411b-bdc9-d515dc92eadf",
        "target": [
          {
            "reference": "Condition/4ac41715-fcbd-421c-8796-9b2c9706dd3f"
          }
        ],
        "recorded": "2018-10-21T21:22:15-07:00",
        "agent": [
          {
            "type": [
              {
                "coding": [
                  {
                    "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type",
                    "code": "author",
                    "display": "Author"
                  }
                ]
              }
            ],
            "who": {
              "reference": "Practitioner/Dr-Jones-12345"
            },
            "onBehalfOf": {
              "reference": "Organization/good-health-54321"
            }
          }
        ]
      },
      "search": {
        "mode": "include"
      }
    }
  ]
}



Signatures

Some data consumers may require that the data they receive are signed. When signatures are required on the returned results, the following general rules apply:

  • The signature representing the sending system is a system-level attestation by the sending organization that they supplied the information and it is a complete and accurate representation of the shareable information available from that system meeting the requested criteria. This signature does NOT attest that the information itself is accurate because the system can’t make that determination.*
  • The Bundle.signature element on the FHIR search set Bundle is used to exchange the signature.

* Consult with your Payer and your legal team for questions regarding legal liability associated with sharing and signing data.

The Data Consumer/Requester Requirements

  • The Data Consumer/Requester pre-negotiates with the organization representing the Data Source/Responder whether electronic or digital signatures are required for FHIR RESTful query response data. If the signatures are required all search query response data will be signed by the sending organization.
  • The Data Consumer/Requester follows the documentation on the Signatures page for validating signatures.
    • If the signatures fail verification, the Data Consumer/Requester notifies the Data Source that the signature is bad or absent. Currently, there is no standard way to communicate this, and it needs to be done “out of band”.

Data Source/Responder Requirements

  • When an electronic or digital signature is required for a FHIR RESTful queries, the Data Source/Responder returns a signed FHIR search set Bundle using the Bundle.signature element for the signature signed by the organization that is responding to the query.
  • The Data Source/Responder follows the documentation on the Signatures page for producing signatures.
  • As discussed in the What is Signed section, a signed search bundle could have entries within it that are individually signed as well. If the Consumer/Requester assumed there would be a signature (wet, electronic, or digital) on an individual returned object within the search set Bundle (e.g CCDA, PDF, Image, CDA on FHIR ) and it is not present, they can re-request the signed object using Task-based request (see Signatures for Task Based Requests).

When signatures are required, the Data Consumer must use a FHIR RESTful search instead of FHIR RESTful read. There is no CDex support for signatures on a FHIR RESTful read because it fetches a single instance of a resource instead of a Bundle. If a read is attempted and a signature is required, the Data Source/Responder SHALL return an HTTP 400 Bad Request and an OperationOutcome describing the business rule error for any read transactions as shown in the following example:

  HTTP/1.1 400 Not Found
  [other headers]
  {
    "resourceType": "OperationOutcome",
    "id": "cdex-signed-read-response",
    "issue": [
  {
    "severity": "error",
    "code": "business-rule",
    "details": {
      "text": "signed FHIR RESTful read response is not supported."
    },
    "diagnostics": "Resubmit the request as a FHIR RESTful search'"
  }
    ]
  }

Example of Signed Direct Query Response

This example is the same as Scenario 1 above except that it also includes a digital signature. See the Signatures page for a complete worked example of how the signature was created and verified.

Preconditions and Assumptions:

  • In addition to the Scenario 1 assumptions above, Payer A pre-negotiated with Provider B that digital signatures are required for direct query responses.

GET [base]/Condition?patient=[FHIR id]&clinical-status=active,recurrance,remission

Request

GET [base]/Condition?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b&clinical-status=active,recurrance,remission

Request Headers

Accept: application/fhir+json
Content-Type: application/fhir+json
...(other headers)

Response Headers

HTTP/1.1 200 OK
Server: nginx/1.14.0 (Ubuntu)
Date: Fri, 23 Oct 2020 04:54:56 GMT
Content-Type: application/fhir+json;charset=utf-8
...(other headers)

Response Body

{
    "resourceType": "Bundle",
    "id": "d88e2910-3c95-469d-b1f4-ab5553b471fb",
    "meta": {
        "lastUpdated": "2020-10-23T04:54:56.048+00:00"
    },
    "type": "searchset",
    "total": 1,
    "link": [
        {
            "relation": "self",
            "url": "http://hapi.fhir.org/baseR4/Condition?patient=06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b"
        }
    ],
    "entry": [
        {
            "fullUrl": "http://hapi.fhir.org/baseR4/Condition/4ac41715-fcbd-421c-8796-9b2c9706dd3f",
            "resource": {
                "resourceType": "Condition",
                "id": "4ac41715-fcbd-421c-8796-9b2c9706dd3f",
                "meta": {
                    "versionId": "10",
                    "lastUpdated": "2020-04-28T20:28:00.008+00:00",
                    "source": "#cabiJIK51sD2iz4N",
                    "profile": [
                        "http://hl7.org/fhir/us/core/StructureDefinition/us-core-condition"
                    ]
                },
                "clinicalStatus": {
                    "coding": [
                        {
                            "system": "http://terminology.hl7.org/CodeSystem/condition-clinical",
                            "code": "active"
                        }
                    ]
                },
                "verificationStatus": {
                    "coding": [
                        {
                            "system": "http://terminology.hl7.org/CodeSystem/condition-ver-status",
                            "code": "confirmed"
                        }
                    ]
                },
                "category": [
                    {
                        "coding": [
                            {
                                "system": "http://terminology.hl7.org/CodeSystem/condition-category",
                                "code": "encounter-diagnosis",
                                "display": "Encounter Diagnosis"
                            }
                        ]
                    }
                ],
                "code": {
                    "coding": [
                        {
                            "system": "http://snomed.info/sct",
                            "code": "1234",
                            "display": "Examplitis"
                        }
                    ],
                    "text": "Examplitis"
                },
                "subject": {
                    "reference": "Patient/06e1f0dd-5fbe-4480-9bb4-6b54ec02d31b"
                },
                "encounter": {
                    "reference": "Encounter/5fe62cd5-bfcf-4d3b-a1e9-80d6f75d6f82"
                },
                "onsetDateTime": "2018-10-21T21:22:15-07:00",
                "recordedDate": "2018-10-21T21:22:15-07:00"
            },
            "search": {
                "mode": "match"
            }
        }
    ],
    "signature": {
        "type": [
            {
                "system": "urn:iso-astm:E1762-95:2013",
                "code": "1.2.840.10065.1.12.1.5",
                "display": "Verification Signature"
            }
        ],
        "when": "2020-10-23T04:54:56.048+00:00",
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