R4 DocumentReference
The DocumentReference resource provides "a reference to a document of any kind for any purpose". It also "provides metadata about the document so that the document can be discovered and managed".
Supported Profiles
This API supports the following FHIR profiles:
Operations
The General Purpose API DocumentReference resources supports the following standard operations. However, support varies by the targeted CareRecord or solution.
| CareRecord / Solution | Create | Read | Update | Search |
|---|---|---|---|---|
| GEHRIMED | - | Yes | - | Yes |
| myAvatar | - | Yes | - | Yes |
| myEvolv | - | Yes | - | Yes |
| myUnity | - | Yes | - | Yes |
| Referral Manager | Yes | - | Yes | - |
Search
Not all Netsmart solutions support DocumentReference search. See supported operations table above and consult your target solution's documentation for more information.
This operation retrieves a list of resources by these query parameters.
Standard Parameters
| Name | Type | Description |
|---|---|---|
| authenticator | reference | Who/what authenticated the document. |
| author | reference | Who and/or what authored the document. |
| custodian | reference | Organization which maintains the document. |
| patient | reference | REQUIRED Who/what is the subject of the document. Not required when searching by _id. |
| period | date | The time of service that is being documented. |
| type | token | Kind of document (LOINC if possible). |
| _id | id | Unique identifier of the DocumentReference. Cannot be used with other search parameters. |
Search Examples
Via POST
The POST method is recommended as it keeps health information out of the URL.
- Production
- Preview
curl -X POST https://fhir.netsmartcloud.com/v4/DocumentReference/_search \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json" \
-d "patient=Patient/123" \
-d "type=http://loinc.org|18842-5"
curl -X POST https://fhirtest.netsmartcloud.com/v4/DocumentReference/_search \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json" \
-d "patient=Patient/123" \
-d "type=http://loinc.org|18842-5"
Via GET
- Production
- Preview
curl -X GET "https://fhir.netsmartcloud.com/uscore/v1/DocumentReference?patient=Patient/123&type=http://loinc.org%7C18748-4" \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json"
curl -X GET "https://fhirtest.netsmartcloud.com/uscore/v1/DocumentReference?patient=Patient/123&type=http://loinc.org%7C18748-4" \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json"
Generate an Ad-hoc CDA
This customization is expected to be replaced with an extended operation in future API versions.
This resource has been customized the search to allow for the generation of an ad-hoc CDA document similar to our CCD API.
This functionality is initiated by using one of our CCD API documentType values in type search parameter.
Supported CDA Types
The following CDA document types are currently supported by this API.
| Type | type Parameter | Note |
|---|---|---|
| Consultation Note | ConsultationNote | |
| Continuity of Care Document | CCD | |
| Discharge Summary | DischargeSummary | |
| Electronic Initial Case Report | EICR | |
| Emergency Healthcare Survey | EmergencyHealthcareSurvey | |
| History and Physical Note | HistoryAndPhysicalNote | |
| Inpatient Healthcare Survey | InpatientHealthcareSurvey | |
| Outpatient Healthcare Survey | OutpatientHealthcareSurvey | |
| Progress Note | ProgressNoteDoc | |
| Public Health Case Report | PublicHealthCaseReport | |
| Referral Note | ReferralNote | |
| Transfer of Care | TransferOfCare | Reserved for future use. This document type is not available currently. |
| Unstructured Document | UnstructuredDocument |
Parameters
The following search parameters are used to generate the CDA. All other search parameters passed are ignored.
| Name | Type | Description |
|---|---|---|
| patient | reference | REQUIRED Who/what is the subject of the document. |
| period | date | The time of service that is being documented. |
| type | token | CCD | ConsultationNote | DischargeSummary | EICR | EmergencyHealthcareSurvey | HistoryAndPhysicalNote | InpatientHealthcareSurvey | OutpatientHealthcareSurvey | ProgressNoteDoc | PublicHealthCaseReport | ReferralNote | TransferOfCare | UnstructuredDocument REQUIRED The type of CDA. |
Examples
The following examples show how to use the search parameters to generate a CDA.
Via POST
The POST method is recommended as it keeps health information out of the URL.
- Production
- Preview
curl -X POST https://fhir.netsmartcloud.com/v4/DocumentReference/_search \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json" \
-H "Content-Type: application/x-form-urlencoded" \
-d "patient=Patient/123" \
-d "type=CCD" \
-d "period=ge2023-07-01" \
-d "period=le2023-07-31"
curl -X POST https://fhirtest.netsmartcloud.com/v4/DocumentReference/_search \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json" \
-H "Content-Type: application/x-form-urlencoded" \
-d "patient=Patient/123" \
-d "type=CCD" \
-d "period=ge2023-07-01" \
-d "period=le2023-07-31"
Via GET
- Production
- Preview
curl -X GET "https://fhir.netsmartcloud.com/uscore/v1/DocumentReference?patient=Patient/123&type=CCD&period=ge2023-07-01&period=ge2023-07-31" \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json"
curl -X GET "https://fhirtest.netsmartcloud.com/uscore/v1/DocumentReference?patient=Patient/123&type=CCD&period=ge2023-07-01&period=ge2023-07-31" \
-H "Authorization: {Bearer Token}" \
-H "Accept: application/fhir+json"