SOLVED Bridge inline variable

Status
Not open for further replies.

EasyBB

Active Member
Oct 23, 2016
240
33
28
Australia
I sometimes use inline variables on the bridge line to pass gateway specific values, like:

Code:
{absolute_codec_string=PCMU}sofia/gateway/gw_uid/00$1

and it works.

Now have a requirement to pass different caller id number numbers to each gateway in fail over mode; so I tried these following examples from https://freeswitch.org/confluence/display/FREESWITCH/mod_dptools:+bridge

Code:
{effective_caller_id_number=1234}sofia/gateway/gw_uid/00$1

and

Code:
[effective_caller_id_number=1234]sofia/gateway/gw_uid/00$1

Both of above formats didn't work. Can you think of anything I am missing here?
 

Adrian Fretwell

Well-Known Member
Aug 13, 2017
1,498
413
83
Reading the Freeswitch Wiki it says "effective_caller_id_number is automatically exported to the B-leg; however, it is not valid in an origination string. In other words, set this before calling bridge, otherwise use origination_caller_id_number."

{origination_caller_id_number=1234}sofia/gateway/gw_uid/00$1 works for me.
 
  • Like
Reactions: EasyBB

EasyBB

Active Member
Oct 23, 2016
240
33
28
Australia
however, it is not valid in an origination string
Thank you very much for the pointer; I can't believe I missed it :eek:

Good news is, it works a charm :D

In other words, set this before calling bridge

This is how I've been using it but when you have more than 2 gateways to fail through, setting individual caller id as well as bridge line becomes a hassle.
 
Status
Not open for further replies.