DevSnippets

Home » Asterisk » Set up voicemail for extensions

Set up voicemail for extensions

Asterisk Set up voicemail for extensions 15 views

Code

voicemail.conf

[general]
format=wav49|gsm|wav
serveremail=asterisk@yourdomain.com
attach=yes
skipms=3000
maxsilence=10
silencethreshold=128
maxlogins=3

[default]
1001 => 1234,John Doe,john@example.com
1002 => 1234,Jane Smith,jane@example.com

extensions.conf

[internal]
exten => 1001,1,Dial(SIP/1001,20)
exten => 1001,n,Voicemail(1001@default,u)
exten => 1001,n,Hangup()

exten => 1002,1,Dial(SIP/1002,20)
exten => 1002,n,Voicemail(1002@default,u)
exten => 1002,n,Hangup()

exten => *97,1,VoicemailMain(${CALLERID(num)}@default)

Explanation

voicemail.conf: Defines mailboxes 1001 and 1002, passwords, names, and email IDs for notification.

extensions.conf:
If the user doesn't answer, the call is routed to voicemail.
*97 allows users to check their voicemail.

Rate this snippet

Click to rate

Have a Better Solution?

Know a more efficient way to solve this problem? Share your own code snippet and help the community!

Submit Your Version