<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">In the sip.conf entry assign a context.<div><br class="webkit-block-placeholder"></div><div>In that context, hint the extension i.e. exten => 7302,hint,SIP/7302. </div><div><br class="webkit-block-placeholder"></div><div>Before you get ready to dial, or whatever, do chanisavail i.e.</div><div><br></div><div><div>exten => _1XXXX,n(CheckUse),ChanIsAvail(SIP/${EXTEN:1},js)</div><div>exten => _1XXXX,n,Playback(beep)</div><div>exten => _1XXXX,n,Dial(SIP/${EXTEN},2)</div><div>exten => _1XXXX,n,Goto(result-${DIALSTATUS},${EXTEN},1)</div><div>exten => _1XXXX,CheckUse+101,SayDigits(${EXTEN:1})</div><div>exten => _1XXXX,CheckUse+102,Playback(vm-isonphone)</div><div>exten => _1XXXX,CheckUse+103,Hangup()</div><div><br class="webkit-block-placeholder"></div><div>This is from the paging stuff. It checks the primary extension before ringing the auto answer extension of the phone. I seem to remember it detecting DND as well for the Cisco 7960.</div><div><br class="webkit-block-placeholder"></div><div>I don't see it in this message but I seem to remember seeing somewhere in this thread that the goal is to keep people from being in a queue forever. Why not just set a time limit on the queue and play back "all operators busy" and hang up if a call hits that limit?</div></div><div><br class="webkit-block-placeholder"></div><div>Richard</div><div><br class="webkit-block-placeholder"></div><div><br class="webkit-block-placeholder"></div><div><br class="webkit-block-placeholder"></div><div><div><div>On Dec 2, 2007, at 8:51 AM, Vieri wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"> <div> <!-- Converted from text/plain format --><p><font size="2">Hi,<br> <br> I am trying to get a SIP extension's status without<br> actually making a call.<br> <br> I am using sofia-sip's "options" example utility and<br> the sip clients are SJphone softphones.<br> <br> From Asterisk I run the "options" utility and query a<br> sip extension at 10.215.147.240. I get:<br> <br> # ./options -1 --all <a href="sip:10.215.147.240">sip:10.215.147.240</a><br> SIP/2.0 501 Not Implemented<br> Via: SIP/2.0/UDP<br> 10.215.144.27:38098;branch=z9hG4bKUKS02S3F8H8ZS;received=10.215.144.27<br> From: <<a href="sip:10.215.144.27">sip:10.215.144.27</a>>;tag=U3DKgF7HgFKXH<br> To: "unknown" <<a href="sip:10.215.147.240">sip:10.215.147.240</a>>;tag=614733430<br> Call-ID: b6968197-1b7d-122b-0ab0-00c09f10e472<br> CSeq: 92182805 OPTIONS<br> Content-Length: 0<br> Server: SJphone/1.65.377a (SJ Labs)<br> <br> I guess that the softphone should be answering with a<br> 2xx code followed by a status description?<br> So I tried with the INVITE method and set DND on the<br> SIP extension:<br> <br> # ./options -1 --all --method INVITE<br> <a href="sip:10.215.147.240">sip:10.215.147.240</a><br> SIP/2.0 486 Busy Here<br> Via: SIP/2.0/UDP<br> 10.215.144.27:38098;branch=z9hG4bK5Z3BS8F737t0e;received=10.215.144.27<br> From: <<a href="sip:10.215.144.27">sip:10.215.144.27</a>>;tag=590Z1ND8B6XpN<br> To: "unknown" <<a href="sip:10.215.147.240">sip:10.215.147.240</a>>;tag=1a2d77b524<br> Call-ID: 668ad4fa-1b7e-122b-fcb6-00c09f10e472<br> CSeq: 92182952 INVITE<br> Content-Length: 0<br> Server: SJphone/1.65.377a (SJ Labs)<br> <br> The above would suit me fine because I get a "486 Busy<br> Here" response.<br> However, if DND is off then I get:<br> <br> # ./options -1 --all --method INVITE<br> <a href="sip:10.215.147.240">sip:10.215.147.240</a><br> SIP/2.0 180 Ringing<br> <br> and the SIP extension actually "rings", as<br> expected.(but this is undesireable)<br> <br> Now, does someone know another way to get the status<br> (ie. does it accept calls or not?) without making the<br> extension "ring"?<br> <br> Thanks<br> <br> Vieri<br> <br> <br> <br> ____________________________________________________________________________________<br> Be a better pen pal.<br> Text or chat with friends inside Yahoo! Mail. See how. <a href="http://overview.mail.yahoo.com/">http://overview.mail.yahoo.com/</a><br> <br> _______________________________________________<br> --Bandwidth and Colocation Provided by <a href="http://www.api-digital.com--">http://www.api-digital.com--</a><br> <br> asterisk-users mailing list<br> To UNSUBSCRIBE or update options visit:<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br> </font> </p> </div> </blockquote></div><br></div></body></html>