I'm working on to implement an audio-only conference app which is something like Google Hangout, but without video.
In Google Hangout, all participants can see which participants is currently speaking, via visual feedback. In other words, when someone starts speaking, their avatar comes foreground of all of participants immediately.
So, here's my questions for Twilio and its client SDKs:
Is there any way to detect current speaker (and give some feedback to users) ?
Is there any way to get input level of a microphone via the SDKs?
Interesting use cases .
I think both these can be achieved with Twilio and here's my views on how to achieve these
Detecting current speaker
What you essentially require is a flag that is globally shared across all participants. This flag should have the facility to be dynamically updated in real time by the speaker who is speaking and at the same time push this information , again in real time , to other participants. So , simply put , you want a shared resource where each Twilio Client can 'publish' and 'subscribe' their 'speaking' state. You could achieve it via Twilio Sync .
To do that , you could create a list object on Sync and add each participants whose audio level goes above a certain level that you consider them speaking . All Client instances in the conference should be subscribed to this list and so on 'itemAdded' or 'itemRemoved' each instance of client can get a list of participants who are speaking . Based on it , UI changes could be done.
You can get audio level (output and input) at each client instance by querying Twilio Voice Insights .For Audio input level , you will have the value passed in parameter named AudioLevelIn .
Note : Both these products require requesting access .
Related
I'm working on a video call web application using Twilio Video REST API and JavaScript SDK 2.8.0.
My requirement is that Users should be able to record video calls only if they want to record, and there is no need to record all calls automatically.
According to twilio documentation, group video rooms created via the REST API can specify whether to record or not in the initial room creation HTTP POST request only. (using RecordParticipantsOnConnect=True)
Is there any possibility to start recording after room was created ?
Currently no. You would have to move participants to another room to record them.
I have a scenario wherein I would need to mute some of the remote participants in the video call in my local machine. Example of this use case is when I want to be able to just hear a remote participant that is presenting and no else.
Solution I found online is to muted as stated here: https://github.com/twilio/twilio-video.js/issues/363.
Muting the html element appears to work but I'm just curious if there is a Twilio method that can achieve the same result?
At this time, the SDK does not provide a native ability to mute remote tracks. Only the local participant can disable their own tracks.
A solution to this problem is the track subscription API. This API allows you to make a request to update a certain participant's subscribe rules so you can programmatically unsubscribe users from tracks. For your use case, you can could hit this API to unsubscribe participants from specific users in the room, or unsubscribe all participants from all tracks except the presenter.
More info on this can be found here: https://www.twilio.com/docs/video/api/track-subscriptions
Let me know what you think!
I am currently developing an iOS application which requires users to join video chat rooms, very similar to how Houseparty and Airtime works. However, I don't know where to start, nor what third party service I should use in order to incorporate this in my app. From what I can find online, Quickblox seem to be one of the best, but on the other hand, it seems to only offer "video calls", meaning that in order to start a group video chat, you have to call users, in contrast to how for example Houseparty works where you can join a room without accepting a call. This issue even seems to state that it is not even possible to do this at all. My question is therefore, is it possible to use Quickblox in order to develop an application that allows users to have video group chats, without ever calling someone and instead allow them to join the video group chat sporadically? If not, which third party service makes this possible?
Regular calls in quick blox are implemented as a peer to peer calls. The feature you need is conference call . Quick blox have custom enterprise solution with the usage of server-side, it provide call with 10 to 15 users but in the enterprise tier . Check Out link below.
Quick blox
I'm using Twilio chat SDK for iOS, and I've run into a problem. I can get the list of channels, get an individual channel, and get the message count for that channel successfully. The next thing I want to do is grab the last message from that channel using getLastWithCount. However, that method's completion is never called.
I need to do this without actually joining the channel, because I'm just trying to get the last message to display in a summary screen with many others. I don't want to join, because the other party may be online on the other end, and it would falsely display the user as online (even if briefly)- when it is simply an automated function at work. (They haven't entered the "chat room" yet.)
I've set client synchronization strategy to .all, and even tried synchronizing the specific channel before attempting getLastWithCount.
How would you get the last message in a Twilio chat channel without joining the channel?
Twilio developer evangelist here.
You can do this, but your users need to have a new permission to do so. The documentation on Users' Roles and Permissions is worth reading to learn more.
Default user permissions are:
createChannel
editOwnUserInfo
joinChannel
But you need one more that allows viewing channels and their messages without joining the channel. One that does this is editChannelName (not obvious, sorry about that).
To do this, you'll want to create a new role and give it those 4 permissions in total. You can then either assign that role to your users or set it as the default role for your Chat service. Once your users have this role and permissions they will be able to view the messages.
Let me know if this helps.
I'm trying to see if this is even possible in twilio. I'm hoping maybe someone's had a similar challenge and came up with a creative solution...
Our company has a unique phone number that's only displayed on our website. I've been asked if it's possible to find out not only how many calls we're getting (which is simple enough to track in twilio), but also who's calling. Basically, they want to follow the details of a users activity. From website to phone call.
Theoretically, they'd like something like this:
A user, lets call him John, comes to the website & is assigned a unique id of "12345". The id is stored in a cookie for returning users (this I can already handle).
If John calls the phone number displayed on the website, we...somehow through the use of twilio...know it's user #12345.
We can then create monthly reports stating user #12345 called the phone number 7 times this month for a total of 18 minutes.
There's so many "what if's" that go into this, that I'm just not sure it's even possible, but perhaps someone knows of a creative way this can work? A few things I've considered, but none of them are foolproof:
Tracking a combination of John's geographical location while browsing the website and the time of web browsing, then using twilio voice to track the geographical location & time of the phone call, to make a best guess. The problem is it sounds like twilio voice isn't always great at providing geo location.
Tracking mobile click to calls on the website, then matching the time of the click to the time of the phone call. Several problems with this, including multiple users calling at the same time, and we'd only be tracking those who browsed the website via mobile, then clicked to call.
For mobile click to call, passing the user's id via a phone extension, which twilio then reads (not sure if this is even possible in twilio). But again, this would be limited to mobile users.
So, I'm just not sure if this is even possible. Any idea's on how this could be implemented?
Thanks so much for any help.
Twilio developer evangelist here.
Have you considered making it possible to make the calls through the website itself? If you implemented Twilio Client you would be able to directly track users who called from the website and they'd be able to do so without picking up the phone too. That direct connection would allow you to make the calls more personal too, as you'd know exactly which user was calling.
Check out the tutorial on implementing browser calls in Twilio and let me know what you think.
I can't think of any straightforward ways to connect a user's browsing session to a phone call made with a different device though. You could ask the user to input their ID in order to start the call, using <Gather> to receive the input and tie that call to the user and whether they currently have a live session on the site. That might be an unnecessary barrier to people calling though, so you'd have to weigh up that option.