Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

google-tts

1.1.2 • Public • Published

google-tts

A Node.js module for text-to-speech conversion using Google's TTS API.

Installation

$ npm install google-tts

Usage

You can either play the received speech directly or save it to a file:

var GoogleTTS = require('google-tts');
 
// Play the received speech
GoogleTTS.play(text[, callback]);
 
// Save the received speech into an mp3 file
GoogleTTS.convert(text, filename[, callback]);

The callback functions are run after the speech is finished playing or the file is completely written, respectively.

Note that the .mp3 extension is added automatically to filename for safety.

install

npm i google-tts

Downloadsweekly downloads

125

version

1.1.2

license

ISC

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability