Skip to content

Commit 694aa5c

Browse files
Merge pull request #21 from DeepLcom/fix-missing-zh-codes
Fix missing ZH codes
2 parents e9d2a1a + 559acaa commit 694aa5c

File tree

4 files changed

+25
-2
lines changed

4 files changed

+25
-2
lines changed

Diff for: CHANGELOG.md

+11
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,16 @@ number is used only for corrections to the OpenAPI specification, for example:
1010
typos, schema fixes, or adding examples.
1111

1212

13+
## [Unreleased]
14+
### Changed
15+
* The Chinese language codes returned in the `/languages` response for target
16+
languages were changed. While previously only `ZH` "Chinese (simplified)" was
17+
included, `ZH-HANS` "Chinese (simplified)" is now listed too.
18+
Both language codes are supported for text and document translation.
19+
### Deprecated
20+
* The target language code `ZH` is deprecated; instead `ZH-HANS` should be used.
21+
22+
1323
## [2.15.0] - 2024-07-03
1424
### Added
1525
* Add supported glossary language: Romanian (`ro`).
@@ -141,6 +151,7 @@ typos, schema fixes, or adding examples.
141151
Initial release of the OpenAPI specification.
142152

143153

154+
[Unreleased]: https://github.com/DeepLcom/openapi/compare/v2.15.0...HEAD
144155
[2.15.0]: https://github.com/DeepLcom/openapi/compare/v2.14.1...v2.15.0
145156
[2.14.1]: https://github.com/DeepLcom/openapi/compare/v2.14.0...v2.14.1
146157
[2.14.0]: https://github.com/DeepLcom/openapi/compare/v2.13.0...v2.14.0

Diff for: openapi.json

