Participant tracks not remoted when joining

So i started with the example gave by the git (example that have some issues). My problem is that when a new participant joins the room, the first one who created it does not remote a new track. The event “USER_JOINED” is triggered but not “TRACK_ADDED”.
On the other side, for the participant, everything is working fine.

I’m using as server target :

var options = {
hosts: {
domain: ‘’,
muc: ‘’,
bosh: “”+roomName,
clientNode: ‘’,

I also noticed that the issu does not occure when i’m using the siteweb as the new participant. It’s only when i use my own code in 2 different pages.

Here some code for the most part it’s the same as the example :

function onConnectionSuccess() {

console.log(“ROOM JOINED”)
room = connection.initJitsiConference(roomName, confOptions);
room.on(, onRemoteTrack );//not triggered
room.on(, track => {
console.log("====TRACK REMOVED====");

for(let i = 0; i < track.containers.length; i++){

room.on(, (id) => {
console.log("====USER===="+id) //Triggered Here
remoteTracks[id] = ;
room.on(, onUserLeft);
room.on(, track => {
console.log(${track.getType()} - ${track.isMuted()});

Thank you in advance for your help.


I’m wondering why you add the roomName in the bosh url ? (options, first piece of code)

Hey, if i dont add it, it’s like it doesn’t know where to go and returns me a “Connection Failed !”