How to change SUBSCRIBER into PUBLISHER during a session?

A certain user is broadcasting in one session.
At first, only one person is publishing in the corresponding Session.
Then, what kind of procedure should one of the viewers, who is a SUBSCRIBER, change their role to PUBLISHER and send the video?

I use React, ReactNative

Is there no way?
I hope somebody could answer me.

You can’t change the participant role on the fly. For doing this you should reconnect the participant with the right role or create it with the right role (publisher) and avoid publish its media (as a fake subscriber).

Further expanding on my colleague’s response, in fact you can change roles, if you are using OpenVidu Pro or OpenVidu Enterprise:

I appreciate your answer.

I am trying to change user’s role.

A broadcast is streaming in live.
A user joined as a subscriber and he changed his role under permission of the broadcaster.

let connectionProperties = {
type: “WEBRTC”,
role: “PUBLISHER”,
record: true
let connectionId = connection.connectionId;
session.updateConnection(connectionId, connectionProperties).then(connection => {
console.log('session.updateConnection > ', connection);

session.updateConnection is not a function error always happens.

At present I am testing OpenVidu Pro, but later I will change it into Enterprise.

Am I missing something?

At present I used “session.updateConnection()” in javascript file of Frontend.
Do I have to use “session.updateConnection()” in Node of Backend?

Yes. Roles must be of course changed from your backend. It wouldn’t make sense for a client to change its own role, would it?

Thanks for kind guiding. I will try it again.

Is openvidu-browser API for Frontend and openvidu-node-client API is for Backend?