Conditional dump to VM

Having some issues with random calls at night. I want to change my inbound processing to send all calls to VM between 2300 and 0700, except for about a half dozen DIDs (family, close friends). Is there a way to do this other than having an inbound route for every allowed number and a catch all for the rest?

All the number I want to exclude from the dump to VM are i the address book.

I’m using this technique to whitelist, but not using phonebook, I’m using contact manager:

For only 6, having an Inbound Route for each VIP is probably easiest. But otherwise, create a Custom Destination with some code in extensions_custom.conf.

[custom-viptest]
exten => s,1,NoOp(CID:${CALLERID(num)})
exten => s,n,GotoIf(${DB_EXISTS(cidname/${CALLERID(num)})}?vip)
exten => s,n,Goto(timeconditions,3,1)
exten => s,n(vip),Goto(from-did-direct,1234,1)

Replace 3 with the proper timeconditions index and 1234 with your extension number

It’s interesting, but my whitelist is not my entire phonebook. I’ll go with routes for now, until a better solution comes along.

The script can be called with a contact mgr group name to only look in that one group.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.