[SR-Users] Routing inbound call from carrier to user or voice mail

Daniel Tryba d.tryba at pocos.nl
Wed May 2 14:53:35 CEST 2018

On Wed, May 02, 2018 at 05:26:07AM +0000, KamDev Essa wrote:
> How do I :   
>    - Associate the 10 digit DID to the 201 or 202?

Can be done with (but not limited to)
or a simple hardcoded line:

>    - In the cfg, check if user is registered if??

With lookup():

>    - yes, relay call to user
>    - no relay call to VM server.

The one line you mentioned shows the example, examing the returncode of
lookup. If not 1 you can sent the call to voicemail by changing $ru (or
specific parts like $rd) and relaying the call. So instead of 
sl_send_reply("404", "Not Found");
you could do something like:

More information about the sr-users mailing list