Changing CONECTEDLINE for internal calls

Hello everyone,

I’m having sone trouble changing the CONNETEDLINE-Value wihle calling internal.
I have a “virtual” externsion 555 which schould be displayed as “Service” but called is a real extension (PJSIP/401).
My problem is, it allways displays the Callerid given in pjsip.conf. Only if I delete this entry, it will show “Service”.

Here is my Dialplan:

exten => 555,1,Set(CONNECTEDLINE(num)=555)
exten => 555,n,Set(CONNECTEDLINE(name)=Service)
exten => 555,n,Dial(PJSIP/401,,b(add-Service^s^1)B(add-Service^s^1))

I also tried Dial wird b and/or B option, but no positive result…

 [add-Service]
exten => s,1,Set(CONNECTEDLINE(num)=555)
exten => s,n,Set(CONNECTEDLINE(name)=Service)
exten => s,n,Return()

Maybe there is something I am missing?
Thanks in advance!

Connected line updates can occur after you manually set it, if you want to have Dial() ignore such things then you would pass it the “I” option[1]. You should also use the “i” option to CONNECTEDLINE on the first invocation so that it doesn’t actually update until Service[2]. The “Straightforward dial through” example is this case.

[1] Dial - Asterisk Documentation
[2] Manipulating Party ID Information - Asterisk Documentation

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.