+6-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
},
3636
{
3737
"name": "ManageGlossaries",
38-
"description": "The *glossary* functions allow you to create, inspect, and delete glossaries.\nGlossaries created with the glossary function can be used in translate requests by specifying the\n`glossary_id` parameter.\nIf you encounter issues, please let us know at [email protected].\n\nThe DeepL API supports glossaries in any combination of two languages from the following list, enabling a total of\n120 possible glossary language pairs:\n\n- DA (Danish)\n- DE (German)\n- EN (English)\n- ES (Spanish)\n- FR (French)\n- IT (Italian)\n- JA (Japanese)\n- KO (Korean)\n- NB (Norwegian (bokm\u00e5l))\n- NL (Dutch)\n- PL (Polish)\n- PT (Portuguese)\n- RO (Romanian)\n- RU (Russian)\n- SV (Swedish)\n- ZH (Chinese)\n\nThe maximum size limit for a glossary is 10 MiB = 10485760 bytes and each source/target text,\nas well as the name of the glossary, is limited to 1024 UTF-8 bytes.\nA total of 1000 glossaries are allowed per account.\n\nWhen creating a glossary with target language `EN`, `PT`, or `ZH`, it's not necessary to specify a variant\n(e.g. `EN-US`, `EN-GB`, `PT-PT`, `PT-BR`, or `ZH-HANT`).\nGlossaries with target language `EN` can be used in translations with either English variant.\nSimilarly `PT`, and `ZH` glossaries can be used in translations with their corresponding variants.\n\n\nGlossaries created via the DeepL API are distinct from glossaries created via the DeepL website and DeepL apps.\nThis means API glossaries cannot be used on the website and vice versa.\n\n\n\nNote that glossaries are immutable: once created, the glossary entries for a given glossary ID cannot be modified.\n\nAs a workaround for effectively editable glossaries, we suggest to identify glossaries by name instead of ID in your application\nand then use the following procedure for modifications:\n- [download](https://www.deepl.com/docs-api/glossaries/get-glossary-entries) and store the current glossary's entries,\n- locally modify the glossary entries,\n- [delete](https://www.deepl.com/docs-api/glossaries/delete-glossary) the existing glossary,\n- [create a new glossary](https://www.deepl.com/docs-api/glossaries/create-glossary) with the same name."
38+
"description": "The *glossary* functions allow you to create, inspect, and delete glossaries.\nGlossaries created with the glossary function can be used in translate requests by specifying the\n`glossary_id` parameter.\nIf you encounter issues, please let us know at [email protected].\n\nThe DeepL API supports glossaries in any combination of two languages from the following list, enabling a total of\n120 possible glossary language pairs:\n\n- DA (Danish)\n- DE (German)\n- EN (English)\n- ES (Spanish)\n- FR (French)\n- IT (Italian)\n- JA (Japanese)\n- KO (Korean)\n- NB (Norwegian (bokm\u00e5l))\n- NL (Dutch)\n- PL (Polish)\n- PT (Portuguese)\n- RO (Romanian)\n- RU (Russian)\n- SV (Swedish)\n- ZH (Chinese)\n\nThe maximum size limit for a glossary is 10 MiB = 10485760 bytes and each source/target text,\nas well as the name of the glossary, is limited to 1024 UTF-8 bytes.\nA total of 1000 glossaries are allowed per account.\n\nWhen creating a glossary with target language `EN`, `PT`, or `ZH`, it's not necessary to specify a variant\n(e.g. `EN-US`, `EN-GB`, `PT-PT`, `PT-BR`, or `ZH-HANS`).\nGlossaries with target language `EN` can be used in translations with either English variant.\nSimilarly `PT`, and `ZH` glossaries can be used in translations with their corresponding variants.\n\n\nGlossaries created via the DeepL API are distinct from glossaries created via the DeepL website and DeepL apps.\nThis means API glossaries cannot be used on the website and vice versa.\n\n\n\nNote that glossaries are immutable: once created, the glossary entries for a given glossary ID cannot be modified.\n\nAs a workaround for effectively editable glossaries, we suggest to identify glossaries by name instead of ID in your application\nand then use the following procedure for modifications:\n- [download](https://www.deepl.com/docs-api/glossaries/get-glossary-entries) and store the current glossary's entries,\n- locally modify the glossary entries,\n- [delete](https://www.deepl.com/docs-api/glossaries/delete-glossary) the existing glossary,\n- [create a new glossary](https://www.deepl.com/docs-api/glossaries/create-glossary) with the same name."
3939
},
4040
{
4141
"name": "MetaInformation",
@@ -1467,6 +1467,11 @@
14671467
"name": "Ukrainian",
14681468
"supports_formality": false
14691469
},
1470+
{
1471+
"language": "ZH",
1472+
"name": "Chinese (simplified)",
1473+
"supports_formality": false
1474+
},
14701475
{
14711476
"language": "ZH-HANS",
14721477
"name": "Chinese (simplified)",

Diff for: openapi.yaml

+4-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ tags:
7878
A total of 1000 glossaries are allowed per account.
7979
8080
When creating a glossary with target language `EN`, `PT`, or `ZH`, it's not necessary to specify a variant
81-
(e.g. `EN-US`, `EN-GB`, `PT-PT`, `PT-BR`, or `ZH-HANT`).
81+
(e.g. `EN-US`, `EN-GB`, `PT-PT`, `PT-BR`, or `ZH-HANS`).
8282
Glossaries with target language `EN` can be used in translations with either English variant.
8383
Similarly `PT`, and `ZH` glossaries can be used in translations with their corresponding variants.
8484
@@ -1134,6 +1134,9 @@ paths:
11341134
- language: UK
11351135
name: Ukrainian
11361136
supports_formality: false
1137+
- language: ZH
1138+
name: Chinese (simplified)
1139+
supports_formality: false
11371140
- language: ZH-HANS
11381141
name: Chinese (simplified)
11391142
supports_formality: false

Diff for: openapi_gitbook.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -1018,6 +1018,9 @@ paths:
10181018
- language: UK
10191019
name: Ukrainian
10201020
supports_formality: false
1021+
- language: ZH
1022+
name: Chinese (simplified)
1023+
supports_formality: false
10211024
- language: ZH-HANS
10221025
name: Chinese (simplified)
10231026
supports_formality: false
@@ -1509,5 +1512,6 @@ components:
15091512
- SV
15101513
- TR
15111514
- UK
1515+
- ZH
15121516
- ZH-HANS
15131517
example: DE

0 commit comments

Comments
 (0)