No matching results Documentation Forum
Asterisk Tutorial 17 - Asterisk Voicemail Dialplan Config

Asterisk Tutorial 17 - Asterisk Voicemail Dialplan Config

Introducing Asterisk Phone Systems – Asterisk Voicemail Dial Plan Setup

Welcome to part II of our Asterisk phone system Voicemail tutorials. Coincidently, I published a piece yesterday based on research from our friends at Software Advice over in the USA. In essence, the article is a Small Business VoIP Buyers Guide, but rather interestingly, one of the top applications that SMBs look for in their IP communications systems is Voicemail. Just further proof that having a top notch voicemail system is pretty much up there with the most essential applications of any business phone system.

With this in mind, it is time to follow on from where we left off. If you remember last time we set about setting up the actual voicemail system and our voicemail boxes. But now the question is: how do we get an incoming call to be directed to our voicemail if we are not about to actually answer the call? Watch on and find out all you need to know about which applications are required as well as how to configure the your dial plans to enable leaving & retrieving messages.

Quick Tips

Before starting, make sure you turn off call waiting on your softphone. Otherwise our test configurations probably won’t work!

In order to view all the applications relating to voicemail, use the command:

core show applications like mail

within the Asterisk CLI. This will generate a screen as shown below:

Asterisk*CLI> core show applications like mail
    -= Matching Asterisk Applications =-
            MailboxExists: Check to see if Voicemail mailbox exists. 
                VoiceMail: Leave a Voicemail message. 
            VoiceMailMain: Check Voicemail messages. 
        VoiceMailPlayMsg: Play a single voice mail msg from a mailbox by msg id. 
    -= 4 Applications Matching =-
Asterisk core show applications like

It is worth noting that the application MailboxExists is particularly useful for checking if a mailbox actually exists within dynamic environments, as not everybody may have a voicemail box. The next application in the list, Voicemail, allows callers to actually leave you a message while the application VoicemailMain refers to the application that allows you retrieve and listen to your messages.

Leaving Messages

The next step is to look at the applications themselves, particularly the syntax associated with each application. To do this, use the command core show application voicemail, where voicemail is the application name. This will then open the application documentation, provide an example of how to formulate the syntax which is important for the dialplan configurations along with providing explanations regarding the Argument options, but we will cover these options in more detail next time.

Next we need to configure our dialplan in order to allow us to actually leave a message.

To do this, go to your dialplan and within the context phones (as it is in our example) add a “time out” to the dial application settings as shown by the number 5 in our example. Next add a new line below that includes the Voicemail application and corresponding syntax. If you want to keep your dialplan really simple for testing purposes, then use the voicemail box numbers you setup when configuring the actual voicemail system. However, you could save some time by using the ${EXTEN} variable, should you be configuring multiple extensions at the same time, as in our example below:

[phones] using voicemail box number
    exten => 100,1,NoOp(Call for Mathias)
    same => n,Dial(SIP/mathias,5)
    same => n,Voicemail(100)
    same => n,Hangup

Or using EXTEN:

[phones] using EXTEN
    exten => 100,1,NoOp(Call for Mathias)
    same => n,Dial(SIP/mathias,5)
    same => n,Voicemail(${EXTEN})
    same => n,Hangup

Calling your Voicemail

In order to be able to call your voicemail you will need to integrate the Application_VoiceMailMain within your dialplans. For you to get a good idea of how to do this, we have demonstrated the most basic of integration options, which we will then work on and improve in our next tutorial.

But just as we did with leaving a message, take a look at the VoiceMailMain application using the command as described above using the appropriate application name. This will allow you to take a look at the syntax as well as any arguments that the application uses and what they mean.

Next go back to your dialplan and under the context phones add a new extension using for example *100 as shown below, set the priority and then the application followed by extension number in brackets:

exten => *100,1,VoiceMailMain(100)
same => n,Hangup

Don’t forget to add the hangup application, but that’s it, your ready to test your voicemail now.

pascom hosted PBX - start upgrading your business communications today

Final Word

A well-configured business phone system that oozes useful tools, delivers excellent audio quality and intuitive call flows will leave callers with a highly professional impression. The configuration options and application availability and how well they are utilized will have a decisive impact on how professionally you manage your calls and therefore how your customers view your company. The switch to a pascom VoIP phone system solution provides the opportunity to not only upgrade your internal collaboration but also to redefine telephony in your company.

If you would like more information regarding pascom and our Asterisk based Software PBX, please visit our website or give the pascom team a call on +49 991 29691 0 to discuss your requirements and get started within minutes using our free hosted business VoIP phone system edition.

Thousands of companies trust pascom to stay connected

Logo - Amparex pascom Customer reference
Logo - KiKxxL pascom Call Centre Customer reference
Logo - Hotel Weitblick pascom Customer reference
Logo - Wake & Camp pascom Customer reference


Philipp Meixner, CEO
As a communications agency with just under 20 employees, the pascom phone system is perfect for us. The technical concept simply functions, which is what you want. The service is exceptional and always accessible (even if it is rarely needed) and as one of the agency’s business partners, we can only recommend pascom: open, straightforward, pleasant to work with - great. Thank you pascom!

Logo - Amparex pascom Customer reference


Stephan Förderung, CEO
We chose pascom because their phone systems offer a sleek, easy-to-use UC client and administration UI whilst providing us with all the PBX and UC features, control and visibility that we could need from our business communications solution. As a result of our excellent experience, we are happy to recommend pascom phone systems to all our customers.

Logo - KiKxxL pascom Call Centre Customer reference


Lars Hoeger, IT Director
When we make decisions regarding new systems, we want to make sure that we have both reins firmly in our hands. Therefore, it is essential to implement systems which adhere to OpenStandards, allowing us to seamlessly connect and integrate these into our existing systems. In addition, we require reliable suppliers, who are ready to customise their solutions to our requirements, which is why we chose pascom who offer exactly this service and more.

Logo - Hotel Weitblick pascom Customer reference


Kassandra Martin, Deputy Director & Reception Manager
We chose pascom as our telephony solution in part due to the scalability, flexibility and ease of deployment. In addition, the pascom platform functions perfectly with our digital guest directories in our rooms whilst offering the largest range of features at easily the most cost effective price compared to alternative solutions. A further deciding factor was the wide choice of compatible hardware that choosing pascom afforded us.

Logo - Wake & Camp pascom Customer reference

Wake & Camp Ruhlsdorf

Markus Gerlitzki, Managing Director
My team and I pride ourselves on the level of excellent care we provide our guests. However, it can be distracting when the phone is always ringing and we constantly answer the same questions. Thanks to the pascom phone system, we have been able to set up an automated attendant self-service hotline which allows guests to quickly get answers and if required callers can be quickly and efficiently routed to an employee. The system greatly improves customer service with around-the-clock answers around opening times and courses and therefore reduces the strain on employees, ensuring we are free to cater to the needs of our on-site guests.

Back to the top