Closed mpbanna closed 6 years ago
If you listen for the ChannelStateChange
[1] event, you'll also get a Channel instance along with the event. The state property of that instance should give you more information about the channel state[2].
[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+15+REST+Data+Models#Asterisk15RESTDataModels-ChannelStateChange [2] https://wiki.asterisk.org/wiki/display/AST/Asterisk+15+REST+Data+Models#Asterisk15RESTDataModels-Channel
sorry for late response , on channel mute or unmute, 'ChannelStateChange' event not fire
How are you muting the channel? Are you muting a phone or doing it via ARI with channel.mute()
? I'm not sure muting via a phone would raise any events as Asterisk wouldn't necessarily know that a client was muting on their end.
I am using mute as :-
ari.channels.mute( {channelId: channel.id,direction:'both'}, function (err) { if (err) { logger.error('Mute error::', err); }
}
);
i try direction parameter with all 3 value 'both', 'in', 'out' But ChannelStateChange event not fire
Muting does not raise an event, as muting a channel is not a state change in Asterisk.
If you wanted an event for that, it would be a feature request against Asterisk, not the ARI client library.
Hello, is there any event fire for 'channelMute' and 'chanelUnmute', like 'channelHold' , 'ChannelTalkingStarted' etc.