Skip to content

Commit 2523e5b

Browse files
authored
Merge pull request #174758 from SteveWohl/fhir-rest-api-stu3-edits
Added notes about the STU3 patch
2 parents db651eb + fb102a0 commit 2523e5b

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

articles/healthcare-apis/azure-api-for-fhir/fhir-rest-api-capabilities.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: stevewohl
55
ms.service: healthcare-apis
66
ms.subservice: fhir
77
ms.topic: conceptual
8-
ms.date: 09/28/2021
8+
ms.date: 10/06/2021
99
ms.author: cavoeg
1010
---
1111

@@ -45,6 +45,9 @@ DELETE `https://{{hostname}}/Patient?identifier=1032704&_count=100`
4545

4646
Patch is a valuable RESTful operation when you need to update only a portion of the FHIR resource. Using Patch allows you to specify the element(s) that you want to update in the resource without having to update the entire record. FHIR defines three types of ways to Patch resources in FHIR: JSON Patch, XML Patch, and FHIR Path Patch. The FHIR service supports JSON Patch and Conditional JSON Patch (which allows you to Patch a resource based on a search criteria instead of an ID). To walk through some examples of using JSON Patch, refer to the sample [REST file](https://github.com/microsoft/fhir-server/blob/main/docs/rest/PatchRequests.http).
4747

48+
> [!NOTE]
49+
> When using `PATCH` against STU3, and if you are requesting a History bundle, the patched resource's `Bundle.entry.request.method` is mapped to `PUT`. This is because STU3 doesn't contain a definition for the `PATCH` verb in the [HTTPVerb value set](http://hl7.org/fhir/STU3/valueset-http-verb.html).
50+
4851
### Testing Patch
4952

5053
Within Patch, there is a test operation that allows you to validate that a condition is true before doing the patch. For example, if you wanted to set a patient deceased, only if they were not already marked as deceased, you could use the example below:
@@ -106,3 +109,5 @@ In this article, you learned about some of the REST capabilities of Azure API fo
106109

107110
>[!div class="nextstepaction"]
108111
>[Overview of search in Azure API for FHIR](overview-of-search.md)
112+
113+
(FHIR®) is a registered trademark of [HL7](https://hl7.org/fhir/) and is used with the permission of HL7.

articles/healthcare-apis/fhir/fhir-rest-api-capabilities.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: stevewohl
55
ms.service: healthcare-apis
66
ms.subservice: fhir
77
ms.topic: conceptual
8-
ms.date: 09/28/2021
8+
ms.date: 10/06/2021
99
ms.author: cavoeg
1010
---
1111

@@ -45,6 +45,9 @@ DELETE `https://{{hostname}}/Patient?identifier=1032704&_count=100`
4545

4646
Patch is a valuable RESTful operation when you need to update only a portion of the FHIR resource. Using Patch allows you to specify the element(s) that you want to update in the resource without having to update the entire record. FHIR defines three types of ways to Patch resources in FHIR: JSON Patch, XML Patch, and FHIR Path Patch. The FHIR service support JSON Patch and Conditional JSON Patch (which allows you to Patch a resource based on a search criteria instead of an ID). To walk through some examples of using JSON Patch, refer to the sample [REST file](https://github.com/microsoft/fhir-server/blob/main/docs/rest/PatchRequests.http).
4747

48+
> [!NOTE]
49+
> When using `PATCH` against STU3, and if you are requesting a History bundle, the patched resource's `Bundle.entry.request.method` is mapped to `PUT`. This is because STU3 doesn't contain a definition for the `PATCH` verb in the [HTTPVerb value set](http://hl7.org/fhir/STU3/valueset-http-verb.html).
50+
4851
### Testing Patch
4952

5053
Within Patch, there is a test operation that allows you to validate that a condition is true before doing the patch. For example, if you want to set a patient as deceased (only if they're not already marked as deceased) you can use the example below:
@@ -107,6 +110,6 @@ In this article, you learned about some of the REST capabilities of the FHIR ser
107110
>[!div class="nextstepaction"]
108111
>[Overview of FHIR search](overview-of-search.md)
109112
110-
113+
(FHIR®) is a registered trademark of [HL7](https://hl7.org/fhir/) and is used with the permission of HL7.
111114

112115

0 commit comments

Comments
 (0)