<div dir="ltr">Hi<div><br></div><div>I guess is not possible send specific SIP response from dialplan in Asterisk, but you can send ISDN hangupcauses. In this case, to reject the call you can use Hangup(21).</div><div>To do this remotly, my suggestion is create a context that pickup the call and execute hangup with cause 21.</div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><br></div><div dir="ltr"><div style="font-size:12.8px"><div><div dir="ltr"><div><table style="font-family:"Times New Roman""><tbody><tr><td rowspan="3"><a href="mailto:rafaelsnsa@gmail.com" title="Enviar um e-mail para mim" style="color:rgb(17,85,204)" target="_blank"><img alt="Sua Foto" src="https://lh5.googleusercontent.com/-4_Ww7w9G_BM/AAAAAAAAAAI/AAAAAAAAD40/IgVDbZCLz5w/s120-c/photo.jpg" width="70" height="70" style="clear:left;float:left;margin-bottom:5px;margin-right:5px"></a></td><td><span style="font-family:"Trebuchet MS",Trebuchet,sans-serif;font-size:22px;font-weight:bold">Rafael S. Saraiva</span></td></tr><tr><td><span style="font-family:"Trebuchet MS",Trebuchet,sans-serif">Porto Alegre - RS | Mobile: (51) 981-747-956</span></td></tr><tr><td><a href="http://br.linkedin.com/pub/rafael-saraiva/52/aab/230" style="color:rgb(17,85,204)" target="_blank"><img src="https://static.licdn.com/scds/common/u/img/webpromo/btn_viewmy_160x25.png" border="0" width="160" height="25" title="View Rafael Saraiva's profile on LinkedIn"></a> <br><br></td></tr></tbody></table></div></div></div></div></div></div></div></div></div>
<br><div class="gmail_quote">2018-05-08 15:12 GMT-03:00 Alexander Lopez <span dir="ltr"><<a href="mailto:alex.lopez@opsys.com" target="_blank">alex.lopez@opsys.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">





<div lang="EN-US" link="blue" vlink="purple">
<div class="m_-572131366244904020WordSection1">
<p class="MsoNormal">Use a script to redirect the ringing call into an extension that returns the proper sip result, and hangup.
<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">You could also add logic to alert or log that call.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<div style="border:none;border-top:solid #e1e1e1 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b>From:</b> <a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-bounces@lists.<wbr>digium.com</a> [mailto:<a href="mailto:asterisk-users-bounces@lists.digium.com" target="_blank">asterisk-users-<wbr>bounces@lists.digium.com</a>]
<b>On Behalf Of </b>Mike<br>
<b>Sent:</b> Tuesday, May 08, 2018 1:46 PM<br>
<b>To:</b> 'Asterisk Users Mailing List - Non-Commercial Discussion' <<a href="mailto:asterisk-users@lists.digium.com" target="_blank">asterisk-users@lists.digium.<wbr>com</a>><br>
<b>Subject:</b> [asterisk-users] Reject call from Asterisk dialplan<u></u><u></u></p>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><span lang="FR-CA">Hi,<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="FR-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA">I’m looking for a way to reject a call remotely using the Asterisk dialplan.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA">For example, phone A is ringing – I’m at the other end of the room next to phone B, and I want to reject the call to Phone A by dialing an extension.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA">I’m basically trying to reproduce the Polycom “reject” action but through the Asterisk dialplan.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA">Reasons:<u></u><u></u></span></p>
<ol style="margin-top:0in" start="1" type="1">
<li class="MsoNormal"><span lang="EN-CA">It would allow me to log through Asterisk who’s rejecting calls<u></u><u></u></span></li><li class="MsoNormal"><span lang="EN-CA">It would allow rejecting calls from another phone  (see above scenario)<u></u><u></u></span></li></ol>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA">I thought there could be a “SendSIPCode 486 to SIP peer phoneA” application, but a quick scan of the documentation does not bring obvious answers.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA">Mike<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-CA"><u></u> <u></u></span></p>
</div>
</div>

<br>-- <br>
______________________________<wbr>______________________________<wbr>_________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" rel="noreferrer" target="_blank">http://www.api-digital.com</a> --<br>
<br>
Check out the new Asterisk community forum at: <a href="https://community.asterisk.org/" rel="noreferrer" target="_blank">https://community.asterisk.<wbr>org/</a><br>
<br>
New to Asterisk? Start here:<br>
      <a href="https://wiki.asterisk.org/wiki/display/AST/Getting+Started" rel="noreferrer" target="_blank">https://wiki.asterisk.org/<wbr>wiki/display/AST/Getting+<wbr>Started</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" rel="noreferrer" target="_blank">http://lists.digium.com/<wbr>mailman/listinfo/asterisk-<wbr>users</a><br></blockquote></div><br></div>