forked from SimplesIP/pabx-app
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
107 lines
2.4 KiB
107 lines
2.4 KiB
2 years ago
|
phpAMI 1.0
|
||
|
|
||
|
iaxPeerList
|
||
|
Envia "ManagerAction_IAXpeerlist"
|
||
|
|
||
|
lista de IAX peer
|
||
|
|
||
|
return: Ver listEvent()
|
||
|
link: https://wiki.asterisk.org/wiki/display/AST/ManagerAction_IAXpeerlist
|
||
|
access: public
|
||
|
array iaxPeerList ()
|
||
|
|
||
|
-------------Interface AMI-------------
|
||
|
Action: IAXpeerlist
|
||
|
|
||
|
Response: Success
|
||
|
Message: IAX Peer status list will follow
|
||
|
|
||
|
Event: PeerEntry
|
||
|
Channeltype: IAX
|
||
|
ObjectName: demo
|
||
|
ObjectUsername: asterisk
|
||
|
ChanObjectType: peer
|
||
|
IPaddress: 216.207.245.47
|
||
|
Mask: 255.255.255.255
|
||
|
Port: 4569
|
||
|
Dynamic: No
|
||
|
Trunk: No
|
||
|
Encryption: No
|
||
|
Status: Unmonitored
|
||
|
|
||
|
Event: PeerEntry
|
||
|
Channeltype: IAX
|
||
|
ObjectName: eltercera
|
||
|
ChanObjectType: peer
|
||
|
IPaddress: (null)
|
||
|
Mask: 255.255.255.255
|
||
|
Port: 0
|
||
|
Dynamic: Yes
|
||
|
Trunk: No
|
||
|
Encryption: No
|
||
|
Status: Unmonitored
|
||
|
|
||
|
Event: PeerlistComplete
|
||
|
ListItems: 2
|
||
|
---------------------------------------
|
||
|
|
||
|
----------------Ejemplo----------------
|
||
|
include "phpAMI.php";
|
||
|
$ami=new phpAMI("admin","admin");
|
||
|
$login=$ami->login();
|
||
|
if($login["Response"]=="Success"){
|
||
|
print_r($ami->iaxPeerList());
|
||
|
$ami->logoff();
|
||
|
}
|
||
|
---------------------------------------
|
||
|
|
||
|
----------Respuesta de phpAMI----------
|
||
|
|
||
|
Array
|
||
|
(
|
||
|
[Response] => Success
|
||
|
[Message] => IAX Peer status list will follow
|
||
|
[List] => Array
|
||
|
(
|
||
|
[demo] => Array
|
||
|
(
|
||
|
[Event] => PeerEntry
|
||
|
[Channeltype] => IAX
|
||
|
[ObjectName] => demo
|
||
|
[ObjectUsername] => asterisk
|
||
|
[ChanObjectType] => peer
|
||
|
[IPaddress] => 216.207.245.47
|
||
|
[Mask] => 255.255.255.255
|
||
|
[Port] => 4569
|
||
|
[Dynamic] => No
|
||
|
[Trunk] => No
|
||
|
[Encryption] => No
|
||
|
[Status] => Unmonitored
|
||
|
)
|
||
|
|
||
|
[eltercera] => Array
|
||
|
(
|
||
|
[Event] => PeerEntry
|
||
|
[Channeltype] => IAX
|
||
|
[ObjectName] => eltercera
|
||
|
[ChanObjectType] => peer
|
||
|
[IPaddress] => (null)
|
||
|
[Mask] => 255.255.255.255
|
||
|
[Port] => 0
|
||
|
[Dynamic] => Yes
|
||
|
[Trunk] => No
|
||
|
[Encryption] => No
|
||
|
[Status] => Unmonitored
|
||
|
)
|
||
|
|
||
|
)
|
||
|
|
||
|
[ListInfo] => Array
|
||
|
(
|
||
|
[Event] => PeerlistComplete
|
||
|
[ListItems] => 2
|
||
|
)
|
||
|
|
||
|
)
|
||
|
---------------------------------------
|