Repository navigation
TL;DR: new APIs in this release: the Admin API, spoken terms, style profiles and text correction.
Translation memories, style rules and multilingual glossaries gained many options and fixes.
Read Changed and Deprecated before upgrading; no public API is removed in this release.
Added
DocumentTranslationExceptionnow copiesHttpStatusCodeandShouldRetryfrom theDeepLExceptionthat
caused it; they were alwaysnullbefore.- Added
DeepLClientoverloads ofListTranslationMemorySegmentsAsync()(translation memory ID or
TranslationMemoryInfo) taking aTranslationMemorySegmentsOptions(PageSize,PageCursor,FilterText,
FilterCaseSensitive); options leftnullare not sent. - Added a
DeepLClientoverload ofCreateTranslationMemoryImportAsync()taking a
CreateTranslationMemoryImportOptions(ContentType,DisplayName); itsExtraBodyParametersare added last to
the JSON request body. - Added a
DeepLClientoverload ofImportTranslationMemoryFromFilepathAsync()taking an
ImportTranslationMemoryOptions(DisplayName,ContentType,Timeout).ContentTypeis declared on the import
job and sent with the upload (defaultapplication/xml);ExtraBodyParametersare added last to the import job
request body. - Added
DeepLClientoverloads ofWaitUntilTranslationMemoryJobDoneAsync()and
ExportTranslationMemoryToFilepathAsync()taking aTimeSpan? timeout; aDeepLExceptionis thrown when it
expires before the job finishes. - Added
DeepLClientoverloads ofGetTranslationMemoryJobAsync()andWaitUntilTranslationMemoryJobDoneAsync()
taking aTranslationMemoryJobinstead of the job ID. TranslationMemoryJobconverts implicitly to its job ID, so a job object can also be passed to the
ITranslationMemoryManagermethods taking a job ID.- Added
TranslationMemoryJobStatus.UnknownandStatusValueonTranslationMemoryJobResultand
TranslationMemoryJob, holding the job status as returned by the API. - The new translation memory overloads are members of
DeepLClient; theITranslationMemoryManagerinterface is
unchanged. - Added
DeepLClientoverloads of all eight style rule methods that take a style rule ID (GetStyleRuleAsync(),
UpdateStyleRuleNameAsync(),UpdateStyleRuleConfiguredRulesAsync(),DeleteStyleRuleAsync(),
CreateStyleRuleCustomInstructionAsync(),GetStyleRuleCustomInstructionAsync(),
UpdateStyleRuleCustomInstructionAsync(),DeleteStyleRuleCustomInstructionAsync()) taking aStyleRuleInfo
instead, and overloads of the get, update and delete custom instruction methods taking aCustomInstruction
instead of the instruction ID.CustomInstructionconverts implicitly to its ID. These and the following style rule
overloads are members ofDeepLClient; theIStyleRuleManagerinterface is unchanged. - Added
DeepLClientoverloads ofCreateStyleRuleAsync()andUpdateStyleRuleConfiguredRulesAsync()taking the
configured rules as aDictionary<string, Dictionary<string, string>>(category to rule to value, keyed by the API
names), sent as given, so categories theConfiguredRulesclass lacks can be sent.ConfiguredRulesconverts
implicitly to this map. - Added
DeepLClientoverloads ofCreateStyleRuleAsync(),UpdateStyleRuleNameAsync(),
UpdateStyleRuleConfiguredRulesAsync(),CreateStyleRuleCustomInstructionAsync()and
UpdateStyleRuleCustomInstructionAsync()taking aCreateStyleRuleOptions,UpdateStyleRuleNameOptions,
UpdateStyleRuleConfiguredRulesOptions,CreateStyleRuleCustomInstructionOptionsor
UpdateStyleRuleCustomInstructionOptions. The options classes derive fromBaseRequestOptions: their
ExtraBodyParametersare added last to the JSON request body (for the configured rules, to the rules map as further
keys). - Added
DeepLClient.UpdateMultilingualGlossaryAsync(), taking a glossary ID orMultilingualGlossaryInfoand an
UpdateMultilingualGlossaryOptionsobject (Name,Dictionaries), to rename a glossary and merge entries into
its dictionaries in one request. Only the set properties are sent;ExtraBodyParametersare added last to the
JSON request body. - Added
DeepLClientoverloads ofCreateMultilingualGlossaryAsync()andCreateMultilingualGlossaryFromCsvAsync()
taking aCreateMultilingualGlossaryOptions, and ofReplaceMultilingualGlossaryDictionaryAsync()and
ReplaceMultilingualGlossaryDictionaryFromCsvAsync()taking aReplaceMultilingualGlossaryDictionaryOptions. Both
options classes derive fromBaseRequestOptions: theirExtraBodyParametersare added last to the request body. - Added
DeepLClientoverloads ofGetMultilingualGlossaryAsync()andUpdateMultilingualGlossaryNameAsync()taking
aMultilingualGlossaryInfoinstead of the glossary ID. - The new multilingual glossary methods and overloads are members of
DeepLClient; theIGlossaryManagerinterface
is unchanged. - Added
StyleProfiletoTextTranslateOptionsandDocumentTranslateOptions(the ID or aStyleProfileobject),
and constructors taking aStyleProfile, to translate text and documents with a style profile (sent as
style_profile_id). - Added
Glossary,StyleRuleandTranslationMemorytoDocumentTranslateOptions, replacingGlossaryId,
StyleIdandTranslationMemoryId, as inTextTranslateOptions: each takes the ID or the resource object.
Glossary objects can also be added toDocumentTranslateOptions.GlossaryIds. - Added
DocumentTranslateOptions.FormalityValue: theformalityvalue as a string, sent unchanged instead of
Formalityif set. - Added
DocumentTranslateOptions.FilenameandStreamoverloads ofTranslateDocumentAsync()and
TranslateDocumentUploadAsync()without theinputFileNameparameter, which sendFilenameas the file name.
TheFileInfooverloads sendFilenameinstead of the file's name if it is set. - Added
TranslateDocumentGetStatusAsync(), replacingTranslateDocumentStatusAsync(). - Added a
TranslateDocumentWaitUntilDoneAsync()overload with aTimeSpan? timeout, and
DocumentTranslateOptions.Timeoutfor the wait insideTranslateDocumentAsync(). When the timeout expires, a
DeepLExceptionis thrown (wrapped in aDocumentTranslationExceptionbyTranslateDocumentAsync()). - Added
DocumentStatus.StatusValue, the status string as returned by the API, and
DocumentStatus.StatusCode.Unknownfor statuses this library does not know. - The new document methods and overloads are members of
TranslatorandDeepLClient; the obsoleteITranslator
interface is unchanged. - Added
Glossary,StyleRuleandTranslationMemorytoTextTranslateOptions, replacingGlossaryId,StyleId
andTranslationMemoryId. Each takes the ID or the resource object (GlossaryInfoorMultilingualGlossaryInfo,
StyleRuleInfo,TranslationMemoryInfo), so several resource objects can be combined in one options object. GlossaryInfo,MultilingualGlossaryInfo,StyleRuleInfo,StyleProfileandTranslationMemoryInfoconvert
implicitly to their ID, so they can also be added toTextTranslateOptions.GlossaryIds, mixed with IDs. Anull
object converts tonull, so assigning one leaves the option unset.- Added
FormalityValue,SplitSentencesandModelTypeValuetoTextTranslateOptions: theformality,
split_sentencesandmodel_typevalues as strings, sent unchanged instead of theFormality,
SentenceSplittingModeandModelTypeenum properties if set, for values the enums do not have. - Added the
TagHandlingMode(Html,Xml) andTagHandlingVersion(V1,V2) constants for
TextTranslateOptions.TagHandlingandTagHandlingVersion, which still accept any string. - Added
TextResult.TagHandlingVersion, thetag_handling_versionof the response (nullif absent or not a
string). - Added
IStyleProfileManager, implemented byDeepLClient, to manage style profiles (/v3/style_profiles):
ListStyleProfilesAsync(),CreateStyleProfileAsync(),GetStyleProfileAsync(),UpdateStyleProfileAsync()and
DeleteStyleProfileAsync(), with the modelStyleProfileand the options classesCreateStyleProfileOptionsand
UpdateStyleProfileOptions(which addsName). Options leftnullare not sent; an empty string clears the
description or industry and an empty list unlinks all components of that kind. Both options classes derive from
BaseRequestOptions:ExtraBodyParametersare added to the body last. The glossary, style rule list and
translation memory lists take IDs or resource objects (SetGlossaries(),SetStyleRules(),
SetTranslationMemories()).StyleProfile.CreationTimeandUpdatedTimeare non-nullable. - Added
ISpokenTermsManager, implemented byDeepLClient, to manage Spoken Terms collections (/v3/spoken-terms):
CreateSpokenTermsAsync(),ListSpokenTermsAsync(),GetSpokenTermsAsync(),UpdateSpokenTermsAsync(),
GetSpokenTermsEntriesAsync(),ReplaceSpokenTermsListAsync(),DeleteSpokenTermsAsync()and
DeleteSpokenTermsListAsync(), with the modelsSpokenTerms,SpokenTermsListandSpokenTermsEntries.
Terms are checked like glossary terms before sending; an invalid term throwsArgumentException.
UpdateSpokenTermsAsync()takes the new name and the terms to merge as anUpdateSpokenTermsOptionsobject
(Name,TermLists).CreateSpokenTermsAsync(),UpdateSpokenTermsAsync()andReplaceSpokenTermsListAsync()
take an optionalCreateSpokenTermsOptions,UpdateSpokenTermsOptionsorReplaceSpokenTermsListOptions, whose
ExtraBodyParametersare added last to the JSON request body. - Added the API Pro fields of
GET /v2/usagetoUsage:ApiKeyCharacter(the character usage of the API key,
as opposed to the account-wideCharacter),SpeechToTextMinutes,SpeechToSpeechMinutes,StartTime,
EndTimeandProducts(per-product usage asUsage.Product). They arenullwhen the response does not
contain them, for example for non-Pro accounts.Usage.JsonFieldsStructkeeps its six character and document
fields; the API Pro fields are parsed internally.Usage.Productproperties arenullwhen the response omits
them. - Added the
DeepLAdminClientclass for the Admin API. It must be created with an admin API key and supports managing
developer keys (CreateDeveloperKeyAsync(),ListDeveloperKeysAsync(),DeactivateDeveloperKeyAsync(),
RenameDeveloperKeyAsync(),SetDeveloperKeyUsageLimitsAsync()) and retrieving usage analytics
(GetUsageAnalyticsAsync(),GetCustomTagUsageAnalyticsAsync()).SetDeveloperKeyUsageLimitsAsync()takes a
DeveloperKeyUsageLimitsUpdateand changes only the limits assigned in it.
The four key-changing methods take optionalCreateDeveloperKeyOptions(with theLabelof the new key),
DeactivateDeveloperKeyOptions,RenameDeveloperKeyOptionsandSetDeveloperKeyUsageLimitsOptions, derived from
BaseRequestOptions: theirExtraBodyParametersare added last to the JSON request body.
DeepLAdminClientimplements the newIAdminManagerinterface.
Results use the new typesDeveloperKey,DeveloperKeyUsageLimits,AdminUsageReport,AdminUsageBreakdown
(includingSpeechToSpeechMinutes),KeyUsage,CustomTagUsageReport,CustomTagUsageand
CustomTagUsageBreakdown, and requests the enumsAdminUsageGroupByandCustomTagUsageAggregateBy; overloads
of the analytics methods takegroupByandaggregateByas strings, sent as given.
DeveloperKey.Label,DeveloperKey.UsageLimits,KeyUsage.ApiKeyLabel,
AdminUsageBreakdown.SpeechToSpeechMinutesandCustomTagUsageBreakdown.SpeechToSpeechMinutesarenullwhen the
API does not return them. Unexpected values in Admin API responses are skipped or replaced by defaults instead of
failing the call; a response that is not a JSON object or array as expected, or a developer key response without
key_id, throws aDeepLException. The SDK passes labels and limit values to the API unchanged.
The analytics methods acceptDateTimevalues, sent as their UTC date (Localvalues are converted to UTC,
Unspecifiedvalues are treated as UTC), or"yyyy-MM-dd"strings.
DeepLAdminClientOptionsandTranslatorOptionsnow share the connection settings of the newBaseClientOptions
base class. - Added
LanguageCodeconstants for target language variantsGermanSwiss(de-CH),GermanGermany(de-DE),
SpanishEuropean(es-ES),FrenchCanadian(fr-CA) andFrenchEuropean(fr-FR). Like the otherLanguageCodeconstants, they are
deprecated with[Obsolete]. - Added
DeepLClient.GetLanguagesForResourceAsync()to retrieve the languages supported by a DeepL API resource
(GET /v3/languages), with source/target usability, status and per-language features. Passincludevalues
LanguageSupport.IncludeBetaandLanguageSupport.IncludeExternalto also return beta and third-party languages
and features.
AGetLanguagesForResourceAsync()overload takes aGetLanguagesForResourceOptionsobject whoseIncludelist
holds these values. - Added
DeepLClient.GetLanguageResourcesAsync()to retrieve the DeepL API resources and their features, including
whether each feature requires source and/or target language support (GET /v3/languages/resources). - Added
DocumentTranslateOptions.EnableWatermarkto request a "Translated by DeepL" watermark on translated
documents (docxandpdfoutput only). - Added
CorrectTextAsync()method to theDeepLClientclass for correcting
grammar and spelling errors via thev2/write/correctendpoint. It takes an optionalCorrectTextOptions, whose
ExtraBodyParametersare added to the request body last. It is a member ofDeepLClient; theIWriterinterface
is unchanged. TextRephraseOptionsnow derives fromBaseRequestOptions: itsExtraBodyParametersare added to the
RephraseTextAsync()request body last, replacing built-in parameters with the same key.- Added
TextRephraseOptionsconstructors taking aWritingStyleorWritingToneenum value, and the
ToApiValue()extension methods for both enums (e.g.WritingStyle.PreferSimpleis sent asprefer_simple). - The
targetLanguageCodeparameter ofRephraseTextAsync()andCorrectTextAsync()now defaults tonull, so it
can be omitted. - Added
DeepLException.HttpStatusCode, the HTTP status of the failed response (nullif there was none), and
DeepLException.ShouldRetry:truefor HTTP 429, 5xx and transient network failures (timeouts, failed connections),
[secure]for other HTTP statuses. ForCreateDeveloperKeyAsync(), which is not safe to repeat, it istrueonly for
HTTP 429, name resolution failures and refused connections. Both are also set for errors of pre-signed storage URLs. - Added the
Proxyoption toDeepLClientOptionsandDeepLAdminClientOptions: the URL of an HTTP(S) proxy for all
requests, with optional credentials in the URL. Unlike a customClientFactory, it keeps the built-in retries and
timeouts. - Added the static method
DeepLClient.IsFreeAccountAuthKey(), replacingTranslator.AuthKeyIsFreeAccount(). - Added
DeepLClientoverloads ofUpdateMultilingualGlossaryNameAsync(),
UpdateMultilingualGlossaryDictionaryAsync()andUpdateMultilingualGlossaryDictionaryFromCsvAsync()taking a
BaseRequestOptions; itsExtraBodyParametersare added last to the request body. TheIGlossaryManagerinterface
is unchanged.
Changed
- The README documents source language detection with glossaries in text translation: with a
nullsource language,
DeepL detects it and applies the glossary's dictionary for the detected language pair. - Because
GlossaryInfo,MultilingualGlossaryInfo,StyleRuleInfo,StyleProfileandTranslationMemoryInfonow
convert implicitly tostring, code recompiled against this version that passes one of them to an API with a
stringoverload, such asConsole.WriteLine(glossary),"..." + glossary,StringBuilder.Append(glossary)or
string.Join(", ", a, b), now gets the bare ID instead ofToString()(Glossary "name" (id)). Interpolation
($"{glossary}") still usesToString().ToString()is for diagnostics only;Languagealready behaves this way.
CustomInstructionnow also converts implicitly tostring. It has noToString()override, so these calls print
its ID, or an empty string if it has none, instead of the type nameDeepL.Model.CustomInstruction. - Target languages
ENandPTare no longer rejected client-side in text translation, document translation and
rephrasing. The API translates them asen-USandpt-PTrespectively. GetSourceLanguagesAsync(),GetTargetLanguagesAsync(), andGetGlossaryLanguagesAsync()now
call theGET /v3/languagesendpoint instead of the deprecatedGET /v2/languagesand
GET /v2/glossary-language-pairsendpoints. No public API changes, but the returned language lists may include
additional languages.- Retries now cover only HTTP 429, 5xx responses and transient network failures (timeouts, failed connections). Before,
any exception thrown while sending a request was retried. - Each attempt of a request may now run until the time the client would wait before retrying it (the backoff delay)
when that is longer thanPerRetryConnectionTimeout;Timeout.InfiniteTimeSpanstill disables it.
OverallConnectionTimeout(default 100 seconds) still limits a request including all retries. Content-Type,Content-Length,Transfer-EncodingandHostentries inHeadersare now ignored; previously the
first two made every request fail with aConnectionExceptionand the others were sent.- An
Acceptentry inHeadersis now ignored where the library sets its own; previously both were sent. - Calls that pass
nullordefaultas the first optional argument of the translation memory methods with new
options overloads are now ambiguous and no longer compile when recompiled against this version (CS0121):
ListTranslationMemorySegmentsAsync(id, null),ListTranslationMemorySegmentsAsync(id, default),
ListTranslationMemorySegmentsAsync(translationMemory, null),
ListTranslationMemorySegmentsAsync(translationMemory, default),CreateTranslationMemoryImportAsync(fileName, contentLength, null)andImportTranslationMemoryFromFilepathAsync(path, null); previously they compiled. Drop the
argument, cast it to the parameter type (for example(TranslationMemorySegmentsOptions?)null), or pass it as a
named argument (for exampledisplayName: null).
Already-compiled callers are unaffected. - A 3xx response the HTTP client does not follow (for example 304, or a redirect without a
Locationheader) now
throws aDeepLExceptionwithHttpStatusCodeset; previously it was treated as a success. GlossaryEntries.FromTsv()now stores and sends the trimmed, validated entries joined with\n, without blank
lines; previously it sent the original string, with untrimmed terms and\r\nline endings. With
skipChecks: truethe string is still sent unchanged.- HTTP 401 now throws an
AuthorizationException, like HTTP 403; previously it threw aDeepLExceptionwith an
"Unexpected status code" message.AuthorizationExceptionderives fromDeepLException. - Members marked
[Obsolete]in this release now raise warning CS0618 in code recompiled against it (an error with
TreatWarningsAsErrors); already-compiled callers are unaffected.
Deprecated
GlossaryNotFoundExceptionis deprecated; catchNotFoundException, its base class. Glossary endpoints
still throw it on HTTP 404 until the next major version, which throwsNotFoundException.- Deprecated the
DeepLClient.CreateStyleRuleAsync()andUpdateStyleRuleConfiguredRulesAsync()overloads taking a
ConfiguredRulesobject with[Obsolete]; use the overloads taking aDictionary<string, Dictionary<string, string>>
instead. They keep working until the next major version. ACreateStyleRuleAsync()call without configured rules
now uses the new overload and sends the same request; passingnullfor the configured rules still calls the
deprecated overload. - Deprecated
TextTranslateOptions.GlossaryId,StyleIdandTranslationMemoryIdwith[Obsolete]; useGlossary,
StyleRuleandTranslationMemoryinstead. They keep working until the next major version. Error messages of text
translation name the new properties, e.g. "Glossary and GlossaryIds cannot be used together". - Deprecated
DocumentTranslateOptions.GlossaryId,StyleIdandTranslationMemoryIdwith[Obsolete]; use
Glossary,StyleRuleandTranslationMemoryinstead. They keep working until the next major version. Error
messages of document translation name the new properties, as for text translation. - Deprecated
Translator.TranslateDocumentStatusAsync()with[Obsolete]; useTranslateDocumentGetStatusAsync()
instead. It keeps working until the next major version. - Deprecated the language code constants of the
LanguageCodeclass (for exampleLanguageCode.German) with
[Obsolete]; they will be removed in the next major version. Pass the language code as a string, for example
"de", and useGetSourceLanguagesAsync()andGetTargetLanguagesAsync()to retrieve the supported languages.
LanguageCode.RemoveRegionalVariant()is not deprecated. - Deprecated document minification with
[Obsolete]:DocumentTranslateOptions.EnableDocumentMinification,
DocumentMinifier,IDocumentMinifier,DocumentMinificationExceptionandDocumentDeminificationException.
They keep working and will be removed in the next major version. The DeepL API accepts larger documents than when
minification was added; see the usage limits. - Deprecated public types that are implementation details with
[Obsolete]:DeepL.Internal.LargeFormUrlEncodedContent,
MultilingualGlossaryDictionaryEntriesResult, and theMultilingualGlossaryDictionaryEntriesconstructor that takes a
MultilingualGlossaryDictionaryEntriesResult. They keep working and will be made internal in the next major version. - Deprecated
Translator,ITranslatorandTranslatorOptionswith[Obsolete]; useDeepLClientand
DeepLClientOptionsinstead. They keep working and will be removed in the next major version. - Deprecated
Translator.AuthKeyIsFreeAccount()with[Obsolete]; useDeepLClient.IsFreeAccountAuthKey()instead.
Fixed
- The first retry now waits exactly 1 second, and the first attempt's backoff deadline is exactly 1 second; the ±23 %
jitter applies only from the second backoff on. - TLS and certificate failures and proxy tunnel rejections are no longer retried, and their
ConnectionException
hasShouldRetryset to[secure]. Connect, name resolution, timeout and connection reset failures are still
retried. - Document uploads from a non-seekable
Stream(e.g. a network stream) are now buffered before sending, so a retry
after HTTP 429, 5xx or a network failure resends the full document instead of failing. CreateDeveloperKeyAsyncretries refused connections and connect timeouts, as its documentation says.- On .NET 5 and later, connecting is limited to half of
PerRetryConnectionTimeout, so that a hanging connect fails
as a connect timeout instead of a per-attempt timeout, andCreateDeveloperKeyAsyncretries it. Before, a hanging
connect was cut by the per-attempt timeout, whichCreateDeveloperKeyAsyncdoes not retry. ImportTranslationMemoryFromFilepathAsyncnow reads the input file, andExportTranslationMemoryToFilepathAsync
creates the output file, before creating the job: an unreadable input, existing output or unwritable path throws its
IOException,UnauthorizedAccessExceptionorDirectoryNotFoundExceptionbefore any job exists; previously after
the job was created. A completed export job without a download URL throws aDeepLExceptioninstead of an
ArgumentException. The output file is deleted if the export fails.- Fixed
GetTranslationMemoryJobAsync()failing on a job status this library does not know: it is now parsed as
TranslationMemoryJobStatus.Unknown, andWaitUntilTranslationMemoryJobDoneAsync()keeps polling on it. - Fixed
GetTranslationMemoryJobAsync()andCreateTranslationMemoryExportAsync()failing when the job's
parameters,errororstatus_metadataobject contains a non-string field; unknown fields are now ignored. - Multilingual glossary IDs are now URL-encoded in request paths.
CreateMultilingualGlossaryAsync()andCreateMultilingualGlossaryFromCsvAsync()now throw
GlossaryNotFoundExceptionon HTTP 404, like the other multilingual glossary methods.GetMultilingualGlossaryDictionaryEntriesAsync()no longer throwsArgumentExceptionfor entries returned by the
API that the client-side entry checks would reject.ReplaceMultilingualGlossaryDictionaryAsync()andReplaceMultilingualGlossaryDictionaryFromCsvAsync()now send
the request body as JSON, the only content type the API accepts for this endpoint.RephraseTextAsync()andCorrectTextAsync()throw aDeepLExceptionif the response holds noimprovementsor
fewer than texts were sent, instead of returningnull, a short array, or throwing aNullReferenceExceptionor
IndexOutOfRangeException.- A Write API response without
detected_source_languagethrows aDeepLExceptioninstead of a
NullReferenceException. - An unknown document status in the response no longer fails
TranslateDocumentStatusAsync(),
TranslateDocumentWaitUntilDoneAsync()andTranslateDocumentAsync(). Before, it threw aDeepLException
("Failed to deserialize JSON in received response"); nowDocumentStatus.StatusisStatusCode.Unknownand the
waiting methods keep polling. - The document ID is now URL-encoded in the paths of the document status and download requests. Before, an ID
containing characters such as/or?was inserted as is and addressed a different URL. ExtraBodyParameterswith atextkey now replace the texts ofTranslateTextAsync(), like any other parameter.
Before, the extratextwas sent in addition to the texts.TranslateTextAsync()now throws aDeepLExceptionwhen the response holds notranslations, an empty list, or
fewer translations than texts sent, or a translation withoutdetected_source_language. Before, it returnednull
or threw aNullReferenceExceptionorIndexOutOfRangeException.- A request that exceeds
PerRetryConnectionTimeoutnow throws aConnectionExceptionwith a "Request timed out"
message, like the other timeouts, instead of "Unexpected request failure". - Cancelling a request through the
CancellationTokenargument now always rethrows the cancellation exception. Before,
a plainOperationCanceledExceptionraised by the HTTP handler was wrapped in aConnectionException.
Document translation still wraps it in aDocumentTranslationException, with the cancellation exception as
InnerException. - Fixed the doc comments of
LanguageCode.EnglishandLanguageCode.Portuguese, which claimed they may only be used as
source languages. - A malformed or mistyped JSON response now throws a
DeepLExceptionwith theJsonExceptionasInnerException.
Before, the rawJsonExceptionwas thrown.