Ah jeez. All I wanted to do was connect to a carrier and then perform fail over 
logic based on their SIP response.
Not supposed to be difficult. This is what Asterisk is supposed to be good at.
We have a SIP module, why not have SIP responses available to the module.

Now, I have to look at the lossy HANGUPCAUSE variable and make a best guess.
Not an ideal situation.

We're trying to improve the ASR's we get from providers. They are low, and 
often they fail calls for no particular reason. They all do it, even the big 
ones like Verizon. Checking their responses for purpose of trying another 
carrier on the fly, and reporting is pretty critical.

Doug.


----- Original Message ----
From: Raj Jain <[EMAIL PROTECTED]>
To: Asterisk Users Mailing List - Non-Commercial Discussion 
<[email protected]>
Sent: Saturday, October 27, 2007 11:29:21 AM
Subject: Re: [asterisk-users] Getting SIP Response Code from HANGUPCAUSE


> > The only place where it is reasonable to customize is in the 
> > specification of the channel in the configuration file.  
> That is where 
> > you would customize, for example, whether DTMF is inband, 
> SIP INFO, or 
> > RFC 2833, as well as what codecs will be negotiated for that 
> > particular user/peer.
> > 
> 
> But you already have the SIP_HEADER function, which is quite 
> contradictory to what you say. This allows users who know 
> what they are doing to examine headers directly. We use this 
> a lot. What would be the harm in having a SIP_RESPONSE 
> function or something alike? 

I'd agree that SIP response code should be accessible from the dial
 plan.
Knowing the exact SIP response code could be critical for making call
processing decisions. The conversion of SIP response codes to Q.931
 codes
(HANGUPCAUSE) is just too lossy. Building a truly protocol agnostic
 dial
plan API is a worthy goal. But, I think it is somewhat of an unsolvable
problem. The signaling protocols are very different and for various
 reasons
people have always wanted access to native information elements carried
 in
the protocol.

Perhaps, a very simple solution for this problem could be to support a
keyword such as "TOPLINE" in the SIP_HEADER function to fetch the
 topmost
line in a SIP message. This will not only get the caller the response
 code
for SIP response messages, but will also have the nice byproduct of
 making
the Request-URI available if the message in question is a SIP request.

- Raj


_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users





__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to