Forums

API whitelist suggestion: acapela-vaas

I am developing a Python app which requires access to the following API:

http://vaas.acapela-group.com/Services/Voices/

It would be great to have access to this under the whitelist on the free account, to allow further development on PythonAnywhere.

Kind regards,

Sam

If it's a public API, we're happy to whitelist it. Do you have a link to the API docs or something like that? The link in your post goes to a 404 page :-(

Oh yes. Here are the API docs (not the best in the world, but adequate):

http://www.acapela-vaas.com/documentation.html

This is the Python wrapper I am using to make the calls:

https://github.com/areski/python-acapela

I believe that the API returns a 404 when no payload is passed, the minimum of which is:

data = {
    'cl_login': 'EVAL_XXXX',
    'cl_app': 'EVAL_XXXXXXX',
    'cl_pwd': 'XXXXXXXX',
    'req_asw_type': 'SOUND',
}

Thanks,

Sam

Unfortunately, I still cannot access the API. From the command line:

python /home/<user>/.local/lib/python2.7/site-packages/acapela.py -a EVAL_xxxx -n EVAL_xxxxxxx -p xxxxxxx -t "Hello World" -d /home/<user>/mysite/static/

should work, but always returns an empty mp3 file, I think due to not being able to access the API.

Sam

So the actuall API endpoint I'm trying to access is: 'http://vaas.acapela-group.com/Services/Synthesizer'

Actually this message might be clearer:

>>> import requests
>>> r = requests.get('http://vaas.acapela-group.com/Services/Synthesizer?cl_login=EVAL_xxxxx&cl_app=EVAL_xxxxxx&cl_pwd=xxxxxx&req_voice=sharon22k&req_text=Hello%20world&eq_asw_type=SOUND')
>>> r.text
u'<HTML>\n  <HEAD>\n     Access Denied\n  </HEAD>\n<BODY>\n\n<h1>Access Denied</h1>\n\n<p>\nAccess to arbitrary websites is not available from free accounts;\nyou can only access sites that are on our\n<a href="http://www.pythonanywhere.com/whitelist">whitelist</a>.\nIf you want to suggest something to add to our whitelist\ndrop us a line at support@pythonanywhere.com.  It will have\nto have an official public API.\n</p>\n\n\n<p>\nAlternatively, you can sign up for a paid account at\n<ahref="http://www.pythonanywhere.com/account/">http://www.pythonanywhere.com/account/</a>\n</p>\n<p>\nIf you have already got a paid account and you\'re still getting this messge,\nyou may need to reload your web app (from the "Web" tab) or restart\nyour consoles.  If that doesn\'t help, drop us a line at support@pythonanywhere.com.\n</p>\n\n</BODY>'
>>>

Thanks! That's whitelisted and should work now.

Great, it's working now!

Thankyou!

Excellent, thanks for confirming!