Azure Cognitive services - TTS

◇◆丶佛笑我妖孽 提交于 2019-12-12 18:10:48

问题


I got an api keys for Azure Cognitive services, but I can't find any documentation how I am calling this service through postmen. Anybody has experience with this?


回答1:


Seems you are trying to call Text To Speech service with your keys. There are two steps for that.

1. Need Access Token

You have to get your token like this format:

Request URL: https://YourResourceEndpoint/sts/v1.0/issuetoken
Method: POST
Hearder: Content-Type:application/x-www-form-urlencoded
Ocp-Apim-Subscription-Key:YourKeys

See The Screen shot for clarity:

You could have a look on official Docs

2. Get List Of Voices With Token You Have Received Earlier

You can request for Text To Speech voice list Like below:

Request URL: https://centralus.tts.speech.microsoft.com/cognitiveservices/voices/list
Method : GET
Authorization: Bearer Token Paste Your Token Here

See the screen shot for clarity

You could find more details here

Note: In case of your test account You can create here

Update:

I would sent a request and somehow I got an uri or something where I can hear it? is this possible?

Yeah its possible. But in that case you have to use sdk. Here Is the complete sample.



来源:https://stackoverflow.com/questions/56920878/azure-cognitive-services-tts

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!