v1.0.0OpenAPI 3.1.1

Document Translation API

Download OpenAPI Document

Translate Office documents one at a time or in batches, with their layout kept intact.

Translate Word, PowerPoint, Excel, CSV, PDF and InDesign files, structured text files (JSON, XML, HTML, XLIFF) and plain text, keeping each document's layout and formatting. Every translation runs through one of your translation memories: matches are reused, the rest is machine translated and stored back. New here? Read Document Translation for the whole flow.

Every request

Send your organization API key in the x-api-key header; it starts with uvk_. Create one in the Universe app under Settings → API keys. The key and organization limits count requests over a rolling minute. See Authentication and Rate limits.

The usual flow: send the file with Translate a document (for a file over 25 MB, first get an upload URL), poll Get a translation until status is DONE, then download the translated file. Each call translates into one language; call it again for each further language, or translate many files at once with Translate a batch of files.

Translations run in the background, so every call returns straight away. They are charged per source word when they start: Count billable words first if you want the count, and see the current rates on Translate a document. Without enough credits you get 402 and nothing is created. See Credits.

Server
{{API_BASE_URL}}
Your API environment
Authentication RequiredApiKeyAuth
Your organization API key (starts with `uvk_`). Create one in the Universe app under Settings → API keys.
x-api-key:
Client Libraries
Shell

Uploads

Files up to 25 MB go straight into Translate a document as the file part. For a Word, PowerPoint, Excel, PDF or InDesign file up to 500 MB, get a presigned upload URL, PUT the file to it, and translate it by its objectKey.

Get an upload URL

Auth Required

For a Word, PowerPoint, Excel, PDF or InDesign file up to 500 MB, or a JSON, XML, XLIFF, HTML, CSV, Markdown, YAML or Tableau file over 10 MB and up to 25 MB (a file over 10 MB cannot be sent inside the request). Returns a presigned uploadUrl: PUT the file bytes to it, with exactly size bytes and the returned Content-Type header (application/octet-stream for the text formats), within 10 minutes. Then pass objectKey (and objectFileName) to Translate a document, or several keys as objectKeys to Translate several documents. The file never passes through a request to this API. An upload not translated within a day is deleted.

Permission: playground.document:create. An API key acts with the role of the member who created it.

Bodyrequiredapplication/json

fileNamestringrequired

Name of the file you will upload. Send it again as objectFileName when you translate, so the translation is named after it.

Example: quarterly-review.pptx
formatstringrequired

Format of the file, lower-case. Word, PowerPoint, Excel, PDF and InDesign files up to 500 MB; JSON, XML, XLIFF, HTML, CSV, Markdown, YAML and Tableau files up to 25 MB (any file over 10 MB must come this way: the file part takes 10 MB). Typed text (TEXT) and DITA packages have their own routes.

Enum values:docxpptxxlsxpdfidmljsonxmlxliffhtmlcsvmarkdownyamltableau
Example: pptx
sizenumberrequired

Exact size of the file in bytes, up to 500 MB (25 MB for the text formats). It is part of the signed URL: storage refuses a PUT of any other length.

Example: 1048576

Responses

201The upload URL and the key to translate it with.
application/json
uploadUrlstringrequired

Presigned URL. PUT the raw file bytes to it with the same Content-Type as the format (for example application/vnd.openxmlformats-officedocument.presentationml.presentation for .pptx) and exactly size bytes. Valid for expiresInSeconds.

Example: https://storage.example.com/0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c….pptx?X-Amz-Signature=…
objectKeystringrequired

Storage key of the upload. Send it as objectKey to Translate a document (or Count billable words) once the PUT has finished.

Example: 0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c7e2a-9d3f-4e5a-8b6c-1d2e3f4a5b6c.pptx
maxBytesnumberrequired

Largest file this route accepts, in bytes (500 MB).

Example: 524288000
expiresInSecondsnumberrequired

Seconds until uploadUrl expires.

Example: 600
headersobjectrequired

Headers to send with the PUT, exactly as given: the URL is signed over them, so another Content-Type is refused (403).

