CALLERID(DNID) behavior in dialplan


#1

Let’s say I’m routing a call outbound to a SIP trunk (e.g. PSTN gateway), and I want to do some digit manipulations. If I perform a Set on:
CALLERID(DNID)

What will happen at the next step of extensions.conf evaluation? Will it hop to the appropriate extension in the current context or Macro? Or will it continue to evaluate the next priority of the same extension that was set before? Seems like a little potential confusion here.

I’m guessing best way to achieve my objective is through variable assignment and then use it in a Dial statement, and stay away from the CALLERID(DNID parameter). I would still use CALLERID(ani) to change calling party number if needed.

Thoughts?


#2

2nd try