[OpenSIPS-Users] Forking call to more than one AOR
Babak Yakhchali
babak.freeswitch at gmail.com
Tue Apr 14 13:25:24 EST 2020
For anyone interested:
I used append_branch() two times to create 2 branches. then using
$(branch(uri)[1]) = $avp(other_aor);
I set the second branch to go for other AOR, now calling lookup() like this:
lookup("location","r")
will create all needed branches based on the 2 already created branches and
removes them from destination set. Till now invites are generated for
different contacts, BUT there is a problem with clients registered with
second contact, because To header is based on the first AOR in ruri and
they will not accept the invite message, to solve this I used a branch
route and changed the To header like this:
branch_route[per_branch_ops] {
if($tU != $rU){
uac_replace_to("","$avp(other_aor)");
}
}
On Tue, Apr 14, 2020 at 12:46 PM Babak Yakhchali <babak.freeswitch at gmail.com>
wrote:
> Hi
> I'm trying to implement this scenario:
> each user has two AORs. one for mobile and one for a userId (random string)
> at any time user may be registered on one, both or none of these AORs
> when a call comes to one of these AORs the other one must be called too
> (if there is a registered contact for it)
>
> reading the documents I think I need to use lookup("location","r"). but I
> don't know how should I add branches before calling it for the two AORs
>
> thanks
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20200414/cf8bf2b1/attachment.html>
More information about the Users
mailing list