Open Terumi opened 6 years ago
Hello @Terumi! Just use:
require_once './vendor/autoload.php';
$agi = new \Agi($yourConfigFileName);
//or $agi = new \Agi(null, $configArray);
//or $ami = new \AGI_AsteriskManager($yourConfigFileNam);
//or $ami = new \AGI_AsteriskManager(null, $configArray);
You can find configuration file example in phpagi/docs folder. If you want to use configuration array - parameters must have same names as in config file.
$configArray = [
'server'=>'hostname or ip of your asterisk server',
'port'=>5038, /*asterisk manager port, integer*/
'username'=>'your_asterisk_manager_username',
'secret'=>'your_asterisk_manager_password'
];
Hello people. I'm trying to use this project (having loaded through composer) but I cannot reference the classes properly as they do not have a namespace. I'm I doing something wrong?