I want to perform a channel redirect from dial plan.
For this reason I have to get the full name of a specific channel, of which I only know the peer involved, e.g., from channel SIP/5313-00008fea I know 5313, of PJSIP/5314-000025a6 I know 5314.
How do I lookup a full channel name from dial plan in such a scenario?
The device dialing into the dial plan that executes the redirect and looks up the channel name is not connected to the channel I want to get information on.
In other words, e.g. peer 5315 is on a call. How do I retrieve its channel name from a dial plan application?