IVR auto dial out


(Toure Amidou) #1

Hi all.
Sorry again for the disturbance
We are searching a way to program a call on our Freepbx server using an IVR. The Xact Dialer solution seems to be expensive for us so we are searching another way to achieve our goal.So we want to proced like this :
-Create an IVR menu on our Freepbx server in extensions_override.conf
-Be able to call an external number using the IVR. When the external number replies the IVR will ask him some questions and It will reply.
We want to be able to program the IVR : For example at 8pm the IVR will call the external user trough our sip provider.
I’m testing it using a simple IVR.
How can I proced? Using an AGI script to program the call or is there a syntax to do this?
Thanks

[ivr-2]
exten => s,1,Answer(500)
same => n(loop),Background(press-1&or&press-2)
same => n,WaitExten()

exten => 1,1,Dial(SIP/2150)
same => n,SayNumber(1)
same => n,Goto(s,loop)

exten => 2,1,Playback(you-entered)
same => n,SayNumber(2)
same => n,Goto(s,loop)


(Itzik) #2

Why? …


(Toure Amidou) #3

Sorry extensions_custom.conf


(Itzik) #4

Asterisk Callfiles

https://wiki.asterisk.org/wiki/display/AST/Asterisk+Call+Files


Also, If you have regular IVRs, I think you shouldn’t use ivr-2


(Toure Amidou) #5

Thanks
It works
I’m able to call a specific extension (here extension 2150) and connect It to an IVR
But how can I call 2 or more extensions using Channel ? Channel : SIP/2500/1002 only calls 1002 extension. What is the correct syntax?
Thanks
call file example
Action: Originate
Channel: SIP/2150
Context: call-file-test
Extension: s
Priority: 1

extensions_custom.conf example :
[call-file-test]
exten => s,1,Answer()
exten => s,n,Wait(1)
exten => s,n,Playback(hello-world)
exten => s,n,Wait(1)
exten => s,n(dest-ext),Goto(ivr-2,s,1)
exten => s,n,Hangup()


(Itzik) #6

I don’t know.

You can try

Channel: SIP/2150&SIP/1002

Or create a callfile for each extension.


(Toure Amidou) #7

It works for different calls files but I got another problem
I use call file to call an external number using trunk 1000 like this :
Action: Originate
Channel: SIP/1000/53584523
Context: call-file-test
Extension: s
Priority: 1
When the call is anwsered I and when the user types 2 The ivr must call another external number like this :
exten => 2,1,Dial(SIP/1000/74588181)
same => n,SayNumber(2)
same => n,Goto(s,loop)
It doesn’t work.It works only if I call an extension in call file like this
Channel: SIP/2150
Must I use another SIP trunk for the external calls of the IVR?
Thanks


(Itzik) #8

Post a call log. Use pastebin please.

https://wiki.freepbx.org/display/SUP/Providing+Great+Debug#ProvidingGreatDebug-AsteriskLogs-PartII


(Toure Amidou) #9

0x7f321c004a20 – Strict RTP learning complete - Locking on source address 192.168.20.4:15062
– SIP/1000-00000012 answered
– Executing [s@call-file-test:1] Answer(“SIP/1000-00000012”, “”) in new stack
– Executing [s@call-file-test:2] Wait(“SIP/1000-00000012”, “1”) in new stack
– Executing [s@call-file-test:3] Playback(“SIP/1000-00000012”, “hello-world”) in new stack
– <SIP/1000-00000012> Playing ‘hello-world.ulaw’ (language ‘en’)
– Executing [s@call-file-test:4] Wait(“SIP/1000-00000012”, “1”) in new stack
– Executing [s@call-file-test:5] Goto(“SIP/1000-00000012”, “ivr-2,s,1”) in new stack
– Goto (ivr-2,s,1)
– Executing [s@ivr-2:1] Answer(“SIP/1000-00000012”, “500”) in new stack
– Executing [s@ivr-2:2] BackGround(“SIP/1000-00000012”, “press-1&or&press-2”) in new stack
– <SIP/1000-00000012> Playing ‘press-1.ulaw’ (language ‘en’)
– <SIP/1000-00000012> Playing ‘or.ulaw’ (language ‘en’)
– <SIP/1000-00000012> Playing ‘press-2.ulaw’ (language ‘en’)
– Executing [s@ivr-2:3] WaitExten(“SIP/1000-00000012”, “”) in new stack
– Executing [2@ivr-2:1] Dial(“SIP/1000-00000012”, “SIP/1000/74588181”) in new stack
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Called SIP/1000/74588181
0x7f321c017cd0 – Strict RTP learning after remote address set to: 192.168.20.4:11466
– SIP/1000-00000013 is making progress passing it to SIP/1000-00000012
– Got SIP response 503 “Service Unavailable” back from 192.168.20.4:5060
– SIP/1000-00000013 is circuit-busy
== Everyone is busy/congested at this time (1:0/1/0)
– Executing [2@ivr-2:2] SayNumber(“SIP/1000-00000012”, “2”) in new stack
– <SIP/1000-00000012> Playing ‘digits/2.ulaw’ (language ‘en’)
– Executing [2@ivr-2:3] Goto(“SIP/1000-00000012”, “s,loop”) in new stack
– Goto (ivr-2,s,2)
– Executing [s@ivr-2:2] BackGround(“SIP/1000-00000012”, “press-1&or&press-2”) in new stack
– <SIP/1000-00000012> Playing ‘press-1.ulaw’ (language ‘en’)
– <SIP/1000-00000012> Playing ‘or.ulaw’ (language ‘en’)
– <SIP/1000-00000012> Playing ‘press-2.ulaw’ (language ‘en’)
– Executing [s@ivr-2:3] WaitExten(“SIP/1000-00000012”, “”) in new stack
== Spawn extension (ivr-2, s, 3) exited non-zero on ‘SIP/1000-00000012’
[2020-01-07 14:52:48] NOTICE[25554][C-0000000b]: pbx_spool.c:460 attempt_thread: Call completed to SIP/1000/53584523


(Toure Amidou) #10

– Executing [s@ivr-2:3] WaitExten(“SIP/1000-00000012”, “”) in new stack
– Executing [2@ivr-2:1] Dial(“SIP/1000-00000012”, “SIP/1000/74588181”) in new stack
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
– Called SIP/1000/7458
This is the problem
745818181 is called but not ringing


(Itzik) #11

Because


(Toure Amidou) #12

So I must configure another sip trunk?


(Itzik) #13

If your Trunk supports only 1 channel, then yes.


(system) closed #14

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