Closed micander closed 3 months ago
It appears that PDF it is not a supported format in the synchronous API after all: https://learn.microsoft.com/en-us/azure/ai-services/translator/document-translation/overview#synchronous-supported-document-formats
So this ticket becomes a report that the link to the list of supported formats does not go to the correct page. See here: https://learn.microsoft.com/en-us/azure/ai-services/translator/document-translation/reference/synchronous-rest-api-guide#request-body
The link "supported document formats" links to https://learn.microsoft.com/en-us/azure/ai-services/translator/language-support but it should link the the link above. I was not able to find this page on my own despite searching. This mis-link should be fixed.
Also, is it possible to know if PDF support is a planned feature for the synchronous API?
Thanks
@micander Thanks for your feedback! We will investigate and update as appropriate.
@micander Thank you for bringing this to our attention. I've delegated this to content author @laujan, who will review it and offer their insightful opinions.
Hello, I am seeking to use the synchronous document translation API to perform PDF translation. I am unable to complete my API requests because the API always responds with
{"code":"InvalidFormat","message":"The format parameter is not valid."}
. I have tried various source and destination languages and various PDF files, but have had no success. I can translate other formats successfully such as DOCX.The API documentation doesn't explicitly confirm that the synchronous API supports PDF translation. Is the feature unimplemented, or just currently broken? I have seen another person asking about the same issue on the community support forum a month ago. Thank you.
Example API call:
curl -i -X POST "https://eelec-translation-uswest.cognitiveservices.azure.com/translator/document:translate?sourceLanguage=en&targetLanguage=hi&api-version=2023-11-01-preview" -H "Ocp-Apim-Subscription-Key:<omitted>" -H "X-ClientTraceId:pdf-translation-issue-b4e3ae21" -F "document=@blank.pdf;type=application/pdf" -o "out.pdf"
Response: