Skip to main content
POST
Import an example document
Importing a file is the only way to create an example document. The request body describes the file you intend to upload; it does not carry the file. DeepL returns a signed upload_url, the file is uploaded to that URL, and processing starts automatically once the upload finishes. For a walkthrough of the full flow with example requests, see Adapting translations with example documents.

Supported file formats

The extension of file_name selects how the file is read. Any other extension is rejected with 400 Bad Request.

Limits

Behavior to be aware of

A 202 Accepted means the job exists, not that an example document does. Until the upload completes and the job reports completed, there is no example_document_id to reference. The declared content_type is not checked against the file extension. The extension of file_name alone decides how the file is read. If expires_at passes before the file is uploaded, the signed URL stops working and the job reports expired. Create a new import job to get a fresh URL. The language of the document is detected during import and is not part of the request. Example documents are currently applied to translations into English, German, French, Italian, and Spanish, including their regional variants. A document in another language has no effect on translations. See Languages supported for the full list. If your account has reached its example document limit, the request returns 456. An import job that is still waiting for its upload counts toward the limit until it expires.

Authorizations

Authorization
string
header
default:DeepL-Auth-Key
required

Authentication with Authorization header and DeepL-Auth-Key authentication scheme. Example: DeepL-Auth-Key <api-key>

Body

application/json
source_file
object
required
parameters
object

Response

The import job was created. Upload the file to upload_url before expires_at.

job_id
string<uuid>
required

The identifier of the import job. Use it to poll the job's status.

Example:

"31909c14-3f7e-4a1f-8b08-38f04ced7f45"

upload_url
string<uri>
required

A signed URL to PUT the file to. Do not send your Authorization header with the upload request.

Example:

"https://assets.deepl.com/upload/31909c14-3f7e-4a1f-8b08-38f04ced7f45"

expires_at
string<date-time>
required

The time the upload_url stops accepting uploads, in the ISO 8601-1:2019 format. After this time, create a new import job.

Example:

"2026-11-19T09:52:09.410Z"