SIPADDHEADER and DIAL in call forking

Hi all, I’m implementing call forking with asterisk using Dial()

Dial(SIP/UA1&SIP/UA2)

that works fine with the behavior one pickup and one get CANCELED.
But I want to add different X- custom headers in these 2 outbound legs.
Using SIPADDHEADER command before Dial() add the same header/value to both leg.
So I’m wondering if Dial and SIPADDHEADER can work for me somehow, or I need to look for another workaround?
Any help would be appreciated.
rgds,
Loi Dang

The easiest way would be to use Local channels to execute dialplan logic which adds the appropriate header to each and dials them.

2 Likes

It’s exactly what I’m looking for, have it works for me.
Many thanks jcolp.
rgds,
Loi Dang