Dial Plan based on agent Code

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Dial Plan based on agent Code

Postby Hitme8622 » Thu Mar 25, 2021 7:08 am

Hello Guys

I have setup the vici dialer and everything is working fine. But i am stuck on one stage in vici dialer dial plan.
I am using the GSM Gateway for the calling Process. i want to configure the Dial plan based on agent User id.i want to map the outbound calling based on caller id. Can i map the agentcode=callerid with single dial prefrix. (example if agent 1 dial the call the callerid in in dial plan will be use SIM1 if agnet2 dial the call the caller id will be used SIM2 but the dial prefrix will remain the same as both users are calling from same campaign)
i am using the vicibox9
Asterisk Version is Asterisk 13.29.2-vici
Hitme8622
 
Posts: 4
Joined: Thu Mar 25, 2021 6:12 am
Location: Ahmedbad

Re: Dial Plan based on agent Code

Postby mjohn425 » Sat Mar 27, 2021 6:13 am

@Hiteme8622 is this for predictive dialling? If so, you are out of luck. You will only be able to do this on manual dialing (without getting a developer).

In the campaign settings, set the MANUAL DIAL CID field to agent phone, then in their phone settings, change the outbound CID to be whatever you want then configure your dialplan as follows.

Agent 1 Outbound CID: 100
Agent 2 Outbound CID :101
Dialprefix: 300

exten => _9XXXXXXXX,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9XXXXXXXX/100,2,Dial(SIP/${EXTEN:1}@GATEWAY1,,tTor)
exten => _9XXXXXXXX/101,2,Dial(SIP/${EXTEN:1}@GATEWAY2,,tTor)
exten => _9XXXXXXXX,3,Hangup()

Note that many carriers won't let you dial out with an invalid CID while some correct to a valid one. You will have to adjust as required.
OS: VICIBox 9.0.1 OpenSuse 15.1 | VERSION: 2.14-742a BUILD: 200327-1715 | Asterisk: 13.21.1-vici | SVN: 3205 DB Schema: 1588
Linux: 4.12.14-lp151.28.44-default | MYSQL: Ver 15.1 Distrib 10.2.31-MariaDB | Perl: v5.26.1 | php: v7.2.5
mjohn425
 
Posts: 51
Joined: Tue Jan 21, 2020 1:20 am

Re: Dial Plan based on agent Code

Postby Hitme8622 » Sat Mar 27, 2021 6:48 am

@ mjohn425

Thanks for your Response. I have set the dial method to Inbound_man.

i have get this output. I am using the GSM Gateway and i have set the dial plan as below,

Connected to Asterisk 13.29.2-vici currently running on vicibox9 (pid = 13676)
[Mar 27 17:01:43] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:01:43] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:01:43] -- Called 58600053@default
[Mar 27 17:01:43] -- Executing [58600053@default:1] MeetMe("Local/58600053@default-000000b3;2", "8600053,Fmq") in new stack
[Mar 27 17:01:43] -- Local/58600053@default-000000b3;1 answered
[Mar 27 17:01:43] -- Executing [8309@default:1] Answer("Local/58600053@default-000000b3;1", "") in new stack
[Mar 27 17:01:43] -- Executing [8309@default:2] Monitor("Local/58600053@default-000000b3;1", "wav,_1104_20210327-170143") in new stack
[Mar 27 17:01:43] -- Executing [8309@default:3] Wait("Local/58600053@default-000000b3;1", "60000") in new stack
[Mar 27 17:01:44] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:01:44] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:59] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:59] -- Manager 'sendcron' from 127.0.0.1, hanging up channel: Local/58600053@default-000000b3;2
[Mar 27 17:02:59] == Spawn extension (default, 58600053, 1) exited non-zero on 'Local/58600053@default-000000b3;2'
[Mar 27 17:02:59] WARNING[14836][C-00000196]: func_hangupcause.c:140 hangupcause_read: Unable to find information for channel
[Mar 27 17:02:59] -- Executing [h@default:1] AGI("Local/58600053@default-000000b3;2", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0--------------------)") in new stack
[Mar 27 17:02:59] -- <Local/58600053@default-000000b3;2>AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ----------) completed, returning 0
[Mar 27 17:02:59] == Spawn extension (default, 8309, 3) exited non-zero on 'Local/58600053@default-000000b3;1'
[Mar 27 17:02:59] WARNING[14835][C-00000197]: func_hangupcause.c:140 hangupcause_read: Unable to find information for channel
[Mar 27 17:02:59] -- Executing [h@default:1] AGI("Local/58600053@default-000000b3;1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0--------------------)") in new stack
[Mar 27 17:02:59] -- <Local/58600053@default-000000b3;1>AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ----------) completed, returning 0
[Mar 27 17:03:00] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:03:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:03:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:03:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:03:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:03:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:03:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:04:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:04:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:04:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:04:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:04:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:04:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:05:02] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:05:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:07] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:05:07] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:18] -- Registered SIP '4000' at 192.168.100.57:57223
[Mar 27 17:05:18] > Saved useragent "Z 3.7.30891 r30851" for peer 4000
[Mar 27 17:06:02] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:06:02] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:06:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:06:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:06:07] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:06:07] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:06:10] -- Registered SIP '4000' at 192.168.100.57:50273
[Mar 27 17:06:10] > Saved useragent "3CXPhone 6.0.26523.0" for peer 4000
[Mar 27 17:07:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:07:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:07:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:07:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:07:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:07:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:08:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:08:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:09:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:09:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:10:01] == Manager 'sendcron' logged on from 127.0.0.1

