All URIs are relative to https://api.lilt.com
Method | HTTP request | Description |
---|---|---|
archiveJob | POST /v2/jobs/{jobId}/archive | Archive a Job |
createJob | POST /v2/jobs | Create a Job |
deleteJob | DELETE /v2/jobs/{jobId} | Delete a Job |
deliverJob | POST /v2/jobs/{jobId}/deliver | Deliver a Job |
downloadJob | GET /v2/jobs/{jobId}/downlod | Download a Job |
exportJob | GET /v2/jobs/{jobId}/export | Export a Job |
getJob | GET /v2/jobs/{jobId} | Retrieve a Job |
getJobLeverageStats | POST /v2/jobs/{jobId}/stats | Retrieve Job Leverage Stats |
reactivateJob | POST /v2/jobs/{jobId}/reactivate | Reactivate a Job |
retrieveAllJobs | GET /v2/jobs | Retrieve all Jobs |
unarchiveJob | POST /v2/jobs/{jobId}/unarchive | Unarchive a Job |
updateJob | PUT /v2/jobs/{jobId} | Update a Job |
Job archiveJob(jobId)
Archive a Job
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: ```bash curl -X POST 'https://api.lilt.com/v2/jobs/{id}/archive?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.archiveJob(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
Job createJob(body)
Create a Job
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: ```bash curl -X POST 'https://api.lilt.com/v2/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" } ] }' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let body = new LiltNode.JobCreateParameters(); // JobCreateParameters |
apiInstance.createJob(body).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
body | JobCreateParameters |
- Content-Type: application/json
- Accept: application/json
JobDeleteResponse deleteJob(jobId)
Delete a Job
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: ```bash curl -X DELETE 'https://api.lilt.com/v2/jobs/{id}?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.deleteJob(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
Job deliverJob(jobId)
Deliver a Job
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: ```bash curl -X POST 'https://api.lilt.com/v2/jobs/{id}/deliver?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.deliverJob(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
downloadJob(jobId)
Download a Job
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: ```bash curl -X GET 'https://api.lilt.com/v2/jobs/{id}/download?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.downloadJob(jobId).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
null (empty response body)
- Content-Type: Not defined
- Accept: application/json
exportJob(jobId, type)
Export a Job
Prepare job files for download. To export translated documents from the job use the query parameter `type=files`: Example CURL command: ```bash curl -X GET 'https://api.lilt.com/v2/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.
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
let type = "type_example"; // String | category for files and memory.
apiInstance.exportJob(jobId, type).then(() => {
console.log('API called successfully.');
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. | |
type | String | category for files and memory. |
null (empty response body)
- Content-Type: Not defined
- Accept: application/json
Job getJob(jobId)
Retrieve a Job
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: ```bash curl -X GET 'https://api.lilt.com/v2/jobs/{id}?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.getJob(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
JobLeverageStats getJobLeverageStats(jobId)
Retrieve Job Leverage Stats
Get the TM leverage stats for the job (new/exact/fuzzy matches). Example CURL command: ```bash curl -X POST 'https://api.lilt.com/v2/jobs/{id}/stats?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.getJobLeverageStats(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
Job reactivateJob(jobId)
Reactivate a Job
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: ```bash curl -X POST 'https://api.lilt.com/v2/jobs/{id}/reactivate?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.reactivateJob(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
[Job] retrieveAllJobs(opts)
Retrieve all Jobs
Get all Jobs within a given offset and limit. You can retrieve jobs from your account using the above API. Example CURL command: ```bash curl -X GET 'https://api.lilt.com/v2/jobs?key=API_KEY&isArchived=false' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let opts = {
'isArchived': true, // Boolean | Retrieves all jobs that are archived.
'isDelivered': true, // Boolean | Retrieves all jobs that are delivered.
'offset': 56, // Number | Return jobs starting at the offset row. If not given the default offset will be 0.
'limit': 56 // Number | The maximum number of jobs to be returned. If not given the default limit will be 25.
};
apiInstance.retrieveAllJobs(opts).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
isArchived | Boolean | Retrieves all jobs that are archived. | [optional] |
isDelivered | Boolean | Retrieves all jobs that are delivered. | [optional] |
offset | Number | Return jobs starting at the offset row. If not given the default offset will be 0. | [optional] |
limit | Number | The maximum number of jobs to be returned. If not given the default limit will be 25. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Job unarchiveJob(jobId)
Unarchive a Job
Set job to unarchived, the job will move to active status. Example CURL command: ```bash curl -X POST 'https://api.lilt.com/v2/jobs/{id}/unarchive?key=API_KEY' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
apiInstance.unarchiveJob(jobId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. |
- Content-Type: Not defined
- Accept: application/json
Job updateJob(jobId, opts)
Update a Job
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: ```bash curl -X PUT 'https://api.lilt.com/v2/jobs/{id}?key=API_KEY' \ --header 'Content-Type: application/json' \ --data-raw '{ "name": "test job", "due": "2022-05-05T10:56:44.985Z" }' ```
import LiltNode from 'lilt-node';
let defaultClient = LiltNode.ApiClient.instance;
// Configure API key authorization: ApiKeyAuth
let ApiKeyAuth = defaultClient.authentications['ApiKeyAuth'];
ApiKeyAuth.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//ApiKeyAuth.apiKeyPrefix = 'Token';
// Configure HTTP basic authorization: BasicAuth
let BasicAuth = defaultClient.authentications['BasicAuth'];
BasicAuth.username = 'YOUR USERNAME';
BasicAuth.password = 'YOUR PASSWORD';
let apiInstance = new LiltNode.JobsApi();
let jobId = 56; // Number | A job id.
let opts = {
'body': new LiltNode.JobUpdateParameters() // JobUpdateParameters |
};
apiInstance.updateJob(jobId, opts).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
jobId | Number | A job id. | |
body | JobUpdateParameters | [optional] |
- Content-Type: application/json
- Accept: application/json