You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -69,7 +69,7 @@ Enter `{{fhirurl}}/metadata` in the `GET`request, and then choose `Send`. You sh
69
69
70
70
## Get a Microsoft Entra access token
71
71
72
-
Get a Microsoft Entra access token by using a service principal or a Microsoft Entra user account. Choose one of the two methods.
72
+
Get a Microsoft Entra access token by choosing either a service principal, or a Microsoft Entra user account.
73
73
74
74
### Use a service principal with a client credential grant type
75
75
@@ -89,9 +89,9 @@ Create a new `POST` request:
89
89
> [!NOTE]
90
90
> In scenarios where the FHIR service audience parameter isn't mapped to the FHIR service endpoint URL, the resource parameter value should be mapped to the audience value on the FHIR service **Authentication** pane.
91
91
92
-
3. Select the **Test** tab and enter in the text section: `pm.environment.set("bearerToken", pm.response.json().access_token);` To make the value available to the collection, use the pm.collectionVariables.set method. For more information on the set method and its scope level, see [Using variables in scripts](https://learning.postman.com/docs/sending-requests/variables/#defining-variables-in-scripts).
92
+
3. Select the **Test** tab and enter `pm.environment.set("bearerToken", pm.response.json().access_token);` in the text section. To make the value available to the collection, use the pm.collectionVariables.set method. For more information on the set method and its scope level, see [Using variables in scripts](https://learning.postman.com/docs/sending-requests/variables/#defining-variables-in-scripts).
93
93
4. Select **Save** to save the settings.
94
-
5. Select **Send**. You should see a response with the Microsoft Entra access token, which is saved to the variable `bearerToken` automatically. You can then use it in all FHIR service API requests.
94
+
5. Select **Send**. You should see a response with the Microsoft Entra access token, which is automatically saved to the variable `bearerToken`. You can then use it in all FHIR service API requests.
95
95
96
96
:::image type="content" source="media/postman/postman-send-button.png" alt-text="Screenshot showing the send button." lightbox="media/postman/postman-send-button.png":::
97
97
@@ -101,7 +101,7 @@ You can examine the access token using online tools such as [https://jwt.ms](htt
101
101
102
102
## Use a user account with the authorization code grant type
103
103
104
-
You can get the Microsoft Entra access token by using your Entra account credentials and following the listed steps.
104
+
You can get the Microsoft Entra access token by using your Microsoft Entra account credentials and following the listed steps.
105
105
106
106
1. Verify that you're a member of Microsoft Entra tenant with the required access permissions.
107
107
@@ -115,7 +115,7 @@ You can get the Microsoft Entra access token by using your Entra account credent
1. In the Postman, select the **Authorization** tab of either a collection or a specific REST Call, select **Type** as OAuth 2.0 and under **Configure New Token** section, set these values:
118
+
1. In Postman, select the **Authorization** tab of either a collection or a specific REST Call, select **Type** as OAuth 2.0 and under **Configure New Token** section, set these values:
@@ -134,9 +134,9 @@ You can get the Microsoft Entra access token by using your Entra account credent
134
134
135
135
1. Choose **Get New Access Token** at the bottom of the page.
136
136
137
-
1.You're asked for User credentials for sign-in.
137
+
1.Provide User credentials for sign-in.
138
138
139
-
1.You receive the token. Choose**Use Token.**
139
+
1.Once you receive the token, choose**Use Token.**
140
140
141
141
1. Ensure the token is in the **Authorization Header** of the REST call.
142
142
@@ -148,7 +148,7 @@ Open Postman, select the **workspace**, **collection**, and **environment** you
148
148
149
149
:::image type="content" source="media/postman/postman-create-new-request.png" alt-text="Screenshot showing creation of new request." lightbox="media/postman/postman-create-new-request.png":::
150
150
151
-
To perform health check on FHIR service, enter `{{fhirurl}}/health/check` in the GET request, and then choose **Send**. You should be able to see the `Status of FHIR service - HTTP Status` code response with 200 and OverallStatus as **Healthy** in response, which means your health check is successful.
151
+
To perform a health check on the FHIR service, enter `{{fhirurl}}/health/check` in the GET request, and then choose **Send**. You should be able to see the `Status of FHIR service - HTTP Status` code response with 200 and OverallStatus as **Healthy** in response, which means your health check is successful.
152
152
153
153
## Get the FHIR resource
154
154
@@ -162,11 +162,11 @@ Select **Bearer Token** as authorization type. Enter `{{bearerToken}}` in the **
162
162
163
163
After you obtain a Microsoft Entra access token, you can create or update the FHIR data. For example, you can create a new patient or update an existing patient.
164
164
165
-
Create a new request, change the method to **Post**, and then enter the value in the request section.
165
+
Create a new request, change the method to **Post**, and enter the value in the request section.
166
166
167
167
`{{fhirurl}}/Patient`
168
168
169
-
Select **Bearer Token** as the authorization type. Enter `{{bearerToken}}` in the **Token** section. Select the **Body** tab. Select the **raw** option and **JSON** as body text format. Copy and paste the text to the body section.
169
+
Select **Bearer Token** as the authorization type. Enter `{{bearerToken}}` in the **Token** section. Select the **Body** tab. Select the **raw** option and **JSON** as body text format. Copy and paste the following text to the body section.
170
170
171
171
172
172
```
@@ -211,7 +211,7 @@ Select **Bearer Token** as authorization type. Enter `{{bearerToken}}` in the **
211
211
212
212
-**Prefer**: `respond-async`
213
213
214
-
Select **Send**. You should notice a `202 Accepted` response. Select the **Headers** tab of the response and make a note of the value in the **Content-Location**. You can use the value to query the export job status.
214
+
Select **Send**. You should notice a `202 Accepted` response. Select the **Headers** tab of the response and make a note of the value in the **Content-Location**. You can use this value to query the export job status.
Copy file name to clipboardExpand all lines: articles/healthcare-apis/fhir/using-curl.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,22 +11,22 @@ ms.author: kesheth
11
11
12
12
# Access the Azure Health Data Services with cURL
13
13
14
-
In this article, you'll learn how to access Azure Health Data Services with cURL.
14
+
In this article, you learn how to access Azure Health Data Services with cURL.
15
15
16
16
## Prerequisites
17
17
18
18
### PowerShell
19
19
20
20
* An Azure account with an active subscription. [Create one for free](https://azure.microsoft.com/free/).
21
-
* If you want to run the code locally, install [PowerShell](/powershell/module/powershellget/) and [Azure Az PowerShell](/powershell/azure/install-azure-powershell).
21
+
* If you want to run the code locally, install [PowerShell](/powershell/module/powershellget/) and [Azure Az PowerShell module PowerShell](/powershell/azure/install-azure-powershell).
22
22
* Optionally, you can run the scripts in Visual Studio Code with the REST Client extension. For more information, see [Make a link to the REST Client doc](using-rest-client.md).
23
23
* Download and install [cURL](https://curl.se/download.html).
24
24
25
25
### CLI
26
26
27
27
* An Azure account with an active subscription. [Create one for free](https://azure.microsoft.com/free/).
28
28
* If you want to run the code locally, install [Azure CLI](/cli/azure/install-azure-cli).
29
-
* Optionally, install a Bash shell, such as Git Bash, which it's included in [Git for Windows](https://gitforwindows.org/).
29
+
* Optionally, install a Bash shell, such as Git Bash, which is included in [Git for Windows](https://gitforwindows.org/).
30
30
* Optionally, run the scripts in Visual Studio Code with the REST Client extension. For more information, see [Make a link to the REST Client doc](using-rest-client.md).
31
31
* Download and install [cURL](https://curl.se/download.html).
> In the scenarios where the FHIR service audience parameter is not mapped to the FHIR service endpoint url. The resource parameter value should be mapped to Audience value under FHIR Service Authentication blade.
81
+
> When the FHIR® service audience parameter is not mapped to the FHIR service endpoint url, the resource parameter value should be mapped to Audience value under the FHIR Service Authentication blade.
82
82
83
83
## Access data in the FHIR service
84
84
@@ -127,4 +127,4 @@ To learn about how to access Azure Health Data Services data using REST Client e
127
127
>[!div class="nextstepaction"]
128
128
>[Access Azure Health Data Services using REST Client](using-rest-client.md)
129
129
130
-
FHIR® is a registered trademark of [HL7](https://hl7.org/fhir/) and is used with the permission of HL7.
Copy file name to clipboardExpand all lines: articles/healthcare-apis/fhir/using-rest-client.md
+13-12Lines changed: 13 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,28 +11,28 @@ ms.author: kesheth
11
11
12
12
# Accessing Azure Health Data Services using the REST Client Extension in Visual Studio Code
13
13
14
-
In this article, you'll learn how to access Azure Health Data Services using [REST Client extension in Visual Studio Code](https://marketplace.visualstudio.com/items?itemName=humao.rest-client).
14
+
In this article, you learn how to access Azure Health Data Services using [REST Client extension in Visual Studio Code](https://marketplace.visualstudio.com/items?itemName=humao.rest-client).
15
15
16
16
## Install REST Client extension
17
17
18
18
Select the Extensions icon on the left side panel of your Visual Studio Code, and search for "REST Client". Find the [REST Client extension](https://marketplace.visualstudio.com/items?itemName=humao.rest-client) and install.
Create a new file in Visual Studio Code. Enter a `GET` request command line in the file, and save it as `test.http`. The file suffix `.http` automatically activates the REST Client environment. Select `Send Request` to get the metadata.
> Before calling the FHIR server REST API (other than getting the metadata), you must complete [application registration](../register-application.md). Make a note of your Azure **tenant ID**, **client ID**, **client secret** and the **service URL**.
31
+
> Before calling the FHIR® server REST API (other than getting the metadata), you must complete [application registration](../register-application.md). Make a note of your Azure **tenant ID**, **client ID**, **client secret** and the **service URL**.
32
32
33
33
While you can use values such as the client ID directly in calls to the REST API, it's a good practice that you define a few variables for these values and use the variables instead.
34
34
35
-
In your `test.http` file, include the following information obtained from registering your application:
35
+
In your `test.http` file, include the following information obtained from registering your application.
36
36
37
37
```
38
38
### REST Client
@@ -46,7 +46,7 @@ In your `test.http` file, include the following information obtained from regist
46
46
47
47
## Get Microsoft Entra access token
48
48
49
-
After including the information below in your `test.http` file, hit `Send Request`. You'll see an HTTP response that contains your access token.
49
+
After including the following information in your `test.http` file, hit `Send Request`. You'll see an HTTP response that contains your access token.
50
50
51
51
The line starting with `@name` contains a variable that captures the HTTP response containing the access token. The variable, `@token`, is used to store the access token.
> In the scenarios where the FHIR service audience parameter is not mapped to the FHIR service endpoint url. The resource parameter value should be mapped to Audience value under FHIR Service Authentication blade.
75
+
> When the FHIR service audience parameter is not mapped to the FHIR service endpoint url, the resource parameter value should be mapped to the Audience value under the FHIR Service Authentication blade.
76
76
77
-
## `GET` FHIR Patient data
77
+
## Get FHIR Patient data
78
78
79
-
You can now get a list of patients or a specific patient with the `GET` request. The line with `Authorization` is the header info for the `GET` request. You can also send `PUT` or `POST` requests to create/update FHIR resources.
79
+
You can now get a list of patients or a specific patient with the `GET` request. The line with `Authorization` is the header info for the `GET` request. You can also send `PUT` or `POST` requests to create and update FHIR resources.
80
80
81
81
```
82
82
### GET Patient
@@ -98,19 +98,20 @@ You can run PowerShell or CLI scripts within Visual Studio Code. Press `CTRL` an
98
98
99
99
## Troubleshooting
100
100
101
-
If you're unable to get the metadata, which doesn't require access token based on the HL7 specification, check that your FHIR server is running properly.
101
+
If you're unable to get the metadata (which doesn't require access token based on the HL7 specification) check that your FHIR server is running properly.
102
102
103
103
If you're unable to get an access token, make sure that the client application is registered properly and you're using the correct values from the application registration step.
104
104
105
105
If you're unable to get data from the FHIR server, make sure that the client application (or the service principal) has been granted access permissions such as "FHIR Data Contributor" to the FHIR server.
106
106
107
107
## Next steps
108
108
109
-
In this article, you learned how to access Azure Health Data Services data using the using the REST Client extension in Visual Studio Code.
109
+
In this article, you learned how to access Azure Health Data Services data using the REST Client extension in Visual Studio Code.
110
110
111
111
To learn about how to validate FHIR resources against profiles in Azure Health Data Services, see
112
112
113
113
>[!div class="nextstepaction"]
114
114
>[Validate FHIR resources against profiles in Azure Health Data Services](validation-against-profiles.md)
115
115
116
-
FHIR® is a registered trademark of [HL7](https://hl7.org/fhir/) and is used with the permission of HL7.
0 commit comments