Document Directory

Translation Task API

Query translation tasks

/v1/translation/query

Query the status and details of a translation task.

Example

curl
1curl -X POST 'https://dltranslator.com/api/v1/translation/query' \
2--header 'Authorization: [yourSecretKey]' \
3--header 'Content-Type: application/json' \
4--data '{
5  "taskId": "[string]"
6}'

Request Parameters

ParametersTypeDefaultDescriptionExample
*taskIdString-

Translation Task ID

-

Response

ParametersTypeDefaultDescriptionExample
taskIdString-

Task ID

-
modelString-

Translation model used

-
fromLangString-

Source language

-
toLangString-

Target Language

-
statusString-

Status: 'Waiting' | 'Processing' | 'Completed' | 'Terminated' | 'Cancelled'

-
progressNumber-

Progress: 0~100

-
errorMsgString-

Error message

-
translatedFileUrlString-

Translation download URL

-
translatedBilingualFileUrlString-
  • Download address for bilingual translations; only supports PDF, DOCX, PPTX, XLSX, EPUB, CSV, SRT, TXT, HTML, ODF
  • When files are too large or translation errors occur, bilingual translations will not be generated
-
tokenCountInteger-
  • Tokens for text requiring translation within the document
  • Image translation in PDFs is calculated at 1,200 tokens per page
-
priceInteger-

Total Credits required for the complete translation

-
usedCreditsInteger-

Number of credits used by the translation task

-
glossaryString[]-

Glossary name used by the translation task

-
shouldTranslateImageBoolean-

Translate images in document

-
createdAtDateTime-

Creation time of the translation task

-
updatedAtDateTime-

Translation task update time

-
Translation Task API
Create Translation Task
Translation Task API
Delete Translation Task