How to integrate Asterisk server with external relational database, like mysql?

南楼画角 提交于 2019-12-01 23:19:49

you can use ODBC on asterisk. even you can connect asterisk to Microsoft SQL Server. if you want to save log data on asterisk you can use CEL or CDR or you can recieve events by AMI. but if you want to force asterisk to do a special task (dynamic) it's better that use AGI. I hope it be helpful.

Asterisk can use MySQL or other database to store billing information, but for your task -- playing various vice files you should use AGI. AGI is very flexible because you can use various languages and libraries you want. I use Python for my AGI scripts but others use C, Perl, Java. You will find examples in those languages on Asterisk wiki: http://www.voip-info.org/wiki/view/Asterisk+AGI

Of course from your AGI program you can connect to database or use HTTP/SOAP/REST to integrate with other software.

No, you not need AGI script.

Most easy way is use of func_odbc(user defined sql functions via odbc) with dialplan.

btw, diallplan is full language like any other programming language. Anything can be done via dialplan only. But not all things effective and require alot of experience.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!