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
Copy file name to clipboardExpand all lines: articles/azure-functions/openapi-apim-integrate-visual-studio.md
+13-9Lines changed: 13 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -183,39 +183,43 @@ Before you can publish your project, you must have a function app in your Azure
183
183
| **API name** | TurbineRepair | Name for the API. |
184
184
| **Subscription name** | Your subscription | The Azure subscription to use. Accept this subscription or select a new one from the drop-down list. |
185
185
| **Resource group** | Name of your resource group | Select the same resource group as your function app from the drop-down list. |
186
-
| **API Management service** | New instance | Select **New** to create a new API Management instance in the serverless tier. |
186
+
| **API Management service** | New instance | Select **New** to create a new API Management instance in the same location in the serverless tier. Select **OK** to create the instance. |
187
187
188
188
:::image type="content" source="media/openapi-apim-integrate-vs/create-api-management-api.png" alt-text="Create API Management instance with API":::
189
189
190
190
1. Select **Create** to create the API Management instance with the TurbineRepair API from the function integration.
191
191
192
-
1. select **Finish**, verify the Publish page says **Ready to publish**, and then select **Publish** to deploy the package containing your project files to your new function app in Azure.
192
+
1. Select **Finish** and after the publish profile creation process completes, select **Close**.
193
+
194
+
1. Verify the Publish page now says **Ready to publish**, and then select **Publish** to deploy the package containing your project files to your new function app in Azure.
193
195
194
196
After the deployment completes, the root URL of the function app in Azure is shown in the **Publish** tab.
195
197
196
198
## Get the function access key
197
199
198
200
1. In the **Publish** tab, select the ellipses (**...**) next to **Hosting** and select **Open in Azure portal**. The function app you created is opened in the Azure portal in your default browser.
199
201
200
-
1. Under **Functions**, select **Functions** > **TurbineRepair** then select **Function keys**.
202
+
1. Under **Functions** on the **Overview page**, select > **Turbine** then select **Function keys**.
201
203
202
204
:::image type="content" source="media/openapi-apim-integrate-vs/get-function-keys.png" alt-text="Get an access key for the TurbineRepair function":::
203
205
204
-
1. Under **Function keys**, select **default** and copy the **value**. You can now set this key in API Management so that it can access the function endpoint.
206
+
1. Under **Function keys**, select the *copy to clipboard* icon next to the **default** key. You can now set this key you copied in API Management so that it can access the function endpoint.
205
207
206
208
## Configure API Management
207
209
208
-
1. In the **Publish** tab, select the ellipses (**...**) next to **Hosting** and select **Open API in Azure portal**. The API Management instance you created is opened in the Azure portal in your default browser. This API Management instance is already linked to your function app.
210
+
1. In the function app page, expand **API** and select **API Management**.
209
211
210
-
1. Under **APIs**, select **OpenAPI Document on Azure Functions** > **POST Run**, then under **Inbound processing** select **Add policy**.
212
+
1. If the function app isn't already connected to the new API Management instance, selectit under **API Management**, select**API**>**OpenAPI Document on Azure Functions**, make sure **Import functions** is checked, and select**Link API**. Make sure that only **Turbine** is selected for import and then**Select**.
211
213
212
-
:::image type="content" source="media/openapi-apim-integrate-vs/apim-add-policy.png" alt-text="Add an inbound policy to the API":::
214
+
1. Select **Go to API Management** at the top of the page, and in the API Management instance, expand **APIs**.
215
+
216
+
1. Under **APIs**>**All APIs**, select**OpenAPI Document on Azure Functions**>**POST Run**, then under **Inbound processing**select**Add policy**>**Set query parameters**.
213
217
214
218
1. Below **Inbound processing**, in**Set query parameters**, type`code`for**Name**, select **+Value**, pastein the copied functionkey, and select**Save**. API Management includes the functionkey when it passes calls through to the functionendpoint.
215
219
216
220
:::image type="content" source="media/openapi-apim-integrate-vs/inbound-processing-rule.png" alt-text="Provide Function credentials to the API inbound processing rule":::
217
221
218
-
Now that the function key is set, you can call the API to verify that it works when hosted in Azure.
222
+
Now that the functionkey is set, you can call the `turbine`API endpoint to verify that it works when hosted in Azure.
219
223
220
224
## Verify the API in Azure
221
225
@@ -236,7 +240,7 @@ Now that the function key is set, you can call the API to verify that it works w
236
240
237
241
## Download the OpenAPI definition
238
242
239
-
If your API works as expected, you can download the OpenAPI definition.
243
+
If your API works as expected, you can download the OpenAPI definitionfor the new hosted APIs from API Managment.
240
244
241
245
1. 1. Under **APIs**, select**OpenAPI Document on Azure Functions**, selectthe ellipses (**...**), and select**Export**.
0 commit comments