in Phone (admin>Phones).i have set the Outbound CallerID as a 4000.(same as agent extension Number)

in carriers i have set the dial plan as below

Registration String:
Account Entry:
Protocol: SIP
Globals String:
Dialplan Entry:
exten => _9XXXXXXXX,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9XXXXXXXX/4000,2,Dial(SIP/${EXTEN:1}@GSM1,,tTor)
exten => _9XXXXXXXX/4001,2,Dial(SIP/${EXTEN:1}@GSM1,,tTor)
exten => _9XXXXXXXX,3,Hangup()

In campaign setting the Dial Prefrix i have set as below :

Dial Prefix: 9
Manual Dial Prefix:


at the GSM Gateway end i have define the caller id as 4000 and set map the Simcard to this caller id.
Hitme8622
 
Posts: 4
Joined: Thu Mar 25, 2021 6:12 am
Location: Ahmedbad

Re: Dial Plan based on agent Code

Postby mjohn425 » Sat Mar 27, 2021 6:53 am

It doesn't look like the call is being placed. For transparency the dialplan I provided, I am unsure if the number of X's is appropriate for you as I am based in Australia. I think the issue is on the vicidial/asterisk end however as we are not yet seeing a Dial(xxxx atttempt, nor are we seeing an invalid extension message. Try dialing it directly from your softphone and see what it says in asterisk.
OS: VICIBox 9.0.1 OpenSuse 15.1 | VERSION: 2.14-742a BUILD: 200327-1715 | Asterisk: 13.21.1-vici | SVN: 3205 DB Schema: 1588
Linux: 4.12.14-lp151.28.44-default | MYSQL: Ver 15.1 Distrib 10.2.31-MariaDB | Perl: v5.26.1 | php: v7.2.5
mjohn425
 
Posts: 51
Joined: Tue Jan 21, 2020 1:20 am

Re: Dial Plan based on agent Code

Postby Hitme8622 » Sat Mar 27, 2021 6:57 am

hey @mjohn425

Please find below output which i have get while dial the call manually from soft phone.i have dial the number like 40009099026092


[Mar 27 17:25:53] Connected to Asterisk 13.29.2-vici currently running on vicibo x9 (pid = 13676)
[Mar 27 17:25:57] == Using SIP RTP CoS mark 5
[Mar 27 17:25:57] > 0x7fe5a405ba10 -- Strict RTP learning after remote address set to: 192.168.100.57:40036
[Mar 27 17:25:57] NOTICE[21986][C-000001aa]: chan_sip.c:26515 handle_request_invite: Call from '4000' (192.168.100.57:50273) to extension '40009099026092' rejected because extension not found in context 'default'.
[Mar 27 17:26:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:26:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:26:01] == Manager 'sendcron' logged on from 127.0.0.1
Hitme8622
 
Posts: 4
Joined: Thu Mar 25, 2021 6:12 am
Location: Ahmedbad

Re: Dial Plan based on agent Code

Postby Kabis » Mon Mar 29, 2021 11:15 am

Hi @hitme8622,

Add this dialplan in your carrier. Then it will take GSM Gateway. In GSM gateway you can give one to one communication to achieve your requirements.
We are ready to help you,
Regards,
KABIS,
Email ID: kabisforu@gmail.com
Website: www.kabis.org.in
Skype: kabisforu
Kabis
 
Posts: 100
Joined: Sat Nov 03, 2018 12:08 am
Location: India

Re: Dial Plan based on agent Code

Postby Hitme8622 » Tue Mar 30, 2021 1:25 am

@Kabis

Thanks For your Feedback i have added the Diale plan shared by #mjohn425 into carrier but i am getting the below shared output while placing the call from Agent end and Directly from Soft Phone.

in GSM Gateway i have Mention the Caller id like for agent 1 i have set the caller id 4000.but call is not placing.is there anything missing in campaign settings ? Manual Dial prefix is set as X.

Hitme8622 wrote:@ mjohn425

Thanks for your Response. I have set the dial method to Inbound_man.

i have get this output. I am using the GSM Gateway and i have set the dial plan as below,

Connected to Asterisk 13.29.2-vici currently running on vicibox9 (pid = 13676)
[Mar 27 17:01:43] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:01:43] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:01:43] -- Called 58600053@default
[Mar 27 17:01:43] -- Executing [58600053@default:1] MeetMe("Local/58600053@default-000000b3;2", "8600053,Fmq") in new stack
[Mar 27 17:01:43] -- Local/58600053@default-000000b3;1 answered
[Mar 27 17:01:43] -- Executing [8309@default:1] Answer("Local/58600053@default-000000b3;1", "") in new stack
[Mar 27 17:01:43] -- Executing [8309@default:2] Monitor("Local/58600053@default-000000b3;1", "wav,_1104_20210327-170143") in new stack
[Mar 27 17:01:43] -- Executing [8309@default:3] Wait("Local/58600053@default-000000b3;1", "60000") in new stack
[Mar 27 17:01:44] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:01:44] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:02:59] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:02:59] -- Manager 'sendcron' from 127.0.0.1, hanging up channel: Local/58600053@default-000000b3;2
[Mar 27 17:02:59] == Spawn extension (default, 58600053, 1) exited non-zero on 'Local/58600053@default-000000b3;2'
[Mar 27 17:02:59] WARNING[14836][C-00000196]: func_hangupcause.c:140 hangupcause_read: Unable to find information for channel
[Mar 27 17:02:59] -- Executing [h@default:1] AGI("Local/58600053@default-000000b3;2", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0--------------------)") in new stack
[Mar 27 17:02:59] -- <Local/58600053@default-000000b3;2>AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ----------) completed, returning 0
[Mar 27 17:02:59] == Spawn extension (default, 8309, 3) exited non-zero on 'Local/58600053@default-000000b3;1'
[Mar 27 17:02:59] WARNING[14835][C-00000197]: func_hangupcause.c:140 hangupcause_read: Unable to find information for channel
[Mar 27 17:02:59] -- Executing [h@default:1] AGI("Local/58600053@default-000000b3;1", "agi://127.0.0.1:4577/call_log--HVcauses--PRI-----NODEBUG-----0--------------------)") in new stack
[Mar 27 17:02:59] -- <Local/58600053@default-000000b3;1>AGI Script agi://127.0.0.1:4577/call_log--HVcauses ... ----------) completed, returning 0
[Mar 27 17:03:00] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:03:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:03:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:03:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:03:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:03:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:03:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:04:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:04:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:04:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:04:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:04:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:04:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:05:02] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:05:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:07] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:05:07] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:05:18] -- Registered SIP '4000' at 192.168.100.57:57223
[Mar 27 17:05:18] > Saved useragent "Z 3.7.30891 r30851" for peer 4000
[Mar 27 17:06:02] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:06:02] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:06:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:06:02] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:06:07] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:06:07] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:06:10] -- Registered SIP '4000' at 192.168.100.57:50273
[Mar 27 17:06:10] > Saved useragent "3CXPhone 6.0.26523.0" for peer 4000
[Mar 27 17:07:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:07:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:07:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:07:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:07:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:07:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:08:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:08:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:08:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:09:01] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:09:06] == Manager 'sendcron' logged on from 127.0.0.1
[Mar 27 17:09:06] == Manager 'sendcron' logged off from 127.0.0.1
[Mar 27 17:10:01] == Manager 'sendcron' logged on from 127.0.0.1

