Skip to content

devlato/python-bing-translate-layer

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Python-bing-translate-layer

Python module for interfacing with the latest Windows Azure Marketplace \ Microsoft Translate API \ Whatever its name is now.

What's the name of the "Do whatever the fuck you want with this, just credit me\show me what your doing with it" license?

You are welcomed to expand this module or notify me about issues.

Last check that this module worked: 3th July 2013' (Microsoft could have changed the API by the time you're looking at this)

Features

  • translate a text or html file in a language into another language
  • Stores the access_token and the expiration date in the background. Uses that access_token unless 10 minutes have passed since it's generation (and then generate a new one).

TODO (someday)

  • test it with HTML requests (only tested with individual words)

Prerequisites

Install

Import this module from your code. No need to install anything.

Example

Look at the tests.py. OR:

import translate as tas
tas.set_credentials(app_id='YOURAPPID',client_id='YOURCLIENTID',client_secret='YOURCLIENTSECRET')
print tas.translate('hello', 'en', 'ko')

Homepage

https://github.com/wildeyes/python-bing-translate-layer

Wildeyes.

About

Python Library for interfacing with Microsoft Translate API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published