API Documentation

Note This page is available only in English

Getting an API token

Go to Project Settings > General Settings to get project's API token. Only project creators have access to the API token.

Setting a Webhook

Go to Project Settings > General Settings to set a webhook. Webhook will get a POST request with updates info when translations are updated and language files have to be rebuilt. Webhook should answer with with a 200 http status code.
Check HTTP_X_LOCALIZATION header to validate incoming requests. It will contain a HMAC-sha256 hash, where your project API Token is used as a message and your webhook url address is used as a key.
[{"type":"translation_update","language":"19","date":1723746786,"string_id":"1428","category_id":"182"}]

Making requests

Use this url for making API requests:
Replace {api_token} with API token for your project and {method_name} with one of the following methods found below.
The response contains a JSON object, which always has a Boolean field 'ok' and may have an optional String field 'description' with a human-readable description of the result. If 'ok' equals True, the request was successful and the result of the query can be found in the 'result' field. In case of an unsuccessful request, 'ok' equals false and theerror is explained in the 'description'.

Types

Label

This object represents a label
Field Type Required Description
label_id String Yes md5 string representing an id of a label obtained from getLabels method
label_value Integer or String Yes Value of the label. Can be 0 or 1 for checkbox or String for input and select labels

Methods

Get languages

Use this method to get project languages list
{"ok":"true","result":[{"id":"17","name":"English","localized_name":"English","code":"en","translated_percent":"0","translated_strings":"0","emoji":"🇬🇧"},{"id":"18","name":"Ukrainian","localized_name":"Українська мова","code":"uk","translated_percent":"0","translated_strings":"0","emoji":"🇺🇦"}]}

Get categories

Use this method to get project categories list
{"ok":"true","result":{"3":{"id":"3","parent_id":"2","name":"Header","description":"","strings":"3"},"2":{"id":"2","parent_id":"0","name":"Website","description":"","strings":"3"},"4":{"id":"4","parent_id":"3","name":"Menu","description":"","strings":"3"}}}

Get labels

Use this method to get project labels list
{"ok":"true","result":[{"label_name":"Checkbox Label 1","label_id":"980a32e552108631daaf0ee071d80fbd","type":"checkbox","default_value":1},{"label_name":"Checkbox Label 2","label_id":"548a3a61a58232fb0f34ef438f0035f9","type":"checkbox","default_value":0},{"label_name":"Select Label","label_id":"1915d8178fc1f289ec79f1021ed665b0","type":"select","options":[{"option_name":"Option 1","option_value":"option_1_value"},{"option_name":"Option 2","option_value":"option_2_value"}]},{"label_name":"Input Label","label_id":"3975342df1406e0c53af446255104472","type":"input","default_value":"Input value"}]}

Create a New Category

Use this method to create a new category. Returns a new category id on success
Parameter Type Required Description
name String Yes Name for the category. Must be unique in parent directory
parent_id Integer Optional id of parent category. Pass 0 or ignore to create a new category in the root directory
description String Optional Description for the category
{"ok":true,"result":6}

Create a New String

Use this method to create a new string with a default string translation. Returns a new string id and string key on success
Parameter Type Required Description
string_id Integer Optional id of the string. Must be unique for the project
category_id Integer Yes id of category
string_key String Yes String key (slug). Must be unique for a category
default_translation_language Integer Optional id of default translation language. Can be ignored if copy_translations_from is provided
default_translation_value String Optional Default translation text. Can be ignored if copy_translations_from is provided
copy_translations_from Integer Optional id of another string which translations will be copied to this string
string_context String Optional Notes about how this string is used in the app (e.g. "button label in the document editor toolbar", "error shown when login fails"). Visible to anyone working with this string — developers, translators, AI tools, support — and returned in API exports. Not shown to end users. Hard limit: 2500 characters; longer payloads are rejected with {"ok":"false","description":"string_context exceeds the 2500-character limit ..."}.
labels Mixed Optional Labels to attach to the new string. Any of the following shapes is accepted:
  • Form-encoded map (recommended): labels[<label_id>]=<value> — repeat for every label you want to set explicitly.
  • JSON list of labels: labels=[{"label_id":"...","label_value":"1"}]
  • JSON map: labels={"<label_id>":"<value>"}
Any project label not listed in your request is automatically populated with its default_value from getLabels, matching the behaviour of the create-string form in the UI. Pass an explicit value to override the default.
{"ok":"true","result":{"string_id":80,"string_key":"test-key"}}

Delete a String

