/api/settings/get
获取配置信息。
需要系统配置查看权限
接口原型
协议 |
HTTP/HTTPS GET |
URL |
ip[:port]/api/settings/get |
数据格式 |
响应消息:Content-Type: application/json |
请求Cookies
名称 |
描述 |
mwcloud-sid |
用于标识当前登录的字符串 |
mwcloud-uid |
当前登录用户名 |
请求URL参数
无
请求示例
GET /api/settings/get
Accept: application/json, text/plain, */*
Content-Type: application/json;charset=utf-8
Content-Length: xx
Cookie: mwcloud-sid=OCXWUMGEYPGIAWWOETYXPNMVHDZIAZJP; mwcloud-uid=Admin;
响应参数
参数 |
描述 |
Content-Type |
取值为:'application/json; charset=UTF-8' |
Response Body
安全相关配置
参数 |
描述 |
enable-code |
是否启用邀请码 |
code-value |
邀请码 |
web服务相关配置
参数 |
描述 |
http-port |
http端口 |
enable-https |
是否启用https |
https-port |
https端口 |
is-cert-valid |
CA证书是否有效 |
is-cert-key-valid |
CA私钥是否有效 |
rtmp服务相关配置
srt服务相关配置
参数 |
描述 |
port |
端口 |
pb-key-len |
加密选项,获取配置将不返回密钥字段 |
加密选项
参数 |
描述 |
0 |
不加密 |
16 |
AES-128 |
24 |
AES-192 |
32 |
AES-256 |
响应示例
HTTP/1.1 200 OK
content-type: application/json; charset=utf-8
content-length: xx
{
"cert-key-path": "/data/cert/control-hub.pem",
"cert-path": "/data/cert/control-hub.crt",
"expired-time": 30,
"pwd-rule": {
"chk-name": 0,
"length": 0,
"number": 0,
"special": 0,
"uppercase": 0
},
"result": 0,
"rtmp": {
"port": 1935
},
"security": {
"code-value": "0165",
"enable-code": false
},
"srt": {
"passphrase": "1234567890",
"pb-key-len": 16,
"port": 80
},
"web": {
"enable-https": true,
"http-port": 80,
"https-port": 443,
"is-cert-key-valid": true,
"is-cert-valid": true
}
}