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

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

List segments

Edit a segment

Auth Required

Change the translation of one segment, its review status, or both. By default the same change is made to other segments with the same source text that still hold the old translation (propagated says how many). The edit is kept on the translation and appears in the next download; it reaches your translation memory only when you call Sync edits to the translation memory.

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

Bodyrequiredapplication/json

playgroundLogIdstringrequired

ID of the translation.

Example: 7d3e9a41-2c5b-4f6e-9a1d-8b2c3d4e5f60
sourceTextstringrequired

Source text of the segment. Used to find it when layerIndex is not sent; required either way.

Example: Welcome to our website
targetLanguagestring

Accepted for older clients and not used: the translation's own target language applies.

Example: hi-IN
updatePhrasestring

New translation, up to 100,000 characters. Keep every <span id=N> marker of an Office segment (400 otherwise). Omit to change only the review status.

Example: हमारी वेबसाइट पर आपका स्वागत है
verificationstring

New review status: u unverified, v verified, a approved. Omit to keep it.

Enum values:uva
Example: v
layerIndexnumber

The segment's layerIndex from List segments (from 0). Recommended: without it the first segment with this sourceText is edited.

Example: 5
propagateToDuplicatesboolean

Also update other segments with the same source text in this document (default true); they are reset to unverified. Segments already translated differently are left alone.

Example: true

Responses

200The segment was updated.
application/json
statusCodenumberrequired

Always 200.

Example: 200
successbooleanrequired

Always true.

Example: true
messagestringrequired

Always Phrase updated successfully.

Example: Phrase updated successfully
propagatednumberrequired

How many other occurrences of the same source text were updated too (see propagateToDuplicates).

Example: 2
400A field failed validation (for example a text over 100,000 characters), or the edit removes an Office formatting marker (`This edit removes the formatting marker <span id=N>. …`).
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
404No translation with this ID in your organization (`Playground log not found`), or the key's role sees only its own work and this translation is not its own (`Process not found`). Or no segment matches `layerIndex` / `sourceText` (`Segment not found`).
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
429Too many requests for this key. Wait the number of seconds in `Retry-After`, then retry.
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
PUT/v1/galaxy/playground/document/update-phrase
curl '{{API_BASE_URL}}/v1/galaxy/playground/document/update-phrase' \
  --request PUT \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
  "playgroundLogId": "7d3e9a41-2c5b-4f6e-9a1d-8b2c3d4e5f60",
  "sourceText": "Welcome to our website",
  "targetLanguage": "hi-IN",
  "updatePhrase": "हमारी वेबसाइट पर आपका स्वागत है",
  "verification": "v",
  "layerIndex": 5,
  "propagateToDuplicates": true
}'
{
  "statusCode": 200,
  "success": true,
  "message": "Phrase updated successfully",
  "propagated": 2
}

Set review status

Sync edits to the translation memory

Update from the translation memory

Explain a segment translation

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