I noticed there is a semicolon and a number added to the channel id in case of the callee doesn’t pick up the call and a CANCEL event occurs.
What is the reason for that?
ChannelHangupRequest 16 - (channel id CHID-76ccb32e-ffb2-46e0-af11-59b4828b2e78;2)
There’s not enough context here to be able to answer this, beyond saying that Local channels are composed of two channels, one being ;1 and the other being ;2.
Okay, that is setting the unique id. Since a unique id has to be by definition unique only one channel can have that unique id. The second channel for a Local channel, by default, will append ;2 to make it unique. When requesting in ARI there is also the ability to set the unique id for the second channel in otherChannelId[1].