Generate composition for p2p video recording on Twilio - react-native

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

Related

How to track whatsapp online status of unsaved contacts programatically

Over searching, I found various solutions such as -
1 - Web Scraping using selenium but that is a very inefficient way to track multiple contacts
2 - Using store object. That was one of the best ways to track WhatsApp online status for multiple numbers but after the recent update, WhatsApp has stopped showing the online status of unsaved, unchatted contacts due to which all these methods have failed.
but I wonder how various applications like -
. https://chatwatch.net/
. https://play.google.com/store/apps/details?id=com.familog&hl=en_IN&gl=US
are still able to track the online status ?
After 6-7 December update, you can't.
Your ways:
Mock the XMPP Protocol
Create a real device (like emulator or android phone) and get the data on client.
Create a real device (like emulator or android phone) and get the data from Whatsapp Web.
Mock the Whatsapp Application.
Man in the middle attack to whatsapp application.
These ways deprecated because after 6/7 December Security Update if you don't have whatsapp chat history with this number, you can not subscribe his presence.
After today, if you want to track someone you have to chat with him. If you message the person you will follow before following, this will be detected by whatsapp and you will get banned.

Is it possible to implement one-to-many WebRTC video room using Twilio Video API?

Is it possible to implement one-to-many WebRTC video room using Twilio Video API? One publisher and many subscribers. Webinar.
Do you mean a group room instead of a peer-to-peer room?
This is possible, and they announced in May'17 an increase in the number of users per room up to 50.
In their documentation and tutorials there is an example on how to start a group room and how to configure it. See this link. You can see how to implement it on different languages. :)
EDIT:
So I don't think you can create the room specifying a user id who would be the presenter, and then automatically all others who join would be just spectators.
Now, when joining a room with Video.connect, you can specify options for audio and video, like:
var Video = require('twilio-video');
// Connect to the Room with just audio
Video.connect('my-token', {
name: 'my-room-name',
audio: true
});
You can see more on how to join and the options you can specify here. So you could always wrap this in your code, and force every other viewer to not send video.
philnash answered in the related topic that it's impossible at the moment.

Getting RTCpeerconnection object of participants in twilio video api

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.

How to implement group video chat using vLine API

I am new to WebRTC and vLine API. I need to implement a Group Video Chat just like Google Hangout using vLine API and PHP. Please suggest if any example or solution available or how to go about it?
Thanks
Tanjum
We have a PHP example on GitHub: https://github.com/vline/vline-php-example (More examples available here).
With the current API you can implement group chat with a mesh topology where each user establishes a connection with the other users (using person.startMedia() on each person you want to include in the conference). Due to both bandwidth and CPU, this won't scale well beyond four people or so.
We have a better conferencing solution in development (that won the Best Conferencing Award at the WebRTC Expo), but it's currently only available to a select group of beta testers.

One to many video Audio conferencing - webrtc - openTok

I searched about this on google but could not find any suitable answer so posting here for help.
I want to implement video streaming with multiple participants connected. While google this topic I found that WebRTC provide similar functionality but I want to make sure whether WebRTC can support all my requirements.
I want to build an application that should support large number of participants in conference (around 10000).
I want to implement facility like one participant is broadcasting its video and audio streams and other are just listening to their stream.
Also when prompted only one participant will be able to communicate with broadcaster which will be managed by one participant (a administrator). Administrator will decide who can communicate with broadcaster.
Is same can be possible with any other WebAPI ?? I found OpenTok, but not confident if it provide any feature of moderation in conference (i.e. feature of having an Administrator who manages stuff)
Did anybody worked on similar concept or having any information related to this.
Let me know if I am not clear of any further details are required.
Any help would be useful,
Thanks in anticipation
Hardik - I am Product Manager at TokBox, the makers of the OpenTok platform. Good news: TokBox can fulfill virtually all of your requirements, but with a few caveats.
TokBox has been building a video chat/conferencing platform for years, long before WebRTC even existed in fact. In that time we have supported many customers with almost your exact requirements on OpenTok, a platform that is based on Flash (Major League Baseball is one such customer). Building applications on this architecture has the added advantage of solving virtually all of the interop issues that exist when connecting people using different devices and browsers. It is based on Flash however, which technically doesn't meet your WebRTC requirement. So you know, there's that.
WebRTC is where it's at though, which is why we created OpenTok for WebRTC in 2012. It was a complete rewrite of the platform that not only provides higher quality video, but also gives developers more hooks and far more control over how exactly they integrate video and audio chat into their primary customer experience.
Currently in beta (as of this writing in June 2013) are two new components in our WebRTC infrastructure. The first we refer to as Mantis, which solves many of the challenges associated with hosting large multi-party calls. The other is Cloud Raptor, which gives developers access to a stream of events stemming from a WebRTC session, and through which developers can issue events and commands of their own. Raptor is what enables you for example to moderate calls, boot participants, and control whose audio and video streams are broadcast to all the other participants.
So, TokBox has what you need. In the short term we can help you get up and running using OpenTok pretty quickly. Then we can discuss with you how to get you onto OpenTok for WebRTC and into our Mantis and Raptor beta program.