获取设备认证信息
通过客户端授权信息获取对应设备认证信息,包含设备归属、可信状态等
请求
| 项目 | 值 |
|---|---|
| HTTP URL | https://open.feishu.cn/open-apis/security_and_compliance/v2/device_records/mine |
| HTTP Method | GET |
| 接口频率限制 | 50 次/秒 |
| 支持的应用类型 | custom,isv |
| 权限要求 调用该 API 所需的权限。开启其中任意一项权限即可调用 | security_and_compliance:device_record:read 获取设备信息 |
请求头
| 名称 | 类型 | 必填 | 描述 |
|---|---|---|---|
| Authorization | string | 是 | user_access_token 值格式:"Bearer access_token" 示例值:"Bearer u-7f1bcd13fc57d46bac21793a18e560" 了解更多:如何选择与获取 access token |
响应
响应体
| 名称 | 类型 | 描述 |
|---|---|---|
code | int | 错误码,非 0 表示失败 |
msg | string | 错误描述 |
data | \- | - |
└ device_record_id | string | 设备认证编码 |
└ device_ownership | int | 设备归属 可选值有: - 0: 未知设备 - 1: 个人设备 - 2: 企业设备 |
└ device_status | int | 可信状态 可选值有: - 0: 未知状态 - 1: 信任设备 - 2: 非信任设备 |
响应体示例
json
{
"code": 0,
"msg": "success",
"data": {
"device_record_id": "7089353870308032531",
"device_ownership": 0,
"device_status": 0
}
}错误码
| HTTP状态码 | 错误码 | 描述 | 排查建议 |
|---|---|---|---|
| 500 | 1780001 | Internal server error. | 内部接口处理失败。若无法解决,请通过【飞书客服入口】寻求帮助,https://applink.larkoffice.com/TLJpeNdW |
| 400 | 1780101 | Request param error. | 检查参数是否正确 |
| 400 | 1780102 | The API is in beta testing. Please contact customer support to request beta access. | 请联系服务提供方排查,https://applink.larkoffice.com/TLJpeNdW |
| 400 | 1785011 | The current user identity has not completed device authentication. | 客户端未完成设备认证,建议提示用户重新登录或升级客户端至7.42及以上后重试 |
| 400 | 1785012 | The third-party device integration is not enabled. | 未开启允许三方应用获取客户端设备认证信息,请联系管理员前往 【飞书管理后台-安全-终端安全-设备管理-设备集成配置】进行配置 |
