Free Translate(google/deepl) API for Python
Project description
Quick Start
supported google and deepl
import mytrans
r = mytrans.google('August 22, 2020 The sky became pitch black due to sudden rain and thunder from the afternoon', target_lang='zh-CN')
print(r.res) # result of list
print(r.text) # source result (unprocessed)
print(r.json) # source result to dict
r = mytrans.deepl('2020年8月22日 午後から急に雨が降ったり雷が鳴ったりして空が真っ暗になった', target_lang='zh')
print(r.res)
Supported Languages
google 和 deepl 的 lang_code有些不同,需自行识别。
The lang_code of google and deepl is a little different, so you need to identify it yourself.
这里列出常用的 lang_code:
Common lang_code are listed here:
deepl 只支持下列几种,google则更多。
deepl only supports the following, google has more.
-
中文(Chinese): zh (deepl), zh-CN (google)
-
英语(English): en
-
德语(German): de
-
法语(French): fr
-
西班牙语(Spanish): es
-
葡萄牙语(Portuguese): pt
-
意大利语(Italian): it
-
荷兰语(Dutch): nl
-
波兰语(Polish): pl
-
俄语(Russian): ru
-
日语(Japanese): ja
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mytrans-0.0.1.tar.gz.
File metadata
- Download URL: mytrans-0.0.1.tar.gz
- Upload date:
- Size: 4.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6bdd801a5f6e2ef31c7208d30bf1ada864d038b27b4c6182e1fa8640d366922f
|
|
| MD5 |
14c877f62bde2598b966b201c7abca67
|
|
| BLAKE2b-256 |
49ca9ff3db031495e2e8018b96b1bef9a8c356d7b429edfbfe7c63da90cd7513
|
File details
Details for the file mytrans-0.0.1-py3-none-any.whl.
File metadata
- Download URL: mytrans-0.0.1-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b87700aefcfb2d6a7c9b6238eb1a6870d04bbe08a58eb32764fe55462373fd73
|
|
| MD5 |
b49c86cd6d34b8d82d7447ec2898d16d
|
|
| BLAKE2b-256 |
a998860f1b4bedcd838cdefd9f9e292475f29511ff0db40798b1cb4952ddf968
|