Documentation for extensions_custom.conf?

Maybe I’m blind but I can’t seem to find any, short of what little is on Is there a reference for the commands you can issue in your dialplan in extensions_custom.conf?

I’m trying to do something really simple - I have a custom extension “1234”, which just plays a few digits, then redirects the user to extension “7300” which is my softphone. That 1234 extension is the target for pressing “1” on my IVR.

I expect to dial the IVR, hit “1”, hear the digits, then get transferred to the softphone. Instead, I hear the digits, and then the phone hangs up. I’m probably using the “Goto” command wrong, but how can I know what to put in there?

My Extensions_Custom.conf is:

exten => 1234,1,Answer
exten => 1234,2,SayDigits(1234)
exten => 1234,3,SayDigits(${CALLERID(num)})
exten => 1234,4,Goto(7300,1)

… also I’ve never really understood priorities. What the heck are they?

The line should read 1234,4,Dial(Local/7300) or SIP/7300 your choice.

Definitive reference

Ahhh so it’s the DIAL function I needed, not the GOTO function. It works now!

That book is great. This section in particular is a tremendously useful read:

Okay, that’s part 1 of my PBX system. I’m going to start searching for the steps to do this next bit, but if you happen to know it’d be useful if you could point me in the right direction:

I need to do more than just dial extension 7300. I need to do something intelligent if the command fails (e.g. 7300 is a softphone, so it can fail if the line is busy or I ignore the call). Is there a way to transfer to a different failover extension if the initial transfer failed? I’d have the failover extension say something useful to the user, maybe run an AGI script or something.

I think I figured it out!

The Dial() command will transfer to the other extension if it succeeds. If it fails, it will return and the original extension continues executing. And you can examine the reason for failure in the ${DIALSTATUS} variable.

So this will play the digits “5,6,7,8” to them if the call fails for some reason. And I can always dial out to some other extension right afterwards

… right?


exten => 1234,1,Answer
exten => 1234,2,SayDigits(1234)
exten => 1234,5,Dial(Local/7300)
exten => 1234,6,SayDigits(5678)
exten => 1234,7,Hangup