Push and pull

Pull a locale as a file

Download one locale in a file format.

GET
/v1/pull

Download one locale in a file format. The body is the file itself, not JSON. An empty locale is served as a valid empty file, so read X-Entry-Count before you overwrite a file on disk. Send the ETag back as If-None-Match to get 304 when nothing changed; the count headers are sent on the 304 too.

Authorization

deployToken
headerAuthorizationBearer <token>

A project deploy token, minted in the console under Settings, Developer, API tokens. Send the whole value, including the numeric prefix before the |. A token carries a set of abilities (push, pull, manage, read, write) and each operation requires one of them. Tokens do not inherit from each other: a manage token cannot read the glossary unless it also has read.

Query Parameters

format*string

A file format transglot reads and writes.

Value in"json_flat""json_nested""android_xml""ios_strings""ios_stringsdict""flutter_arb""laravel_php""laravel_json""xliff_12""ios_xcstrings""gettext_po""yaml""csv""xlsx""xliff_20""java_properties""resx""markdown""unity_csv""unreal_po"
locale*string
Lengthlength <= 35
min_state?string

Leave out values below this state. human_edited keeps edited and reviewed values and leaves out Glossa drafts; reviewed keeps only approved values. Omit to include everything.

Value in"human_edited""reviewed"

Header Parameters

If-None-Match?string

An ETag from an earlier response. When it still matches, the answer is 304 with no body.

Response Body

The file. Content-Type follows the format, for example application/json for json_flat.

response?fileapplication/octet-stream
Formatbinary
curl -X GET 'https://api.transglot.ai/v1/pull?format=json_flat&locale=string'
"{\"checkout.submit\":\"Payer maintenant\"}"