Google’s Text to Speech API

Google had introduced upgrades to it’s translate service by adding a provision to Speak out loud the translated text. If you haven’t tried it so far, give it a shot here.

There’s no official API for the text-to-speech service. But while playing around with the web interface, I found that anyone can  get access to  the service. Basically, what Google is taking a plain HTTP GET (REST) based request and returning the audio in MP3 format, The Request URL : http://translate.google.com/translate_tts?tl=en&q=some+text

How to Use it: It’s easy, put some REST based Text in the above URL, and you`ll get a MP3 back. http://translate.google.com/translate_tts?q=This+is+a+good+hack

This can be integrated into different AJAX based widgets to read out the text.

Limitations: All this being unofficial, comes with a limitation. First one: It’s English only, and second, I couldn’t get it to convert text larger than 100 characters. But that can be taken care of by splitting the text into multiple 100 char chunks and then calling the REST API everytime. I made a dummy script, read 1000+ characters with a charm. Make use of it before Google plans to remove it.

VN:F [1.9.22_1171]
Rating: 5.5/10 (2 votes cast)
VN:F [1.9.22_1171]
Rating: +1 (from 1 vote)
Google's Text to Speech API, 5.5 out of 10 based on 2 ratings

Filed in: programming Tags: ,

Related Posts

Bookmark and Promote!

  • stmikeg

    I want to read books and sometimes listen without having my computer in my lap all the time. I want to lay in bed, I want to take it to the gym, in the car. If the price is really 530 I guess I will start looking in other places. The key here is “to read” and when I get tired to listen. I'm older and books are getting to hard to handle most mp3 players are of too great cost have a screen that is too small. They will hold more than one book. I want to be able to download rom many sites and locked into one as the Kindle. How about an answer ?

    VA:F [1.9.22_1171]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
  • hi can you share your dummy script to read 1000 characters. thanks.

    VA:F [1.9.22_1171]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.22_1171]
    Rating: 0 (from 0 votes)
© 2016 Geeknizer. All rights reserved. XHTML / CSS Valid.
Designed by taranfx.