POST /api/v0.0.1/trunklist/query?token={token}&type={type}
无参数,直接发送查询中继列表请求即可。
名称 | 类型 | 描述 |
trunklist | Object | 对象参数。 |
trunkname | Int | 中继名称。 |
type | String |
中继类型。
|
status | String |
SIP/IAX 中继状态。
|
port | String | 中继端口。 |
请求示例
POST /api/v0.0.1/trunklist/query?token=813b621cfe8eecf445a2ce1f4a079ffe&type=json HTTP/1.1
Content-Type:application/json; charset=utf-8
Host: 172.16.6.150
POST /api/v0.0.1/trunklist/query?token=813b621cfe8eecf445a2ce1f4a079ffe&type=xml HTTP/1.1
Content-Type:application/json; charset=utf-8
Host: 172.16.6.150
响应示例
HTTP/1.1 200 OK
Access-control-allow-origin: *
Access-control-allow-methods: GET, POST, OPTIONS, PUT, DELETE
{
"status": "Success",
"trunkname": [
{
"trunkname": "to-108-16",
"status": "Registered",
"type": "SIP"
},
{
"trunkname": "to-18-16-2",
"status": "Registered",
"type": "SIP"
}
]
}
HTTP/1.1 200 OK
Access-control-allow-origin: *
Access-control-allow-methods: GET, POST, OPTIONS, PUT, DELETE
<?xml version="1.0" encoding="utf-8"?>
<xml>
<status>Success</status>
<trunkname>
<item id="0">
<trunkname>to-18-16-2</trunkname>
<status>Registered</status>
<type>SIP</type>
</item>
</trunkname>
</xml>
Document generated by Confluence on 2023 十一月 13, 14:43