Use this method to delete a string and all of its translations, suggestions, labels and uploaded illustrations. Returns the deleted string_id on success.
Disabled by default. Because a leaked API token with this method enabled can wipe every string in the project, you must explicitly opt-in: go to Project Settings > API and webhook and tick "Allow deleteString via API". Calls to a project where the toggle is off return {"ok":"false","description":"API method 'deleteString' is disabled for this project. ..."}.
Parameter Type Required Description
string_id Integer Yes id of the string to delete (the string_id returned by createString or getTranslations)
{"ok":"true","result":{"string_id":80}}

Add a translation

Use this method to set the API bot's translation for a (string_id, language) pair. The call is idempotent — if the bot already has a translation for that pair, its value is updated in place; otherwise a new suggestion is created. Returns the translation id on success.
Parameter Type Required Description
string_id Integer Yes id of the string
translation_language Integer Yes id of the translation language
translation_value String Yes Translation text
approve Boolean Optional Pass 'true' to approve this translation immideatly. If string is already has approved translation for selected language, it will be disapproved
{"ok":true,"result":6}

Update a translation

Use this method to overwrite the value of an already-approved translation in place. The original author and approval state are preserved, so this is the right way to fix typos in published strings without disturbing attribution or suggestion history. Returns the updated translation id on success. If no approved translation exists for the given pair, returns ok:false — use addTranslation to create one.
Disabled by default. Because a leaked API token with this method enabled can silently rewrite every translation in the project, you must explicitly opt-in: go to Project Settings > API and webhook and tick "Allow updateTranslation via API". Calls to a project where the toggle is off return {"ok":"false","description":"API method 'updateTranslation' is disabled for this project. ..."}.
Parameter Type Required Description
string_id Integer Yes id of the string
translation_language Integer Yes id of the translation language
translation_value String Yes New translation text
{"ok":"true","result":35937}

Disapprove all translations of a string

Use this method to flip every approved translation of a string back to "suggestion" state (approve=0) across every language at once. Mirrors the "Disapprove all approved translations of this string" checkbox on the edit-string modal in the UI, but is not paired with an edit — so it operates on every language without exception. Nothing is deleted; the previous values stay in history as non-approved suggestions and can be re-approved later. Language builds are rebuilt for every affected language via the same webhook the UI uses. Returns the number of translations that were disapproved.
Disabled by default. Because a leaked API token with this method enabled can wipe every approved translation in the project, you must explicitly opt-in: go to Project Settings > API and webhook and tick "Allow disapproveAllTranslations via API". Calls to a project where the toggle is off return {"ok":"false","description":"API method 'disapproveAllTranslations' is disabled for this project. ..."}.
Parameter Type Required Description
string_id Integer Yes id of the string whose approved translations should be flipped back to "suggestion" state
{"ok":"true","result":{"string_id":80,"disapproved":4}}

Delete all suggestions of a string

Use this method to drop every non-approved suggestion of a string across every language. Mirrors the "Delete all suggested translations of this string" checkbox on the edit-string modal in the UI. Approved translations are untouched — to also remove the approved ones, call disapproveAllTranslations first (which converts approvals into suggestions), then call this method. Notifications and logs tied to the deleted suggestions are cleaned up the same way the UI does. Returns the number of suggestions that were deleted.
Disabled by default. Because a leaked API token with this method enabled can wipe every pending suggestion in the project, you must explicitly opt-in: go to Project Settings > API and webhook and tick "Allow deleteAllSuggestions via API". Calls to a project where the toggle is off return {"ok":"false","description":"API method 'deleteAllSuggestions' is disabled for this project. ..."}.
Parameter Type Required Description
string_id Integer Yes id of the string whose non-approved suggestions should be deleted
{"ok":"true","result":{"string_id":80,"deleted":7}}

Get strings Translations

Use this method to get string(s) translations for a selected language
Parameter Type Required Description
translation_language Integer Yes id of the translation language
category_id Integer Optional Pass a category_id to get all translations for strings in selected category
string_id Integer Optional Pass a string_id to get a translation for selected string
format Mixed Optional Pass a format to get a translation in one of the following formats: json (or 0) - Default JSON format, xml-android (or 1) - Android Strings XML, ios-strings (or 2) - iOS (.strings), json-clean (or 3) - React Clean JSON, php-array (or 4) - Laravel (PHP Array), arb (or 5) - Flutter (.arb), csv (or 6) - Excel (.csv), po (or 7) - Gettext (.po), properties (or 8) - Java Properties (.properties)
{"ok":"true","result":[{"string_id":"22","string_key":"test-kry","category_id":"158","translation":"Test","string_context":"button label in document editor toolbar","labels":[{"name":"Label Name 1","value":"1"},{"name":"Label Name 2","value":"0"}]}]}