You imported an OpenAPI definition into APIM that includes example responses. The backend is not yet available, but frontend teams must be able to call GET /orders and receive a 200 response with the documented example payload without invoking any backend. What should you configure?
Choose an answer
Tap an option to check your answer.
Correct answer: Add a mock-response policy at the operation scope for GET /orders and configure it to return the 200 example..
Why this is the answer
The mock-response policy is designed specifically for this scenario. It allows API Management to return example responses defined in the OpenAPI specification without forwarding the request to a backend. By applying it at the operation scope for GET /orders and specifying the 200 example, you enable frontend teams to test against a realistic response even when the backend is unavailable. The return-response policy is for constructing custom responses, not directly leveraging OpenAPI examples. Removing the backend and relying on rewrite-uri to serve a static JSON payload would require manually maintaining the JSON, which defeats the purpose of using the OpenAPI example. Configuring set-backend-service with a default backend URL would still involve an external service, which is not the goal when the backend is unavailable and you want to use an embedded example.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed