支持给网关指定变量,设置网关的语音编码编码和主叫号码。网关配置编辑后,不能实时生效 ,需要执行sofia命令才可以生效,具体看SIP设置。有关系统方面问题请找博主,看他名字和他一起技术交流学习
cti_gateway@domain
{
"param": {
"register": "true",
"caller-id-in-from": "true",
"realm": "180.76.224.191:35560",
"from-user": "",
"destination-prefix": "",
"username": "mytrunk",
"password": "mytrunk@ddt"
},
"variables": {
"sip_sticky_contact": "true"
}
}
|

cti.json
"gui": {
/*网关信息推送到redis*/
"gateway": {
"hash": "gateways",
"channel": "",
"list": ""
}
}
`
|
网关注册信息会记录到哈希表gateways
key:网关名字
value:注册信息
没勾选注册的
{
"Event-Name": "CUSTOM",
"Core-UUID": "651a086c-4d20-4749-96a4-3eb2cb866ec3",
"FreeSWITCH-Hostname": "ai",
"FreeSWITCH-Switchname": "ai",
"FreeSWITCH-IPv4": "192.168.31.57",
"FreeSWITCH-IPv6": "::1",
"Event-Date-Local": "2022-04-07 23:19:29",
"Event-Date-GMT": "Thu, 07 Apr 2022 15:19:29 GMT",
"Event-Date-Timestamp": "1649344769167507",
"Event-Calling-File": "sofia_reg.c",
"Event-Calling-Function": "sofia_reg_add_gateway",
"Event-Calling-Line-Number": "3740",
"Event-Sequence": "92",
"Event-Subclass": "sofia::gateway_add",
"Gateway": "default",
"profile-name": "external"
}
`
|
注册成功的
{
"Event-Name": "CUSTOM",
"Core-UUID": "651a086c-4d20-4749-96a4-3eb2cb866ec3",
"FreeSWITCH-Hostname": "ai",
"FreeSWITCH-Switchname": "ai",
"FreeSWITCH-IPv4": "192.168.31.57",
"FreeSWITCH-IPv6": "::1",
"Event-Date-Local": "2022-04-07 23:23:11",
"Event-Date-GMT": "Thu, 07 Apr 2022 15:23:11 GMT",
"Event-Date-Timestamp": "1649344991284944",
"Event-Calling-File": "sofia_reg.c",
"Event-Calling-Function": "sofia_reg_fire_custom_gateway_state_event",
"Event-Calling-Line-Number": "156",
"Event-Sequence": "680",
"Event-Subclass": "sofia::gateway_state",
"Gateway": "default",
"State": "REGED",
"Ping-Status": "UP",
"Register-Network-IP": "49.235.127.246",
"Register-Network-Port": "39468"
}
`
|