in Phone (admin>Phones).i have set the Outbound CallerID as a 4000.(same as agent extension Number)

in carriers i have set the dial plan as below

Registration String:
Account Entry:
Protocol: SIP
Globals String:
Dialplan Entry:
exten => _9XXXXXXXX,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _9XXXXXXXX/4000,2,Dial(SIP/${EXTEN:1}@GSM1,,tTor)
exten => _9XXXXXXXX/4001,2,Dial(SIP/${EXTEN:1}@GSM1,,tTor)
exten => _9XXXXXXXX,3,Hangup()

In campaign setting the Dial Prefrix i have set as below :

Dial Prefix: 9
Manual Dial Prefix:


at the GSM Gateway end i have define the caller id as 4000 and set map the Simcard to this caller id.
Hitme8622
 
Posts: 4
Joined: Thu Mar 25, 2021 6:12 am
Location: Ahmedbad

Re: Dial Plan based on agent Code

Postby Kabis » Mon Apr 12, 2021 3:34 am

If you give access, I will configure for you. You can reach me in skype.
We are ready to help you,
Regards,
KABIS,
Email ID: kabisforu@gmail.com
Website: www.kabis.org.in
Skype: kabisforu
Kabis
 
Posts: 100
Joined: Sat Nov 03, 2018 12:08 am
Location: India


Return to Support

Who is online

Users browsing this forum: Google [Bot] and 40 guests