API: Import translations

Last updated: October 05, 2023Author: Jakub Pomykała

Import translations from a file. Check 'Import options' section to learn more about possibilities. Using this endpoint requires authorization.

Endpoint

POST
https://api.simplelocalize.io
/api/v2/import?uploadFormat=

Sample requests

Import all translations from one file

curl
  --request POST \
  --url 'https://api.simplelocalize.io/api/v2/import?uploadFormat=multi-language-json' \
  --header 'x-simplelocalize-token: <API_KEY>' \
  --form file=@/path/to/your/all-translations.json

Learn more about multi-language-json.

Import translations for one language

curl
  --request POST \
  --url 'https://api.simplelocalize.io/api/v2/import?uploadFormat=single-language-json&languageKey=en' \
  --header 'x-simplelocalize-token: <API_KEY>' \
  --form file=@/path/to/your/english-translations.json

Learn more about single-language-json.

Query parameters

ParameterDescription
uploadFormatSee all available upload formats
languageKeySet language key if you want to import translations for only one language
importOptionsSee all available import options

Successful response

{
  "numberOfKeysFound": 2137,
  "numberOfUniqueKeysFound": 1004,
  "foundLanguages": [
      {
        "key": "pl",
        "name": "Polish"
      }
  ]
}