I want to dial to multiple numbers at once ,I had tried with func. Dial(PJSIP/101 & PJSIP/102) but it will only ring to both user and hung-up the other ,if any one user has picked up the call.
e.g,101–> dialing,102–> dialing
if 101 pick up the call.
101—> Answer,102—>Hangup(automatically by asterisk)
but, i want to make calls simultaneously to multiple user ,either they Answer or not.
Thanks for your reply david551,
Currently our motive is to not to do conference call,instead we want calls to initiate parallelly to mutilple clients.
we tried originate func.,but it was not able to set callerId and not working for outbound calls through our SIP trunk.
We have tried call files and they seem to be working fine, but is there any overhead associate with them or does any better way exist?
hi david,
I had tried the call files, it is working fine in case if i have to playback something but in case of
AGI function it will not executing . below is showing our configuration and logs.
we are trying to playback some files and generate logs of the calls ,so for that we are using AGI script of python for more control over flow.
below is “test.agi”
#!/usr/bin/env python
from asterisk.agi import AGI
from app.callLogs import callLogs
from callconferencing import socketClient
def playbackMessage():
try:
agi = AGI()
# print(“playback Message started”)
agi.verbose("&&&& playback message $$$$")
# audioFile = socketClient.audioFilePath
# get the file form particular path
agi.appexec(“Playback”,“demo-instruct”)
# set the call logs for the users.
dialStatus = agi.get_variable(“DIALSTATUS”)
agi.verbose(%s,dialStatus)
empCallType=“tata”
hungUpBy=“caller”
employeeId=1
employeeName=“ash”
agi.verbose("SET out call Logs started ")
callLogs.setOutCallLog(agi, employeeId, employeeName, empCallType, dialStatus, hungUpBy)
except Exception as E:
logger.exception(E)
as it was mentioned, Page() is a solution for you.
“Places outbound calls to the given technology/resource and dumps them into a conference bridge as muted participants (if the ‘d’ option is not specified). The original caller is dumped into the conference as a speaker and the room is destroyed when the original caller leaves.”
To get it work smoothly, is better to Page the Local/s@some-context, where a certain group of extensions are called (precheck if they are currently paging or not ) .
Hi @VoipLinux,
Sorry for the late reply ,
in between i tried your solution but the problem with this is,
if i Dial like below :
Dial—>101,(picked up the call)—> playback started()
Dial----->102,(picked up the call after some delay 15 secs )------------------->playback already playing(joined in the middle listen half of the playback message )
Dial------>103 (picked up the call after delay 30 secs) -------->Playback message finished (nothing to listen)
but instead of that we wants to made listen the whole message to everyone
irrespective of their pickup time of call.
hi @david551,
sorry for replying you late,
since as you see in last thread we are using call-files and through
which we are calling AGI script, agi is executing as we are excepted but
Dial status is missing in logs, since we need dial status to save start time ,end time in our DB.
Attempting call on PJSIP/101 for application AGI(/home/voi/Documents/nonConfCall.py) (Retry 1)
– Called 101
– PJSIP/101-00000008 is ringing
> 0x7f2ed8027740 – Strict RTP learning after remote address set to: 127.0.0.1:8000
> 0x7f2ed8027740 – Strict RTP switching to RTP target address 127.0.0.1:8000 as source
– PJSIP/101-00000008 answered
> Launching AGI(/home/voi/Documents/nonConfCall.py) on PJSIP/101-00000008
– Launched AGI Script /home/voi/Documents/nonConfCall.py
/home/voi/Documents/nonConfCall.py: &&&& playback message $$$$
– AGI Script Executing Application: (Playback) Options: (hello)
– <PJSIP/101-00000008> Playing ‘hello.gsm’ (language ‘en’)
/home/voi/Documents/nonConfCall.py: DialStatus ############>
/home/voi/Documents/nonConfCall.py: DialStatus ############>
/home/voi/Documents/nonConfCall.py: SET out call Logs started
– <PJSIP/101-00000008>/home/voi/Documents/nonConfCall.py
completed, returning 0
Seems you need predictive dialer
Vici/Goautodial - upload leads with PJPSIP extensions, create campaign - and it will call each number, play message and generate CDRs for you.
if it’s also not work for you, then I agree with david551, several Originate dial plan procedure , and set channel Hangup handler to track cdrs.
p.s.
I am not big fun of call files, using Originate() is more comfortable as for me.