@@ -89,14 +89,14 @@ var sttAuthService = new AuthorizationV1(
8989 {
9090 username : process . env . SPEECH_TO_TEXT_USERNAME , // or hard-code credentials here
9191 password : process . env . SPEECH_TO_TEXT_PASSWORD ,
92- iam_apikey : process . env . SPEECH_TO_TEXT_IAM_APIKEY , // if using an RC service
92+ // iam_apikey: process.env.SPEECH_TO_TEXT_IAM_APIKEY, // if using an RC service
9393 url : process . env . SPEECH_TO_TEXT_URL ? process . env . SPEECH_TO_TEXT_URL : SpeechToTextV1 . URL
9494 } ,
9595 vcapServices . getCredentials ( 'speech_to_text' ) // pulls credentials from environment in bluemix, otherwise returns {}
9696 )
9797) ;
9898app . use ( '/api/speech-to-text/token' , function ( req , res ) {
99- sttAuthService . getToken ( { } , function ( err , token ) {
99+ sttAuthService . getToken ( function ( err , token ) {
100100 if ( err ) {
101101 console . log ( 'Error retrieving token: ' , err ) ;
102102 res . status ( 500 ) . send ( 'Error retrieving token' ) ;
@@ -119,7 +119,7 @@ var ttsAuthService = new AuthorizationV1(
119119 )
120120) ;
121121app . use ( '/api/text-to-speech/token' , function ( req , res ) {
122- ttsAuthService . getToken ( { } , function ( err , token ) {
122+ ttsAuthService . getToken ( function ( err , token ) {
123123 if ( err ) {
124124 console . log ( 'Error retrieving token: ' , err ) ;
125125 res . status ( 500 ) . send ( 'Error retrieving token' ) ;
0 commit comments