Gro*_*ler 7 javascript google-api text-to-speech google-translate http-status-code-403
我正在制作一个语言学习网络应用程序,当你将鼠标悬停在单词上时,它会为你发音.我想访问Google Translate API的母语翻译.
我找到了这个资源,它提供http://translate.google.com/translate_tts了基本URL,tl目标语言和q查询字符串.
当我在浏览器中访问它时,这非常有用, http://translate.google.com/translate_tts?tl = zh-CN&q =你好,但我的应用的任何httprequests都会返回403 Forbidden错误.
localhost:~me $ wget" http://translate.google.com/translate_tts?ie=UTF-8&tl=en&q=hello+world "--2015-06-02 11:02:06-- http://翻译.google.com/translate_tts?ie = UTF-8&tl = en&q = hello + world 解析translate.google.com ... 173.194.123.38,173.194.123.36,173.194.123.32,...连接到translate.google.com | 173.194.123.38 |:80 ...连接.发送HTTP请求,等待响应... 403 Forbidden 2015-06-02 11:02:07错误403:禁止.
是否有一个正式的Google API,用于与传统Google Translate API的付款计划相关联的文字转语音,我还没有找到?或者是否有办法以get某种方式播放此音频?
该资源已过时。Google 已弃用免费访问语言翻译 API。现在需要一个 API 密钥。该 API 现在也处于 V2 版本。
如果没有 api 密钥,您将收到 403 禁止错误。
更多信息请参见: https: //cloud.google.com/translate/docs
| 归档时间: |
|
| 查看次数: |
18415 次 |
| 最近记录: |