translations.api

SQLite-backed translations API. Use JSON endpoints from an external UI or service.

Bearer token: configured

Import

Import is intentionally outside the server. Create or place translations.sqlite first, then run the one-off importer from this directory:

go run import_translations.go

Authentication

All endpoints require this header:

Authorization: Bearer <TRANSLATIONS_BEARER_TOKEN>

Endpoints

GET/translations/

Returns translations. Optional query params:

GET /translations/?limit=50&search=invoice&complete=false

POST/translations/sync/

Used by Link cron. Sends the last remote sync timestamp and returns every row newer than since.

{
  "since": 1778845200000,
  "items": [{
    "key": "button.save",
    "source_lang": "en",
    "en": "Save",
    "sk": "",
    "ge": "",
    "it": "",
    "hu": "",
    "ru": "",
    "cz": "",
    "ua": ""
  }]
}

Persist sync_time from the response and use it as the next since.

POST/translations/update/

Used by Link admin for direct edits of existing rows.

{
  "item": {
    "key": "button.save",
    "source_lang": "en",
    "en": "Save",
    "sk": "Ulozit",
    "ge": "",
    "it": "",
    "hu": "",
    "ru": "",
    "cz": "",
    "ua": ""
  }
}

Languages

en, sk, ge, it, hu, ru, cz, ua