<div dir="ltr"><div>Hi Jon,</div><div><br></div><div>Thank you for the reply. We wanted to read a particular SIP header in the 302 Moved response, but it seems that Asterisk creates a Local channel for the redirected call and the SIP_HEADER() function isn't available, so we can't really do what we wanted at all.</div><div><br></div><div>Thanks anyway!</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 27 Apr 2022 at 18:57, Jon Bonilla (Manwe) <<a href="mailto:manwe@aholab.ehu.es">manwe@aholab.ehu.es</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">El Wed, 27 Apr 2022 12:27:03 +1200<br>
David Cunningham <<a href="mailto:dcunningham@voisonics.com" target="_blank">dcunningham@voisonics.com</a>> escribió:<br>
<br>
> Hello,<br>
> <br>
> Does anyone know of a way to have a call go to a particular context when a<br>
> 302 Moved is received in response to an invite? This is with chan_sip. We<br>
> tried setting __TRANSFER_CONTEXT but it didn't seem to have any effect.<br>
> Basically if a remote device returns a 302 Moved we want to send the call<br>
> somewhere different to all other calls.<br>
> <br>
> Thanks very much,<br>
> <br>
<br>
<br>
You can detect a 302 in the dialplan. Not perfect but does the job.<br>
<br>
same => n,GotoIf($[${EXISTS(${FORWARDERNAME})}]?sipcfu)<br>
<br>
<br>
-- <br>
PekePBX, the multitenant PBX solution<br>
<a href="https://pekepbx.com" rel="noreferrer" target="_blank">https://pekepbx.com</a><br>
<br>
-- <br>
_____________________________________________________________________<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.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/wiki/display/AST/Getting+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/mailman/listinfo/asterisk-users</a></blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>David Cunningham, Voisonics Limited<br><a href="http://voisonics.com/" target="_blank">http://voisonics.com/</a><br>USA: +1 213 221 1092<br>New Zealand: +64 (0)28 2558 3782</div></div></div></div></div></div></div></div></div></div></div>