Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Uses the paid Google Translate API to translate text.

branch: master
Octocat-spinner-32 lib Initial commit. December 27, 2011
Octocat-spinner-32 test Initial commit December 27, 2011
Octocat-spinner-32 .gitignore . December 22, 2011
Octocat-spinner-32 LICENSE Created files. December 22, 2011
Octocat-spinner-32 readme indentation December 27, 2011
Octocat-spinner-32 package.json Initial commit. December 27, 2011

Google Translate API client for node.js. The new API (v2) is a paid service. To create a key, you'll need to go here and enter your credit card details.

var translate = require('../lib/translate')
  , assert = require('assert')

var key = '<your-secret>';

// Translate ones string
translate({key: key, q: 'my test', target: 'fr'}, function(result){
  console.log(result); // prints {"my test": "mon test"}

// Translate multiple strings
translate({key: key, q: ['one', 'two'], target: 'fr'}, function(result){
  console.log(result); // prints {"one": "un", "two": "duex"}
Something went wrong with that request. Please try again.