Leave Confbridge when one of the last two user disconnect

As shown in the image in dialplan Hangup() function is not invoked
can anyone please help me,
asterisk version 16.0

Is your post title is what you want to do, or it is what it is happening right now ?

that’s what i want to do

Use end_marked option

Kick the user from the conference when the last marked user leaves



1 Like

i have added
[default_user] type=user end_marked=yes
in my confbridge.conf file but it’s still not working for me @ambiorixg12

That’s not enough, also did you make sure that the user has entered to the conferece as marked and is also leaving the conferece

can you explain me in details @ambiorixg12 i didn’t understand your point

exten => 1,1,Answer()
exten => 1,n,GotoIf($["${CALLERID(num)}"!="6000"]?end)
exten => 1,n,Set(CONFBRIDGE(user,admin)=yes)
exten => 1,n,Set(CONFBRIDGE(user,marked)=yes)
exten => 1,n,Goto(conf)
exten => 1,n(end),Set(CONFBRIDGE(user,end_marked)=yes)
exten => 1,n(conf),ConfBridge(1)

Device with Caller ID num 6000 is the marked user, once that device leave the conference all the other users will be kicked out

In our use case, the last device can be anyone who has joined the conference, if among last two who are already in the conference if one of them hangup then another device should also hangup @ambiorixg12

I dont understand clearly your question to be honest, anyway I gave you a functional code, you can test and modify based on your needs

Did you ever find a solution for this? We need the same functionality. I need the conference to end anytime there is only one person left in the conference, marked or not. What I am trying to avoid is having a single user in a conference leaving the call in play if that user doesn’t hang up for some reason.