[Freeswitch-users] Custom Headers with Sip.js

Ítalo Rossi italorossib at gmail.com
Wed Mar 18 17:25:01 MSK 2015


using mod_callcenter? try setting cc_export_vars

On Wed, Mar 18, 2015 at 9:47 AM, Ali Jibran <ali.jibran44 at gmail.com> wrote:

> Ok yeah :) thank you that worked.
>
> One more thing. I can access the Header now in my dialplan. But I pass the
> call into call Center.
> Now how do I pass the header into call Center so that it pops up to which
> ever agent picked it up.
>
> Like
> Web->fs->call center->agent
>
> I can get the header to Freeswitch but it's not showing after the call is
> bridged to agent.
> I tried sip_copy_custom_headers=true but it didn't work
>
> On Wednesday, March 18, 2015, Ben Langfeld <ben at langfeld.co.uk> wrote:
>
>> Prefix the header with X-. Anything else is invalid.
>>
>> On 18 March 2015 at 07:51, Ali Jibran <ali.jibran44 at gmail.com> wrote:
>>
>>> Hi all.
>>> I make a call to FS callcenter using webRTC. Now I would like to add
>>> some additional data to the header.
>>> That I did by using extraheaders. Now all that is good. I can see the
>>> custom header in the sip trace on freeswitch.
>>>
>>> For e.g in sip.js I add:
>>> var options = {
>>>   extraHeaders: [ 'a: foo' ]
>>> };
>>>
>>>
>>> on FS i get:
>>>  INVITE sip:900 at anonymous.invalid SIP/2.0
>>>    Via: SIP/2.0/WS 9jscv0q24s4m.invalid;branch=z9hG4bK1002472
>>>    Max-Forwards: 70
>>>    To: <sip:900 at anonymous.invalid>
>>>    From: <sip:anonymous.hfsqa4 at anonymous.invalid>;tag=depmif1fo5
>>>    Call-ID: l5pieavpjguoset7ugvd
>>>    CSeq: 1458 INVITE
>>>   * a: foo*
>>>    Contact: <sip:8rgi365g at 9jscv0q24s4m.invalid;transport=ws;ob>
>>>    Allow: ACK,CANCEL,BYE,OPTIONS,INVITE,MESSAGE
>>>    Content-Type: application/sdp
>>>    Contact: <sip:8rgi365g at 9jscv0q24s4m.invalid;transport=ws;ob>
>>>    Allow: ACK,CANCEL,BYE,OPTIONS,INVITE,MESSAGE
>>>    Content-Type: application/sdp
>>>    Supported: outbound
>>>    User-Agent: SIP.js/0.5.0
>>>    Content-Length: 3636
>>>
>>> How do I access it in the dialplan? I tried ${sip_h_X-a} but it didnt't
>>> work. Help please?
>>>
>>> _________________________________________________________________________
>>> Professional FreeSWITCH Consulting Services:
>>> consulting at freeswitch.org
>>> http://www.freeswitchsolutions.com
>>>
>>> Official FreeSWITCH Sites
>>> http://www.freeswitch.org
>>> http://confluence.freeswitch.org
>>> http://www.cluecon.com
>>>
>>> FreeSWITCH-users mailing list
>>> FreeSWITCH-users at lists.freeswitch.org
>>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>>> http://www.freeswitch.org
>>>
>>
>>
> _________________________________________________________________________
> Professional FreeSWITCH Consulting Services:
> consulting at freeswitch.org
> http://www.freeswitchsolutions.com
>
> Official FreeSWITCH Sites
> http://www.freeswitch.org
> http://confluence.freeswitch.org
> http://www.cluecon.com
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>



-- 
Ítalo Rossi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20150318/2087106e/attachment.html 


Join us at ClueCon 2016 Aug 8-12, 2016
More information about the FreeSWITCH-users mailing list