Translation admin API Resource

Abstract class for REST webservices

POST /admin/translation/import

Import selected translations for language specified in fileName from uploadFile - language is taken from fileName prefix getFirst, if it's not matched it's taken from hidden "Language" sheet in file

Try it out!

Request Parameters
name type description default constraints
activities query   boolean
activitymessages query   boolean
dictionaries query if true, dictionaries translations are imported   boolean
errorcodes query if true, errorCodes translations are imported   boolean
fields query if true, fields translations are imported   boolean
legendtexts query if true, legendTexts translations are imported   boolean
objectclasses query if true, objectClasses translations are imported   boolean
units query if true, units units are imported   boolean
Request Body
media type data type description
multipart/form-data (custom) request with upload file and selected translations in queryString, if all translation flags are false, all translations are imported
Response Body
media type data type description
application/json object (JSON) JSON response with detailed import report

Example of response:

{"list":[{"errorMessage":"No Translations found for this type in import file","errorCodeNumber":10919,"errorCode":"NoTranslationsError","errorContext":"errorcodes Translations Import","errorLevel":"Critical"},{"errorMessage":"Successfully updated ReferenceValue Contract translation with Kontrakt2 for contract","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"objectclasses Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue inch translation with cal for 1","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue foot translation with stopa for 2","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue yard translation with jarddd for 3","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue mile translation with mila for 4","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue centimeter translation with centymetr for 6","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue meter translation with metr for 7","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"Successfully updated ReferenceValue kilometer translation with kilometr for 8","errorCodeNumber":10916,"errorCode":"TranslationUpdateSuccessful","errorContext":"units Translations Import","errorLevel":"Info"},{"errorMessage":"No Translations found for this type in import file","errorCodeNumber":10919,"errorCode":"NoTranslationsError","errorContext":"fields Translations Import","errorLevel":"Critical"},{"errorMessage":"No Translations found for this type in import file","errorCodeNumber":10919,"errorCode":"NoTranslationsError","errorContext":"dictionaries Translations Import","errorLevel":"Critical"}],"success":true}

GET /admin/translation/json/{labelType}

Try it out!

Request Parameters
name type description default constraints
labelType path    
Response Body
media type data type description
application/json object (JSON)

GET /admin/translation/export/xls/{langId}

Get xls file with selected translations for language. If all translation flags are false, all translations are exported

Try it out!

Request Parameters
name type description default constraints
langId path Language Id   int
activities query   boolean
activitymessages query   boolean
dictionaries query if true, dictionaries translations are exported   boolean
errorcodes query if true, errorCodes translations are exported   boolean
fields query if true, fields translations are exported   boolean
legendtexts query if true, legendTexts translations are exported   boolean
objectclasses query if true, objectClasses translations are exported   boolean
units query if true, units units are exported   boolean
Response Body
media type data type description
application/vnd.ms-excel object xls file with selected translations for given language

POST /admin/translation/export/xls/{langId}

Try it out!

Request Parameters
name type description default constraints
langId path    
Response Body
media type data type description
application/json object (JSON)

PUT /admin/translation/json/{labelType}/{langId}

Try it out!

Request Parameters
name type description default constraints
labelType path    
langId path   int
Request Body
media type data type
application/json HdcLabelTranslationsTO (JSON)
Response Body
media type data type description
application/json HdcLabelTranslationsTO (JSON)