TIPS Unable to get TTS to work on vitalpbx.

piaftnt

Member
Joined
Jul 16, 2010
Messages
93
Reaction score
17
Hi,
I am having an issue getting TTS to work on vitalpbx. In following http://nerdvittles.com/?p=25333 I see in the script that the password is supposed to look line the following: $IBM_password = "xxxxxxxxxxxx";
Yet in http://nerdvittles.com/?page_id=25616 it says "When Text to Speech dialog opens, copy your API Key and URL". I see in the url in the script but there is no place to put the API Key. I only have a place for a password, yet IBM does not give me a password in the credentials.
For giggles I tried putting the api key in the $IBM_password field but no joy.

In the ibmtts.txt log I see the following at the bottom:
Code:
CURL URL: https://stream.watsonplatform.net/text-to-speech/api/v1/synthesize?voice=en-US_LisaVoice

STREAM FILE /tmp/text ""
510 Invalid or unknown command
Couldn't figure out returned string, Returning code=510 result=0

Is this just the error from Watson because the credentials are incorrect?

In addition, if I dial into the demo ivr on my system and tell it to call American Airlines it completes the call. This tells me that STT is working. The weird thing about that is I forgot to put the credentials into the getnumber.sh file. To be sure I was working with the correct file I renamed getnumber.sh and of course I am unable to place a call using the STT.

Can someone please tell me what I am missing?
 

AndyInNYC

Active Member
Joined
May 23, 2013
Messages
773
Reaction score
124
The APIKey is now 'APIKey' and you no longer need to use it. You should just need to use your password.
If there is a bluemix-test file, try putting the password there and running that script.
 

piaftnt

Member
Joined
Jul 16, 2010
Messages
93
Reaction score
17
The APIKey is now 'APIKey' and you no longer need to use it. You should just need to use your password.
If there is a bluemix-test file, try putting the password there and running that script.

But that is the problem. I do not have a password. Only an api_key. I even tried deleting the service and recreating it.

The format is like the following:
Code:
{
  "apikey": "XXXXXXX-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
  "iam_apikey_description": "Auto-generated for key XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
  "iam_apikey_name": "Auto-generated service credentials",
  "iam_role_crn": "crn:v1:bluemix:public:iam::::serviceRole:Manager",
  "iam_serviceid_crn": "crn:v1:bluemix:public:iam-identity::a/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX::serviceid:ServiceId-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
  "url": "https://stream.watsonplatform.net/text-to-speech/api"
}

What am I missing?
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,206
Reaction score
5,228
If you ever forget your passwords, you can retrieve them by navigating to Resource List:Services:TTS or STT:View Full Details:Show Credentials.

This is the key you insert in the password field. The username now is "apikey" and you shouldn't change it.
 

piaftnt

Member
Joined
Jul 16, 2010
Messages
93
Reaction score
17
If you ever forget your passwords, you can retrieve them by navigating to Resource List:Services:TTS or STT:View Full Details:Show Credentials.

This is the key you insert in the password field. The username now is "apikey" and you shouldn't change it.

Ok, that is what I did but I cannot get it to work.

Just to be clear, the password line should look something like this:
Code:
$IBM_password    = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"

The only 2 lines I changed in the file are the password field and my email address. How can I troubleshoot this? Is there some way to turn up logging to get meaningful errors?
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,206
Reaction score
5,228
Are you sure you're using your TTS ApiKey and not your STT ApiKey?? They're different.

The other possibility if you're using the free tier is you're out of free credits until next month.
 

piaftnt

Member
Joined
Jul 16, 2010
Messages
93
Reaction score
17
Are you sure you're using your TTS ApiKey and not your STT ApiKey?? They're different.

The other possibility if you're using the free tier is you're out of free credits until next month.

I am on the standard plan and I just copied the key into the curl example on the ibm site and was able to generate hello world.wav and play it back.

Any other ideas?
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,206
Reaction score
5,228
After untarring it, insert your APIkey in the attached script. Then run it and see what you see.
 

Attachments

  • bluemix-test.tar.gz
    556 bytes · Views: 6

piaftnt

Member
Joined
Jul 16, 2010
Messages
93
Reaction score
17
After untarring it, insert your APIkey in the attached script. Then run it and see what you see.

I did as you suggested and initially it failed because cdir-transferring-further-assistance.wav does not exist on vitalpbx. Is it supposed to exist? var www html is empty on my vitalpbx.

Once I pointed the bluemix script to a valid wav file it works as expected.

To be clear my problem is with TTS not STT but I figured it was worth testing anyway.

Edit: Finally figured out the problem. There was a missing ; at the end of the password line.

Thanks for the help.
 
Last edited:

Members online

Forum statistics

Threads
25,825
Messages
167,849
Members
19,250
Latest member
mark-curtis
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top