<HTML>
<HEAD>
<TITLE>Getting DIALSTATUS from SIP provider</TITLE>
</HEAD>
<BODY>
<FONT FACE="Verdana, Helvetica, Arial"><SPAN STYLE='font-size:12.0px'>I use sipphone.com as my sip provider for testing. If I use the following AMI packet and extensions I connect to the QueueAnswer extension, as if the called party answered, before the called phone even rings once. This prevents me from getting no answer or busy status returned from the Dial application. What might I be doing wrong to not have the sip provider return me correct call statuses?<BR>
<BR>
I am using version 1.4.23.1<BR>
<BR>
<BR>
Action: Originate<BR>
Channel: Local/DialNumber@cfmc_cdi_info<BR>
Exten: QueueAnswer<BR>
Context: cfmc_cdi_info<BR>
Priority: 1<BR>
Variable: CfMC_ActionID=callE1321<BR>
Variable: CfMC_QueueToUse=tqe<BR>
Variable: CfMC_AgentToUse=1001<BR>
Variable: CfMC_DialInfo=SIP/xxxyyyzzzz@proxy01.sipphone.com<BR>
Variable: CfMC_RingTimeout=20<BR>
Variable: CfMC_DoAMD=No<BR>
ActionID: callE1321<BR>
Async: true<BR>
<BR>
<BR>
exten => DialNumber,1,UserEvent(BeforeDial,ActionID:${CfMC_ActionID}=${CHANNEL} & ${UNIQUEID} & ${CfMC_DialInfo} ** ${CfMC_RingTimeout})<BR>
exten => DialNumber,n,Dial(${CfMC_DialInfo},${CfMC_RingTimeout})<BR>
; DIALSTATUS - CHANUNAVAIL CONGESTION NOANSWER BUSY ANSWER CANCEL DONTCALL TORTURE INVALIDARGS<BR>
exten => DialNumber,n,UserEvent(AfterDial,ActionID:${CfMC_ActionID}=${CHANNEL} & ${UNIQUEID} & ${CfMC_DialInfo} == ${DIALSTATUS})<BR>
exten => DialNumber,n,Hangup()<BR>
<BR>
exten => QueueAnswer,1,Answer()<BR>
exten => QueueAnswer,2,Set(CfMC_AMDValue="NotChecked")<BR>
exten => QueueAnswer,3,GotoIf($["${CfMC_DoAMD}"!="Yes"]?NoAMD)<BR>
exten => QueueAnswer,4,AMD()<BR>
; AMDSTATUS - MACHINE HUMAN NOTSURE HANGUP<BR>
exten => QueueAnswer,5,Set(CfMC_AMDValue="${AMDSTATUS}")<BR>
exten => QueueAnswer,6(NoAMD),Wait(0.3)<BR>
exten => QueueAnswer,7,UserEvent(BeforeQueue,ActionID:${CfMC_ActionID}=${CHANNEL} & ${CfMC_DialInfo} & ${CfMC_AMDValue})<BR>
exten => QueueAnswer,8,GotoIf($["${CfMC_AMDValue}"="NotChecked"]?QueueIt)<BR>
exten => QueueAnswer,9,GotoIf($["${CfMC_AMDValue}"!="HUMAN"]?ForceHangUp)<BR>
exten => QueueAnswer,10(QueueIt),Queue(${CfMC_QueueToUse},n,,,20)<BR>
; QUEUESTATUS - TIMEOUT FULL JOINEMPTY LEAVEEMPTY JOINUNAVAIL LEAVEUNAVAIL<BR>
exten => QueueAnswer,11,UserEvent(AfterQueue,ActionID:${CfMC_ActionID}=${CHANNEL} & ${CfMC_DialInfo} & ${CfMC_QueueToUse} & ${CfMC_AgentToUse} & ${QUEUESTATUS})<BR>
exten => QueueAnswer,12(ForceHangUp),Hangup()<BR>
<BR>
-- <BR>
Jim Dickenson<BR>
<a href="mailto:dickenson@cfmc.com">mailto:dickenson@cfmc.com</a><BR>
<BR>
CfMC<BR>
<a href="http://www.cfmc.com/">http://www.cfmc.com/</a><BR>
<BR>
</SPAN></FONT>
</BODY>
</HTML>