Lilt REST API API Reference

The Lilt REST API enables programmatic access to the full-range of Lilt backend services including:

  • Training of and translating with interactive, adaptive machine translation
  • Large-scale translation memory
  • The Lexicon (a large-scale termbase)
  • Programmatic control of the Lilt CAT environment
  • Translation memory synchronization

Requests and responses are in JSON format. The REST API only responds to HTTPS / SSL requests.

Authentication

Requests are authenticated via REST API key, which requires the Business plan.

Requests are authenticated using HTTP Basic Auth. Add your REST API key as both the username and password.

For development, you may also pass the REST API key via the key query parameter. This is less secure than HTTP Basic Auth, and is not recommended for production use.

Quotas

Our services have a general quota of 4000 requests per minute. Should you hit the maximum requests per minute, you will need to wait 60 seconds before you can send another request.

API Endpoint
https://lilt.com/2
Contact: support@lilt.com
Request Content-Types: application/json
Response Content-Types: application/json
Schemes: https
Version: v2.0

Authentication

BasicAuth

type
basic

ApiKeyAuth

type
apiKey
in
query
name
key

Workflows

These endpoints are only relevant if Lilt Workflows are enabled for your organization. Any other Workflow related topics you notice within these docs will also only be relevant for a Workflows enabled organization.

Retrieve workflow templates

GET /workflows/templates

Get all the possible Workflow Templates owned by the team. Useful for retrieving the ids corresponding to each workflow tables, and passing them to subsequent requests, for example, creating a new Job with a specific Workflow.

Example CURL:

curl --X --request GET 'https://lilt.com/2/workflows/templates?key=API_KEY'

An array with a team's available WorkflowTemplates.

Response Content-Types: application/json
Response Example (200 OK)
[
  {
    "id": 15,
    "name": "Translate > Review > Customer Review",
    "TeamId": 100,
    "stages": [
      {
        "name": "Translate",
        "assignmentType": "TRANSLATE"
      }
    ]
  }
]

Retrieve document Workflow metadata

GET /workflows/document/{documentId}

Get Workflow metadata related to a document. This is useful for gathering information about the current Workflow stage of a document.

Example CURL:

curl --X --request GET 'https://lilt.com/2/workflows/document/{documentId}?key=API_KEY'
documentId: integer
in path

A document id.

An object with document Workflow metadata.

Response Content-Types: application/json
Response Example (200 OK)
{
  "documentId": 12345,
  "workflowId": 1111,
  "stages": [
    {
      "id": 1,
      "name": "Translate",
      "active": true,
      "assignmentType": "TRANSLATE"
    }
  ],
  "currentTask": {
    "id": 1,
    "workflowStageId": 123,
    "name": "Review",
    "enteredAt": "2022-09-09T21:33:21.000Z",
    "startedAt": "2022-09-09T21:33:21.000Z"
  }
}

Set Workflow stage for a document

PUT /workflows/{documentId}/stage

Set the Workflow stage for a document. You can find the stage information required for this request from the "Retrieve document Workflow metadata" endpoint.

Example CURL:

curl --X --request PUT 'https://lilt.com/2/workflows/document/{documentId}/stage?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{
  "workflowStageId": {workflowStageId}
}'
workflowStageId: string

A workflow stage id. Can be found in "Retrieve document Workflow metadata" endpoint. To set the document stage to 'Done', pass through an empty request body.

documentId: integer
in path

A document id.

Request Example
{
  "workflowStageId": 1234
}

An object with a documents next task Workflow metadata.

Response Content-Types: application/json
Response Example (200 OK)
{
  "status": "SUCCESS",
  "newTaskId": 123,
  "newStageName": "Review"
}

Advance workflow to the next stage

POST /document/{documentId}/task/{taskId}/advance

Advance a workflow to the next stage and mark current workflow task as complete.

Example CURL:

curl --X --request POST 'https://lilt.com/2/workflows/document/{documentId}/task/{taskId}/advance?key=API_KEY'
documentId: integer
in path

A document id.

taskId: integer
in path

The task id of the current workflow stage.

An object with a documents next task Workflow metadata.

Response Content-Types: application/json
Response Example (200 OK)
{
  "status": "SUCCESS",
  "newTaskId": 123,
  "newStageName": "Review"
}

Move workflow to the previous stage

POST /document/{documentId}/task/{taskId}/reject

Move a workflow to the previous stage and mark current workflow task as rejected.

Example CURL:

curl --X --request POST 'https://lilt.com/2/workflows/document/{documentId}/task/{taskId}/reject?key=API_KEY'
documentId: integer
in path

A document id.

taskId: integer
in path

The task id of the current workflow stage.

An object with a documents next task Workflow metadata.

Response Content-Types: application/json
Response Example (200 OK)
{
  "status": "SUCCESS",
  "newTaskId": 123,
  "newStageName": "Review"
}

Root

Retrieve the REST API root

GET /

This resource does not have any attributes. It lists the name of the REST API.

This endpoint can be used to verify REST API keys and to check the availability of the REST API.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "api_name": "Lilt REST API v2",
  "api_root": "/2"
}
Response Example (default )
{
  "message": "Internal server error."
}

Files

Retrieve a File

GET /files

Retrieves one or more files available to your user. Files are not associated with a project or a memory. They are unprocessed and can be used later in the project/document creation workflow step.

To retrieve a specific file, specify the id request parameter. To retrieve all files, omit the id request parameter.

Example CURL command:

curl -X GET https://lilt.com/2/files?key=API_KEY&id=274

id: integer
in query

A unique File identifier.

labels: string[]
in query

One or more labels. This will return the files which contain all of the given labels.

Array values passed separated by comma: ?labels=aaa,bbb

200 OK

A list of files.

type
403 Forbidden

User does not have permission for provided file.

410 Gone

File deleted.

default

Unexpected error.

