[asterisk-users] VoiceMail - Allow * for only some users

John Kiniston johnkiniston at gmail.com
Thu Jul 21 16:53:47 CDT 2016

I think you almost have it.

In your vmfwd context have a wildcard match that sends the caller back to
the originating voicemail and then define specific extensions that are
allowed to forward.

exten => _XXXX,1,Voicemail(box at context,option)
 same =>          n,Hangup

; Andrew Ruthven
exten => 7231,1,Set(CALLERID(number)=yyy)
same =>         n,Goto(pstn,xxx,1)

On Thu, Jul 21, 2016 at 2:23 PM, Andrew Ruthven <
andrew.ruthven at catalyst.net.nz> wrote:

> Hey,
> I have free calling to between DDIs and cellphones on our group plan. I
> figure it'd be nice to allow staff with those cellphones to be able to
> forward callers to their VoiceMail to their cellphones using the *
> feature.
> I have a standard extension macro that has VoiceMail support.
> So far I've done this by duplicating the standard extension macro, and
> adding this rule (where ARG1 is the extension):
>   exten => a,1,Goto(vmfwd,${ARG1},1)
> Then in the vmfwd context I have rules like this (I need to set the
> CALLERID(number) so our SIP provider accepts the call):
>   ; Andrew Ruthven
>   exten => 7231,1,Set(CALLERID(number)=yyy)
>   exten => 7231,n,Goto(pstn,xxx,1)
> Which is working nicely. But, I thought, can I simplify this and just
> have one macro?
> So I've tried doing the following to fold it into my standard extension
> macro:
> 1) Tried using a/_7231 but that didn't match (well, it was worth a try)
> 2) exten => a,1,Goto(vmfwd,${ARG1},1) works for calls to my extension,
> but if I disable the 7231 rules in vmfwd, I get:
>   [2016-07-22 09:01:07.691] WARNING[11488][C-00000420]: pbx.c:6646
> __ast_pbx_run: Channel 'SIP/' sent to invalid
> extension but no invalid handler: context,exten,priority=vmfwd,7231,1
>   and the call hangs up, not a very nice user experience.
> The second option could work, as long as the user lands back into
> VoiceMail if there is no valid extension. I thought about using GoSub,
> but how do I get the caller back into VoiceMail?
> I've done a bunch of searching for this, but haven't found any general
> solutions. Is it possible to do what I'm trying to achieve, or is there
> a better approach?
> This is Asterisk 11.13.
> Cheers,
> Andrew
> --
> Andrew Ruthven, Wellington, New Zealand
> At work: andrew.ruthven at catalyst.net.nz
> At home: andrew at etc.gen.nz
> Card   : http://qr.catalyst.net.nz/907675e1
> Cloud  : NZs only real cloud - https://catalyst.net.nz/cloud
> GPG fpr: C603 FC4E 600F 1CEC D1C8  D97C 4B53 D931 E4D3 E863
> LCA2016: LCA By the Bay, Geelong, AU - lca2016.linux.org
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>                http://www.asterisk.org/hello
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-users

A human being should be able to change a diaper, plan an invasion, butcher
a hog, conn a ship, design a building, write a sonnet, balance accounts,
build a wall, set a bone, comfort the dying, take orders, give orders,
cooperate, act alone, solve equations, analyze a new problem, pitch manure,
program a computer, cook a tasty meal, fight efficiently, die gallantly.
Specialization is for insects.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20160721/f4bbba8f/attachment.html>

More information about the asterisk-users mailing list