Localization
Localization calls use x-blocks-key and the project key in the query string.
List project languages
GET /localization/v4/Language/Gets?ProjectKey={projectKey}
curl --get 'https://api.seliseblocks.com/localization/v4/Language/Gets' \
-H 'x-blocks-key: YOUR_PROJECT_KEY' \
--data-urlencode 'ProjectKey=YOUR_PROJECT_KEY'
The response may be an array or expose the array through items or data. The example recognizes languageCode, code, or culture as the locale identifier.
Get a UI localization module
GET /localization/v4/Key/GetUilmFile
| Query parameter | Required | Description |
|---|---|---|
Language | Yes | Language code, such as en |
ModuleName | Yes | UI module name; the example uses construct |
ProjectKey | Yes | Blocks project key |
curl --get 'https://api.seliseblocks.com/localization/v4/Key/GetUilmFile' \
-H 'x-blocks-key: YOUR_PROJECT_KEY' \
--data-urlencode 'Language=en' \
--data-urlencode 'ModuleName=construct' \
--data-urlencode 'ProjectKey=YOUR_PROJECT_KEY'
The response is a key/value resource object that can be loaded into the selected i18n module.