2017-07-15 149 views
1

我一直在這個問題上撞了我的頭2天,並將解決方案張貼在希望它可以幫助過去的人。我創建了一個Alexa技能來流式播放電臺,即使使用示例代碼也無法播放它。最後,我只是硬編碼發送電線的值,並且它仍然沒有工作。下面是我送:Alexa的技能不會播放我的流媒體音頻

{ 
 
    "version": "1.0", 
 
    "response": { 
 
    "shouldEndSession": 1, 
 
    "response": { 
 
     "outputSpeech": { 
 
     "text": "Playing Somgwriters island", 
 
     "type": "PlainText" 
 
     }, 
 
     "directives": [ 
 
     { 
 
      "playBehavior": "REPLACE_ALL", 
 
      "audioItem": { 
 
      "stream": { 
 
       "url": "http://la2-ssd.myautodj.com:8198/stream.mp3", 
 
       "token": "", 
 
       "offsetInMilliseconds": 0 
 
      } 
 
      }, 
 
      "type": "AudioPlayer.Play" 
 
     } 
 
     ], 
 
     "reprompt": {}, 
 
     "card": {} 
 
    } 
 
    }, 
 
    "sessionAttributes": {}, 
 
    "statusCode": "200" 
 
}

回答

1

我終於找到了事業的documentation

audioItem.stream.url: 在遠程標識的音頻內容的位置HTTPS位置。 音頻文件必須託管在Internet可訪問的HTTPS端點上。 HTTPS是必需的,託管文件的域必須提供有效的,可信的SSL證書。自簽證書不能使用。許多內容託管服務提供這一點。例如,您可以將文件託管在Amazon Simple Storage Service(Amazon S3)(Amazon Web Services產品)等服務中。

相關問題