Help Center Import/Export
Exported JSON - Understanding the File Structure

Exported JSON - Understanding the File Structure

Last updated: a month ago
3 minute read
Yuliia Kovalchuk
Developer at SiteTran

ALL ARTICLES

Help Center

Exported JSON - Understanding the File Structure

Overview

The exported JSON file is an array of objects, where each object contains the original phrase along with its corresponding translations and optional metadata. This format is highly suitable for software or programmatic use.

JSON Structure

Here’s a description of each key that can appear in the JSON export:

  • phrase_id: (Number) A unique (SiteTran) identifier for each phrase.
  • source_term: (String) The original phrase in the source language.
  • phrase_key: (String, Optional) A unique key associated with the phrase.
  • tag_name: (String, Optional) The HTML tag (e.g., "div", "span") associated with the phrase.
  • attribute_name: (String, Optional) The attribute of the HTML element in which the phrase is located (e.g., "title", "placeholder").
  • translations: (Object) Contains key-value pairs representing translations for each selected language. The key is the language code (in ISO 639-1 format. If country code is included, it will conform to ISO 3166-1 Alpha-2 [e.g., es-MX]) and the value is the translated phrase.
  • translation_approved: (Object, Optional) Indicates whether the translation for each language is approved. Each key is a language code, and the corresponding value is "Y" (approved) or "N" (not approved).
  • translation_flagged: (Object, Optional) Indicates whether the translation requires additional attention. Each key is a language code, and the value is "Y" (flagged) or "N" (not flagged).
  • phrase_lang_create_dtime: (Object, Optional) The creation date and time of the translation for each language, formatted in ISO 8601. Each key is a language code, and the value is the timestamp.
  • translator_email: (Object, Optional) Contains the email address of that phrase’s translator. Each key is a language code, and the value is the translator's email address.
  • translator_name: (Object, Optional) Contains the name of that phrase’s translator. Each key is a language code, and the value is the translator's name.

Example

Here's an example of how an exported JSON object might look with some of the optional language-specific data included:


[
  {
    "phrase_id": 326507,
    "source_term": "Example phrase",
    "tag_name": "div",
    "attribute_name": "title",
    "translations": {
      "es": "Frase de ejemplo",
      "fr": "Phrase d'exemple"
    },
    "translation_approved": {
      "es": "Y",
      "fr": "N"
    }
  },
  {
    "phrase_id": 326508,
    "source_term": "Second Example Phrase",
    "tag_name": "div",
    "attribute_name": null,
    "translations": {
      "es": "Segunda frase de ejemplo",
      "fr": "Deuxième phrase d'exemple"
    },
    "translation_approved": {
      "es": "N",
      "fr": "Y"
    }
  }
]
Couldn't find what you were looking for?

In this article

Website Translation Made Easy