I am developing a bot in C# for Skype and my problem is that I would like to transform the voice notes that can be sent by the phone (with the icon of the microphone) in text and I can't get that audio.
In the properties of the activity.attachment that I receive I have seen the following:
ContentType: audio
Content:
ContentURL: https://smba.trafficmanager.net/apis/v3/attachments/0-weu-d9-734cab9e78c28a1619a39ce8c69342d1/views/original
Name: 2-audioMessage.m4a
Properties: {}
ThumbnailUrl: https://smba.trafficmanager.net/apis/v3/attachments/0-weu-d9-734cab9e78c28a1619a39ce8c69342d1/views/thumbnail
it seems that it is saved in the state.
Is there any solution to get the audio file for later send it to a text to speech API?
I would not like to use audio calls because at the moment it's very complicated to implement.
Thanks.
I am assuming that you must have done the following setting to use your callback URL to convert it into text:
1) Register you bot in Microsoft Bot Framework Portal. Please refer to this for the instructions. Once you complete the registration, update the Bot's Web.config file with the registered config values (Bot Id, MicrosoftAppId and MicrosoftAppPassword).
2) Enable the Skype Channel and update the settings by enabling 1:1 audio cals and updating the Calling Webhook to be https:://{your domain}/api/calling/call. Refer to this for more information on how to configure channels.
3) Update the Microsoft.Bot.Builder.Calling.CallbackUrl setting of the Bot's Web.config file with the callback route https://{yourdomain}/api/calling/callback.
4) Subscribe to the Microsoft Cognitive Services Bing Speech API here to get a key to use the API. Update the MicrosoftSpeechApiKey setting of the Bot's Web.config with the obtained key.
In the following repo , you can find the complete implementation forthe same.
https://github.com/jj116/skype-CallingBot/blob/ac913ab484fcdaf1933bfd230b60041ab10ff3f1/IVRBot.cs
Hope it helps.