Latest supported version: Sitefinity CMS 14.1.7800.0
Documentation articles: Custom translation connector
IMPORTANT: This repository may not be compatible with the latest or your current Sitefinity CMS version. If you want to use the repository with a specific Sitefinity CMS version, either upgrade the code from this repository or your Sitefinity CMS project to ensure compatibility.
The dev team monitors the repository. You can create a GitHub issue to submit feedback or report bugs. Or make a pull request to submit project enhancements or compatibility changes that support new Sitefinity CMS versions.
In addition to the built-in Translation module connectors, you can implement your own translation connector with custom logic to serve your requirements.
This repo contains a translation connector to work with the Microsoft Azure Translator V3 API service.
- You must have a Sitefinity CMS license.
- Your setup must comply with the system requirements. For more information, see the System requirements for the respective Sitefinity CMS version.
- You must sign up for Microsoft Translator Text API V3 service in Microsoft Azure. For more information, see How to sign up for Translator. Then you can use one of the generated API keys to configure the connector in Sitefinity CMS. All of the available tiers are supported.
Add the Microsoft translation connector sample project to your solution. To do this, perform the following:
- Open your Sitefinity CMS solution in Visual Studio.
- Add
Progress.Sitefinity.Translations.MicrosoftMachineTranslatorConnector
project to the same solution. - Ensure
Telerik.Sitefinity.Translations
nuget package is installed in Progress.Sitefinity.Translations.MicrosoftMachineTranslatorConnector. - In SitefinityWebApp, add a reference to the Progress.Sitefinity.Translations.MicrosoftMachineTranslatorConnector project.
- Build your solution.
Using one of the generated API keys, configure the connector in the following way:
-
In Sitefinity CMS backend, navigate to Administration » Settings » Advanced.
-
In the treeview on the left, expand Translations » Connectors » MicrosoftMachineTranslatorConnector » Parameters.
-
Set the apiKey parameter to the API key provided by Microsoft Azure.
-
Set the baseURL to one of the URL’s supported by Microsoft Azure API. For more information, see Microsoft Azure documentation » Translator v3.0 » Base URL's. If you do not set the baseURL parameter, the system takes the Global (non-regional) base URL.
-
Set the region parameter to one of the regions, supported by Microsoft Azure API. If you have not changed the baseURL parameter from the default one, you do not need to configure the region parameter. For more information, see Microsoft Azure documentation » Authenticate requests to Azure Cognitive Services » Supported regions.
IMPORTANT: The Azure geography of the base URL must include the region that you have configured.
-
You may optionally configure any additional parameter of the Microsoft Translator service described in Translator 3.0: Translate. To do this, click queryString on the left. In the Value field on the right enter the parameters.
IMPORTANT: You format the string in the Value field using the query string format without the leading ? or & characters. You separate the translator parameters with &.
-
Navigate back to MicrosoftMachineTranslatorConnector.
-
Select Enabled and deselect Strip HTML tags.
-
Save your changes.
For more information for supported languages, see Language and region support for text and speech translation.