I'll-Be-Back I'll-Be-Back - 4 years ago 140
PHP Question

Asterisk - which asterisk PHP library?

I am going to develop a call manager system website that will communicate with Asterisk server(s).

It will be developed in PHP, I have been googling around and I notice there are a few opensource asterisk PHP library like

phpagi


Would phpagi (or any other one do you recommend) allow me to do the following?


  1. Support inbound and outbound access.

  2. 80+ operators using the phone at the same time.

  3. Can create many groups of operators, for example: 30 sales operators (inbound & outbound) and 50 technical operators (inbound).

  4. Atomically record voice calls

  5. Connect and interoperate with ISDN lines



I understand I will have to install Asterisk server on Linux server and then do some configurations.

Answer Source

PHPAGI is certainly the "go-to" package for what you're looking to do. You'll likely want to build your own custom library on top of PHPAGI to give you higher level functionality for your particular needs.

If your PHP will reside on a different server than the Asterisk instance it is controlling, you'll want to specifically use php-fastagi. It implements the Asterisk FastAGI interface and makes it more accessible in PHP land:

FastAGI Reference: http://www.voip-info.org/wiki/view/Asterisk+FastAGI

PHP-FastAGI Reference: http://phpagi.sourceforge.net/phpagi22/api-docs/phpAGI/_phpagi-fastagi.php.html

To respond to your specific capacity requirements: you shouldn't have an issue. Stay away from server virtualization when it comes to the Asterisk server, and use moderately-capable server hardware, and you should be fine.

In the interest of not hammering the Asterisk instance with read-type fastagi commands, such as polling for extension statuses, you may want to consider a caching mechanism on the PHP side that polls on a regular interval and stores this information for any number of individual client/browser data requests.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download