Response Content-Types: application/json
Response Example (200 OK)
[
  {
    "id": 46530,
    "name": "en_US.json",
    "file_hash": "3858f62230ac3c915f300c664312c63f",
    "detected_lang": "de",
    "detected_lang_confidence": 0.7,
    "category": "REFERENCE",
    "labels": [],
    "created_at": "2019-10-16T22:12:34.000Z",
    "updated_at": "2019-10-16T22:12:34.000Z"
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Upload a File

POST /files

Upload a File in any of the formats documented in our knowledge base. Request parameters should be passed in as query string parameters.

Example CURL command:

  curl -X POST https://lilt.com/2/files?key=API_KEY&name=en_US.json \
  --header "Content-Type: application/octet-stream" \
  --data-binary @en_US.json

Calls to GET /files are used to monitor the language detection results. The API response will be augmented to include detected language and confidence score.

The language detection will complete asynchronously. Prior to completion, the detected_lang value will be zxx, the reserved ISO 639-2 code for "No linguistic content/not applicable".

If the language can not be determined, or the detection process fails, the detected_lang field will return und, the reserved ISO 639-2 code for undetermined language, and the detected_lang_confidence score will be 0.

The file contents to be uploaded. The entire POST body will be treated as the file.

name: string
in query

A file name.

file_hash: string
in query

A hash value to associate with the file. The MD5 hash of the body contents will be used by default if a value isn't provided.

langId: boolean
in query

Flag indicating whether to perform language detection on the uploaded file. Default is false.

project_id: integer
in query

The project to associate the uploaded file with.

category: string
in query

The category of the file. The options are REFERENCE, or API. The default is API. Files with the REFERENCE category will be displayed as reference material.

labels: string
in query

Comma-separated list of labels to add to the uploaded document.

Request Content-Types: application/octet-stream
Request Example
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n<xliff xmlns=\"urn:oasis:names:tc:xliff:document:1.2\">\n...\n</xliff>"
201 Created

A SourceFile object.

default

Unexpected error

Response Example (201 Created)
{
  "id": 46530,
  "name": "en_US.json",
  "file_hash": "3858f62230ac3c915f300c664312c63f",
  "detected_lang": "de",
  "detected_lang_confidence": 0.7,
  "category": "REFERENCE",
  "labels": [],
  "created_at": "2019-10-16T22:12:34.000Z",
  "updated_at": "2019-10-16T22:12:34.000Z"
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete a File

DELETE /files

Delete a File.

Example CURL command:

  curl -X DELETE https://lilt.com/2/files?key=API_KEY&id=123 ```
                  
                  
id: integer
in query

A unique File identifier.

204 No Content

A status object.

type
object
default

Unexpected error

Response Example (204 No Content)
{
  "id": 12345,
  "deleted": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Download file

GET /files/download

Download a File.

Example CURL:

curl --X --request GET 'https://lilt.com/2/files/download?key=API_KEY&id=1'
id: string
in query

A File id.

200 OK

A file.

type
string (byte)
Response Content-Types: application/octet-stream
Response Example (200 OK)
"string (byte)"

Add Label to File

POST /files/labels

Add a label to a File.

Example CURL:

curl --X --request POST 'https://lilt.com/2/files/labels?key=API_KEY&id=1'
--header 'Content-Type: application/json' \
--data-raw '{
    "name": "label_name"
}'

A label name.

name: string

The Label name.

id: string
in query

A File id.

Request Example
{
  "name": "label_name"
}
204 No Content

A success response.

Remove Label from File

DELETE /files/labels

Remove a label from a File.

Example CURL:

curl --X --request DELETE 'https://lilt.com/2/files/labels?key=API_KEY&id=1&name=label_name'
id: string
in query

A File id.

name: string
in query

A label name.

204 No Content

A success response.

Comments

Retrieve a document's comments by segment

GET /comments

Retrieves all comments associated with a specified document, grouped by their Segment's ID.

To retrieve a document's comments, specify the document_id request parameter.

Example CURL command:

  curl -X GET https://lilt.com/2/comments?key=API_KEY&document_id=123
document_id: integer
in query

A unique document identifier.

An object containing lists of comments identified by the id of the segment to which they belong.

403 Forbidden

User does not have permission for provided document.

410 Gone

Comment deleted.

default

Unexpected error.

Response Example (200 OK)
{
  "1234567": [
    {
      "id": 84480010,
      "text": "This is incorrect.",
      "annotations": [
        {
          "text": "mistranslation"
        }
      ],
      "is_resolved": true,
      "document_id": 5678,
      "segment_id": 5678,
      "segment_revision_id": 5678,
      "user_id": 5678,
      "created_at": 1489147692
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Create a new comment

POST /comments

Create a new comment for the specified Segment ID.

The comment being created

document_id: integer
in query

A unique document identifier.

segment_id: integer
in query

A unique segment identifier.

Request Content-Types: application/json
Request Example
{
  "text": "Please update this segment",
  "annotations": [
    {
      "text": "mistranslation"
    }
  ],
  "isResolved": false
}
201 Created

A Comment object.

default

Unexpected error

Response Example (201 Created)
{
  "id": 84480010,
  "text": "This is incorrect.",
  "annotations": [
    {
      "text": "mistranslation"
    }
  ],
  "is_resolved": true,
  "document_id": 5678,
  "segment_id": 5678,
  "segment_revision_id": 5678,
  "user_id": 5678,
  "created_at": 1489147692
}
Response Example (default )
{
  "message": "Internal server error."
}

Update an existing comment

PUT /comments

Update an existing comment.

The comment being updated.

comment_id: integer
in query

A unique comment identifier.

document_id: integer
in query

A unique document identifier.

Request Content-Types: application/json
Request Example
{
  "text": "Please update this segment",
  "annotations": [
    {
      "text": "mistranslation"
    }
  ],
  "isResolved": false
}
201 Created

A Comment object.

default

Unexpected error

Response Example (201 Created)
{
  "id": 84480010,
  "text": "This is incorrect.",
  "annotations": [
    {
      "text": "mistranslation"
    }
  ],
  "is_resolved": true,
  "document_id": 5678,
  "segment_id": 5678,
  "segment_revision_id": 5678,
  "user_id": 5678,
  "created_at": 1489147692
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Comment

DELETE /comments

Delete a Comment.

Example CURL command:

  curl -X DELETE https://lilt.com/2/comments?key=API_KEY&comment_id=123
comment_id: integer
in query

A unique Comment identifier.

204 No Content

A status object.

type
object
default

Unexpected error

Response Example (204 No Content)
{
  "id": 12345
}
Response Example (default )
{
  "message": "Internal server error."
}

Connectors

Retrieve a Connector

GET /connectors

Retrieves one or more connectors available to your user. Connectors are not associated with a project or a memory.

To retrieve a specific connector, specify the id request parameter. To retrieve all connectors, omit the id request parameter.

Example CURL command:

curl -X GET https://lilt.com/2/connectors?key=API_KEY&id=274

id: integer
in query

A unique Connector identifier.

200 OK

A list of Connectors.

type
403 Forbidden

User does not have permission for provided connector.

410 Gone

Connector deleted.

default

Unexpected error.

Response Example (200 OK)
[
  {
    "id": "integer",
    "name": "string",
    "schedule": "string",
    "last_check": "string",
    "healthy": "boolean",
    "args": "object",
    "created_at": "string",
    "updated_at": "string"
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Upload a Connector

POST /connectors

Create a new connector linked to a supported external cms.

Connector arguments.

name: string

Name of connector.

args: object

Connector parameters.

schedule: string

Cron string

Request Content-Types: application/json
Request Example
{
  "name": "string",
  "args": "object",
  "schedule": "0 0 * * *"
}
201 Created

A Connector object.

default

Unexpected error

Response Example (201 Created)
{
  "id": "integer",
  "name": "string",
  "schedule": "string",
  "last_check": "string",
  "healthy": "boolean",
  "args": "object",
  "created_at": "string",
  "updated_at": "string"
}
Response Example (default )
{
  "message": "Internal server error."
}

Upload a Connector

PUT /connectors

Create a new connector linked to a supported external content source.

Connector arguments.

id: integer

A unique Connector identifier.

name: string

Name of connector.

args: object

Connector parameters.

schedule: string

Cron string

Request Content-Types: application/json
Request Example
{
  "id": 46530,
  "name": "zendesk",
  "args": "object",
  "schedule": "0 0 * * *"
}
201 Created

A Connector object.

default

Unexpected error

Response Example (201 Created)
{
  "id": "integer",
  "name": "string",
  "schedule": "string",
  "last_check": "string",
  "healthy": "boolean",
  "args": "object",
  "created_at": "string",
  "updated_at": "string"
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Connector

DELETE /connectors

Delete a Connector.

Example CURL command:

  curl -X DELETE https://lilt.com/2/connectors?key=API_KEY&id=123 ```
                  
                  
id: integer
in query

A unique Connector identifier.

204 No Content

A status object.

type
object
default

Unexpected error

Response Example (204 No Content)
{
  "id": 12345,
  "deleted": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Sync a Connector

POST /connectors/sync

Request an import job for the given connector ID. This will check the target system for new content to pull into Lilt.

Example CURL command:

 curl -X GET https://lilt.com/2/connectors/sync?key=API_KEY&id=128
id: integer
in query

A unique Connector identifier.

201 Created

A Connector Job object.

default

Unexpected error

Response Example (201 Created)
{
  "id": "integer",
  "status": "string",
  "args": "object",
  "created_at": "string",
  "updated_at": "string"
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve a Connector Job

GET /connectors/jobs

Retrieves a connector job available to your user. Use this to check the status of jobs started by the /connectors/sync and /connectors/jobs/deliver endpoints.

Example CURL command:

 curl -X GET https://lilt.com/2/connectors/jobs?key=API_KEY&id=9274
id: integer
in query

A unique Connector Job identifier.

200 OK

A list of Connector Jobs.

default

Unexpected error

Response Example (200 OK)
[
  {
    "id": "integer",
    "status": "string",
    "args": "object",
    "created_at": "string",
    "updated_at": "string"
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Deliver a Connector Job

POST /connectors/jobs/deliver

Request an export job for the given connector job ID. This will check Lilt for completed projects that are associated with this job and deliver them to the target system.

Example CURL command:

 curl -X POST https://lilt.com/2/connectors/jobs/deliver?key=API_KEY&id=9274
id: integer
in query

A unique Connector Job identifier.

200 OK

A success status code.

default

Unexpected error

Response Example (default )
{
  "message": "Internal server error."
}

ConverterConfig

List Converter Configs

GET /configs/converter

List all file filter configurations for your Organization.

organizationId: integer
in query

A unique Organization identifier.

A map of config id to string escaped config json.

default

Unexpected error

Response Example (200 OK)
{
  "145": "{\"registry\": {\".xlsx\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_openxml\", \"filterConfig\": \"#v1\\nbPreferenceTranslateDocProperties.b=false\\nbPreferenceTranslateComments.b=true\\nbPreferenceTranslatePowerpointNotes.b=true\\nbPreferenceTranslatePowerpointMasters.b=true\\nbPreferenceIgnorePlaceholdersInPowerpointMasters.b=false\\nbPreferenceTranslateWordHeadersFooters.b=true\\nbPreferenceTranslateWordHidden.b=false\\nbPreferenceTranslateWordExcludeGraphicMetaData.b=true\\nbPreferenceTranslatePowerpointHidden.b=false\\nbPreferenceTranslateExcelHidden.b=false\\nbPreferenceTranslateExcelExcludeColors.b=false\\nbPreferenceTranslateExcelExcludeColumns.b=false\\nbPreferenceTranslateExcelSheetNames.b=false\\nbPreferenceAddLineSeparatorAsCharacter.b=false\\nsPreferenceLineSeparatorReplacement=$0a$\\nbPreferenceReplaceNoBreakHyphenTag.b=false\\nbPreferenceIgnoreSoftHyphenTag.b=false\\nbPreferenceAddTabAsCharacter.b=false\\nbPreferenceAggressiveCleanup.b=true\\nbPreferenceAutomaticallyAcceptRevisions.b=true\\nbPreferencePowerpointIncludedSlideNumbersOnly.b=false\\nbPreferenceTranslateExcelDiagramData.b=false\\nbPreferenceTranslateExcelDrawings.b=false\\nsubfilter=okf_plaintext\\nbInExcludeMode.b=true\\nbInExcludeHighlightMode.b=true\\nbPreferenceTranslateWordExcludeColors.b=false\\nbReorderPowerpointNotesAndComments.b=true\\ntsComplexFieldDefinitionsToExtract.i=1\\ncfd0=HYPERLINK\\ntsExcelExcludedColors.i=0\\ntsExcelExcludedColumns.i=0\\ntsExcludeWordStyles.i=0\\ntsWordHighlightColors.i=0\\ntsWordExcludedColors.i=0\\ntsPowerpointIncludedSlideNumbers.i=0\\nbExtractExternalHyperlinks.b=false\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}}",
  "432": "{\"registry\": {\".md\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_markdown\", \"filterConfig\": \"#v1\\nuseCodeFinder.b=false\\ntranslateUrls.b=true\\nurlToTranslatePattern=.+\\ntranslateCodeBlocks.b=false\\ntranslateInlineCodeBlocks.b=true\\ntranslateHeaderMetadata.b=true\\ntranslateImageAltText.b=true\\nuseLinkSubflow.b=true\\ncodeFinderRules.count.i=1\\ncodeFinderRules.rule0=\\\\{\\\\{[^}]+\\\\}\\\\}\\ncodeFinderRules.sample={{#test}} handle bar test {{/test}}$0a${{stand-alone handle bar}}$0a$\\ncodeFinderRules.useAllRulesWhenTesting.b=true\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}"
}
Response Example (default )
{
  "message": "Internal server error."
}

Add Converter Config

PUT /configs/converter

Add a file filter configuration for your Organization.

The file filter configuration to create.

configJson: string

The configuration json blob, string escaped.

configName: string

The user defined name of your configuration.

configDescription: string

A description for the configuration.

organizationId: integer
in query

A unique Organization identifier.

Request Content-Types: application/json
Request Example
{
  "configJson": "{\"registry\": {\".md\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_markdown\", \"filterConfig\": \"#v1\\nuseCodeFinder.b=false\\ntranslateUrls.b=true\\nurlToTranslatePattern=.+\\ntranslateCodeBlocks.b=false\\ntranslateInlineCodeBlocks.b=true\\ntranslateHeaderMetadata.b=true\\ntranslateImageAltText.b=true\\nuseLinkSubflow.b=true\\ncodeFinderRules.count.i=1\\ncodeFinderRules.rule0=\\\\{\\\\{[^}]+\\\\}\\\\}\\ncodeFinderRules.sample={{#test}} handle bar test {{/test}}$0a${{stand-alone handle bar}}$0a$\\ncodeFinderRules.useAllRulesWhenTesting.b=true\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}",
  "configName": "my_config",
  "configDescription": "config for custom markdown escaping"
}
200 OK

The config id of the configuration created.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "configId": "integer"
}
Response Example (default )
{
  "message": "Internal server error."
}

Fetch Converter Config by Id

GET /configs/converter/{configId}

Fetch a file filter configuration by id.

configId: integer
in path

A unique configuration identifier.

A map of config id to string escaped config json.

default

Unexpected error

Response Example (200 OK)
{
  "145": "{\"registry\": {\".xlsx\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_openxml\", \"filterConfig\": \"#v1\\nbPreferenceTranslateDocProperties.b=false\\nbPreferenceTranslateComments.b=true\\nbPreferenceTranslatePowerpointNotes.b=true\\nbPreferenceTranslatePowerpointMasters.b=true\\nbPreferenceIgnorePlaceholdersInPowerpointMasters.b=false\\nbPreferenceTranslateWordHeadersFooters.b=true\\nbPreferenceTranslateWordHidden.b=false\\nbPreferenceTranslateWordExcludeGraphicMetaData.b=true\\nbPreferenceTranslatePowerpointHidden.b=false\\nbPreferenceTranslateExcelHidden.b=false\\nbPreferenceTranslateExcelExcludeColors.b=false\\nbPreferenceTranslateExcelExcludeColumns.b=false\\nbPreferenceTranslateExcelSheetNames.b=false\\nbPreferenceAddLineSeparatorAsCharacter.b=false\\nsPreferenceLineSeparatorReplacement=$0a$\\nbPreferenceReplaceNoBreakHyphenTag.b=false\\nbPreferenceIgnoreSoftHyphenTag.b=false\\nbPreferenceAddTabAsCharacter.b=false\\nbPreferenceAggressiveCleanup.b=true\\nbPreferenceAutomaticallyAcceptRevisions.b=true\\nbPreferencePowerpointIncludedSlideNumbersOnly.b=false\\nbPreferenceTranslateExcelDiagramData.b=false\\nbPreferenceTranslateExcelDrawings.b=false\\nsubfilter=okf_plaintext\\nbInExcludeMode.b=true\\nbInExcludeHighlightMode.b=true\\nbPreferenceTranslateWordExcludeColors.b=false\\nbReorderPowerpointNotesAndComments.b=true\\ntsComplexFieldDefinitionsToExtract.i=1\\ncfd0=HYPERLINK\\ntsExcelExcludedColors.i=0\\ntsExcelExcludedColumns.i=0\\ntsExcludeWordStyles.i=0\\ntsWordHighlightColors.i=0\\ntsWordExcludedColors.i=0\\ntsPowerpointIncludedSlideNumbers.i=0\\nbExtractExternalHyperlinks.b=false\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}}",
  "432": "{\"registry\": {\".md\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_markdown\", \"filterConfig\": \"#v1\\nuseCodeFinder.b=false\\ntranslateUrls.b=true\\nurlToTranslatePattern=.+\\ntranslateCodeBlocks.b=false\\ntranslateInlineCodeBlocks.b=true\\ntranslateHeaderMetadata.b=true\\ntranslateImageAltText.b=true\\nuseLinkSubflow.b=true\\ncodeFinderRules.count.i=1\\ncodeFinderRules.rule0=\\\\{\\\\{[^}]+\\\\}\\\\}\\ncodeFinderRules.sample={{#test}} handle bar test {{/test}}$0a${{stand-alone handle bar}}$0a$\\ncodeFinderRules.useAllRulesWhenTesting.b=true\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}"
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete Converter Config

DELETE /configs/converter/{configId}

Delete a file filter configuration by id.

configId: integer
in path

A unique configuration identifier.

200 OK

The config id of the configuration deleted.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "configId": "integer"
}
Response Example (default )
{
  "message": "Internal server error."
}

Add Filter Mapping

PUT /configs/converter/{configId}/{fileExtension}

Add a specific filter mapping to your file filter configuration

The file filter mapping to create.

registryEntryJson: string

The filter mapping json blob, string escaped.

configName: string

The user defined name of your configuration.

configDescription: string

A description for the configuration.

configId: integer
in path

A unique configuration identifier.

fileExtension: string
in path

A file extension for the filter mapping.

Request Content-Types: application/json
Request Example
{
  "registryEntryJson": "{\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_markdown\", \"filterConfig\": \"#v1\\nuseCodeFinder.b=false\\ntranslateUrls.b=true\\nurlToTranslatePattern=.+\\ntranslateCodeBlocks.b=false\\ntranslateInlineCodeBlocks.b=true\\ntranslateHeaderMetadata.b=true\\ntranslateImageAltText.b=true\\nuseLinkSubflow.b=true\\ncodeFinderRules.count.i=1\\ncodeFinderRules.rule0=\\\\{\\\\{[^}]+\\\\}\\\\}\\ncodeFinderRules.sample={{#test}} handle bar test {{/test}}$0a${{stand-alone handle bar}}$0a$\\ncodeFinderRules.useAllRulesWhenTesting.b=true\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}",
  "configName": "my_config",
  "configDescription": "config for custom markdown escaping"
}

A map of config id to string escaped config json.

default

Unexpected error

Response Example (200 OK)
{
  "145": "{\"registry\": {\".xlsx\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_openxml\", \"filterConfig\": \"#v1\\nbPreferenceTranslateDocProperties.b=false\\nbPreferenceTranslateComments.b=true\\nbPreferenceTranslatePowerpointNotes.b=true\\nbPreferenceTranslatePowerpointMasters.b=true\\nbPreferenceIgnorePlaceholdersInPowerpointMasters.b=false\\nbPreferenceTranslateWordHeadersFooters.b=true\\nbPreferenceTranslateWordHidden.b=false\\nbPreferenceTranslateWordExcludeGraphicMetaData.b=true\\nbPreferenceTranslatePowerpointHidden.b=false\\nbPreferenceTranslateExcelHidden.b=false\\nbPreferenceTranslateExcelExcludeColors.b=false\\nbPreferenceTranslateExcelExcludeColumns.b=false\\nbPreferenceTranslateExcelSheetNames.b=false\\nbPreferenceAddLineSeparatorAsCharacter.b=false\\nsPreferenceLineSeparatorReplacement=$0a$\\nbPreferenceReplaceNoBreakHyphenTag.b=false\\nbPreferenceIgnoreSoftHyphenTag.b=false\\nbPreferenceAddTabAsCharacter.b=false\\nbPreferenceAggressiveCleanup.b=true\\nbPreferenceAutomaticallyAcceptRevisions.b=true\\nbPreferencePowerpointIncludedSlideNumbersOnly.b=false\\nbPreferenceTranslateExcelDiagramData.b=false\\nbPreferenceTranslateExcelDrawings.b=false\\nsubfilter=okf_plaintext\\nbInExcludeMode.b=true\\nbInExcludeHighlightMode.b=true\\nbPreferenceTranslateWordExcludeColors.b=false\\nbReorderPowerpointNotesAndComments.b=true\\ntsComplexFieldDefinitionsToExtract.i=1\\ncfd0=HYPERLINK\\ntsExcelExcludedColors.i=0\\ntsExcelExcludedColumns.i=0\\ntsExcludeWordStyles.i=0\\ntsWordHighlightColors.i=0\\ntsWordExcludedColors.i=0\\ntsPowerpointIncludedSlideNumbers.i=0\\nbExtractExternalHyperlinks.b=false\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}}",
  "432": "{\"registry\": {\".md\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_markdown\", \"filterConfig\": \"#v1\\nuseCodeFinder.b=false\\ntranslateUrls.b=true\\nurlToTranslatePattern=.+\\ntranslateCodeBlocks.b=false\\ntranslateInlineCodeBlocks.b=true\\ntranslateHeaderMetadata.b=true\\ntranslateImageAltText.b=true\\nuseLinkSubflow.b=true\\ncodeFinderRules.count.i=1\\ncodeFinderRules.rule0=\\\\{\\\\{[^}]+\\\\}\\\\}\\ncodeFinderRules.sample={{#test}} handle bar test {{/test}}$0a${{stand-alone handle bar}}$0a$\\ncodeFinderRules.useAllRulesWhenTesting.b=true\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}"
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete Filter Mapping

DELETE /configs/converter/{configId}/{fileExtension}

Delete a file filter mapping by id and file extension.

configId: integer
in path

A unique configuration identifier.

fileExtension: string
in path

A file extension to delete.

A map of config id to string escaped config json.

default

Unexpected error

Response Example (200 OK)
{
  "145": "{\"registry\": {\".xlsx\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_openxml\", \"filterConfig\": \"#v1\\nbPreferenceTranslateDocProperties.b=false\\nbPreferenceTranslateComments.b=true\\nbPreferenceTranslatePowerpointNotes.b=true\\nbPreferenceTranslatePowerpointMasters.b=true\\nbPreferenceIgnorePlaceholdersInPowerpointMasters.b=false\\nbPreferenceTranslateWordHeadersFooters.b=true\\nbPreferenceTranslateWordHidden.b=false\\nbPreferenceTranslateWordExcludeGraphicMetaData.b=true\\nbPreferenceTranslatePowerpointHidden.b=false\\nbPreferenceTranslateExcelHidden.b=false\\nbPreferenceTranslateExcelExcludeColors.b=false\\nbPreferenceTranslateExcelExcludeColumns.b=false\\nbPreferenceTranslateExcelSheetNames.b=false\\nbPreferenceAddLineSeparatorAsCharacter.b=false\\nsPreferenceLineSeparatorReplacement=$0a$\\nbPreferenceReplaceNoBreakHyphenTag.b=false\\nbPreferenceIgnoreSoftHyphenTag.b=false\\nbPreferenceAddTabAsCharacter.b=false\\nbPreferenceAggressiveCleanup.b=true\\nbPreferenceAutomaticallyAcceptRevisions.b=true\\nbPreferencePowerpointIncludedSlideNumbersOnly.b=false\\nbPreferenceTranslateExcelDiagramData.b=false\\nbPreferenceTranslateExcelDrawings.b=false\\nsubfilter=okf_plaintext\\nbInExcludeMode.b=true\\nbInExcludeHighlightMode.b=true\\nbPreferenceTranslateWordExcludeColors.b=false\\nbReorderPowerpointNotesAndComments.b=true\\ntsComplexFieldDefinitionsToExtract.i=1\\ncfd0=HYPERLINK\\ntsExcelExcludedColors.i=0\\ntsExcelExcludedColumns.i=0\\ntsExcludeWordStyles.i=0\\ntsWordHighlightColors.i=0\\ntsWordExcludedColors.i=0\\ntsPowerpointIncludedSlideNumbers.i=0\\nbExtractExternalHyperlinks.b=false\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}}",
  "432": "{\"registry\": {\".md\": {\"type\": \"OkapiFprm\", \"version\": 1, \"filterName\": \"okf_markdown\", \"filterConfig\": \"#v1\\nuseCodeFinder.b=false\\ntranslateUrls.b=true\\nurlToTranslatePattern=.+\\ntranslateCodeBlocks.b=false\\ntranslateInlineCodeBlocks.b=true\\ntranslateHeaderMetadata.b=true\\ntranslateImageAltText.b=true\\nuseLinkSubflow.b=true\\ncodeFinderRules.count.i=1\\ncodeFinderRules.rule0=\\\\{\\\\{[^}]+\\\\}\\\\}\\ncodeFinderRules.sample={{#test}} handle bar test {{/test}}$0a${{stand-alone handle bar}}$0a$\\ncodeFinderRules.useAllRulesWhenTesting.b=true\\n\", \"extractAllTags\": true, \"exportReplacements\": {\"patterns\": [], \"replacements\": []}, \"importReplacements\": {\"patterns\": [], \"replacements\": []}}}"
}
Response Example (default )
{
  "message": "Internal server error."
}

Documents

Create a Document

POST /documents

Create a new Document. A Document is a collection of one or more Segments. Documents are nested inside of Projects, and appear in the Project details view in the web app. Document-level relationships between Segments are considered by the machine translation system during adaptation. If there is no inherent document structure in your data, you still might consider grouping related Segments into Documents to improve translation quality.

The Document resource to create.

name: string

The document name.

project_id: integer

A unique Project identifier.

Request Content-Types: application/json
Request Example
{
  "name": "Introduction.xliff",
  "project_id": 23618
}

A Document object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "project_id": 287,
  "srclang": "en",
  "trglang": "de",
  "name": "Introduction.xliff",
  "import_in_progress": false,
  "import_succeeded": false,
  "import_error_message": "Could not parse XML.",
  "export_in_progress": false,
  "export_succeeded": false,
  "export_error_message": "Could not parse XML.",
  "is_pretranslating": false,
  "status": {
    "pretranslation": "idle"
  },
  "translator_email": "translator@example.com",
  "reviewer_email": "reviewer@example.com",
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "is_review_complete": true,
  "segments": [
    {
      "id": 84480010,
      "created_at": 1489147692,
      "updated_at": 1489147692,
      "document_id": 1234,
      "memory_id": 5678,
      "source": "The red bus.",
      "srclang": "en",
      "target": "Le bus rouge.",
      "trglang": "fr",
      "is_confirmed": true,
      "is_reviewed": true
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve a Document

GET /documents

List a Document.

The listing will include the pretranslation status for the document. When pretranslation is in progress for a document, the GET /documents endpoint's response will include is_pretranslating = true as well as a more detailed status property status.pretranslation one of idle, pending, or running.

id: integer
in query

A unique Document identifier.

with_segments: boolean
in query

Flag indicating whether full segment information should be returned.

A Document object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "project_id": 287,
  "srclang": "en",
  "trglang": "de",
  "name": "Introduction.xliff",
  "import_in_progress": false,
  "import_succeeded": false,
  "import_error_message": "Could not parse XML.",
  "export_in_progress": false,
  "export_succeeded": false,
  "export_error_message": "Could not parse XML.",
  "is_pretranslating": false,
  "status": {
    "pretranslation": "idle"
  },
  "translator_email": "translator@example.com",
  "reviewer_email": "reviewer@example.com",
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "is_review_complete": true,
  "segments": [
    {
      "id": 84480010,
      "created_at": 1489147692,
      "updated_at": 1489147692,
      "document_id": 1234,
      "memory_id": 5678,
      "source": "The red bus.",
      "srclang": "en",
      "target": "Le bus rouge.",
      "trglang": "fr",
      "is_confirmed": true,
      "is_reviewed": true
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Update a Document

PUT /documents

Update a Document.

The Document resource to update.

id: integer

A unique Document identifier.

name: string

The Document name.

Request Content-Types: application/json
Request Example
{
  "id": 46530,
  "name": "Introduction to our App"
}

A Document object.

400 Bad Request

Invalid id or name or one of them was missing.

default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "project_id": 287,
  "srclang": "en",
  "trglang": "de",
  "name": "Introduction.xliff",
  "import_in_progress": false,
  "import_succeeded": false,
  "import_error_message": "Could not parse XML.",
  "export_in_progress": false,
  "export_succeeded": false,
  "export_error_message": "Could not parse XML.",
  "is_pretranslating": false,
  "status": {
    "pretranslation": "idle"
  },
  "translator_email": "translator@example.com",
  "reviewer_email": "reviewer@example.com",
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "is_review_complete": true,
  "segments": [
    {
      "id": 84480010,
      "created_at": 1489147692,
      "updated_at": 1489147692,
      "document_id": 1234,
      "memory_id": 5678,
      "source": "The red bus.",
      "srclang": "en",
      "target": "Le bus rouge.",
      "trglang": "fr",
      "is_confirmed": true,
      "is_reviewed": true
    }
  ]
}
Response Example (400 Bad Request)
{
  "message": "Internal server error."
}
Response Example (default )
{
  "message": "Internal server error."
}

Update multiple Documents

PUT /documents

Update multiple Documents.

An array of Document resources to update.

object
id: integer

A unique Document identifier.

name: string

The Document name.

Request Content-Types: application/json
Request Example
[
  {
    "id": 46530,
    "name": "Introduction to our App"
  }
]

Multiple Document objects.

400 Bad Request

Invalid id or name or one of them was missing.

type
default

Unexpected error

Response Example (200 OK)
[
  {
    "id": 46530,
    "project_id": 287,
    "srclang": "en",
    "trglang": "de",
    "name": "Introduction.xliff",
    "import_in_progress": false,
    "import_succeeded": false,
    "import_error_message": "Could not parse XML.",
    "export_in_progress": false,
    "export_succeeded": false,
    "export_error_message": "Could not parse XML.",
    "is_pretranslating": false,
    "status": {
      "pretranslation": "idle"
    },
    "translator_email": "translator@example.com",
    "reviewer_email": "reviewer@example.com",
    "created_at": 1489147692,
    "updated_at": 1489147692,
    "is_review_complete": true,
    "segments": [
      {
        "id": 84480010,
        "created_at": 1489147692,
        "updated_at": 1489147692,
        "document_id": 1234,
        "memory_id": 5678,
        "source": "The red bus.",
        "srclang": "en",
        "target": "Le bus rouge.",
        "trglang": "fr",
        "is_confirmed": true,
        "is_reviewed": true
      }
    ]
  }
]
Response Example (400 Bad Request)
[
  {
    "message": "Internal server error."
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Document

DELETE /documents

Delete a Document.

id: integer
in query

A unique Document identifier.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "deleted": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Assign a Document

PUT /documents/share

Assign and unassign a Document for translation and/or review.

Attributes of the Document resource to assign.

id: integer

A unique Document identifier.

email: string

An email address.

is_translator: boolean

If true, assign for translating. If false, then unassign.

is_reviewer: boolean

If true, assign for reviewing. If false, then unassign.

due_date: string (date-time)

Due date for translation or review (set based on is_translator and is_reviewer flags).

Request Content-Types: application/json
Request Example
{
  "id": 46530,
  "email": "user@email.com",
  "is_translator": true,
  "is_reviewer": false,
  "due_date": "2019-10-16T22:12:34.000Z"
}
200 OK

A status object.

type
object
default

Unexpected error

Response Content-Types: application/json
Response Example (200 OK)
{
  "id": 46530
}
Response Example (default )
{
  "message": "Internal server error."
}

Pretranslate a Document

POST /documents/pretranslate

Initiate pretranslation of a list of Documents. This request will mark document(s) as being pretranslated. Pretranslation in this context is:

  • Applying and confirming exact TM matches based on the Memory of the Project;
  • Translating all other segments via MT without confirming them.

Example CURL command:

curl -X POST https://lilt.com/2/documents/pretranslate?key=API_KEY -d '{"id": [123]}' -H "Content-Type: application/json"

Document translation is an asynchronous process that, in effect, is performed in the background.

To check the status of pretranslation for a document, use the GET /documents endpoint. When pretranslation is in progress for a document, the GET /documents endpoint's response will include is_pretranslating = true as well as a more detailed status property status.pretranslation one of idle, pending, or running.

Once pretranslation is finished, the document can be downloaded via GET /documents/files.

A list of unique Document identifiers.

id: integer[]

A list of unique Document identifiers.

integer
auto_accept: boolean

Optional parameter for auto-accepting 100% TM hits.

case_sensitive: boolean

Optional for using case matching against TM hits..

attribute_to_creator: boolean

Optional parameter for attributing translation authorship of exact matches to document creator.

mode: string

An optional parameter indicating how the document will be pretranslated.

The accepted values are tm, or tm+mt. Default is tm.

auto_accept: boolean
in query

Deprecated, use body param instead. Optional parameter for auto-accepting 100% TM hits.

case_sensitive: boolean
in query

Deprecated, use body param instead. Optional for using case matching against TM hits.

attribute_to_creator: boolean
in query

Deprecated, use body param instead. Optional parameter for attributing translation authorship of exact matches to document creator.

mode: string
in query

Deprecated, use body param instead. An optional parameter indicating how the document will be pretranslated.

The accepted values are tm, or tm+mt. Default is tm.

Request Content-Types: application/json
Request Example
{
  "id": [
    123,
    234
  ],
  "auto_accept": false,
  "case_sensitive": false,
  "attribute_to_creator": false,
  "mode": "tm+mt"
}
202 Accepted

A status object.

type
object
default

Unexpected error

Response Example (202 Accepted)
{
  "id": [
    123,
    234
  ],
  "is_pretranslating": true,
  "documents": [
    {
      "id": 123,
      "import_in_progress": false,
      "import_succeeded": true,
      "import_error_message": "",
      "is_processing": false,
      "is_pretranslating": true,
      "status": {
        "pretranslation": "running"
      }
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Download a Document

GET /documents/files

Export a Document that has been translated in the Lilt web application. Any Document can be downloaded in XLIFF 1.2 format, or can be retrieved in its original uploaded format by setting is_xliff=false. This endpoint will fail if either (a) export or (b) pre-translation operations are in-progress. The status of those operations can be determined by retrieving the Document resource. Example CURL command:

  curl -X GET https://lilt.com/2/documents/files?key=API_KEY&id=274 -o from_lilt.xliff
id: integer
in query

An unique Document identifier.

is_xliff: boolean true
in query

Download the document in XLIFF 1.2 format.

200 OK

A file.

type
string (byte)
502 Bad Gateway

File in pretranslation.

default

Unexpected error

Response Content-Types: application/octet-stream
Response Example (200 OK)
"string (byte)"
Response Example (default )
{
  "message": "Internal server error."
}

Upload a File

POST /documents/files

Create a Document from a file in any of the formats documented in our knowledge base. Request parameters should be passed as JSON object with the header field LILT-API.

File names in the header can only contain US-ASCII characters. File names with characters outside of US-ASCII should be URI encoded or transliterated to US-ASCII strings.

Example CURL command:

  curl -X POST https://lilt.com/2/documents/files?key=API_KEY \
  --header "LILT-API: {\"name\": \"introduction.xliff\",\"pretranslate\": \"tm+mt\",\"project_id\": 9}" \
  --header "Content-Type: application/octet-stream" \
  --data-binary @Introduction.xliff

The file contents to be uploaded. The entire POST body will be treated as the file.

name: string
in header

A file name.

project_id: integer
in header

A unique Project identifier.

pretranslate: string
in header

An optional parameter indicating if and how the document will be pretranslated upon being uploaded. The accepted values are TM, or TM+MT

auto_accept: boolean
in header

An optional parameter to auto-accept segments with 100% translation memory matches when the pretranslate option is also set, or to auto-accept any target data that is present when the uploaded file is XLIFF. If omitted it will default to your organization settings for Accept and lock exact matches, if set to false, no segments will be auto-accepted.

case_sensitive: boolean
in header

An optional parameter to use case sensitive translation memory matching when the pretranslate option is also enabled. Matches must have identical character-by-character case to qualify as matches. Default value matches your organization settings for Use case sensitive translation memory matching setting

match_attribution: boolean
in header

An optional parameter to attribute translation authorship of exact matches to the author of the file when the pretranslate option is also enabled. Default value matches your organization settings for Translation authorship setting

config_id: integer
in header

An optional pararameter to specify an import configuration to be applied when extracting translatable content from this file.

Request Content-Types: application/octet-stream
Request Example
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n<xliff xmlns=\"urn:oasis:names:tc:xliff:document:1.2\">\n...\n</xliff>"

A Document object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "project_id": 287,
  "srclang": "en",
  "trglang": "de",
  "name": "Introduction.xliff",
  "import_in_progress": false,
  "import_succeeded": false,
  "import_error_message": "Could not parse XML.",
  "export_in_progress": false,
  "export_succeeded": false,
  "export_error_message": "Could not parse XML.",
  "is_pretranslating": false,
  "status": {
    "pretranslation": "idle"
  },
  "translator_email": "translator@example.com",
  "reviewer_email": "reviewer@example.com",
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "is_review_complete": true,
  "segments": [
    {
      "id": 84480010,
      "created_at": 1489147692,
      "updated_at": 1489147692,
      "document_id": 1234,
      "memory_id": 5678,
      "source": "The red bus.",
      "srclang": "en",
      "target": "Le bus rouge.",
      "trglang": "fr",
      "is_confirmed": true,
      "is_reviewed": true
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Unlock documents

POST /documents/done/unlock

Unlock documents for translation. Sets document "Translation Done" and "Review Done" to false.

Example curl:

  curl --X --request POST 'https://lilt.com/2/documents/done/unlock?key=API_KEY' \
  --header 'Content-Type: application/json' \
  --data-raw '{
      "documentIds": [23921, 23922]
  }'

document ids to update

documentIds: number[]

array of document ids

number
Request Example
{
  "documentIds": [
    10641,
    10642
  ]
}
200 OK

array of updated documents

type
number[]
Response Example (200 OK)
[
  "number"
]

Mark translation done

POST /documents/done/translation

Mark the translation of documents as done/undone in bulk.

When being marked positively as done:

  • Documents must not already be marked as done and all segments must be confirmed.
  • This request will also trigger an email notification to a document's assigned reviewer that the document is ready for review.

When being marked as un-done:

  • Documents must not be marked as complete for review.

Example curl:

  curl --X --request POST 'https://lilt.com/2/documents/done/translation?key=API_KEY' \
  --header 'Content-Type: application/json' \
  --data-raw '{
      "documentIds": [23921, 23922],
      "isDone": true
  }'

document ids to update

documentIds: number[]

array of document ids

number
isDone: boolean
Request Example
{
  "documentIds": [
    10641,
    10642
  ],
  "isDone": true
}
200 OK

array of updated documents

type
number[]

Unexpected error

Response Example (200 OK)
[
  "number"
]
Response Example (default )
{
  "message": "Some documents are already marked as complete for review. DocumentIds 22322, 23343"
}

Mark review done

POST /documents/done/review

Mark the review of documents as done/undone in bulk.

When being marked positively as done:

  • Documents must not already be marked as done for review.
  • Documents must already be marked as done for translation.
  • This request will also trigger an email notification.

Example curl:

  curl --X --request POST 'https://lilt.com/2/documents/done/review?key=API_KEY' \
  --header 'Content-Type: application/json' \
  --data-raw '{
      "documentIds": [23921, 23922],
      "isDone": true
  }'

document ids to update

documentIds: number[]

array of document ids

number
isDone: boolean
Request Example
{
  "documentIds": [
    10641,
    10642
  ],
  "isDone": true
}
200 OK

array of updated documents

type
number[]

Unexpected error

Response Example (200 OK)
[
  "number"
]
Response Example (default )
{
  "message": "Some documents' translation is not marked as complete. Complete translation before completing review. DocumentIds 22322, 23343"
}

Languages

Retrieve supported languages

GET /languages

Get a list of supported languages.

200 OK

An object listing supported languages and their corresponding locales.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "source_to_target": {
    "en": {
      "da": true,
      "de": true,
      "fr": true,
      "...": "..."
    },
    "...": "..."
  },
  "code_to_name": {
    "aa": "Afar",
    "ab": "Abkhazian",
    "af": "Afrikaans",
    "...": "..."
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Lexicon

Update a Lexicon

POST /lexicon

Update the Lexicon (Termbase as displayed in the ui) with a new term. The maximum source length is 250 characters.

The lexicon entry.

memory_id: integer

A unique Memory identifier.

source: string

The source side of the lexicon entry.

target: string

The target side of the lexicon entry.

Request Content-Types: application/json
Request Example
{
  "memory_id": 10641,
  "source": "washing machine",
  "target": "Waschmaschine"
}
200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "memory_id": 46530,
  "success": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Query a Lexicon

GET /lexicon

Query the Lexicon. The Lexicon is an editable termbase / concordance that is integrated with the Memory.

memory_id: integer
in query

A unique Memory identifier.

srclang: string
in query

An ISO 639-1 language code.

trglang: string
in query

An ISO 639-1 language code.

query: string
in query

The query term.

n: integer 1
in query

The maximum number of results to return.

200 OK

A list of LexiconEntry objects.

default

Unexpected error

Response Example (200 OK)
[
  {
    "translations": [],
    "examples": [
      [
        {
          "source": "Waschmaschine",
          "sourceDelimiters": [
            "",
            ""
          ],
          "target": [
            "washing",
            "machine"
          ],
          "targetDelimiters": [
            "",
            " ",
            ""
          ],
          "sourceSpan": {
            "start": 0,
            "length": 1
          },
          "targetSpan": {
            "start": 1,
            "length": 1
          },
          "similarity": 0,
          "memoryId": 10641
        }
      ]
    ]
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Memories

Create a Memory

POST /memories

Create a new Memory. A Memory is a container that collects source/target sentences for a specific language pair (e.g., English>French). The data in the Memory is used to train the MT system, populate the TM, and update the lexicon. Memories are private to your account - the data is not shared across users - unless you explicitly share a Memory with your team (via web app only).

Refer to our KB for a more detailed description.

The Memory resource to create.

name: string

A name for the Memory.

srclang: string

An ISO 639-1 language identifier.

trglang: string

An ISO 639-1 language identifier.

srclocale: string

An ISO 3166-1 region name for language locales

trglocale: string

An ISO 3166-1 region name for language locales

Request Content-Types: application/json
Request Example
{
  "name": "automotive",
  "srclang": "en",
  "trglang": "fr",
  "srclocale": "US",
  "trglocale": "FR"
}
200 OK

A Memory object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 1234,
  "srclang": "en",
  "trglang": "fr",
  "srclocale": "US",
  "trglocale": "FR",
  "name": "Acme Corp Support Content",
  "is_processing": false,
  "version": 78,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "resources": [
    "string"
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve a Memory

GET /memories

Retrieve a Memory. If you cannot access the Memory (401 error) please check permissions (e.g. in case you created the Memory via the web app with a different account you may have to explicitly share that Memory).

id: integer
in query

An optional Memory identifier.

200 OK

A list of Memory objects.

type
default

Unexpected error

Response Example (200 OK)
[
  {
    "id": 1234,
    "srclang": "en",
    "trglang": "fr",
    "srclocale": "US",
    "trglocale": "FR",
    "name": "Acme Corp Support Content",
    "is_processing": false,
    "version": 78,
    "created_at": 1489147692,
    "updated_at": 1489147692,
    "resources": [
      "string"
    ]
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Update the name of a Memory

PUT /memories

Update a Memory.

The Memory resource to update.

id: integer

A unique Memory identifier.

name: string

The Memory name.

Request Content-Types: application/json
Request Example
{
  "id": 7246,
  "name": "Automotive Memory"
}
200 OK

A Memory object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 1234,
  "srclang": "en",
  "trglang": "fr",
  "srclocale": "US",
  "trglocale": "FR",
  "name": "Acme Corp Support Content",
  "is_processing": false,
  "version": 78,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "resources": [
    "string"
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Memory

DELETE /memories

Delete a Memory.

id: integer
in query

A unique Memory identifier.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "deleted": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Query a Memory

GET /memories/query

Perform a translation memory query.

id: integer
in query

A unique Memory identifier.

query: string
in query

A source query.

n: integer 10
in query

Maximum number of results to return.

A list of TranslationMemoryEntry objects.

default

Unexpected error

Response Example (200 OK)
[
  {
    "source": "The red bus.",
    "target": "Le bus rouge.",
    "score": 100,
    "metadata": "object"
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Get-sync for a Memory

GET /memories/sync

Get all or part of a memory in TMX 1.4b format. If the from_time and/or to_time are omitted, then all segments are returned. The parameter when specifies on which date field from_time and to_time are matched. Possible values are created (when the segment was originally created in the memory), updated (when the segment was lastly updated), and deleted (when the segment was deleted).

Example CURL command:

  curl -X GET https://lilt.com/2/memories/sync?key=API_KEY&id=42 -o from_lilt.tmx
id: integer
in query

A unique Memory identifier.

from_time: integer
in query

Unix time stamp (epoch, in seconds) of the start of the Memory section.

to_time: integer
in query

Unix time stamp (epoch, in seconds) of the end of the Memory section.

when: string
in query

The date field on which retrieved segments match from/to time stamps: created, updated, deleted. If this parameter is omitted, then the whole Memory is returned.

200 OK

A TMX 1.4b file.

type
string (byte)
default

Unexpected error

Response Content-Types: application/x-tmx
Response Example (200 OK)
"string (byte)"
Response Example (default )
{
  "message": "Internal server error."
}

Insert-sync for a Memory

POST /memories/sync

Inserts a TM in TMX 1.4b format into the Memory. Request parameters should be passed as JSON object with the header field LILT-API.

Example CURL command:

  curl -X POST https://lilt.com/2/memories/sync?key=API_KEY \
    --header "LILT-API: {\"name\": \"my_memory.tmx\",\"id\": 42}" \
    --header "Content-Type: application/octet-stream" \
    --data-binary @my_memory.tmx

The file contents to be uploaded. The entire POST body will be treated as the file.

id: integer
in header

A unique Memory identifier.

name: string
in header

Name of the TMX file.

Request Content-Types: application/octet-stream
Request Example
"string"
200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 123,
  "num_updates": 107
}
Response Example (default )
{
  "message": "Internal server error."
}

Update-sync for a Memory

PUT /memories/sync

Updates the Memory with given TMX file. Request parameters should be passed as JSON object with the header field LILT-API. The number of segments returned by the from_time, to_time, when parameters and the number of segments in the TMX file need to be identical.

Example CURL command:

  curl -X PUT https://lilt.com/2/memories/sync?key=API_KEY \
    --header "LILT-API: {\"name\": \"my_memory.tmx\", \"id\": 42, \"from_time\": 1491048000, \"to_time\": 1491049800, "when": "Updated"}" \
    --header "Content-Type: application/octet-stream" \
    --data-binary @my_memory.tmx

The file contents to be uploaded. The entire PUT body will be treated as the file.

id: integer
in header

A unique Memory identifier.

from_time: integer
in header

Unix time stamp (epoch, in seconds) of the start of the Memory section.

to_time: integer
in header

Unix time stamp (epoch, in seconds) of the end of the Memory section.

when: string
in header

The date field on which retrieved segments match from/to time stamps: created, updated, deleted.

Request Example
"string"
200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 123,
  "num_updates": "num_updates"
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete-sync for a Memory

DELETE /memories/sync

Deletes segments in the Memory matching the from_time, to_time and when parameters.

Example CURL command:

  curl -X DELETE https://lilt.com/2/memories/sync?key=API_KEY&id=42&from_time=1491048000&to_time=1491049800&when=created
id: integer
in query

A unique Memory identifier.

from_time: integer
in query

Unix time stamp (epoch, in seconds) of the start of the Memory section.

to_time: integer
in query

Unix time stamp (epoch, in seconds) of the end of the Memory section.

when: string
in query

The date field on which retrieved segments match from/to time stamps: created, updated, deleted.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 123,
  "num_updates": 107
}
Response Example (default )
{
  "message": "Internal server error."
}

File import for a Memory

POST /memories/import

Imports common translation memory or termbase file formats to a specific Lilt memory. Currently supported file formats are *.tmx, *.sdltm, *.sdlxliff(With custom Filters), '*.xliff', and *.tmq for TM data; *.csv and *.tbx for termbase data. Request parameters should be passed as JSON object with the header field LILT-API.

Example CURL command to upload a translation memory file named my_memory.sdltm in the current working directory:

  curl -X POST https://lilt.com/2/memories/import?key=API_KEY \
    --header "LILT-API: {\"name\": \"my_memory.sdltm\",\"memory_id\": 42}" \
    --header "Content-Type: application/octet-stream" \
    --data-binary @my_memory.sdltm

Example CURL command to upload a translation memory file named my_memory.sdlxliff in the current working directory, with Custom Filters based on SDLXLIFF fields, conf_name which maps to, percentage, and whether we should ignore unlocked segments.

  curl -X POST https://lilt.com/2/memories/import?key=API_KEY \
                      --header "LILT-API: {\"name\": \"my_memory.sdlxliff\",\"memory_id\": 12,\"sdlxliff_filters\":[{\"conf_name\": \"Translated\", \"percentage\": 100, \"allow_unlocked\": false}]"}" \
                      --header "Content-Type: application/octet-stream" \
                      --data-binary @my_memory.sdlxliff
                  
                  
                  

The file contents to be uploaded. The entire POST body will be treated as the file.

memory_id: integer
in header

A unique Memory identifier.

name: string
in header

Name of the TM or termbase file.

sdlxliff_filters: SDLXLIFFFilter
in header

Contains Filter information Unique to SDLXLIFF

has_header_row: boolean
in header

A flag indicating whether an imported Termbase CSV has a header row or not (the default value is false).

skip_duplicates: boolean
in header

A flag indicating whether or not to skip the import of segments which already exist in the memory. (the default value is false).

Request Content-Types: application/octet-stream
Request Example
"string (binary)"
200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 123,
  "isProcessing": 1
}
Response Example (default )
{
  "message": "Internal server error."
}

Termbase export for a Memory

POST /memories/termbase/export

Exports the termbase entries for the given memory into a CSV file.

Calling this endpoint will begin the export process in the background. Check that the processing is complete by polling the GET /2/memories endpoint. When the is_processing value is 0 then call the POST /2/memories/termbase/download endpoint.

  curl -X POST https://lilt.com/2/memories/termbase/export?key=API_KEY&id=ID
id: integer
in query

A unique Memory identifier.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 123,
  "is_processing": 1
}
Response Example (default )
{
  "message": "Internal server error."
}

Termbase download for a Memory

GET /memories/termbase/download

Downloads the termbase export for the given memory as a CSV file.

Ensure you first call the /2/memories/termbase/export endpoint to start the export process before you try to download it.

  curl -X GET https://lilt.com/2/memories/termbase/download?key=API_KEY&id=ID
id: integer
in query

A unique Memory identifier.

200 OK

A file.

type
string (byte)
default

Unexpected error

Response Example (200 OK)
"string (byte)"
Response Example (default )
{
  "message": "Internal server error."
}

Delete a segment from a memory.

DELETE /memories/segment

Delete a segment from a memory.

  curl -X DELETE https://lilt.com/2/memories/segment?key=API_KEY&id=ID&segment_id=$SEGMENT_ID
id: integer
in query

A unique Memory identifier.

segment_id: integer
in query

A unique Segment identifier.

200 OK

A success resposne.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "success": "boolean"
}
Response Example (default )
{
  "message": "Internal server error."
}

Jobs

Create a Job

POST /jobs

Create a Job. A Job is a collection of Projects. A Job will contain multiple projects, based on the language pair. A Project is associated with exactly one Memory.

Jobs appear in the Jobs dashboard of the web app.

Example CURL command:

curl -X POST 'https://lilt.com/2/jobs?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{
  "name": "test job",
  "fileIds": [5009, 5010, 5011],
  "due": "2022-05-05T10:56:44.985Z",
  "srcLang": "en",
  "srcLocale": "US",
  "languagePairs": [
      { "memoryId": 3121, "trgLang": "de" },
      { "memoryId": 2508, "trgLang": "fr" },
      { "memoryId": 3037, "trgLang": "zh" }
    ]
}'

The Job resource to create.

name: string

A name for the Job.

languagePairs: LanguagePair

Language pairs is a set of one or more pairs that includes source language, source locale(optional), target language, target locale(optional), and memoryId.

LanguagePair
fileIds: integer[]

A list of file ids to upload to job creation.

integer
due: string

An ISO string date representing job due date.

srcLang: string

2-letter ISO source language code

srcLocale: string

2-letter source language code

isPlural: boolean

A boolean value representing if the files have plurals.

workflowTemplateId: integer

Identifier of the workflow template to be used when creating a job. If not passed the organization default will be used.

workflowTemplateName: integer

Name of the workflow template to be used, must be passed with teamId or look up will fail. If workflowTemplateId is passed it supercedes any other look up.

Request Content-Types: application/json
Request Example
{
  "name": "My new Job",
  "languagePairs": [
    {
      "srcLang": "en",
      "srcLocale": "US",
      "trgLang": "de",
      "trgLocale": "DE",
      "dueDate": "2021-10-03T13:43:00.000Z",
      "memoryId": 1241,
      "externalModelId": 44,
      "pretranslate": "boolean",
      "autoAccept": true,
      "caseSensitive": "boolean",
      "takeMatchAttribution": true,
      "configId": 2332,
      "workflowTemplateId": 14,
      "workflowTemplateName": "Translate > Review",
      "workflowStageAssignments": [
        {
          "workflowStageTemplateId": 12345,
          "userId": 123,
          "email": "username@domain.com"
        }
      ]
    }
  ],
  "fileIds": [
    298,
    299
  ],
  "due": "2021-10-05T14:48:00.000Z",
  "srcLang": "en",
  "srcLocale": "US",
  "isPlural": true,
  "workflowTemplateId": 123,
  "workflowTemplateName": "Translate > Review"
}
200 OK
Job

A Job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve all Jobs

GET /jobs

Get all Jobs within a given offset and limit. You can retrieve jobs from your account using the above API.

Example CURL command:

curl -X GET 'https://lilt.com/2/jobs?key=API_KEY&isArchived=false'
isArchived: boolean
in query

Retrieves all jobs that are archived.

isDelivered: boolean
in query

Retrieves all jobs that are delivered.

offset: integer x ≥ 0
in query

Return jobs starting at the offset row. If not given the default offset will be 0.

limit: integer x ≤ 50
in query

The maximum number of jobs to be returned. If not given the default limit will be 25.

200 OK
Job

A list of Job objects.

type
Job
default

Unexpected error

Response Example (200 OK)
[
  {
    "name": "My New Job",
    "creationStatus": "COMPLETE",
    "deliveredAt": "2021-06-03T13:43:00.000Z",
    "status": "active",
    "due": "2021-06-03T13:43:00.000Z",
    "id": 241,
    "isProcessing": 0,
    "stats": {
      "exactWords": 0,
      "fuzzyWords": 0,
      "newWords": 0,
      "numDeliveredProjects": 0,
      "numLanguagePairs": 0,
      "numProjects": 0,
      "percentReviewed": 0,
      "percentTranslated": 0,
      "projects": [
        {
          "id": "en",
          "srcLang": "en",
          "srcLocale": "US",
          "trgLang": "fr",
          "trgLocale": "CA",
          "name": "My new project",
          "due": "2021-10-03T13:43:00.000Z",
          "isComplete": false,
          "isArchived": false,
          "state": "inProgress",
          "numSourceTokens": 2134,
          "createdAt": "2021-04-01T13:43:00.000Z",
          "updatedAt": "2021-06-03T13:43:00.000Z",
          "isDeleted": false,
          "memoryId": 2134,
          "workflowStatus": "READY_TO_START",
          "workflowName": "Translate > Review > Analyst Review"
        }
      ],
      "sourceWords": 0,
      "uniqueLanguagePairs": 1,
      "uniqueLinguists": 1,
      "workflowStatus": "READY_TO_START"
    }
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve a Job

GET /jobs/{jobId}

Retrieves a job data along with stats. To retrieve a specific job, you will need the job id in the url path.

Example CURL command:

curl -X GET 'https://lilt.com/2/jobs/{id}?key=API_KEY'
jobId: integer
in path

A job id.

200 OK
Job

A job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Update a Job

PUT /jobs/{jobId}

Updates a job with the new job properties. To update a specific job, you will need the job id in the url path.

You can update job's name and due date by passing the property and new value in the body.

Example CURL command:

curl -X PUT 'https://lilt.com/2/jobs/{id}?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{
  "name": "test job",
  "due": "2022-05-05T10:56:44.985Z"
}'

The Job resource to update.

name: string

A name for the Job.

dueDate: integer

An ISO string date.

isProcessing: string 0, 1, -2

The processing status of the job. Provide one of the following integers to indicate the status.

Ok = 0 Started = 1 ExportError = -2

processingErrorMsg: string

The processing error message.

jobId: integer
in path

A job id.

Request Example
{
  "name": "My new Job",
  "dueDate": "2021-10-05T14:48:00.000Z",
  "isProcessing": "ExportError",
  "processingErrorMsg": "Authentication failed. Check your Contentful API Key."
}
200 OK
Job

A job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Job

DELETE /jobs/{jobId}

Delete a job, deletes all projects and documents in the job, deletes all the segments from all the job's translation memories.

Example CURL command:

curl -X DELETE 'https://lilt.com/2/jobs/{id}?key=API_KEY'
jobId: integer
in path

A job id.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 241
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve Job Leverage Stats

POST /jobs/{jobId}/stats

Get the TM leverage stats for the job (new/exact/fuzzy matches).

Example CURL command:

curl -X POST 'https://lilt.com/2/jobs/{id}/stats?key=API_KEY'
jobId: integer
in path

A job id.

A job leverage stats object.

default

Unexpected error

Response Example (200 OK)
{
  "sourceWords": 0,
  "exactWords": 0,
  "fuzzyWords": 0,
  "newWords": 0,
  "projects": [
    {
      "id": 1,
      "sourceWords": 1000,
      "exactWords": 800,
      "fuzzyWords": 150,
      "newWords": 50
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Archive a Job

POST /jobs/{jobId}/archive

Set job to archived, unassign all linguists and archive all projects and documents inside the job.

It will return the archived job.

Example CURL command:

curl -X POST 'https://lilt.com/2/jobs/{id}/archive?key=API_KEY'
jobId: integer
in path

A job id.

200 OK
Job

A job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Unarchive a Job

POST /jobs/{jobId}/unarchive

Set job to unarchived, the job will move to active status.

Example CURL command:

curl -X POST 'https://lilt.com/2/jobs/{id}/unarchive?key=API_KEY'
jobId: integer
in path

A job id.

200 OK
Job

A job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Deliver a Job

POST /jobs/{jobId}/deliver

Set the job state to delivered and set all the projects in the job to done

It will return the delivered job.

Example CURL command:

curl -X POST 'https://lilt.com/2/jobs/{id}/deliver?key=API_KEY'
jobId: integer
in path

A job id.

200 OK
Job

A job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Reactivate a Job

POST /jobs/{jobId}/reactivate

Set the job state to active. Does not change the state of projects associated with the given job.

It will return the reactivated job.

Example CURL command:

curl -X POST 'https://lilt.com/2/jobs/{id}/reactivate?key=API_KEY'
jobId: integer
in path

A job id.

200 OK
Job

A job object.

default

Unexpected error

Response Example (200 OK)
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}
Response Example (default )
{
  "message": "Internal server error."
}

Export a Job

GET /jobs/{jobId}/export

Prepare job files for download. To export translated documents from the job use the query parameter type=files:

Example CURL command:

curl -X GET 'https://lilt.com/2/jobs/{id}/export?key=API_KEY&type=files'

To export job memories use the query parameter type=memory.

The status of the export can be checked by requesting the job GET /jobs/:jobId, job.isProcessing will be 1 while in progress, 0 when idle and -2 when the export failed.

jobId: integer
in path

A job id.

type: string
in query

category for files and memory.

200 OK

200 status.

default

Unexpected error

Response Example (default )
{
  "message": "Internal server error."
}

Download a Job

GET /jobs/{jobId}/downlod

Make sure you have exported a job with the same id before using this api.

Downloading files requires the exported job id in the param.

Example CURL command:

curl -X GET 'https://lilt.com/2/jobs/{id}/download?key=API_KEY'
jobId: integer
in path

A job id.

200 OK

zipped file

default

Unexpected error

Response Example (default )
{
  "message": "Internal server error."
}

Projects

Create a Project

POST /projects

Create a Project. A Project is a collection of Documents.

A Project is associated with exactly one Memory.

Projects appear in the dashboard of the web app.

The Project resource to create.

name: string

A name for the Project.

memory_id: integer

The Memory to associate with this new Project.

job_id: integer

The Job to associate with this new Project. If a Job ID is not provided then a new Job will be created to contain the Project.

due_date: integer

The due date. Measured in seconds since the Unix epoch.

metadata: object

A JSON object of key/value string pairs. Stores custom project information.

workflowTemplateId: integer

The workflow template used to create this project. WorkflowTemplateIds can be retrieved via the /workflows/templates endpoint. If not specified then the organization default workflowTemplateId will be used.

workflow_template_name: string

The LLM provider to use for this project. If not specified then the "neural" LLM provider will be used.

llm_provider: string

The LLM provider to use for this project. If not specified then the "neural" LLM provider will be used.

external_model_id: integer

The external model id to use for project creation. The model provider needs to match the llm_provider that has been set.

is_plural: boolean

If true then documents in this project contain ICU plural forms. If false, ICU plural forms will not be parsed. Defaults to false.

Request Content-Types: application/json
Request Example
{
  "name": "My new project",
  "memory_id": 1234,
  "job_id": 1234,
  "due_date": 1489147692,
  "metadata": {
    "connectorType": "github",
    "notes": "example metadata"
  },
  "workflowTemplateId": 14,
  "workflow_template_name": "neural",
  "llm_provider": "neural",
  "external_model_id": 123,
  "is_plural": false
}
200 OK

A Project object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 448,
  "memory_id": 1234,
  "job_id": 1234,
  "srclang": "en",
  "trglang": "fr",
  "srclocale": "US",
  "trglocale": "FR",
  "name": "My New Project",
  "state": "backlog",
  "due_date": 1489147692,
  "archived": false,
  "metadata": {
    "connectorType": "github",
    "notes": "example metadata"
  },
  "sample_review_percentage": 20,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "workflowStatus": "READY_TO_START",
  "document": [
    {
      "id": 46530,
      "project_id": 287,
      "srclang": "en",
      "trglang": "de",
      "name": "Introduction.xliff",
      "import_in_progress": false,
      "import_succeeded": false,
      "import_error_message": "Could not parse XML.",
      "export_in_progress": false,
      "export_succeeded": false,
      "export_error_message": "Could not parse XML.",
      "is_pretranslating": false,
      "status": {
        "pretranslation": "idle"
      },
      "translator_email": "translator@example.com",
      "reviewer_email": "reviewer@example.com",
      "customer_reviewer_email": "reviewer@example.com",
      "created_at": 1489147692,
      "updated_at": 1489147692,
      "is_review_complete": true
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve a Project

GET /projects

Retrieves one or more projects, including the documents associated with each project. Retrieving a project is the most efficient way to retrieve a single project, multiple projects or a list of all available projects.

To retrieve a specific project, specify the id request parameter or you can retrieve multiple projects by adding comma (,) between ids eg. ?id=1234,5678. To retrieve all projects, omit the id request parameter. To limit the retrieved projects to those with a particular source language or target language, specify the corresponding ISO 639-1 language codes in the srclang and trglang request parameters, respectively.

id: integer
in query

A unique Project identifier. It can be a single id or multiple ids separated by a comma

srclang: string
in query

An ISO 639-1 language code.

trglang: string
in query

An ISO 639-1 language code.

from_time: integer
in query

Unix time stamp (epoch, in seconds) of Projects with created_at greater than or equal to the value.

to_time: integer
in query

Unix time stamp (epoch, in seconds) of Projects with created_at less than the value.

state: string
in query

A project state (backlog, inProgress, inReview, inQA, done).

archived: boolean
in query

A flag that toggles whether to include archived projects in the response (the default is true).

connector_id: integer
in query

A unique Connector identifier.

200 OK

A list of Project objects.

type
default

Unexpected error

Response Example (200 OK)
[
  {
    "id": 448,
    "memory_id": 1234,
    "job_id": 1234,
    "srclang": "en",
    "trglang": "fr",
    "srclocale": "US",
    "trglocale": "FR",
    "name": "My New Project",
    "state": "backlog",
    "due_date": 1489147692,
    "archived": false,
    "metadata": {
      "connectorType": "github",
      "notes": "example metadata"
    },
    "sample_review_percentage": 20,
    "created_at": 1489147692,
    "updated_at": 1489147692,
    "workflowStatus": "READY_TO_START",
    "document": [
      {
        "id": 46530,
        "project_id": 287,
        "srclang": "en",
        "trglang": "de",
        "name": "Introduction.xliff",
        "import_in_progress": false,
        "import_succeeded": false,
        "import_error_message": "Could not parse XML.",
        "export_in_progress": false,
        "export_succeeded": false,
        "export_error_message": "Could not parse XML.",
        "is_pretranslating": false,
        "status": {
          "pretranslation": "idle"
        },
        "translator_email": "translator@example.com",
        "reviewer_email": "reviewer@example.com",
        "customer_reviewer_email": "reviewer@example.com",
        "created_at": 1489147692,
        "updated_at": 1489147692,
        "is_review_complete": true
      }
    ]
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Update a Project

PUT /projects

Update a Project.

The Project resource to update.

id: integer

A unique Project identifier.

name: string

The Project name.

state: string

The project's state. The possible states are 'backlog', 'inProgress', 'inReview', 'inQA', and 'done'

due_date: integer

The due date. Measured in seconds since the Unix epoch.

archived: boolean

True if the project is archived. Otherwise, false.

metadata: object

Metadata associated with a project. This field must be valid JSON.

sample_review_percentage: integer

The Project's sample review percentage. Must be an integer between 10 and 100, a multiple of 10 and greater than minimum value (displayed in error message).

Request Content-Types: application/json
Request Example
{
  "id": 1234,
  "name": "Walker Percy Essays",
  "state": "backlog",
  "due_date": 1489147692,
  "archived": false,
  "metadata": {
    "connectorType": "github",
    "notes": "example metadata"
  },
  "sample_review_percentage": 20
}
200 OK

A Project object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 448,
  "memory_id": 1234,
  "job_id": 1234,
  "srclang": "en",
  "trglang": "fr",
  "srclocale": "US",
  "trglocale": "FR",
  "name": "My New Project",
  "state": "backlog",
  "due_date": 1489147692,
  "archived": false,
  "metadata": {
    "connectorType": "github",
    "notes": "example metadata"
  },
  "sample_review_percentage": 20,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "workflowStatus": "READY_TO_START",
  "document": [
    {
      "id": 46530,
      "project_id": 287,
      "srclang": "en",
      "trglang": "de",
      "name": "Introduction.xliff",
      "import_in_progress": false,
      "import_succeeded": false,
      "import_error_message": "Could not parse XML.",
      "export_in_progress": false,
      "export_succeeded": false,
      "export_error_message": "Could not parse XML.",
      "is_pretranslating": false,
      "status": {
        "pretranslation": "idle"
      },
      "translator_email": "translator@example.com",
      "reviewer_email": "reviewer@example.com",
      "customer_reviewer_email": "reviewer@example.com",
      "created_at": 1489147692,
      "updated_at": 1489147692,
      "is_review_complete": true
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Update multiple Projects

PUT /projects

Update multiple Projects.

The Project resources to update.

object
id: integer

A unique Project identifier.

name: string

The Project name.

state: string

The project's state. The possible states are 'backlog', 'inProgress', 'inReview', 'inQA', and 'done'

due_date: integer

The due date. Measured in seconds since the Unix epoch.

archived: boolean

True if the project is archived. Otherwise, false.

metadata: object

Metadata associated with a project. This field must be valid JSON.

sample_review_percentage: integer

The Project's sample review percentage. Must be an integer between 10 and 100, a multiple of 10 and greater than minimum value (displayed in error message).

Request Content-Types: application/json
Request Example
[
  {
    "id": 1234,
    "name": "Walker Percy Essays",
    "state": "backlog",
    "due_date": 1489147692,
    "archived": false,
    "metadata": {
      "connectorType": "github",
      "notes": "example metadata"
    },
    "sample_review_percentage": 20
  }
]
200 OK

The updated Project objects.

type
default

Unexpected error

Response Example (200 OK)
[
  {
    "id": 448,
    "memory_id": 1234,
    "job_id": 1234,
    "srclang": "en",
    "trglang": "fr",
    "srclocale": "US",
    "trglocale": "FR",
    "name": "My New Project",
    "state": "backlog",
    "due_date": 1489147692,
    "archived": false,
    "metadata": {
      "connectorType": "github",
      "notes": "example metadata"
    },
    "sample_review_percentage": 20,
    "created_at": 1489147692,
    "updated_at": 1489147692,
    "workflowStatus": "READY_TO_START",
    "document": [
      {
        "id": 46530,
        "project_id": 287,
        "srclang": "en",
        "trglang": "de",
        "name": "Introduction.xliff",
        "import_in_progress": false,
        "import_succeeded": false,
        "import_error_message": "Could not parse XML.",
        "export_in_progress": false,
        "export_succeeded": false,
        "export_error_message": "Could not parse XML.",
        "is_pretranslating": false,
        "status": {
          "pretranslation": "idle"
        },
        "translator_email": "translator@example.com",
        "reviewer_email": "reviewer@example.com",
        "customer_reviewer_email": "reviewer@example.com",
        "created_at": 1489147692,
        "updated_at": 1489147692,
        "is_review_complete": true
      }
    ]
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Project

DELETE /projects

Delete a Project.

id: integer
in query

A unique Project identifier.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "deleted": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Update multiple Projects with a single payload

PUT /projects/bulk-update

Update multiple Projects with a single payload.

The Project resources to update.

projectIds: integer[]
integer

A unique Project identifier.

project: object
name: string

The Project name.

state: string

The project's state. The possible states are 'backlog', 'inProgress', 'inReview', 'inQA', and 'done'

due_date: integer

The due date. Measured in seconds since the Unix epoch.

archived: boolean

True if the project is archived. Otherwise, false.

metadata: object

Metadata associated with a project. This field must be valid JSON.

sample_review_percentage: integer

The Project's sample review percentage. Must be an integer between 10 and 100, a multiple of 10 and greater than minimum value (displayed in error message).

Request Content-Types: application/json
Request Example
{
  "projectIds": [
    1234
  ],
  "project": {
    "name": "Walker Percy Essays",
    "state": "backlog",
    "due_date": 1489147692,
    "archived": false,
    "metadata": {
      "connectorType": "github",
      "notes": "example metadata"
    },
    "sample_review_percentage": 20
  }
}
200 OK

The updated Project objects.

type
default

Unexpected error

Response Example (200 OK)
[
  {
    "id": 448,
    "memory_id": 1234,
    "job_id": 1234,
    "srclang": "en",
    "trglang": "fr",
    "srclocale": "US",
    "trglocale": "FR",
    "name": "My New Project",
    "state": "backlog",
    "due_date": 1489147692,
    "archived": false,
    "metadata": {
      "connectorType": "github",
      "notes": "example metadata"
    },
    "sample_review_percentage": 20,
    "created_at": 1489147692,
    "updated_at": 1489147692,
    "workflowStatus": "READY_TO_START",
    "document": [
      {
        "id": 46530,
        "project_id": 287,
        "srclang": "en",
        "trglang": "de",
        "name": "Introduction.xliff",
        "import_in_progress": false,
        "import_succeeded": false,
        "import_error_message": "Could not parse XML.",
        "export_in_progress": false,
        "export_succeeded": false,
        "export_error_message": "Could not parse XML.",
        "is_pretranslating": false,
        "status": {
          "pretranslation": "idle"
        },
        "translator_email": "translator@example.com",
        "reviewer_email": "reviewer@example.com",
        "customer_reviewer_email": "reviewer@example.com",
        "created_at": 1489147692,
        "updated_at": 1489147692,
        "is_review_complete": true
      }
    ]
  }
]
Response Example (default )
{
  "message": "Internal server error."
}

Deliver multiple projects apart from their jobs.

POST /projects/bulk-deliver

Deliver mulitple projects apart from their jobs.

The Project resources to update.

projectIds: integer[]
integer

A unique Project identifier.

workflowEnabled: boolean
in query

Whether the project has or not workflows enabled. (not used)

Request Content-Types: application/json
Request Example
{
  "projectIds": [
    1234
  ]
}
200 OK

Empty response if succeed.

default

Unexpected error

Response Example (default )
{
  "message": "Internal server error."
}

Retrieve Project report

GET /projects/quote

Get information about a project that can be used for quoting. This includes:

  • A translation memory leverage report
  • Word count
  • Segment count
id: integer
in query

A unique Project identifier.

200 OK

An object that represents a Project quote.

default

Unexpected error

Response Example (200 OK)
{
  "id": 21902,
  "num_source_words": 8000,
  "num_words_new": 6039,
  "num_segments_new": 151,
  "num_words_repetition": 12,
  "num_segments_repetition": 2980000,
  "bands": [
    {
      "minimum_score": 94,
      "maximum_score": 85,
      "num_source_words": 151,
      "num_segments": 12
    }
  ],
  "documents": [
    {
      "id": 21902,
      "num_source_words": 8000,
      "num_words_new": 6039,
      "num_segments_new": 151,
      "num_words_repetition": 12,
      "num_segments_repetition": 2980000,
      "bands": [
        {
          "minimum_score": 94,
          "maximum_score": 85,
          "num_source_words": 151,
          "num_segments": 12
        }
      ]
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve Project revision report

GET /projects/{id}/revision

Get information about a project's revision report. This includes:

  • Stats on accepted segments
  • reviewer details
  • Error rate
id: integer
in path

A unique Project identifier.

200 OK

A csv file containing revision report.

default

Unexpected error

Response Example (default )
{
  "message": "Internal server error."
}

Retrieve Project status

GET /projects/status

Retrieve the status of a Project.

id: integer
in query

A unique Project identifier.

200 OK

An object that represents a Project status report.

default

Unexpected error

Response Example (200 OK)
{
  "id": 21902,
  "num_source_words": 6039,
  "num_words_confirmed": 151,
  "num_words_reviewed": 12,
  "time_elapsed": 2980000,
  "time_elapsed_translation": 33487,
  "time_elapsed_research": 912348,
  "time_elapsed_review": 66521,
  "updated_at": 1656513752,
  "resources": [
    {
      "email": "joe.strummer@lilt.com",
      "name": "Joe Strummer",
      "num_words_confirmed": 151,
      "num_words_new": 12,
      "num_words_fuzzy": 24,
      "num_words_exact": 56,
      "num_words_reviewed": 182,
      "time_elapsed": 1172000,
      "time_elapsed_translation": 1172000,
      "time_elapsed_research": 1172000,
      "time_elapsed_review": 1172000,
      "num_segments_confirmed": 25,
      "num_segments_reviewed": 30
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Auto Assignment

POST /autoAssignment

Trigger automatic assignment of linguists.

Requires auto-assignment to be enabled as a setting on the origanization level.

An array of project ids to auto-assign. (optional) If projectIds is specified in the querystring it will have precedence.

projectIds: integer[]
integer
projectIds: string
in query

The comma separated list of project ids to auto-assign. Can be sent in the body as an alternative but if both are specified the query has precedence.

Request Content-Types: application/json
Request Example
{
  "projectIds": [
    "integer"
  ]
}

An auto assignment response.

400 Bad Request

Bad request. Possible causes include no permission to the projects and the auto-assignment setting not being enabled.

default

Unexpected error

Response Example (200 OK)
[
  {
    "projectId": 123,
    "success": "boolean",
    "error": "string",
    "errors": [
      {
        "errorType": "LINGUIST_MAY_BE_DELETED",
        "projectId": 123,
        "documentId": 456,
        "error": "Linguist may be deleted"
      }
    ],
    "assignments": [
      {
        "isPreferredTranslator": true,
        "wordsLeftAveragedTranslator": 56,
        "wordsLeftAveragedReviewer": 56,
        "assignmentErrors": [
          "Error message"
        ],
        "docId": 56,
        "projectId": 56,
        "isAutoAssigned": true,
        "translatorUserId": 56,
        "translatorRoleId": 56,
        "translatorDueDate": "2023-03-28T16:00:00Z",
        "reviewerUserId": 56
      }
    ]
  }
]
Response Example (400 Bad Request)
{
  "message": "Bad Request."
}
Response Example (default )
{
  "message": "Internal server error."
}

QA

QA

Perform QA check

GET /qa

Perform QA checks on a target string. Optionally, you can specify a source string for additional bilingual checks, e.g. number consistency.

target: string
in query

A target string to be checked.

trglang: string
in query

An ISO 639-1 language code.

source: string
in query

An optional source string.

srclang: string
in query

An ISO 639-1 language code.

memory_id: integer
in query

Any custom rules defined for this Memory will also be applied as part of the QA check.

200 OK

A QARuleMatches object.

default

Unexpected error

Response Example (200 OK)
{
  "matches": [
    {
      "context": {
        "length": 7,
        "offset": 19,
        "text": "This segment has a speling mistake"
      },
      "length": 7,
      "message": "Possible spelling mistake found",
      "offset": 19,
      "replacements": [
        {
          "value": "spelling"
        },
        {
          "value": "spewing"
        },
        {
          "value": "spieling"
        }
      ],
      "rule": {
        "category": {
          "id": "TYPOS",
          "name": "Possible Typo"
        },
        "description": "Possible spelling mistake",
        "id": "MORFOLOGIK_RULE_EN_US",
        "issueType": "misspelling",
        "subId": "",
        "urls": []
      },
      "shortMessage": "Spelling mistake"
    }
  ],
  "custom_rules": [
    {
      "description": "Mistake detected by a custom rule."
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Segments

Create a Segment

POST /segments

Create a Segment and add it to a Memory or a Document. A Segment is a source/target pair that is used to train the machine translation system and populate the translation memory.

The maximum source length is 5,000 characters.

The Segment resource to create.

To add a Segment to a Memory, include the memory_id and target parameters.

To add a Segment to a Document, include the document_id and the source parameters. The target parameter is optional.

memory_id: integer

A unique Memory identifier.

document_id: integer

A unique Document identifier.

source: string

The source string.

target: string

The target string.

shouldApplySegmentation: boolean

A flag for whether this segment should be broken down into smaller segments. If this is true then the response is an array of segments.

srcLang: string

A two letter language code for the source language. Required if shouldApplySegmentation is enabled.

Request Content-Types: application/json
Request Example
{
  "memory_id": 10641,
  "document_id": 1876,
  "source": "Code zur Fehleranalyse einschalten",
  "target": "Enable debugging code",
  "shouldApplySegmentation": "boolean",
  "srcLang": "fr"
}
200 OK

A Segment object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 84480010,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "document_id": 1234,
  "memory_id": 5678,
  "source": "The red bus.",
  "srclang": "en",
  "target": "Le bus rouge.",
  "trglang": "fr",
  "is_confirmed": true,
  "is_reviewed": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Retrieve a Segment

GET /segments

Retrieve a Segment.

id: integer
in query

A unique Segment identifier.

include_comments: boolean false
in query

Include comments in the response.

A Segment object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 84480010,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "document_id": 1234,
  "memory_id": 5678,
  "source": "The red bus.",
  "srclang": "en",
  "target": "Le bus rouge.",
  "trglang": "fr",
  "is_confirmed": true,
  "is_reviewed": true,
  "comments": [
    {
      "id": 84480010,
      "text": "This is incorrect.",
      "annotations": [
        {
          "text": "mistranslation"
        }
      ],
      "is_resolved": true,
      "document_id": 5678,
      "segment_id": 5678,
      "segment_revision_id": 5678,
      "user_id": 5678,
      "created_at": 1489147692
    }
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Update a Segment

PUT /segments

Update a Segment in memory. The Memory will be updated with the new target string.

The Segment resource to update.

id: integer

A unique Segment identifier.

target: string

The target string.

Request Content-Types: application/json
Request Example
{
  "id": 84480010,
  "target": "Enable debug code"
}
200 OK

A Segment object.

default

Unexpected error

Response Example (200 OK)
{
  "id": 84480010,
  "created_at": 1489147692,
  "updated_at": 1489147692,
  "document_id": 1234,
  "memory_id": 5678,
  "source": "The red bus.",
  "srclang": "en",
  "target": "Le bus rouge.",
  "trglang": "fr",
  "is_confirmed": true,
  "is_reviewed": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Delete a Segment

DELETE /segments

Delete a Segment from memory. This will not delete a segment from a document.

id: integer
in query

A unique Segment identifier.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "id": 46530,
  "deleted": true
}
Response Example (default )
{
  "message": "Internal server error."
}

Unaccept and unlock segments

POST /segments/review/unlock

Unaccept and unlock segments. Sets individual segments' "Review Done" to false. Confirmed segments will remain confirmed.

Example curl:

  curl --X --request POST 'https://lilt.com/2/segments/review/unlock?key=API_KEY' \
  --header 'Content-Type: application/json' \
  --data-raw '{
      "segmentIds": [23921, 23922]
  }'

segment ids to update

documentIds: number[]

array of segment ids

number
Request Example
{
  "documentIds": [
    30032,
    30125
  ]
}
200 OK

array of updated segments

type
number[]
Response Example (200 OK)
[
  "number"
]

Tag a Segment

GET /segments/tag

Project tags for a segment. The source_tagged string contains one or more SGML tags. The target string is untagged. This endpoint will automatically place the source tags in the target.

Usage charges apply to this endpoint for production REST API keys.

source_tagged: string
in query

The tagged source string.

target: string
in query

The target string.

memory_id: integer
in query

A unique Memory identifier.

200 OK

A TaggedSegment object.

default

Unexpected error

Response Example (200 OK)
{
  "source_tagged": "The <b>red bus.</b>",
  "target_tagged": "Le <b>bus rouge.</b>"
}
Response Example (default )
{
  "message": "Internal server error."
}

Settings

Update or create a setting

POST /settings

Create or update the value for the given setting and setting scope.

Example CURL to set an organization-level setting:

curl --location --request POST 'https://lilt.com/2/settings?key=<API_KEY>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "settingName": "requireBatchQaTranslator",
    "value": false,
    "organizationId": 285,
    "scope": "Organization"
}'

undefined

Request Example
{
  "settingName": "requireBatchQaTranslator",
  "scope": "Organization",
  "value": "string | integer | object | boolean",
  "isEnforced": "boolean",
  "projectId": "number",
  "organizationId": 123
}

Updated settings object and updated active settings.

default

Unexpected error

Response Example (200 OK)
{
  "scopedSetting": {
    "id": "integer (int32)",
    "name": "string",
    "valueType": "string",
    "value": "string | integer | object | boolean",
    "defaultValue": "string | integer | object | boolean",
    "isUserFacing": "boolean",
    "isDefault": "boolean"
  },
  "activeSettings": "object"
}
Response Example (default )
{
  "message": "Internal server error."
}

Get organization-level settings

GET /settings/organization

Get the organization-level settings for the active users organization

Example CURL:

curl --location --request GET 'https://lilt.com/2/settings/organization?key=<API_KEY>' \

Organization settings dictionary.

default

Unexpected error

Response Example (200 OK)
"object"
Response Example (default )
{
  "message": "Internal server error."
}

Get settings for a project

GET /settings/project/{projectId}

Get the settings as applied to a specific project. Active settings will combine project-level settings, organization-level settings and fallback to setting default values.

Example CURL:

curl --location --request GET 'https://lilt.com/2/settings/project/123?key=<API_KEY>' \
projectId: integer
in path

A project id.

Project settings dictionary.

default

Unexpected error

Response Example (200 OK)
"object"
Response Example (default )
{
  "message": "Internal server error."
}

Get settings for the authenticated user

GET /settings/user

Get the active settings applied to the authenticated user.

Example CURL:

curl --location --request GET 'https://lilt.com/2/settings/user?key=<API_KEY>' \

Settings dictionary.

default

Unexpected error

Response Example (200 OK)
"object"
Response Example (default )
{
  "message": "Internal server error."
}

Translate

Translate a segment

GET /translate

Translate a source string.

Setting the rich parameter to true will change the response format to include additional information about each translation including a model score, word alignments, and formatting information. The rich format can be seen in the example response on this page.

By default, this endpoint also returns translation memory (TM) fuzzy matches, along with associated scores. Fuzzy matches always appear ahead of machine translation output in the response.

The source parameter may be supplied in the query or in the request body.

The maximum source length is 5,000 characters.

Usage charges apply to this endpoint for production REST API keys.

The source text to be translated.

source: string

A unique Segment identifier.

memory_id: integer
in query

A unique Memory identifier.

source: string
in query

The source text to be translated.

source_hash: integer
in query

A source hash code.

prefix: string
in query

A target prefix.

n: integer 1
in query

Return top n translations (deprecated).

rich: boolean false
in query

Returns rich translation information (e.g., with word alignments).

tm_matches: boolean true
in query

Include translation memory fuzzy matches.

project_tags: boolean false
in query

Project tags. Projects tags in source to target if set to true.

contains_icu_data: boolean false
in query

Contains ICU data. If true then tags in the source following the ICU standard will be parsed and retained.

Request Example
{
  "source": "string"
}

A TranslationList object.

202 Accepted

When the ML model is loading.

default

Unexpected error

Response Example (200 OK)
{
  "untokenizedSource": "Authentication not required.",
  "tokenizedSource": "Authentication not required .",
  "sourceDelimiters": [
    "",
    " ",
    " ",
    "",
    ""
  ],
  "translation": [
    [
      {
        "score": 3.4936864e-8,
        "align": "0-0 1-1 2-2 3-3",
        "targetDelimiters": [
          "",
          " ",
          " ",
          "",
          ""
        ],
        "targetWords": [
          "Authentifizierung",
          "nicht",
          "erforderlich",
          "."
        ],
        "target": "Authentifizierung nicht erforderlich .",
        "targetWithTags": "Authentifizierung nicht erforderlich.",
        "isTMMatch": false,
        "provenance": "0 0 0 0"
      }
    ]
  ]
}
Response Example (202 Accepted)
{
  "untokenizedSource": "Authentication not required.",
  "tokenizedSource": "Authentication not required .",
  "sourceDelimiters": [
    "",
    " ",
    " ",
    "",
    ""
  ],
  "translation": [
    [
      {
        "score": 3.4936864e-8,
        "align": "0-0 1-1 2-2 3-3",
        "targetDelimiters": [
          "",
          " ",
          " ",
          "",
          ""
        ],
        "targetWords": [
          "Authentifizierung",
          "nicht",
          "erforderlich",
          "."
        ],
        "target": "Authentifizierung nicht erforderlich .",
        "targetWithTags": "Authentifizierung nicht erforderlich.",
        "isTMMatch": false,
        "provenance": "0 0 0 0"
      }
    ]
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Translate a segment

POST /translate

Translate a source string.

Setting the rich parameter to true will change the response format to include additional information about each translation including a model score, word alignments, and formatting information. The rich format can be seen in the example response on this page.

By default, this endpoint also returns translation memory (TM) fuzzy matches, along with associated scores. Fuzzy matches always appear ahead of machine translation output in the response.

The maximum source length is 5,000 characters.

Usage charges apply to this endpoint for production REST API keys.

source: string

A unique Segment identifier.

memory_id: integer

A unique Memory identifier.

source_hash: integer

A source hash code.

n: integer 1

Return top n translations (deprecated).

prefix: string

A target prefix

rich: boolean false

Returns rich translation information (e.g., with word alignments).

tm_matches: boolean true

Include translation memory fuzzy matches.

project_tags: boolean false

Project tags. Projects tags in source to target if set to true.

containsICUData: boolean false

Contains ICU data. If true then tags in the source following the ICU standard will be parsed and retained.

Request Example
{
  "source": "string",
  "memory_id": "integer",
  "source_hash": "integer",
  "n": "integer",
  "prefix": "string",
  "rich": "boolean",
  "tm_matches": "boolean",
  "project_tags": "boolean",
  "containsICUData": "boolean"
}

A TranslationList object.

default

Unexpected error

Response Example (200 OK)
{
  "untokenizedSource": "Authentication not required.",
  "tokenizedSource": "Authentication not required .",
  "sourceDelimiters": [
    "",
    " ",
    " ",
    "",
    ""
  ],
  "translation": [
    [
      {
        "score": 3.4936864e-8,
        "align": "0-0 1-1 2-2 3-3",
        "targetDelimiters": [
          "",
          " ",
          " ",
          "",
          ""
        ],
        "targetWords": [
          "Authentifizierung",
          "nicht",
          "erforderlich",
          "."
        ],
        "target": "Authentifizierung nicht erforderlich .",
        "targetWithTags": "Authentifizierung nicht erforderlich.",
        "isTMMatch": false,
        "provenance": "0 0 0 0"
      }
    ]
  ]
}
Response Example (default )
{
  "message": "Internal server error."
}

Register a segment

GET /translate/register

Register a source string for interactive translation. The source_hash value that is returned by this request is required by the prefix parameter for the translation endpoint. The maximum source length is 5,000 characters. Usage charges apply to this endpoint for production REST API keys.

source: string
in query

A source string to be registered.

srclang: string
in query

An ISO 639-1 language code.

trglang: string
in query

An ISO 639-1 language code.

200 OK

A status object.

type
object
default

Unexpected error

Response Example (200 OK)
{
  "source_hash": 11476,
  "num_words": 88
}
Response Example (default )
{
  "message": "Internal server error."
}

Translate a File

POST /translate/file

Start machine translation of one or more Files that have previously been uploaded. The response will include an id parameter that can be used to monitor and download the translations in subsequent calls.

Example CURL:

curl --X --request POST 'https://lilt.com/2/translate/file?key=API_KEY&fileId=583&memoryId=2495&configId=123&withTM=true'
fileId: string
in query

List of File ids to be translated, comma separated.

memoryId: string
in query

Id of Memory to use in translation.

configId: number
in query

An optional pararameter to specify an import configuration to be applied when extracting translatable content from this file.

withTM: boolean
in query

An optional boolean parameter to toggle the use of Translation Memory in the translation of the file.

Translation info

default

Unexpected error

Response Example (200 OK)
{
  "id": 1,
  "fileId": "2,",
  "status": "InProgress",
  "createdAt": 1609357135
}
Response Example (default )
{
  "message": "Internal server error."
}

Monitor file translation

GET /translate/file

Get information about the one or more Files that are being translated with machine translation. Query filters are optional but at least one must be provided.

Example CURL:

curl --X --request GET 'https://lilt.com/2/translate/file?key=API_KEY&translationIds=1,2&fromTime=1607966744&toTime=1707966744&status=InProgress'
translationIds: string
in query

List of translation ids, comma separated

status: string
in query

One of the translation statuses - InProgress, Completed, Failed, ReadyForDownload

fromTime: number
in query

Results after this time (inclusive) will be returned, specified as seconds since the Unix epoch.

toTime: number
in query

Results before this time (exclusive) will be returned, specified as seconds since the Unix epoch.

Translation info

Unexpected error

Response Example (200 OK)
{
  "id": 1,
  "fileId": "2,",
  "status": "InProgress",
  "createdAt": 1609357135
}
Response Example (default )
{
  "Unsupported_file_type": {
    "message": "Customer gave us garbage."
  },
  "File_extraction_error": {
    "message": "Customer gave us garbage."
  },
  "No_translatable_content": {
    "message": "Customer gave us an empty file."
  },
  "Batch_MT_initiation_failure": {
    "message": "Something is wrong with MT."
  },
  "Batch_MT_response_failure": {
    "message": "Something is wrong with MT."
  },
  "File_reassembly_error": {
    "message": "We couldn't put the translated file back together.(okapi error)"
  },
  "Billing_error": {
    "message": "We couldn't log the information about the MT to our billing system."
  },
  "Invalid_memory": {
    "message": "Something is wrong with the memory."
  },
  "Storage_error": {
    "message": "Error occurred interacting with file storage."
  }
}

Download translated file

GET /translate/files

Download a translated File.

Example CURL:

curl --X --request GET 'https://lilt.com/2/translate/files?key=API_KEY&id=1'
id: string
in query

A translation id.

200 OK

A file.

type
string (byte)
Response Content-Types: application/octet-stream
Response Example (200 OK)
"string (byte)"

Create

Sign the Lilt Create terms and conditions

POST /create/terms-and-conditions

Lilt Create requires that the terms and conditions are signed first before using it. The terms and conditions can be signed by using this endpoint.

Example CURL:

curl --X --request POST 'https://lilt.com/2/create/terms-and-conditions?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{"signedAgreement": true}'
Request Example
"boolean"
200 OK

An object indicating whether the agreement has been signed or not.

type
object
Response Content-Types: application/json
Response Example (200 OK)
{
  "signedAgreement": true
}

Get Lilt Create content

GET /create

Get a list of all content that has been generated by Lilt Create.

Example CURL:

curl --X --request GET 'https://lilt.com/2/create?key=API_KEY'

An object with a documents next task Workflow metadata.

Response Content-Types: application/json
Response Example (200 OK)
[
  {
    "id": "integer",
    "name": "string",
    "template": "string",
    "templateParams": {
      "memoryId": "integer"
    },
    "content": "string",
    "language": "string",
    "createdAt": "2021-04-01T13:43:00.000Z",
    "updatedAt": "2021-06-03T13:43:00.000Z"
  }
]

Generate new Lilt Create content

POST /create

Generate new Lilt Create content with the given parameters.

Example CURL:

curl --X --request POST 'https://lilt.com/2/create?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{
  "language":"en-US",
  "template":"blog-post",
  "templateParams":{
    "contentLength":"100",
    "language":"en-US",
    "sections":[],
    "summary":"a blog post about hiking"
    },
  "preferences":{"tone":"formal","styleguide":""}
}'
Request Example
{
  "contentLength": "string",
  "keywords": "string",
  "sections": [
    "string"
  ]
}
200 OK

An event stream produced by Server Side Events. The following events are supported.

  • message: an object with the newly generated text (e.g. {"text": "hello"})
  • message: upon completion of events the string "[DONE]" will be emitted
  • fullcontent: an object containing the full response
Response Content-Types: text/event-stream

Get Lilt Create preferences

GET /create/preferences

Get the stored preferences for Lilt Create.

Example CURL:

curl --X --request POST 'https://lilt.com/2/create/preferences?key=API_KEY'

An object describing the stored preferences.

Response Content-Types: application/json
Response Example (200 OK)

Update Lilt Create preferences

PUT /create/preferences

Update the stored preferences for Lilt Create.

Example CURL:

curl --X --request PUT
'https://lilt.com/2/create/preferences?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{"tone": "formal", "styleguide": ""}'
Request Example
"string"

The updated Lilt Create preferences.

Response Content-Types: application/json
Response Example (200 OK)

Get Lilt Create content by ID.

GET /create/{contentId}

Get Lilt Create content by ID.

Example CURL:

curl --X --request GET 'https://lilt.com/2/create/1234?key=API_KEY'
contentId: integer
in path

The content ID.

The Lilt Create content.

Response Content-Types: application/json
Response Example (200 OK)
{
  "id": "integer",
  "name": "string",
  "template": "string",
  "templateParams": {
    "memoryId": "integer"
  },
  "content": "string",
  "language": "string",
  "createdAt": "2021-04-01T13:43:00.000Z",
  "updatedAt": "2021-06-03T13:43:00.000Z"
}

Update Lilt Create content

PUT /create/{contentId}

Update a piece of Lilt Create content.

Example CURL:

curl --X --request PUT 'https://lilt.com/2/create/1234?key=API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{"language":"de-DE"}'

undefined

contentId: integer
in path

The content ID.

Request Example
{
  "id": "integer",
  "name": "string",
  "template": "string",
  "templateParams": {
    "memoryId": "integer"
  },
  "content": "string",
  "language": "string",
  "createdAt": "2021-04-01T13:43:00.000Z",
  "updatedAt": "2021-06-03T13:43:00.000Z"
}

The updated Lilt Create content.

Response Content-Types: application/json
Response Example (200 OK)
{
  "id": "integer",
  "name": "string",
  "template": "string",
  "templateParams": {
    "memoryId": "integer"
  },
  "content": "string",
  "language": "string",
  "createdAt": "2021-04-01T13:43:00.000Z",
  "updatedAt": "2021-06-03T13:43:00.000Z"
}

Delete Lilt Create content

DELETE /create/{contentId}

Delete a piece of Lilt Create content.

Example CURL:

curl --X --request DELETE 'https://lilt.com/2/create/1234?key=API_KEY'
contentId: integer
in path

The content ID.

200 OK

The Delete Lilt Create Content Response.

type
object
Response Content-Types: application/json
Response Example (200 OK)
{
  "id": "integer"
}

Regenerate Lilt Create content

GET /create/{contentId}/create

Regenerate the given piece of content with the current parameters.

Example CURL:

curl --X --request GET 'https://lilt.com/2/create/1234/create?key=API_KEY'
contentId: integer
in path

The content ID.

200 OK

An event stream produced by Server Side Events. The following events are supported.

  • message: an object with the newly generated text (e.g. {"text": "hello"})
  • message: upon completion of events the string "[DONE]" will be emitted
  • fullcontent: an object containing the full response
Response Content-Types: text/event-stream

Schema Definitions

TranslationInfo: object

Information describing a batch translation process.

id: integer

Unique identifier for this translation.

fileId: integer

id of the File that is being translated.

status: string

Status of the translation - InProgress, ReadyForDownload, Completed, Failed.

createdAt: integer

Time when this translation was started, in seconds since the Unix epoch.

errorMsg: string

Error message, present when status is Failed.

Example
{
  "id": 1,
  "fileId": "2,",
  "status": "InProgress",
  "createdAt": 1609357135
}

Error: object

Response in the event of an unexpected error.

message: object

A human-readable message describing the error.

Example
{
  "message": "Internal server error."
}

BadRequest: object

Response in the event of a malformed request.

message: object

A human-readable message describing the error.

Example
{
  "message": "Bad Request."
}

MonitorFileTranslationTypeError: object

Monitor file translation can have different errors based on reasons explained in the examples.

Example
{
  "Unsupported_file_type": {
    "message": "Customer gave us garbage."
  },
  "File_extraction_error": {
    "message": "Customer gave us garbage."
  },
  "No_translatable_content": {
    "message": "Customer gave us an empty file."
  },
  "Batch_MT_initiation_failure": {
    "message": "Something is wrong with MT."
  },
  "Batch_MT_response_failure": {
    "message": "Something is wrong with MT."
  },
  "File_reassembly_error": {
    "message": "We couldn't put the translated file back together.(okapi error)"
  },
  "Billing_error": {
    "message": "We couldn't log the information about the MT to our billing system."
  },
  "Invalid_memory": {
    "message": "Something is wrong with the memory."
  },
  "Storage_error": {
    "message": "Error occurred interacting with file storage."
  }
}

TranslateCompletionTypeError: object

Response in the event of a malformed error.

message: object

A human-readable message describing the error.

Example
{
  "message": "Some documents are already marked as complete for review. DocumentIds 22322, 23343"
}

ReviewCompletionTypeError: object

Response in the event of a malformed error.

message: object

A human-readable message describing the error.

Example
{
  "message": "Some documents' translation is not marked as complete. Complete translation before completing review. DocumentIds 22322, 23343"
}

Connector: object

A Connector is a Lilt managed api bridge between a content source and Lilt services.

id: integer
name: string
schedule: string
last_check: string
healthy: boolean
args: object
created_at: string
updated_at: string
Example
{
  "id": "integer",
  "name": "string",
  "schedule": "string",
  "last_check": "string",
  "healthy": "boolean",
  "args": "object",
  "created_at": "string",
  "updated_at": "string"
}

ConnectorJob: object

A ConnectorJob tracks the status of an import or export action.

id: integer
status: string
args: object
created_at: string
updated_at: string
Example
{
  "id": "integer",
  "status": "string",
  "args": "object",
  "created_at": "string",
  "updated_at": "string"
}

Job: object

A Job is a collection of multiple Projects. Each project is specific to a language pair, and is associated with exactly one Memory for that language pair. The Memory association cannot be changed after the Project is created.

name: string

A name for the job.

creationStatus: string

Status of job creation process that includes PENDING, COMPLETE, and FAILED.

deliveredAt: string (date-time)
status: string

Current status of job that includes archived, delivered, and active.

due: string (date-time)

An ISO string date.

id: integer

An id for the job.

isProcessing: integer

Values include 1 while in progress, 0 when idle and -2 when processing failed.

stats: JobStats

Overview of job's statistical data.

Example
{
  "name": "My New Job",
  "creationStatus": "COMPLETE",
  "deliveredAt": "2021-06-03T13:43:00.000Z",
  "status": "active",
  "due": "2021-06-03T13:43:00.000Z",
  "id": 241,
  "isProcessing": 0,
  "stats": {
    "exactWords": 0,
    "fuzzyWords": 0,
    "newWords": 0,
    "numDeliveredProjects": 0,
    "numLanguagePairs": 0,
    "numProjects": 0,
    "percentReviewed": 0,
    "percentTranslated": 0,
    "projects": [
      {
        "id": "en",
        "srcLang": "en",
        "srcLocale": "US",
        "trgLang": "fr",
        "trgLocale": "CA",
        "name": "My new project",
        "due": "2021-10-03T13:43:00.000Z",
        "isComplete": false,
        "isArchived": false,
        "state": "inProgress",
        "numSourceTokens": 2134,
        "createdAt": "2021-04-01T13:43:00.000Z",
        "updatedAt": "2021-06-03T13:43:00.000Z",
        "isDeleted": false,
        "memoryId": 2134,
        "workflowStatus": "READY_TO_START",
        "workflowName": "Translate > Review > Analyst Review"
      }
    ],
    "sourceWords": 0,
    "uniqueLanguagePairs": 1,
    "uniqueLinguists": 1,
    "workflowStatus": "READY_TO_START"
  }
}

JobStats: object

A job stats shows an overview of job's statistical data including total number of exact words, fuzzy words, language pairs, projects, etc.

exactWords: integer

Total number of exact words.

fuzzyWords: integer

Total number of fuzzy words.

newWords: integer

Total number of fuzzy words.

numDeliveredProjects: integer

Total number of delivered projects.

numLanguagePairs: integer

Total number of delivered projects.

numProjects: integer

Total number of projects.

percentReviewed: integer

Overall percentage of documents reviewed.

percentTranslated: integer

Overall percentage of documents translated.

projects: JobProject
JobProject
sourceWords: integer

Total number of source words.

uniqueLanguagePairs: integer

Number of unique language pairs.

uniqueLinguists: integer

Number of unique linguists.

workflowStatus: object READY_TO_START, IN_PROGRESS, DONE

The status of the Workflow for the current job.

Example
{
  "exactWords": 0,
  "fuzzyWords": 0,
  "newWords": 0,
  "numDeliveredProjects": 0,
  "numLanguagePairs": 0,
  "numProjects": 0,
  "percentReviewed": 0,
  "percentTranslated": 0,
  "projects": [
    {
      "id": "en",
      "srcLang": "en",
      "srcLocale": "US",
      "trgLang": "fr",
      "trgLocale": "CA",
      "name": "My new project",
      "due": "2021-10-03T13:43:00.000Z",
      "isComplete": false,
      "isArchived": false,
      "state": "inProgress",
      "numSourceTokens": 2134,
      "createdAt": "2021-04-01T13:43:00.000Z",
      "updatedAt": "2021-06-03T13:43:00.000Z",
      "isDeleted": false,
      "memoryId": 2134,
      "workflowStatus": "READY_TO_START",
      "workflowName": "Translate > Review > Analyst Review"
    }
  ],
  "sourceWords": 0,
  "uniqueLanguagePairs": 1,
  "uniqueLinguists": 1,
  "workflowStatus": "READY_TO_START"
}

JobLeverageStats: object

A job leverage stats object shows an overview of job's statistical data including total number of exact words, fuzzy words, and exact words for the job in total and for each project.

sourceWords: integer

Total number of source words.

exactWords: integer

Total number of exact words.

fuzzyWords: integer

Total number of fuzzy words.

newWords: integer

Total number of new words.

projects: ProjectStats
ProjectStats
Example
{
  "sourceWords": 0,
  "exactWords": 0,
  "fuzzyWords": 0,
  "newWords": 0,
  "projects": [
    {
      "id": 1,
      "sourceWords": 1000,
      "exactWords": 800,
      "fuzzyWords": 150,
      "newWords": 50
    }
  ]
}

ProjectStats: object

id: integer
sourceWords: integer
exactWords: integer
fuzzyWords: integer
newWords: integer
Example
{
  "id": 1,
  "sourceWords": 1000,
  "exactWords": 800,
  "fuzzyWords": 150,
  "newWords": 50
}

JobProject: object

A job project contains project statistical data that belongs to a specific job.

id: integer

An id for the project.

srcLang: string

Source language, an ISO 639-1 language identifier.

srcLocale: string

A locale identifier, supported for source language.

trgLang: string

Target language, an ISO 639-1 language identifier.

trgLocale: string

A locale identifier, supported for target language.

name: string

A name for the project.

due: string

An ISO date.

isComplete: boolean

A state that checks project was completed.

isArchived: boolean

The archived state of the project.

state: string

Current state of the project. Example, backlog, inProgress, inReview, done.

numSourceTokens: integer

Total number of source tokens.

createdAt: string

Time at which the object was created.

updatedAt: string

Time at which the object was updated.

isDeleted: boolean

A state that checks project was deleted.

memoryId: integer

A unique number identifying the associated Memory.

workflowStatus: object READY_TO_START, IN_PROGRESS, DONE

The status of the Workflow for the current project.

workflowName: string

Human readable name of the workflow associated with the current project.

Example
{
  "id": "en",
  "srcLang": "en",
  "srcLocale": "US",
  "trgLang": "fr",
  "trgLocale": "CA",
  "name": "My new project",
  "due": "2021-10-03T13:43:00.000Z",
  "isComplete": false,
  "isArchived": false,
  "state": "inProgress",
  "numSourceTokens": 2134,
  "createdAt": "2021-04-01T13:43:00.000Z",
  "updatedAt": "2021-06-03T13:43:00.000Z",
  "isDeleted": false,
  "memoryId": 2134,
  "workflowStatus": "READY_TO_START",
  "workflowName": "Translate > Review > Analyst Review"
}

LanguagePair: object

A language pair couples the source and target language along with memory and pre-translations settings associated to a project.

srcLang: string

Source language, an ISO 639-1 language identifier.

srcLocale: string

A locale identifier, supported for source language.

trgLang: string

Target language, an ISO 639-1 language identifier.

trgLocale: string

A locale identifier, supported for target language.

dueDate: string

An ISO date.

memoryId: integer

A unique number identifying the associated Memory.

externalModelId: integer

A unique identifier for working with a third party model in the Lilt Platform

pretranslate: boolean

Attribute translation authorship of exact matches to the creator of the document being pretranslated.

autoAccept: boolean

Accept and lock exact matches.

caseSensitive: boolean

Use case sensitive translation memory matching.

takeMatchAttribution: boolean

Use MT for unmatched segments.

configId: integer

Configuration id

workflowTemplateId: integer

Workflow Template id, to assign a specific Workflow to the project created out of this Language Pair. WorkflowTemplateIds can be retrieved via the /workflows/templates endpoint. If not specified then the Job level workflowTemplateId will be used.

workflowTemplateName: integer

Workflow Template Name, when passed with TeamId it allows for an on the fly look up of the correct WorkflowTemplate to use. If workflowTemplateId is passed the workflowTemplateId supercedes other lookups.

workflowStageAssignments: WorkflowStageAssignment