• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 467
  • Last Modified:

Asterisk multiple recipeints when e-mailing voicemail messages?

Is it possible for Asterisk to e-mail the voicemail messages to more than one e-mail address per mailbox?  I specified a second e-mail address, but the second e-mail address only received a short message notifying there was a voicemail, and no message was attached.  The subject line was different than what I specified globally, as well as the message body.  The first e-mail address received the normal e-mail with message attached... I specified the 2 e-mail addresses as:

515xxxxxxx => 1111,name,email1@gmail.com,e-mail2@gmail.com,attach=yes,|tz=eastern|saycid=yes|


  • 3
1 Solution
Ron MalmsteadInformation Services ManagerCommented:
What you are trying to do is already an available function.

Voicemail broadcasts can be created with the VoiceMail command in the dialplan. This can be combined with the delete option to delete the original voicemail.

In extensions.conf:
  exten => 100,1,VoiceMail(u101&102&103)

In voicemail.conf:
  101 => 4242,Group Mailbox,,,delete=1
  102 => 4242,Buckaroo Bonzai,buckaroo@bonzai.com
  103 => 4242,John Whorphin,john@monkeyboy.com

This entry creates a group mailbox at mailbox 101, which, on receipt, is copied to mailboxes 102 and 103. Following the copy to these other mailboxes, the original voice message is deleted.

When multiple mailboxes are specified, the unavailable or busy message will be taken from the first mailbox specified. This could be used to record a special unavailable or busy message for the broadcast mailbox (101 in this example).
Ron MalmsteadInformation Services ManagerCommented:
The other option would be...make a forwarding e-mail mailbox.... so that when the e-mail message is recieved on that box it is forwarded to two people.
jkocklerAuthor Commented:
xuserx...That would be great if this scenario involved multiple mailboxes.  This is only for one mailbox, and one extension, and I do not have control over the recipients e-mail box to setup any forwarding rules.

So for example, a phone call to phone number 515-xxx-xxxx, is missed and sends the caller to voicemail box 515-xxx-xxxx ... The caller leaves a messge in mailbox 515-xxx-xxxx.  I then want that voicemail e-mailed to two e-mail addresses, joe@gmail com, and Mike@gmail.com ...

Currently it will e-mail the first e-mail address in the mailbox functions, with the email text body that I typed out in the [general] context, and attach the e-mail.  The second e-mail in the mailbox function section, gets an e-mail alerting of the voicemail, but does not attach the e-mail, nor is the message body text what I specified.

I am guessing the second e-mail address is pulling it's "servermail" and message body from somewhere else, and it needs to be pulled from general, just like the first e-mail address.

This is an example of what I have for the mailbox function

515xxxxxxx => 1111,name,john@gmail.com,e-mike@gmail.com,attach=yes,|tz=eastern|saycid=yes|
Ron MalmsteadInformation Services ManagerCommented:
Right.... I got it...
I'm pretty sure this is the default behaviour.... If you specify multiple recipients, only one of them actually get the attachement.

What you should do then is create a "dummy" mailbox (without an extension) for the other external recipient...then use the voicemail broadcast method.

Example extensions.conf
exten => 515xxxxxxx,n,Dial(SIP/${EXTEN})
exten => 515xxxxxxx,n,VoiceMail(u101&515xxxxxx1&515xxxxxx2)

In voicemail.conf:
101 => 4242,Group Mailbox,,,delete=1
515xxxxxx1 => 1234,Person1,email1@gmail.com
515xxxxxx2 => 1234,Person2,email2@gmail.com
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now