【发布时间】:2015-08-12 04:06:22
【问题描述】:
我们如何在 Freeswitch 中使用 xml_curl 动态更改 mod_callcenter 配置。
谁能给我一些php配置示例?
提前致谢。
【问题讨论】:
标签: php freeswitch
我们如何在 Freeswitch 中使用 xml_curl 动态更改 mod_callcenter 配置。
谁能给我一些php配置示例?
提前致谢。
【问题讨论】:
标签: php freeswitch
您可以配置 mod_xml_curl 以尝试从您的 xml api 中提取所有模块的配置数据:
<configuration name="xml_curl.conf" description="cURL XML Gateway">
<bindings>
<binding name="configuration">
<param name="gateway-url" value="http://example.com:8080/fsapi" bindings="configuration"/>
</binding>
</bindings>
</configuration>
您可以配置您的 PHP 脚本以转储 $_REQUEST 的内容,以查看为 mod_callcenter 提供的确切参数。
一旦您知道您正在使用哪些参数,您就可以使用与静态文件中相同的 XML 来响应请求。
如果您收到不是针对 mod_callcenter 的请求,您可以返回以下响应以使 FreeSwitch 从静态文件中读取:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="freeswitch/xml">
<section name="result">
<result status="not found"/>
</section>
</document>
【讨论】: