Skip to main content

Unofficial Free Google Translation API

Project description

goslate provides you free python API to google translation service by querying google translation website.

It is:

  • Free: you know it ;)

  • Fast: batch, cache and concurrently fetch

  • Simple: single file module, just Goslate().translate('Hi!', 'zh-CN')

Usage

>>> import goslate
>>> gs = goslate.Goslate()
>>> print gs.translate('hello world', 'de')
hallo welt

For batch translation, language detection, proxy support etc., please check API reference

Install

$ pip install goslate

or just download latest goslate.py directly and use

futures is optional but recommended to install for best performance.

CLI

goslate.py is also a command line tool

  • Translate stdin input into Chinese

    $ echo "hello world" | goslate.py -t zh-CN
  • Translate 2 text files into Chinese, output to UTF-8 file

    $ goslate.py -t zh-CN -o utf-8 source/1.txt "source 2.txt" > output.txt

use --help for detail usage

$ goslate.py -h

Contribute

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

goslate-1.1.0.tar.gz (8.9 kB view hashes)

Uploaded Source

Built Distributions

goslate-1.1.0-py3.3.egg (14.6 kB view hashes)

Uploaded Source

goslate-1.1.0-py2.7.egg (14.3 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page