Azure API Management · AZ-204: Developing Solutions for Microsoft Azure Connect to and Consume Azure and Third-party Services

An Azure API Management API has a backend service configured at https://api.contoso.com. One operation must instead send requests to https://orders.c…

Practice question from Azure API Management (AZ-204: Developing Solutions for Microsoft Azure Connect to and Consume Azure and Third-party Services), with the correct answer and a step-by-step solution.

easy · MCQ · Q-09FDB3

An Azure API Management API has a backend service configured at https://api.contoso.com. One operation must instead send requests to https://orders.contoso.com/v2/orders without changing the backend used by other operations. Which policy should be added to that operation's inbound processing?

  1. A.set-backend-service with the service-url set to https://orders.contoso.com/v2Correct answer
  2. B.rewrite-uri with the template set to https://orders.contoso.com/v2
  3. C.set-header with the header name Host and value orders.contoso.com
  4. D.set-method with the method set to POST

Solution

The set-backend-service policy changes the backend URL for the request. rewrite-uri changes only the path and query portion of the URI, while setting a Host header does not reliably change the APIM backend destination.

More from Azure API Management

All of Azure API Management

Practise more Connect to and Consume Azure and Third-party Services

Sign up free for adaptive practice on this chapter, with instant feedback and hints on every question.

Start practising free

Free to start · No credit card needed