I need connect 2 users in asterisk. What best choise for this ?AGI or PAMI ?now i test PAGI and my extension.conf some like this
exten => 1,1,AGI(/var/tmp/quickstart/run.sh)
exten => 1,n,Hangup
and in main method i make test call ,like
$result = $client->dial("SIP/demo-alice");
if ($result->isAnswer()) {
$this->log("ANSWERIN");
$this->log($clid);
}
But dial in php script ,its blocking application. But dial from php script is blocking all script. And when a lot of connection happen, server will be overloaded. What is the best choice to connect 2 sip users?AGI or AMI?