Is it possible to stream voice to directline API from native app on iOS using Swift or Objective-c - ios

I have a bot that leverages all the cool tech that comes with botframework, e.g. LUIS, QnA maker, adaptivecards, etc. The bot works well and I can use WebChat to connect to and ask questions and get responses. However, I now need native iOS (and eventually Android) app that can perform much like webchat does but I do not want to embed webchat in a web control in native app. I plan to have voice always on leveraging something like snowboy or picovoice for hotword to wake app and send commands to bot - users would ask things like "hey bot what is weather in Boston" and get presented with result message or adaptivecard.
Is voice steaming to directline API from Swift on iOS possible (I know most things are possible so any pointers would be greatly appreciated)? Or am I approaching from wrong angle and perhaps there is better/easier way to achieve my goal?

Related

Telegram API swift (or objective-c) client, to read channel messages

I'm wondering if it's possible the read messages from telegram channel from the iOS app.
I want to parse public channel to implement an application which will show a map with latest Air-Raid sirens in Ukraine. There's official channel here - https://t.me/air_alert_ua, which I'd like to parse, and then draw an overlay on the map in an iOS app, like on the following web-site.
I know that there's telethon client for python, but running python inside iOS app isn't a very good idea and perhaps there's a better way. Any help is greatly appreciated.

Twilio: Call and Voice features?

I am trying to implement a call feature in my xamarin forms app using Twilio. I am able to call by providing From and To numbers using this API of Twilio. But the above call is happening via Twilio, I need to make a call via the internet (App to App). Is there any way to do this using Twilio?
Also is there a way to send a voice clip if the call is not answered? And any way to list out all the voices? I am able to list out SMS and call logs, but couldn't find a way to list the voices. I am using c# codes.
Twilio developer evangelist here.
If you want to make App to App calls then you want the Twilio Voice SDK. I am afraid we don't provide an official Xamarin wrapper for this SDK, though there are community wrappers available that might help you.

Video call and chat using WebRTC and Pubnub in native iOS Swift

I'm working on a doctor-patient appointment app on native iOS Swift project. Here I want to implement a live video call with chat using WebRTC and PubNub signaling server. I'm totally new to it. I don't know how to implement this. I have seen some of the Objective-C codes but still I didn't understand. Please help if any of you implement the same in swift.
Highly recommend you reach out to a service such as Vonage (https://www.vonage.com) who can provide HIPAA compliant WebRTC video service for you.
Once you have a set of keys on Vonage, you can use PubNub to move the video session details around the channel in question.
Traditionally I use a JSON object model that looks like this:
channel: "UUID of medical session"
messageID: "MessageID on your platform"
messageType: "videoInvite"
sender: "Hilaj"
sessionDetails: "session JWT and/or session token"
timestamp: "1597347054"
This means you can send text based messages as well as video invites in the same channel and write the event to logs.
I have implemented this in Swift (and previously in Objective C) but it is completely proprietary.
You are going to have to download the Google WebRTC framework.
Taking a quick look at PubNub, it looks like it just does signalling. You are still going to need an actual WebRTC server (eg, Janus). There are others and I'm not really sure which ones support PubNub.

Make a telephone call and send different DTMF tones during the call in iOS

Is it possible to call a phone number programmatically in iOS and send different DTMF tones during the call?.
Basically I want an App to handle the IVR call. I don't know anything about iOS programming. I just want to know the feasibility so that I will put further effort.
Thanks
You cannot do this interactively within the bounds of the iOS SDK (ie, in an App Store app).
You can, however, build a tel URL. See the Apple documentation on phone links for more details if you think this will work for your needs.

How can I get Alexa working on my iOS app?

I have been checking out the Alexa Skills kit the past few days. I have also been poring through the documentations for both the Skills kit and the Voice Service. I am just having a little hiccup trying to understand the flow. I have implemented one of amazon's sample skills (favourite colour sample) in the developer console and also wrote a sample lambda function to handle the type of response that will be delivered. Its working on the test simulator and what left is basically getting lambda running through my ios app. However I have the impression that I don't have to use the voice service. Am I wrong? I am quite confused, it would be awesome if anybody who has some more clarity could shed some light on the matter. If I get lambda working also, I think it will accept requests that are in a particular format. Where do I have to send the encoded audio to get a json response to send to the skills kit? To the Alexa Voice Service?
Also I am authenticating my app using cognito and dynamo db. If I were to use Alexa Voice Service, then it is mentioned that the user will have to also login to amazon. So do I still have to work with the login with amazon sdk? Or is there a workaround?
Based on Amazon documentation there are two ways to interact with Alexa:
Sounds like you want to implement the app thru the Companion method.
As far as the JSON goes, i am currently resolving that issue now, (will post answer once I have it resolved).
Basically you have to use AVFoundation to capture audio from iPhone and send 2 https messages to Alexa (One message with JSON Body & the second message with audio captured as body.) Bases on Documentation
Companion App
(You have a device (such as a smart speaker) that you want to add Alexa to. So, you build in support for AVS. Great! Now you need a way to authorize it and associate it with the user's account. This is the "companion app" approach. The companion app connects to your smart product and allows the user to login and authorize the speaker to use Alexa and connect to their Amazon account.)
Mobile OR Website
AVS App
(You don't have a device you need to authorize - instead you want to speak to Alexa from within your Android/Iphone application.)
Android or Iphone
You can find a swift example on github on how to implement a iOS AVS client
https://github.com/chintan1891/iOS-Alexa

Resources