[SR-Users] Is this idea even feasible?
Antony.Stone at kamailio.open.source.it
Wed Aug 18 10:36:02 CEST 2021
On Wednesday 18 August 2021 at 00:20:20, Raúl Alexis Betancor Santana wrote:
> On Tuesday 17 August 2021 at 21:22:37, Antony Stone wrote:
> > On Tuesday 17 August 2021 at 21:55:15, Fred Posner wrote:
> > > On 8/17/21 2:20 PM, Antony Stone wrote:
> > > > If not, can anyone suggest something else which could sit in between
> > > > a very basic SIP client and a PBX server, in order to inject these
> > > > sorts of commands into the path and thereby give me these sorts of
> > > > extra call capabilities?
> > >
> > > This really sounds like a better use case for Asterisk, FreeSWITCH,
> > > SEMS, or PJSIP.
> > I know Asterisk pretty well.
> > When you use it as a SIP client to register to another PBX, it is
> > extremely basic - it can place a call and it can receive a call, but it
> > has no concept of presence, it cannot send a REINVITE to put a call on
> > hold, it cannot send a REFER to transfer a call...
> > I don't understand how placing this in between my simple client and the
> > PBX which is handling the call can possibly inject the commands I need.
> Sorry for telling you this, but if you think that, you don't know Asterisk
> at all.
No problem - I'm very prepared to learn from experts.
> You don't need to send a REINVITE to put a call on hold, just change how
> you handle the RTP of the call if you SIP endpoint doesn't support
So, for such a simple thing, how could I get Asterisk to change the handling
of the RTP of the call, so that the remote PBX server starts playing its music
on hold to the other party?
If you can just show me the basics of what dialplan commands I should be
looking at, I can work out the rest (or ask the Asterisk people).
> Asterisk knows about presence, it doesn't have full implementation,
Asterisk certainly knows about presence *when it is the server* telling
clients *about* the presence of other clients / extensions.
It knows zero about presence when *it* is a client *asking* for the state of
other extensions on another PBX (at least, that's according to Joshua Colp,
Asterisk developer, when I asked on the Asterisk mailing list).
> The thing you need it's a B2BUA, and Asterisk, FreeSwitch, YATE, SEMS,
> either a simple python script using pjsua2 or any of the dozens SIP
> frameworks out there, will allow you to acomplish your goals
> If you go the Asterisk road, any of the AMI/ARI documentation will explain
> to you how to handle ongoing calls.
There is no AMI command to put a call on hold. There are AMI notifications to
tell you that a call has been put on hold (or resumed) but there is no command
to cause this to happen. To quote from Joshua Colp: "I know of no way from
AMI to control putting a call on and off hold."
> You could take any road you like, but not Kamailio, as it's not a B2BUA.
Okay, thank you for confirming that I'm looking in the wrong place here, and
that Kamailio is not the solution to my needs.
However, my understanding of a B2BUA is that *it* would then start handling
the state of the calls itself - whether they're on hold, routing the
I need something which can *tell the existing PBX* to do these things, in the
same way that a competent hardware SIP telephone would tell it.
If there are multiple ways of achieving what I'm trying to do (even if
Kamailio isn't one of them), please just point me at something specific which
shows me *how* - telling me "it's simple" or "there are lots of ways of doing
it" doesn't help me to find out *how* I can do it, and the suggestions
regarding Asterisk are simply in conflict with the advice I've had from people
on the Asterisk list, who say it can't be done.
I hope someone can point me at just one example of how this requirement can be
achieved - I've tried to keep it as simple as possible, by focusing on call
hold - once I've got that, I can build up the more complex stuff.
To reiterate, a SIP client places a call to a SIP server; I then need a way to
tell that SIP server to put the call on hold, given that the client itself
cannot do it.
3 logicians walk into a bar. The bartender asks "Do you all want a drink?"
The first logician says "I don't know."
The second logician says "I don't know."
The third logician says "Yes!"
Please reply to the list;
please *don't* CC me.
More information about the sr-users