nerdexam
MicrosoftMicrosoft

AZ-204 · Question #377

AZ-204 Question #377: Real Exam Question with Answer & Explanation

The set-variable, cache-lookup-value, and cache-store-value policies must all be placed in the Inbound section because they handle request processing before the backend is called - extracting the JWT user identity, checking for a cached response, and storing the result for future

Submitted by manish99· Mar 30, 2026Implement API Management policies and caching strategies in Azure - AZ-204 / Azure Developer Associate: Implement Azure API Management

Question

Drag and Drop Question Contoso, Ltd. provides an API to customers by using Azure API Management (APIM). The API authorizes users with a JWT token. You must implement response caching for the APIM gateway. The caching mechanism must detect the user ID of the client that accesses data for a given location and cache the response for that user ID. You need to add the following policies to the policies file: - a set-variable policy to store the detected user identity - a cache-lookup-value policy - a cache-store-value policy - a find-and-replace policy to update the response body with the user profile information To which policy section should you add the policies? To answer, drag the appropriate sections to the correct policies. Each section may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content. NOTE: Each correct selection is worth one point. Answer:

Explanation

The set-variable, cache-lookup-value, and cache-store-value policies must all be placed in the Inbound section because they handle request processing before the backend is called - extracting the JWT user identity, checking for a cached response, and storing the result for future requests all happen as part of request handling. The find-and-replace policy belongs in the Outbound section because it modifies the response body after the backend has returned a result, enriching it with user profile information before sending it to the client.

Topics

#Azure API Management#APIM Policies#Response Caching#JWT Authorization

Community Discussion

No community discussion yet for this question.

Full AZ-204 PracticeBrowse All AZ-204 Questions