htilly / zenmusic

Slack / Sonos / Spotify / Node.js - Control Sonos through #Slack
125 stars 36 forks source link

TTS not working #18

Closed laurensV closed 6 years ago

laurensV commented 7 years ago

The text-to-speech function uses the following uri to play text:

  // This url just redirects to voicerss because of the specific url format for the sonos
  var url = 'http://i872953.iris.fhict.nl/speech/en-us_' + encodeURIComponent(text) + '.mp3';

However, the url redirects to google translate instead of voicerss.. the google tts api is offline :(. I tried to use the voicerss url directly, but I get a error 500. Is this because the url format from voicerss is in the wrong format? What format does the url needs to be? Can we get the redirect script to voicerss, so we can use our own url with the redirect script installed there?