ManageMultilingualGlossaries

Replaces or creates a dictionary in the glossary with the specified entries.

Changed on

Replace all entries in the dictionary for a source and target language pair, or create the dictionary if it does not exist yet. Entries not included in the request are removed.

put/v3/glossaries/{glossary_id}/dictionaries

Request

  • Base URL
    https://api.deepl.com
  • URL
    https://api.deepl.com/v3/glossaries/{glossary_id}/dictionaries
  • Auth
    API key in header Authorization

Path parameters

glossary_idstring required

A unique ID assigned to the glossary.

Request body

source_lang'ar' | 'bg' | 'cs' | 'da' | 'de' | 'el' | 'en' | 'es' | 'et' | 'fi' | 'fr' | 'he' | 'hu' | 'id' | 'it' | 'ja' | 'ko' | 'lt' | 'lv' | 'nb' | 'nl' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk' | 'sl' | 'sv' | 'tr' | 'uk' | 'vi' | 'zh'

The language in which the source texts in the glossary are specified.

target_lang'ar' | 'bg' | 'cs' | 'da' | 'de' | 'de-CH' | 'de-DE' | 'el' | 'en' | 'en-GB' | 'en-US' | 'es' | 'es-419' | 'es-ES' | 'et' | 'fi' | 'fr' | 'fr-CA' | 'fr-FR' | 'he' | 'hu' | 'id' | 'it' | 'ja' | 'ko' | 'lt' | 'lv' | 'nb' | 'nl' | 'pl' | 'pt' | 'pt-BR' | 'pt-PT' | 'ro' | 'ru' | 'sk' | 'sl' | 'sv' | 'tr' | 'uk' | 'vi' | 'zh' | 'zh-Hans' | 'zh-Hant'

The language in which the target texts in the dictionary are specified. Besides the base languages, the target can be one of these variants: de-CH, de-DE, en-GB, en-US, es-419, es-ES, fr-CA, fr-FR, pt-BR, pt-PT, zh-Hans, or zh-Hant. Source languages are always base languages. The current list is returned by GET /v3/languages?resource=glossary.

A dictionary with a base target, such as de, applies when translating into that language and any of its variants. A dictionary with a variant target, such as de-CH, applies only when translating into that exact variant.

Within one glossary, each language family uses either the base language or its variants as targets, not both. For example, de-CH and de-DE can be combined, but de and de-DE cannot. Adding a dictionary that breaks this rule returns a 400 error.

entriesstring

The entries of the glossary. The entries have to be specified in the format provided by the entries_format parameter.

entries_format'tsv' | 'csv'

The format in which the glossary entries are provided. Formats currently available:

  • tsv (default) - tab-separated values
  • csv - comma-separated values

See Supported Glossary Formats for details about each format.

Example request

{
  "source_lang": "en",
  "target_lang": "de",
  "entries": "Hello\tGuten Tag",
  "entries_format": "tsv"
}

Response

JSON object containing the dictionary meta-information.

source_lang'ar' | 'bg' | 'cs' | 'da' | 'de' | 'el' | 'en' | 'es' | 'et' | 'fi' | 'fr' | 'he' | 'hu' | 'id' | 'it' | 'ja' | 'ko' | 'lt' | 'lv' | 'nb' | 'nl' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk' | 'sl' | 'sv' | 'tr' | 'uk' | 'vi' | 'zh'

The language in which the source texts in the glossary are specified.

target_lang'ar' | 'bg' | 'cs' | 'da' | 'de' | 'de-CH' | 'de-DE' | 'el' | 'en' | 'en-GB' | 'en-US' | 'es' | 'es-419' | 'es-ES' | 'et' | 'fi' | 'fr' | 'fr-CA' | 'fr-FR' | 'he' | 'hu' | 'id' | 'it' | 'ja' | 'ko' | 'lt' | 'lv' | 'nb' | 'nl' | 'pl' | 'pt' | 'pt-BR' | 'pt-PT' | 'ro' | 'ru' | 'sk' | 'sl' | 'sv' | 'tr' | 'uk' | 'vi' | 'zh' | 'zh-Hans' | 'zh-Hant'

The language in which the target texts in the dictionary are specified. Besides the base languages, the target can be one of these variants: de-CH, de-DE, en-GB, en-US, es-419, es-ES, fr-CA, fr-FR, pt-BR, pt-PT, zh-Hans, or zh-Hant. Source languages are always base languages. The current list is returned by GET /v3/languages?resource=glossary.

A dictionary with a base target, such as de, applies when translating into that language and any of its variants. A dictionary with a variant target, such as de-CH, applies only when translating into that exact variant.

Within one glossary, each language family uses either the base language or its variants as targets, not both. For example, de-CH and de-DE can be combined, but de and de-DE cannot. Adding a dictionary that breaks this rule returns a 400 error.

entry_countinteger

The number of entries in the glossary.

Example response

{
  "source_lang": "en",
  "target_lang": "de"
}

Changes

    • breaking

      removed the enum value th of the request property

    • breaking

      removed the enum value th of the request property

    • warning

      added the new de-CH enum value to the response property for the response status

    • warning

      added the new de-DE enum value to the response property for the response status

    • warning

      added the new en-GB enum value to the response property for the response status

    • warning

      added the new en-US enum value to the response property for the response status

    • warning

      added the new es-419 enum value to the response property for the response status

    • warning

      added the new es-ES enum value to the response property for the response status

    • warning

      added the new fr-CA enum value to the response property for the response status

    • warning

      added the new fr-FR enum value to the response property for the response status

    • warning

      added the new pt-BR enum value to the response property for the response status

    • warning

      added the new pt-PT enum value to the response property for the response status

    • warning

      added the new zh-Hans enum value to the response property for the response status

    • warning

      added the new zh-Hant enum value to the response property for the response status

    • info

      added the new de-CH enum value to the request property

    • info

      added the new de-DE enum value to the request property

    • info

      added the new en-GB enum value to the request property

    • info

      added the new en-US enum value to the request property

    • info

      added the new es-419 enum value to the request property

    • info

      added the new es-ES enum value to the request property

    • info

      added the new fr-CA enum value to the request property

    • info

      added the new fr-FR enum value to the request property

    • info

      added the new pt-BR enum value to the request property

    • info

      added the new pt-PT enum value to the request property

    • info

      added the new zh-Hans enum value to the request property

    • info

      added the new zh-Hant enum value to the request property

    • info

      added the media type application/json for the response with the status

    • info

      added the media type application/json for the response with the status

    • info

      added the media type application/json for the response with the status

    • info

      added the media type application/json for the response with the status

    • info

      added the media type application/json for the response with the status

    • info

      removed the th enum value from the response property for the response status

    • info

      removed the th enum value from the response property for the response status