查询信令房间
更新时间: 2025/08/19 15:37:22
该接口支持根据频道名称查询频道房间信息。
调用频率
单个应用默认最高调用频率请参考 频控说明。
请求信息
请求 URL
httpsPOST https://api.yunxinapi.com/nimserver/signal/getRoomInfo.action HTTP/1.1
Content-Type: application/x-www-form-urlencoded;charset=utf-8
请求头参数
请求 Header 的参数说明请参考 请求 Header。
请求体参数
| 参数名称 | 类型 | 是否必选 | 描述 |
|---|---|---|---|
channelName |
String | 否 | 频道名称。channelName 与 channelId 至少填一个,否则报错。若两者都填,则优先取 channelId 的值。 |
channelId |
String | 否 | 频道 ID。 |
请求示例
curlcurl -X POST -H "AppKey: go9dnk49***w0803mgq3" -H "Nonce: 4tggge**23t23t" -H "CurTime: 1443592222" -H "CheckSum: 9e9db3b6c9abb**cc55583f86" -H "Content-Type: application/x-www-form-urlencoded" -d 'channelId=ch_87654321' 'https://api.yunxinapi.com/nimserver/signal/getRoomInfo.action'
响应示例
响应头参数
响应 Header 的参数说明请参考 响应 Header。
响应体参数
| 参数名称 | 类型 | 说明 |
|---|---|---|
code |
Integer | 状态码,200 表示请求成功。 |
-
data |
Object | 频道房间信息。 |
channelName |
String | 频道名称。 |
type |
String | 频道类型,AUDIO:音频;VEDIO:视频;CUSTOM:自定义。 |
channelId |
String | 频道 ID,服务器生成,确保唯一。 |
channelCreateTime |
Long | 频道创建时间。 |
channelExpireTime |
Long | 频道过期时间。 |
creator |
String | 频道创建者账号。 |
-
members |
Array of objects | 频道成员列表。 |
accid |
String | 成员账号 ID。 |
uid |
String | 服务器生成的成员 ID。 |
deviceId |
String | 成员设备 ID。 |
expireTime |
Long | 成员过期时间。 |
createTime |
Long | 成员加入时间。 |
ext |
String | 扩展字段。 |
响应体示例
JSON{
"code": 200,
"data": {
"channelName": "room-123",
"type": "VIDEO",
"channelId": "ch_87654321",
"channelCreateTime": 1685432800000,
"channelExpireTime": 1685439000000,
"creator": "user_abc123",
"ext": "ext",
"members": [
{
"accid": "user_abc123",
"uid": "uid_98765",
"deviceId": "device_24680",
"expireTime": 1685439000000,
"createTime": 1685432800000
},
{
"accid": "user_def456",
"uid": "uid_12345",
"deviceId": "device_13579",
"expireTime": 1685439000000,
"createTime": 1685432800000
}
]
}
}
错误码
完整错误码请参考 错误码。
此文档是否对你有帮助?




