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
In this tutorial, you'll learn about configuring common [policies](api-management-howto-policies.md) to transform your API. You might want to transform your API so it doesn't reveal private backend info. Transforming an API can help you hide the technology stack info that's running in the backend, or hide the original URLs that appear in the body of the API's HTTP response.
17
+
In this tutorial, you learn about configuring common [policies](api-management-howto-policies.md) to transform your API. You might want to transform your API so it doesn't reveal private backend info. Transforming an API can help you hide the technology stack info that's running in the backend, or hide the original URLs that appear in the body of the API's HTTP response.
18
18
19
19
This tutorial also explains how to add protection to your backend API by configuring a rate limit policy, so that the API isn't overused by developers. For more policy options, see [API Management policies](api-management-policies.md).
20
20
@@ -114,7 +114,7 @@ In this example, you use the policy code editor to add the policy XML snippet di
114
114
115
115
1. Position the cursor inside the **`<outbound>`** element on a blank line. Then select **Show snippets** at the top-right corner of the screen.
116
116
117
-
:::image type="content" source="media/transform-api/show-snippets-1.png" alt-text="Screenshot of selecting show snippets in policy editor in the portal.":::
117
+
:::image type="content" source="media/transform-api/show-snippets-1.png" alt-text="Screenshot of selecting show snippets in outbound policy editor in the portal.":::
118
118
119
119
1. In the right window, under **Transformation policies**, select **Mask URLs in content**.
120
120
@@ -131,17 +131,17 @@ This section shows how to add protection to your backend API by configuring rate
1. In the **Inbound processing** section, select the code editor (**</>**) icon.
133
133
134
-
:::image type="content" source="media/transform-api/inbound-policy-code.png" alt-text="Navigate to inbound policy":::
134
+
:::image type="content" source="media/transform-api/inbound-policy-code.png" alt-text="Screenshot of navigating to inbound policy code editor in the portal.":::
135
135
136
136
1. Position the cursor inside the **`<inbound>`** element on a blank line. Then, select **Show snippets** at the top-right corner of the screen.
:::image type="content" source="media/transform-api/show-snippets-2.png" alt-text="Screenshot of selecting show snippets in inbound policy editor in the portal.":::
139
139
140
140
1. In the right window, under **Access restriction policies**, select **Limit call rate per key**.
141
141
142
142
The **`<rate-limit-by-key />`** element is added at the cursor.
143
143
144
-
:::image type="content" source="media/transform-api/limit-call-rate-per-key.png" alt-text="Select limit call rate per key":::
144
+
:::image type="content" source="media/transform-api/limit-call-rate-per-key.png" alt-text="Screenshot of inserting limit call rate per key policy in the pportal":::
145
145
146
146
1. Modify your **`<rate-limit-by-key />`** code in the **`<inbound>`** element to the following code. Then select **Save**.
147
147
@@ -181,9 +181,9 @@ The rest of this section tests policy transformations that you set in this artic
181
181
1. Select **Demo Conference API** > **Test**.
182
182
1. Select the **GetSpeakers** operation and select **Send**.
:::image type="content" source="media/transform-api/test-replaced-url.png" alt-text="Screenshot showing replaced URLs in the portal.":::
196
196
197
197
### Test the rate limit (throttling)
198
198
@@ -201,7 +201,7 @@ The rest of this section tests policy transformations that you set in this artic
201
201
202
202
After sending the request three times, you get the **429 Too Many Requests** response.
203
203
204
-
:::image type="content" source="media/transform-api/test-throttling-new.png" alt-text="Too many requests":::
204
+
:::image type="content" source="media/transform-api/test-throttling-new.png" alt-text="Screenshot showing Too Many Requests in the response in the portal.":::
205
205
206
206
1. Wait for 15 seconds or more and then select **Send** again. This time you should get a **200 OK** response.
0 commit comments