Reply To: RE: Custom Sip Headers

VitalPBX Community Support General Discussion Custom Sip Headers Reply To: RE: Custom Sip Headers

    Up
    0
    Down

    @hlev

    Looks like is an issue on VitalPBX’s dialplan, because, according to Asterisk documentation the PJSIP headers must be add-ed in a pre-dial handler:

    To operate on the¬†callee’s (outgoing)¬†channel call PJSIP_HEADER in a pre-dial handler.

    Example:

    ;

    [handler]
    exten => addheader,1,Set(PJSIP_HEADER(add,X-MyHeader)=myvalue)
    exten => addheader,2,Set(PJSIP_HEADER(add,X-MyHeader2)=myvalue2)

    ;

    [somecontext]
    exten => 1,1,Dial(PJSIP/${EXTEN},,b(handler^addheader^1))
    ;

    0