The translations endpoint provides operations to view the custom string translations for a specified language and to update localized strings for specified user interface elements. The GET /environments/{{envID}}/translations/{{languageCode}}
operation returns the translated strings for the specified language code (for example, the language code fr
returns the French custom string translations).
The response for a GET
request returns numerous embedded resources that identify UI strings in English and their associated localized string content in the specified language. The following sample shows the localized string (in French) for the cancel button on the flow-ui interface page.
"_embedded": {
"translations": [
{
"id": "3e90224d-9036-4d78-badb-65e98f4fc944",
"key": "flow-ui.button.cancel",
"shortKey": "button.cancel",
"referenceText": "Cancel",
"translatedText": "Annuler"
},
PingOne includes translated string catalogs for the following languages:
Code | Language |
---|---|
de |
German |
en |
English |
es |
Spanish |
fr |
French |
fr-CA |
French (Canadian) |
it |
Italian |
ja |
Japanese |
ko |
Korean |
nl |
Dutch |
pt |
Portuguese |
ru |
Russian |
th |
Thai |
tr |
Turkish |
zh |
Chinese |
For GET
requests, the data model returns the following information about the specified language’s localized strings.
Property | Description |
---|---|
translations.id |
A string that specifies the translation ID for a specific string. |
translations.key |
A string that specifies the page and name of the interface element to be localized (for example, flow-ui.button.cancel ). |
translations.shortKey |
A string that specifies the interace element only (for example, button.cancel ). |
translations.referenceText |
A string that specifies the English string text associated with the interface element. |
translations.translatedText |
A string that specifies the translated string text associated with the interface element. |
For PUT
requests, the following properties are required in the request body.
Property | Description |
---|---|
key |
A string that specifies the page and name of the interface element to be localized (for example, flow-ui.button.cancel ). |
translatedText |
A string that specifies the translated string text associated with the interface element. |
Code | Message |
---|---|
200 | Successful operation. |
400 | The request could not be completed. |
401 | You do not have access to this resource. |
403 | You do not have permissions or are not licensed to make this request. |
404 | The requested resource was not found. |