ext-to-speech/">Text to Speech</a> service to synthesize text into a
.wav file.</p>
<pre class="prettyprint source lang-js"><code>var watson = require('watson-developer-cloud');
var fs = require('fs');

var text_to_speech = watson.text_to_speech({
  username: '&lt;username>',
  password: '&lt;password>',
  version: 'v1'
});

var params = {
  text: 'Hello from IBM Watson',
  voice: 'en-US_AllisonVoice', // Optional voice
  accept: 'audio/wav'
};

// Pipe the synthesized text to a file
text_to_speech.synthesi