Which Headers Does Azure Translator REST API Require?
You have an Azure subscription that contains a multi-service Azure Cognitive Services Translator resource named Translator1. You are building an app that will translate text and documents by using Translator1. You need to create the REST API request for the app. Which headers should you include in the request?
Community Votes
100% of anonymous learners picked answer D. Votes are pick records left by other test-takers — they are not the verified answer.
Community Insight
The question tests header requirements for a multi-service Translator resource; the trap is assuming only the subscription key or generic HTTP headers are sufficient.
Azure Cognitive Services Translator requires authentication and content negotiation headers for REST calls. This page confirms that a multi-service Translator resource needs the subscription key, subscription region, and content type, not generic HTTP or optional tracing headers.
A frequent wrong choice is B, because candidates remember the subscription key and client trace ID but forget that a multi-service resource also requires the subscription region and the Content-Type header.
Community Discussion (8 comments)
Comments & Corrections
No comments yet — spotted an error or have a note? Share it below.
Expert Analysis
Why the Answer Is Correct
Option D is correct because the Translator v3 REST API for a multi-service Cognitive Services resource authenticates with bothOcp-Apim-Subscription-Key and Ocp-Apim-Subscription-Region, and the translate operation also requires Content-Type: application/json. The subscription key proves access to Translator1, while the region header tells the multi-service endpoint where the resource is deployed. Without the region, a multi-service key cannot be routed reliably. The Content-Type header is mandatory when sending the JSON body for text or document translation. This combination matches the required request headers for Translator1.Why the Other Options Are Wrong
Option A lists generic HTTP or CORS-style headers such as access control request, content type, and content length, but it omits authentication. Option B includes the subscription key and a client trace ID; the trace ID is optional diagnostics and does not replace the required region or content type headers. Option C names a resource ID and content language, neither of which authenticates a Translator request; content language is typically a query parameter or body field. Therefore A, B, and C all miss at least one header that Translator1 requires.Community Comment Notes
As audlindr noted, Microsoft documentation states the content type is required and that with a multi-service secret key "you must include two authentication headers with your request." Murtuza likewise listed the subscription key, subscription region, and content type as the needed headers. takaimomoGcup put it as "the subscription key, the subscription region, and the content type." kay1101 pointed to the Translator quickstart headers and selected D. The consistent community vote for D reflects the documented requirement for multi-service Translator resources.Official Reference
Exam Strategy
For multi-service Translator resources, always include both Ocp-Apim-Subscription-Key and Ocp-Apim-Subscription-Region alongside Content-Type: application/json for JSON requests. Single-service Translator resources may not need the region header, which is why the multi-service detail in the question matters.
Frequently Asked Questions
Why does a multi-service Translator resource need the subscription region header?
Because a multi-service key can be used with several services and regions, Translator needs Ocp-Apim-Subscription-Region to route the request to Translator1's deployment.
Is Content-Type required for Azure Translator REST text translation?
Yes. The Translator v3 translate operation expects Content-Type: application/json when you send a JSON request body, in addition to the subscription key and region headers.