/write/rephrase
, which is described below. The endpoint:
Content-Type: application/x-www-form-urlencoded
) and JSON-encoded (Content-Type: application/json
) request bodies/languages
endpoint. At the time of the beta, the following languages are supported:de
(German)en-GB
(British English)en-US
(American English)es
(Spanish)fr
(French)it
(Italian)pt-BR
(Brazilian Portuguese)pt-PT
(Portuguese)text
parameter must match the target language (translating and improving text simultaneously is not yet supported).Note that it is possible to convert text from one variant to another within a language. For example, if American English is sent in an API request with target_lang
set to EN-GB
, the submitted text will be improved and also converted to British English.de
en-GB
en-US
prefer_
will fall back to the default
style when used with a language that does not support styles (this is recommended for cases where no target_lang
is set), the non-prefixed writing styles (except default
) will return a HTTP 400 error in that case.It’s not possible to include both writing_style
and tone
in a request; only one or the other can be included.de
en-GB
en-US
prefer_
will fall back to the default
tone when used with a language that does not support tones (this is recommended for cases where no target_lang
is set), the non-prefixed tones (except default
) will return a HTTP 400 error in that case.It’s not possible to include both writing_style
and tone
in a request; only one or the other can be included./write/rephrase
endpoint returns a JSON object with Improvements under the improvements
key, which contains an array of text
, target_language
, and detected_source_language
objects. Improvements are returned in the same order as they are requested.
character_count
field in the /usage
endpoint response returns a sum of Translate API + Write API characters. You can learn more about the /usage
endpoint here.