Skip to main content

Create new key

POST 

/v2/projects/:projectId/keys

Create new key

Request

Path Parameters

    projectId int64required

Body

required
    description string

    Possible values: <= 2000 characters

    Description of the key

    isPlural booleanrequired

    If key is pluralized. If it will be reflected in the editor

    name stringrequired

    Name of the key

    namespace string
    pluralArgName string

    The argument name for the plural. If null, value will be guessed from the values provided in translations.

    relatedKeysInOrder object[]

    Keys in the document used as a context for machine translation. Keys in the same order as they appear in the document. The order is important! We are using it for graph distance calculation.

  • Array [
  • keyName stringrequired
    namespace string
  • ]
  • screenshotUploadedImageIds int64[]

    Ids of screenshots uploaded with /v2/image-upload endpoint

    screenshots object[]
  • Array [
  • positions object[]
  • Array [
  • height int32required
    width int32required
    x int32required
    y int32required
  • ]
  • text string
    uploadedImageId int64required

    Ids of screenshot uploaded with /v2/image-upload endpoint

  • ]
  • states object

    Translation states to update, if not provided states won't be modified

    property name* string

    Translation states to update, if not provided states won't be modified

    tags string[]
    translations object
    property name* string

Responses

Created

Schema
    custom objectrequired

    Custom values of the key

    property name* object

    Custom values of the key

    description string

    Description of key

    id int64required

    Id of key record

    isPlural booleanrequired

    If key is pluralized. If it will be reflected in the editor

    name stringrequired

    Name of key

    namespace string

    Namespace of key

    pluralArgName string

    The argument name for the plural

    screenshots object[]required

    Screenshots of the key

  • Array [
  • createdAt date-time
    fileUrl stringrequired
    filename stringrequired

    File name, which may be downloaded from the screenshot path.

    When images are secured. Encrypted timestamp is appended to the filename.

    height int32
    id int64required
    keyReferences object[]required
  • Array [
  • keyId int64required
    keyName stringrequired
    keyNamespace string
    originalText string
    position object
    height int32required
    width int32required
    x int32required
    y int32required
  • ]
  • location string
    middleSized string
    middleSizedUrl string
    thumbnail stringrequired

    Thumbnail file name, which may be downloaded from the screenshot path.

    When images are secured. Encrypted timestamp is appended to the filename.

    thumbnailUrl stringrequired
    width int32
  • ]
  • tags object[]required

    Tags of key

  • Array [
  • id int64required
    name stringrequired
  • ]
  • translations objectrequired

    Translations object containing values updated in this request

    property name* TranslationModel

    Translations object containing values updated in this request

    auto booleanrequired

    Was translated using Translation Memory or Machine translation service?

    id int64required

    Id of translation record

    mtProvider string

    Possible values: [GOOGLE, AWS, DEEPL, AZURE, BAIDU, TOLGEE]

    Which machine translation service was used to auto translate this

    outdated booleanrequired

    Whether base language translation was changed after this translation was updated

    state stringrequired

    Possible values: [UNTRANSLATED, TRANSLATED, REVIEWED, DISABLED]

    State of translation

    text string

    Translation text

Loading...