Skip to main content

Custom voicemail message

Posted by gb_delti on Tue, 12/02/2008

Hello,

I would like to greet callers with a custom voicemail message and instruction instead of the default one. While I could abuse the IVRs functionality for this, I would like to know if there is some better way to do that.

If there is no default way I could write a user script for it. But I don't know how to create an argument list for media files. What is the correct argument that goes into the third place of an args triplet in user_scripts_source.include?

Greetings,

Gabriel


Submitted by cbbs70a on Tue, 12/02/2008 Permalink

I think I know what you are talking about. In fact, I just implemented this today. I think what you want to do is record multiple voice prompts and select them based on inbound CallerID. Its easy to do this if you implement this in the following way (this assumes the voice prompts have already been recorded):

(1) associate a CallerID number with a audio file (I did it in MySQL)

(2) if the CallerID matches one of the numbers in MySQL, play that specific audio file

(3) now send the caller to voicemail, (skipping the usual voicemail greeting)

It seems to work straightforward for me.

Regards;

FSD

Submitted by gb_delti on Wed, 12/03/2008 Permalink

We have several hotlines that have business hours. I would like to create an inbound route with a time-based handler. If a customer calls off-hours, I would like to call a script that plays the special message and then records the voicemail message (skipping the regular voicemail greetings).

Since the script will be reused for several hotlines, each with a different message, I would like the message file to be configurable in the GUI. This can be done by specifying args=1,Description,type in the user_scripts_source.include file. For example to get a select list of IVR menus you write

args=1,Select a menu,menu

What I would like to know is if you can get a select list of the audio recordings you made with the Voice Recording feature.

Submitted by eeman on Wed, 12/03/2008 Permalink

the IVR menu screen already has an option for Voicemail(Silent), you could use this to skip your greetings. Instead of using a DTMF option, just use the timeout as your action to go to voicemail silent. Your custom greeting would be handled by the IVR menu as well.

Submitted by gb_delti on Wed, 12/03/2008 Permalink

@eeman: That's what I meant with "abuse IVR functionality". It works, and if there is no way to select voice recordings as an argument I will use it. But in my eyes it's not the most optimal solution.

Submitted by eeman on Wed, 12/03/2008 Permalink

An IVR is just an execution of dialplan, no different than a hunt list. If you were to code the dialplan manually to do what you described, it would basically look like an IVR. Alternatively you could create your own script that lets you pick recorded media from a listbox as an arguement and call the script from the time based handlers. If you're familiar with dialplan it wouldnt take you but a few seconds to write. Recorded calls is one of the optional arguement types.

Submitted by gb_delti on Tue, 12/09/2008 Permalink

Alternatively you could create your own script that lets you pick recorded media from a listbox as an arguement and call the script from the time based handlers.

This is exactly what I wanted. I didn't realize you could configure your arguments to scripts via the GUI ("PBX Settings --> Script Library --> Create Script") and searched for documentation on how to write the generated scripts on the command line! Now I wrote my custom script (in seconds indeed) and I am quite happy.

Submitted by gb_delti on Tue, 12/09/2008 Permalink

Note that you must place the path "ogm/" before the argument when using recorded messages as arguments. The line in your script would look like this:

exten => 1,1,Playback(ogm/${ARG1})