Example: {"Content-Type":"application/vnd.openxmlformats-officedocument.presentationml.presentation"}
400A field failed validation, or: `The file is empty.`, `The file is larger than the 500 MB limit` (`25 MB` for the text formats), or a `format` that cannot be uploaded this way (`Only these formats can be uploaded this way: …`).
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
401The `x-api-key` header is missing, or the key is invalid, expired or deleted.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
403Not allowed: the API key's role lacks the permission (`PermissionDenied`), the product is not enabled for your organization, or it has been turned off.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
429The API key's member asked for 60 upload URLs in the last hour (`Too many uploads in the last hour. Please wait and try again.`), or has 5 GB of uploads not yet translated (`Too many uploads are waiting to be translated. Translate or discard them first.`). Also returned when the key exceeds its request rate.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
500Something failed on our side. Retry with backoff; if it persists, contact support with the `X-Request-Id`.
application/json
statusCodeintegerrequired

HTTP status code, repeated in the body.

Example: 404
messagestring | string[]required

What went wrong, for people. Validation failures list one entry per problem. Do not branch on this text.

Example: Booking not found
errorstring

Short name of the status.

Example: Not Found
POST/v1/galaxy/playground/document/upload/presign
curl '{{API_BASE_URL}}/v1/galaxy/playground/document/upload/presign' \
  --request POST \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
  "fileName": "quarterly-review.pptx",
  "format": "pptx",
  "size": 1048576
}'
{
  "uploadUrl": "https://storage.example.com/0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c….pptx?X-Amz-Signature=…",
  "objectKey": "0f8e2d4c-6b1a-4c9e-8d7f-3a2b1c0d9e8f/playground/document/upload/4b1c7e2a-9d3f-4e5a-8b6c-1d2e3f4a5b6c.pptx",
  "maxBytes": 524288000,
  "expiresInSeconds": 600,
  "headers": {
    "Content-Type": "application/vnd.openxmlformats-officedocument.presentationml.presentation"
  }
}

Get a text file upload URL

Get an edited picture upload URL

Batches

Translate many files in one call: up to 20 uploaded files into one language, or every matching file in a folder of your assets into several languages. Each file becomes its own translation, grouped in a batch you can follow. These endpoints must be turned on for your organization.

Translate a batch of files

Get a batch

List batches

Preview a folder translation

Translate a folder

Models

BatchDetailResponseDto
BatchListResponseDto
BatchStartFileDto
BatchStartResponseDto
BulkUpdatePlaygroundVerificationDto
BulkVerifyResponseDto
CosmosRunRefDto
CreateDocumentUploadPresignDto
CreateStagedUploadDto
DocumentImagePreviewDto
DocumentImagesPreviewResponseDto
DocumentImagesSummaryDto
DocumentUploadUrlResponseDto
FolderPreviewFileDto
FolderPreviewResponseDto
FolderPreviewTotalsDto
FolderRefDto
FolderRunBatchDto
FolderRunDto
FolderRunFailureDto
FolderRunResponseDto
FolderSkippedFileDto
InsufficientCreditsErrorDto
LogAssigneeDto
LogDetailConsumedDto
LogDetailDto
LogDetailResponseDto
LogImageDto
LogImagesResponseDto
LogListConsumedDto
LogListItemDto
LogListResponseDto
LogOwnerDto
LogTmDto
LogVerificationCountsDto
PdfUnreadablePageDto
PlaygroundBatchFileDto
PlaygroundBatchSummaryDto
PlaygroundSyncFromTmResponseDto
PlaygroundSyncToTmResponseDto
RenameDitaPackageDto
RenameLogResponseDto
RenamePlaygroundLogDto
SavePlaygroundOutputToAssetsDto
SaveToAssetsResponseDto
SegmentCountsDto
SegmentDto
SegmentLocationDto
SegmentPaginationDto
SegmentsResponseDto
StagedUploadTicketDto
SyncPlaygroundToTmDto
TextResultDto
TextResultResponseDto
TranslateBatchFormDto
TranslateDocumentFormDto
TranslateLogImagesDto
TranslationStartedResponseDto
UpdatePhraseResponseDto
UpdatePlaygroundPhraseDto
UseEditedLogImageFormDto
WordCountResponseDto