Skip to content

Commit 1dc9e59

Browse files
committed
markdown updates and editing
1 parent 923e29a commit 1dc9e59

File tree

3 files changed

+49
-49
lines changed

3 files changed

+49
-49
lines changed

articles/healthcare-apis/azure-api-for-fhir/patient-everything.md

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ ms.author: kesheth
1212

1313
# Patient-everything in FHIR
1414

15-
[!INCLUDE [retirement banner](../includes/healthcare-apis-azure-api-fhir-retirement.md)]
15+
[!INCLUDE[retirement banner](../includes/healthcare-apis-azure-api-fhir-retirement.md)]
1616

17-
The [Patient-everything](https://www.hl7.org/fhir/patient-operation-everything.html) operation is used to provide a view of all resources related to a patient. This operation can be useful to give patients' access to their entire record or for a provider or other user to perform a bulk data download related to a patient. According to the FHIR specification, Patient-everything returns all the information related to one or more patients described in the resource or context on which this operation is invoked. In the Azure API for FHIR, Patient-everything is available to pull data related to a specific patient.
17+
The [Patient-everything](https://www.hl7.org/fhir/patient-operation-everything.html) operation is used to provide a view of all resources related to a patient. This operation can be useful to give patients access to their entire record or for a provider or other user to perform a bulk data download related to a patient. According to the FHIR specification, Patient-everything returns all the information related to one or more patients described in the resource or context on which this operation is invoked. In the Azure API for FHIR®, Patient-everything is available to pull data related to a specific patient.
1818

1919
## Use Patient-everything
20-
To call Patient-everything, use the following command:
20+
To call Patient-everything, use the following command.
2121

2222
```json
2323
GET {FHIRURL}/Patient/{ID}/$everything
@@ -26,36 +26,36 @@ GET {FHIRURL}/Patient/{ID}/$everything
2626
> [!Note]
2727
> You must specify an ID for a specific patient. If you need all data for all patients, see [$export](../data-transformation/export-data.md).
2828
29-
The Azure API for FHIR validates that it can find the patient matching the provided patient ID. If a result is found, the response will be a bundle of type `searchset` with the following information:
29+
The Azure API for FHIR validates that it can find the patient matching the provided patient ID. If a result is found, the response is a bundle of type `searchset` with the following information.
3030

3131
* [Patient resource](https://www.hl7.org/fhir/patient.html)
32-
* Resources that are directly referenced by the patient resource, except [link](https://www.hl7.org/fhir/patient-definitions.html#Patient.link) references that aren't of [seealso](https://www.hl7.org/fhir/codesystem-link-type.html#content) or if the `seealso` link references a `RelatedPerson`.
33-
* If there are `seealso` link reference(s) to other patient(s), the results will include Patient-everything operation against the `seealso` patient(s) listed.
32+
* Resources directly referenced by the patient resource, except [link](https://www.hl7.org/fhir/patient-definitions.html#Patient.link) references that aren't of [seealso](https://www.hl7.org/fhir/codesystem-link-type.html#content) or if the `seealso` link references a `RelatedPerson`.
33+
* If there are `seealso` link references to other patients, the results include Patient-everything operations against the `seealso` patients listed.
3434
* Resources in the [Patient Compartment](https://www.hl7.org/fhir/compartmentdefinition-patient.html)
3535
* [Device resources](https://www.hl7.org/fhir/device.html) that reference the patient resource.
3636

3737
> [!Note]
3838
> If the patient has more than 100 devices linked to them, only 100 will be returned.
3939
4040
## Patient-everything parameters
41-
The Azure API for FHIR supports the following query parameters. All of these parameters are optional:
41+
The Azure API for FHIR supports the following query parameters. All of these parameters are optional.
4242

4343
|Query parameter | Description|
4444
|-----------------------|------------|
45-
| \_type | Allows you to specify which types of resources will be included in the response. For example, \_type=Encounter would return only `Encounter` resources associated with the patient. |
46-
| \_since | Will return only resources that have been modified since the time provided. |
45+
| \_type | Allows you to specify which types of resources to be included in the response. For example, \_type=Encounter would return only `Encounter` resources associated with the patient. |
46+
| \_since | Returns only resources that have been modified since the time provided. |
4747
| start | Specifying the start date will pull in resources where their clinical date is after the specified start date. If no start date is provided, all records before the end date are in scope. |
48-
| end | Specifying the end date will pull in resources where their clinical date is before the specified end date. If no end date is provided, all records after the start date are in scope. |
48+
| end | Specifying the end date pulls in resources where their clinical date is before the specified end date. If no end date is provided, all records after the start date are in scope. |
4949

5050
> [!Note]
51-
> This implementation of Patient-everything does not support the _count parameter.
51+
> This implementation of Patient-everything does not support the `_count` parameter.
5252
5353

5454
## Processing patient links
5555

56-
On a patient resource, there's an element called link, which links a patient to other patients or related persons. These linked patients help give a holistic view of the original patient. The link reference can be used when a patient is replacing another patient or when two patient resources have complementary information. One use case for links is when an ADT 38 or 39 HL7v2 message comes. The ADT38/39 describe an update to a patient. This update can be stored as a reference between two patients in the link element.
56+
On a patient resource, there's an element called link, which links a patient to other patients or related persons. These linked patients help give a holistic view of the original patient. The link reference can be used when a patient is replacing another patient or when two patient resources have complementary information. One use case for links is when an ADT 38 or 39 HL7v2 message comes. The ADT38/39 describes an update to a patient. This update can be stored as a reference between two patients in the link element.
5757

58-
The FHIR specification has a detailed overview of the different types of [patient links](https://www.hl7.org/fhir/valueset-link-type.html#expansion), but here's a high-level summary:
58+
The FHIR specification has a detailed overview of the different types of [patient links](https://www.hl7.org/fhir/valueset-link-type.html#expansion). The following list is a high-level summary.
5959

6060
* [replaces](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-replaces) - The Patient resource replaces a different Patient.
6161
* [refer](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-refer) - Patient is valid, but it's not considered the main source of information. Points to another patient to retrieve additional information.
@@ -67,58 +67,58 @@ The FHIR specification has a detailed overview of the different types of [patien
6767
The Patient-everything operation in Azure API for FHIR processes patient links in different ways to give you the most holistic view of the patient.
6868

6969
> [!Note]
70-
> A link can also reference a `RelatedPerson`. Right now, `RelatedPerson` resources are not processed in Patient-everything and are not returned in the bundle.
70+
> A link can also reference a `RelatedPerson`. Presently, `RelatedPerson` resources are not processed in Patient-everything and are not returned in the bundle.
7171
72-
Right now, [replaces](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-replaces) and [refer](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-refer) links are ignored by the Patient-everything operation, and the linked patient isn't returned in the bundle.
72+
Presently, [replaces](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-replaces) and [refer](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-refer) links are ignored by the Patient-everything operation, and the linked patient isn't returned in the bundle.
7373

74-
As described, [seealso](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-seealso) links reference another patient that's considered equally valid to the original. After the Patient-everything operation is run, if the patient has `seealso` links to other patients, the operation runs Patient-everything on each `seealso` link. This means if a patient links to five other patients with a type `seealso` link, we'll run Patient-everything on each of those five patients.
74+
As described, [seealso](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-seealso) links reference another patient that's considered equally valid to the original. After the Patient-everything operation is run, if the patient has `seealso` links to other patients, the operation runs Patient-everything on each `seealso` link. This means if a patient links to five other patients with a type `seealso` link, Patient-everything will run on each of those five patients.
7575

7676
> [!Note]
7777
> This is set up to only follow `seealso` links one layer deep. It doesn't process a `seealso` link's `seealso` links.
7878
7979
[![See also flow diagram.](media/patient-everything/see-also-flow.png)](media/patient-everything/see-also-flow.png#lightbox)
8080

81-
The final link type is [replaced-by](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-replaced-by). In this case, the original patient resource is no longer being used and the `replaced-by` link points to the patient that should be used. This implementation of `Patient-everything` will include by default an operation outcome at the start of the bundle with a warning that the patient is no longer valid. This will also be the behavior when the `Prefer` header is set to `handling=lenient`.
81+
The final link type is [replaced-by](https://www.hl7.org/fhir/codesystem-link-type.html#link-type-replaced-by). In this case, the original patient resource is no longer being used and the `replaced-by` link points to the patient that should be used. This implementation of `Patient-everything` will by default include an operation outcome at the start of the bundle with a warning that the patient is no longer valid. This will also be the behavior when the `Prefer` header is set to `handling=lenient`.
8282

83-
In addition, you can set the `Prefer` header to `handling=strict` to throw an error instead. In this case, a return of error code 301 `MovedPermanently` indicates that the current patient is out of date and returns the ID for the correct patient that's included in the link. The `ContentLocation` header of the returned error will point to the correct and up-to-date request.
83+
Alternatively, you can set the `Prefer` header to `handling=strict` to throw an error. In this case, a return of error code 301 `MovedPermanently` indicates that the current patient is out of date and returns the ID for the correct patient that's included in the link. The `ContentLocation` header of the returned error points to the correct and up-to-date request.
8484

8585
> [!Note]
8686
> If a `replaced-by` link is present, `Prefer: handling=lenient` and results are returned asynchronously in multiple bundles, only an operation outcome is returned in one bundle.
8787
8888
## Patient-everything response order
8989

90-
The Patient-everything operation returns results in phases:
90+
The Patient-everything operation returns results in phases.
9191

92-
1. Phase 1 returns the `Patient` resource itself in addition to any `generalPractitioner` and `managingOrganization` resources ir references.
92+
1. Phase 1 returns the `Patient` resource itself in addition to any `generalPractitioner` and `managingOrganization` resources or references.
9393
1. Phase 2 and 3 both return resources in the patient compartment. If the start or end query parameters are specified, Phase 2 returns resources from the compartment that can be filtered by their clinical date, and Phase 3 returns resources from the compartment that can't be filtered by their clinical date. If neither of these parameters are specified, Phase 2 is skipped and Phase 3 returns all patient-compartment resources.
94-
1. Phase 4 will return any devices that reference the patient.
94+
1. Phase 4 returns any devices that reference the patient.
9595

96-
Each phase will return results in a bundle. If the results span multiple pages, the next link in the bundle will point to the next page of results for that phase. After all results from a phase are returned, the next link in the bundle will point to the call to initiate the next phase.
96+
Each phase returns results in a bundle. If the results span multiple pages, the **next** link in the bundle will point to the next page of results for that phase. After all results from a phase are returned, the next link in the bundle will point to the call to initiate the next phase.
9797

98-
If the original patient has any `seealso` links, phases 1 through 4 will be repeated for each of those patients.
98+
If the original patient has any `seealso` links, phases 1 through 4 are repeated for each of those patients.
9999

100100
## Examples of Patient-everything
101101

102-
Here are some examples of using the Patient-everything operation. In addition to the examples, we have a [sample REST file](https://github.com/microsoft/fhir-server/blob/main/docs/rest/PatientEverythingLinks.http) that illustrates how the `seealso` and `replaced-by` behavior works.
102+
Here are some examples of using the Patient-everything operation. In addition to these examples, we have a [sample REST file](https://github.com/microsoft/fhir-server/blob/main/docs/rest/PatientEverythingLinks.http) that illustrates how the `seealso` and `replaced-by` behavior works.
103103

104-
To use Patient-everything to query between 2010 and 2020, use the following call:
104+
To use Patient-everything to query between 2010 and 2020, use the following call.
105105

106106
```json
107107
GET {FHIRURL}/Patient/{ID}/$everything?start=2010&end=2020
108108
```
109109

110-
To use $patient-everything to query a patient’s Observation and Encounter, use the following call:
110+
To use `$patient-everything` to query a patient’s Observation and Encounter, use the following call.
111111
```json
112112
GET {FHIRURL}/Patient/{ID}/$everything?_type=Observation,Encounter
113113
```
114114

115-
To use $patient-everything to query a patient’s everything since 2021-05-27T05:00:00Z, use the following call:
115+
To use `$patient-everything` to query a patient’s "everything" since 2021-05-27T05:00:00Z, use the following call.
116116

117117
```json
118118
GET {FHIRURL}/Patient/{ID}/$everything?_since=2021-05-27T05:00:00Z
119119
```
120120

121-
If a patient is found for each of these calls, you'll get back a 200 response with a `Bundle` of the corresponding resources.
121+
If a patient is found for each of these calls, you get back a 200 response with a `Bundle` of the corresponding resources.
122122

123123
## Next steps
124124

@@ -127,4 +127,4 @@ Now that you know how to use the Patient-everything operation, you can learn abo
127127
>[!div class="nextstepaction"]
128128
>[Overview of search in Azure API for FHIR](overview-of-search.md)
129129
130-
FHIR® is a registered trademark of [HL7](https://hl7.org/fhir/) and is used with the permission of HL7.
130+
[!INCLUDE[FHIR trademark statement](../includes/healthcare-apis-fhir-trademark.md)]

0 commit comments

Comments
 (0)