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.
Related
I have built a bot in Visual Studio using C#, which I have registered with the Bot framework. Its a test bot at the moment, which merely scans the incoming text and returns a message on how many characters are in the message. However, what I want to do is to hook this bot up to a Teams channel and use some sort of trigger (similar to slash commands in Slack) and then take the text from the message and send that to my bot, which will then run some code to forward that data on to an external URL, which would then reply back to the bot and then forward that data into the Teams channel. Does anyone know if something like this is possible? At the least all I need to know is whether I can get some functionality similar to slash commands in Slack, which I can then work with and get the desired outcome from this bot.
Firstly, the issue with Microsoft Teams bots that you either need to talk to them in 101 or mentioned them in a group conversation.
Secondly, the Slack-like commands are not supported and you need to understand the intent of a person. You can use buttons on cards instead.
It can be done in a few ways. The main idea is the following.
Bot: Hello, my name is Pradeep Patel. You can use me like "#pradeep launch ", where what is a parameter for launch command.
User: #pradeep launch rocket
Bot: User, the rocket has been launched.
User: #pradeep try jump
Bot: Sorry, I don't have the command "try" implemented. Please type "help" to find out more information.
You can use multiple tools to recognize intents:
RegEx
Google Api.ai
Microsoft LUIS
I have an ordinary C# MVC website that is connected to a database were I'm storing my phone apps Push IDs.
I take these push IDs and want to send a push to it.
I can do this manually with the send test push function on Microsoft Azure website by inserting the value into the tag field there.
But now I want to do it with the REST API from my website.
I followed this for the .NET example
https://github.com/Azure/azure-notificationhubs-samples
The payload for Android looks like this:
{\"data\":{\"message\":\"" + message + "\"}}
I tried adding the tags to the payload by doing this:
{\"data\":{\"message\":\"" + message + "\"}, \"tags\":{\"DeviceToken\":\"the push ID here\"}}
But it didn't work. The push got sent to everyone.
How do you use or format the tags in the REST API?
Solution:
headers.Add("ServiceBusNotification-Tags", recipient);
recipient in my case is the installationID
According to your description, I checked the REST API Send a GCM Native Notification and followed azure-notificationhubs-samples to test this issue. In order to add tags to your payload, you could specify ServiceBusNotification-Tags header. I sent a GCM native notification to a set of tags (game, news), you could refer to it:
Additionally, you could leverage Microsoft.Azure.NotificationHubs for sending push notifications. For more details, you could refer to this official document.
Long shot, but I'd like to fiddle with ViaGogo API (C# library more precisely). ViaGogo has a well documented public API, documentation is avaliable here.
Problem is, you need to authenticated as it usually happens with this kind of APIs: usually, you find a section of the website, maybe in your profile section, where you can obtain keys, secrets and so on (this happens for example on Facebook or Amazon).
As for ViaGogo, I only found a link that points to a Google Form: this form asks for info about advertising and affiliation on a complete different level of what I need, I won't publish anything read via API. Furthermore, there's no field to leave an e-mail address.
Their C# library seems pretty popular as far as I can tell from downloads from NuGet; I wonder how all these thousands of devs succesfully called that API.
Has anyone succesfully obtained authentication info from ViaGogo?
According to note in registration form, you have to wait for 30 days for their reply.
For more help you can contact them on following contacts:
E-mail: affiliate#viagogo.com
Telephone: +442075532777
Or
http://www.viagogo.com/in/help
There doesn't seem to be any way around this registration according to their website and the api itself -- an appID and password is required. You may try your luck emailing them at Affiliate.Team#viagogo.com -- see this issue on github where the possibility of getting an account via email is discussed: https://github.com/viagogo/developer.viagogo.net/issues/24
I am trying to keep track of the livestream viewers of a specific channel.
This is no problem when I have got the stream ID and use it manually.
However I want my program to be able to track upcoming livestream automatically. So I want to get the livestream ID from the channel for the next upcoming livestream. I have been looking through the documentation from the API, but I couldn't find anything.
What API call do I need to make?
You cannot get the liveBroadcast or liveStream object that does not belong to the user or channel you are authenticated as. The list endpoint for each object requires you to authenticate as your own channel/user to retrieve your own live events only.
If you want to retrieve information on another channel's current live broadcasts, you have to use the standard Search/list endpoint:
part -> snippet
channelId -> [channelId of the channel/user with the live event]
eventType -> live
type -> video (required when setting eventType to live)
HTTP GET https://www.googleapis.com/youtube/v3/search?part=snippet&channelId={channelId}&eventType=live&type=video&key={YOUR_API_KEY}
I am a beginner in QuickBook. I have created a .NET application and is able to connect to a QuickBooks Api based app from my application. I have managed to show Blue Dot Menu in my application.
Now I have a requirement to attach to company file.
1 - I would like what this company file is all about and what does it contain ?
2 - How are they created and managed ?
3 - How can I attach or access these files using .NET application ?
Thanks in advance.
At first, you can read the common QB terminologies.
https://developer.intuit.com/docs/0025_quickbooksapi/0070_glossary
Development related docs are available here -
https://developer.intuit.com/docs/0025_quickbooksapi/0010_getting_started
Using ApiExplorer, you can test all endpoint.
Ref - https://developer.intuit.com/docs/0025_quickbooksapi/0010_getting_started/0007_firstrequest
You can try the sample .net
https://github.com/IntuitDeveloperRelations/IPP_Sample_Code/tree/master/QuickbooksAPI/DotNet
.net devkit - https://developer.intuit.com/docs/0025_quickbooksapi/0055_devkits/0100_ipp_.net_devkit
1 - I would like what this company file is all about and what does it contain ?
Company file contains data. Your QBD's data get saved in company file(locally). Comapny file's data gets uploaded to cloud when you sync it. After sync, you get an id(called 'relamId' corresponding to your company file). While calling API endpoints, you use that relamId as a dataSource.
For QBO, all data gets saved in cloud.
2 - How are they created and managed ?
End-users(company file owners) manage their company files.
3 - How can I attach or access these files using .NET application ?
In the sample app's web.config, you need to set consumer key, consumer secret and app tokens. Your app's user will go through the OAuth flow to connect their QB account's data(available in cloud) with your app. Your app should use that consumer key, consumer secret, apptoken and releamId to get access token and access secret. Using these tokens, your app will be able to communicate with end-user's data-file.
Hope these info will be useful.
Thanks