Lenz Emilitri
2009-Feb-18 09:04 UTC
[asterisk-users] Setting SIP header on agent calls made by a queue
Hello list, I am trying to set a custom SIP header on all calls that are made by the app queue because I want to track a certain state at the SIP level. If I use the following code: exten => s,n,SIPAddHeader(X-Unique-ID: ${UNIQUEID}) exten => s,n,Queue(myQueue) this works fine for the FIRST call made from the queue to an agent; but if that call does not go through, it's not repeated on subsequent calls. I know I could use Local channels as members of the queue, but I was wondering if ther was something more general and that worked whatever your channel configuration might be. I also tried exporting the variable by setting the URL field of the queue() call, but it is not shown in the resulting SIP dialog. Any suggestion but patching the source? l. -- Loway - home of QueueMetrics - http://queuemetrics.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090218/80bd27e6/attachment.htm
Danny Nicholas
2009-Feb-18 14:43 UTC
[asterisk-users] Setting SIP header on agent calls made by a queue
Put this snippet in a macro and call the macro. That way the data lives for the duration of the incoming call. _____ From: asterisk-users-bounces at lists.digium.com [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of Lenz Emilitri Sent: Wednesday, February 18, 2009 3:05 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: [asterisk-users] Setting SIP header on agent calls made by a queue Hello list, I am trying to set a custom SIP header on all calls that are made by the app queue because I want to track a certain state at the SIP level. If I use the following code: exten => s,n,SIPAddHeader(X-Unique-ID: ${UNIQUEID}) exten => s,n,Queue(myQueue) this works fine for the FIRST call made from the queue to an agent; but if that call does not go through, it's not repeated on subsequent calls. I know I could use Local channels as members of the queue, but I was wondering if ther was something more general and that worked whatever your channel configuration might be. I also tried exporting the variable by setting the URL field of the queue() call, but it is not shown in the resulting SIP dialog. Any suggestion but patching the source? l. -- Loway - home of QueueMetrics - http://queuemetrics.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20090218/1b662427/attachment.htm
Benny Amorsen
2009-Feb-18 14:50 UTC
[asterisk-users] Setting SIP header on agent calls made by a queue
Lenz Emilitri <lenz.loway at gmail.com> writes:> If I use the following code: > > exten => s,n,SIPAddHeader(X-Unique-ID: ${UNIQUEID}) > exten => s,n,Queue(myQueue) > > this works fine for the FIRST call made from the queue to an agent; but if > that call does not go through, it's not repeated on subsequent calls.??That sounds like a bug to me. /Benny