Getting RTCpeerconnection object of participants in twilio video api - webrtc

I need to implement signalling between peers in a many to many video conference.
To do that i need access to the RTC Data Channel.
Since "Twilio Video API" doesn't yet provide Data Channel, should I use "Twilio Conversations API" for this task as it provides access to the RTCPeerConnection Object which can be used to create data channels which i found over here:
Or is there a way to get the RTCPeerConnection object of other peers in "Twilio Video API" itself?

Twilio developer evangelist here.
The Twilio Conversations API is deprecated so you should not use that.
There's no official way to get access to the RTCPeerConnection object within the Video API. I haven't found an unofficial way yet myself (though I'm sure there is, given that JavaScript doesn't really have private methods/properties).
If you definitely need the RTCDataChannel itself then you might not want to build with the Twilio Video API.
However, if you are looking to signal between peers, then perhaps the Twilio Sync API, which is a real time API for syncing data between clients and works really well alongside Twilio Video, can help.

Related

How to get "mute" state of all users in the channel? [agora.io]

I have a Voice Call in which I would like to have a little overlay showcasing which users have their audio muted. Is there a callback I can use to know whether users have locally muted their stream?
I have not found a way to do this directly using agora.io's library.
You can use the onRemoteAudioStateChanged API: https://docs.agora.io/en/Video/API%20Reference/java/classio_1_1agora_1_1rtc_1_1_i_rtc_engine_event_handler.html#a24fd6b0d12214f6bc6fa7a9b6235aeff

Generate composition for p2p video recording on Twilio

I am using twilio to in my app for a peer to peer video chat (using Small Group Room with max 2 participants). I have enabled video recording in my backend so I am able to record and save the videos but the problem occurs when I try to use the compositions API.
Composition API requires video_sources which is an array of video sources that will be used in the composition. Nowhere on the documentation it says how I can set the video source value. I can grab the PARTICIPANT SID and use that but it would be much much easier if I can use a value that is stored in my database. Users are also able to disconnect from the room and connect again so I need to keep track of video sources of a user.
Has anyone came across this issue?
This is a perfect example of what I mean by custom video_source
Link to Twilio Documentation
The compositions API is only supported for Group Rooms.
Comparing Room Types

Voice call connection routing React-Native

I am trying to build an application which works this way: I as a user want to start a call with another user. The way I want the connection be made is by random. So it will connect to one of the many clients out there by random. Also when other clients try to make a call, it should connect to another random client and so on. I want those phone calls be made via application(such as WhatsApp) not as a phone call.
Now, the question is; is Twilio a good approach for this purpose?
If yes can you tell me which of their feature would fit my app the best?
Thanks for any suggestions!
Twilio developer evangelist here.
I can answer that Twilio would be a good approach for you to do this within your own application. I'd recommend using Twilio Video to build this as it allows cross platform communication via audio or video (in your case, you may not need the video, but this will give you the best audio quality).
As an example, my colleague Dominik built a video roulette application. It is the case that the interface was built in JavaScript for the web, but the idea would be the same for a native app. The code for the server side part of the application should give some insight into how to connect random pairings.
It's also possible to integrate Twilio Video with CallKit and Connection Services so that you can make outbound calls to other devices that ring like a real incoming call.

How do Events work in the Sonos Cloud API?

Various parts of the Sonos Cloud API include subscribe/unsubscribe calls, but I don't see any example of how those events get delivered to the caller. What am I missing?
The documentation for how to subscribe to and handle events can be found here.

Using pre-recorded audio instead of text-to-speech along with Watson Conversation bot

I built a conversation bot with text-to-speech, but no matter how well I tune it, the voice sounds robotic.
I think it would be simpler to have the conversation bot pick a pre-recorded audio and stream it back to the user.
Does anyone see issues with this?
Is there already an example of this so I don't reinvent the wheel?
This functionality needs to be implemented on the client side of the application. Watson Conversation Service can return a text answer and for example an index of the audio record you want to play.
This index then needs to be picked up by the client application communicating with Watson Conversation Service (e.g. a web page in node.js) and the audio record can be played to the user.
As for some examples...in Conversation Service docs there are links to github projects that integrate Watson Conversation Service with node.js web applications - these can be extended by adding the audio records and functionality that will play those records to the user.