[Asterisk-Dev] Asterisk channel variable access: a proposal

Holger Schurig hs4233 at mail.mn-solutions.de
Tue Aug 17 08:05:07 MST 2004


>    It sounds like that manager.py is useful in certain circumstances,
> but it does not easily allow integration of these variables into the
> diaplan,

No, that is not for what manager.py is. However, I quoted a snippet of 
your text:

> Technically, it is possible to write a daemon that sits on a manager
>  port and watches for all traffic it sees. Extracting channel data is
>  then quite easy since you can basically execute any command from the
>  manager interface.

... and this is what this program does.

> and it also doesn't have the ability to see most of the
> variables that I describe 

Yes, it can't, because they are not exported via the Manager API. From 
your list

> channels/SIP/2109-996a/Unique-ID
> channels/SIP/2109-996a/Caller-ID
> channels/SIP/2109-996a/DNID-Digits
> channels/SIP/2109-996a/State
> channels/SIP/2109-996a/Rings
> channels/SIP/2109-996a/NativeFormat
> channels/SIP/2109-996a/WriteFormat
> channels/SIP/2109-996a/ReadFormat

only Unique-ID, Caller-ID, DNID-Digits and State is exported.

BTW: "Number of Rings" doesn't exist generally (you don't know how fast 
the phone will ring). But you can get the time from the ringing-state to 
the connected-state, even via Manager-API and a listening-daemon.




More information about the asterisk-dev mailing list