Extension voicemail press 1 for cell 2 for voicemail

Hello, I am new to Asterisk and have acquired an Asterisk 1.8 box. I would like to setup an extensions voice mail to have an option to press 0 to dial that persons extension cell phone and press 1 to dump directly into that persons extension voice mail box. I have about 4 extensions that need to have this done. Currently there isn’t a menu for each extension it just goes straight to the greeting and voicemail. I was looking at the voicemail.conf documentation and was wondering if the dialout option would be the feature that I would need to look at or would it be some type of macro that would need to be written in the extensions.conf?

Like I said, I am quite new to Asterisk but I do understand the basics somewhat.

I tried searching the forum for the answer, but I am not sure if I am using the right keywords.

Can anyone point me in the right direction or give an example of how this would be accomplished?

Any help would be much appreciated!

-Bryan

If I understand the problem, you’d like callers to be sent to voicemail, but be given the option to send the call to the recipient’s cell phone or to voicemail.

This is one way to try it. I didn’t test it all though, but it should get you close.

[phones]
;assuming a 4-digit extension
exten => _XXXX,1,Dial(SIP/${EXTEN},20)
same => n,Goto(voicemail,s,1)
same => n,Hangup()

exten	=> i,1,Hangup()
exten	=> t,1,Hangup()
exten	=> h,1,Hangup()

[voicemail]
exten => s,1,Background(play-options)

;Caller pressed 0
exten => 0,1,NoOp(Use a database to look up the extension's cell phone or pass it as an ARG)
same => n,Dial(DAHDI/g0/${cellnumber},20)
same => n,Hangup()

;Caller pressed 1
exten => 1,1,Voicemail($EXTEN})
same => n,Hangup()

mko, thank you so much for your quick reply. I think I understand, somewhat…

In my extensions.conf I have args for each extensions cell phone declared like this (by the way we have a 3 digit extensions):

CELL224=1234445555 ; EXT: 224 CELL NUMBER

My current [voicemail] config is like this:

[voicemail]
;exten dialed voicemail using *7 from phone
 exten => *7,1,NoOp(${CALLERID(num)})
 exten => *7,2,Voicemailmain(${CALLERID(num)}@default)

;exten dialed the voicemail directory using *6 from phone
 exten => *6,1,Voicemailmain(default)

;go to voicemail for exten
 exten => _0XXX,1,Ringing() ; ring extension
 exten => _0XXX,2,Wait(4) ; wait four seconds
 exten => _0XXX,3,Voicemail(${EXTEN:1}@default,u) ; go to voicemail for extension

Trying to understand what you wrote out, would the following work?

[voicemail]

;exten dialed voicemail using *7 from phone
 exten => *7,1,NoOp(${CALLERID(num)})
 exten => *7,2,Voicemailmain(${CALLERID(num)}@default)

;exten dialed the voicemail directory using *6 from phone
 exten => *6,1,Voicemailmain(default)

;go to voicemail for exten
 exten => _0XXX,1,Ringing() ; ring extension
 exten => _0XXX,2,Wait(4) ; wait four seconds
 exten => _0XXX,3,Voicemail(${EXTEN:1}@default,u) ; go to voicemail for extension

;Caller pressed 1
exten => 1,1,NoOp(${CELL${EXTEN}})
exten => n,Dial(DAHDI/g2/${CELL${EXTEN}},20)
exten => n,Hangup()

;Caller pressed 2
exten => 2,1,Voicemail(${EXTEN}@default,u)
exten => n,Hangup()

I changed the 0 to dial cell to 1 to dial cell and instead of 1 to dial voicemail it is now set to 2. I currently have the option for dialing 0 to go back operator configured in the voicemail.conf. Seems like this wouldn’t work, it seems as if the system already picked up to voicemail.

Would the voicemail greeting play for that extension and then a caller can press 1 to call the extensions cell?

Also what would happen if the caller doesn’t press any key will it default the caller to be able to leave a voicemail?

I would like for each extension that has a phone to a have a greeting like this “Hello you have reached EXT 224. Press 1 to be forwarded to my cell. Press 2 or wait for the beep to leave a message.”

Oh yeah one more question, for exten => _0XXX I used ${EXTEN:1} to strip off the first 0 do I need to do that thru out? Like so:

exten => 1,1,NoOp(${CELL${EXTEN:1}})

Sorry again I am really new to asterisk and I will not be at the office until Saturday this week to test and I am trying to get all my ducks in a row.

Here is a pastebin of my current extensions.conf which might be helpful with some of details left out on purpose such as phone number ect: http://pastebin.com/7jhsf2Uw

I am so lost lol!

Again any help would be greatly appreciated!