Custom Translation API
A GET request will be sent to the API address you fill in with application/www-urlencode data:
text: The text/string to be translated
source_language: Original text language code zh,en,ja,ko,ru,de,fr,tr,th,vi,ar,hi,hu,es,pt,it/string
target_language: Target text language code zh,en,ja,ko,ru,de,fr,tr,th,vi,ar,hi,hu,es,pt,it/string
Expects a JSON format data to be returned from the interface:
{
code:0=success, >0 represents failure, msg:ok=success, others are the reason for failure, text: translated text
}
See https://github.com/jianchang512/translate-api for a free translation API implemented based on cloudflare and m2m100.