Re: Setting a channel variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


Thanks Joshua, yes it works by directly passing the variables to originate.


On Tue, Apr 5, 2016 at 4:30 PM, Joshua Colp <jcolp@xxxxxxxxxx> wrote:
Nitesh Bansal wrote:

I want to use ARI node client library to initiate a call, i'm using the
sample code
from the ari example 'bridge-move.js', the code is running fine.
But now before initiating the call, I want to be able to add a 'Route'
header in
the outgoing call placed, I'm trying to achieve it by adding a channel
variable, it seems
that it isn't working, I don't see any route header added in the
outgoing INVITE.

This is my code in the originate function:
channel.setChannelVar({variable : "SIPADDHEADER", value : "Route :
nbansal@xxxxxxxxx <mailto:nbansal@xxxxxxxxx>"});

You need to pass in the variables to set on the originate itself using the variables argument, and not set it afterwards. This should work as you expect/need.

Joshua Colp
Digium, Inc. | Senior Software Developer
445 Jan Davis Drive NW - Huntsville, AL 35806 - US
Check us out at: &

asterisk-app-dev mailing list

asterisk-app-dev mailing list

[Index of Archives]     [Asterisk SS7]     [Asterisk Announcements]     [Asterisk Users]     [PJ SIP]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Linux API]

  Powered by Linux