添加资产到企业
POST
/eims/api/v2/admin/assets/devices
请求参数
Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token示例:
Authorization: Bearer ********************
Body 参数application/json
loginAccount
string | null
必需
identifierType==0 时,账号字段必现是以0开头的八位数字
identifierType==1 时,该字段置空
loginPassword
string | null
必需
identifierType==0 时,密码字段不能为空
identifierType==1 时,密码字段需要置空
type
enum<integer> | enum<null>
终端类型
枚举值:
11236745
identifierType
enum<integer> | enum<null>
必需
枚举值:
01
name
string | null
终端名称
<= 30 字符
remark
string
备注信息
<= 200 字符
groupId
string <int64>
所在分组id
audioGain
integer | null
必需
>= -20<= 20
serialNo
string
设备序列号
<= 64 字符
zoneId
string <int64>
服务区id
previewDevice
boolean
是否为预监设备
默认值:
false
示例
{
"loginAccount": "string",
"loginPassword": "string",
"type": 1,
"identifierType": 0,
"name": "string",
"remark": "string",
"groupId": "string",
"audioGain": -20,
"serialNo": "string",
"zoneId": "string",
"previewDevice": false
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST '/eims/api/v2/admin/assets/devices' \
--header 'Content-Type: application/json' \
--data-raw '{
"loginAccount": "string",
"loginPassword": "string",
"type": 1,
"identifierType": 0,
"name": "string",
"remark": "string",
"groupId": "string",
"audioGain": -20,
"serialNo": "string",
"zoneId": "string",
"previewDevice": false
}'
返回响应
🟢200成功
application/json
Body
loginAccount
string
可选
loginPassword
string
终端登录密码
id
string
资产id
companyId
string
企业id
type
enum<integer>
可选
枚举值:
11236745
identifierType
integer
可选
terminalNo
string
终端号
serialNo
string
设备序列号
name
string | null
终端名称
remark
string
备注信息
<= 200 字符
model
string
终端型号
status
integer
可选
默认值:
1
groupId
string <int64>
分组id
groupName
string
分组名称
avatar
string
设备头像
osType
string
可选
clientVersion
string
可选
platformType
string
可选
identifier
string
可选
onlineStatus
integer
可选
audioGain
integer
音频增益
registerIp
string
可选
zoneId
string <int64>
服务区id
zoneName
string
服务区名称
previewDevice
boolean
是否预监设备
默认值:
false
示例
{
"loginAccount": "",
"loginPassword": "",
"id": "",
"companyId": "",
"type": 0,
"identifierType": 0,
"terminalNo": "",
"serialNo": "",
"name": "",
"remark": "",
"model": "",
"status": 0,
"groupId": "",
"groupName": "",
"avatar": "",
"osType": "",
"clientVersion": "",
"platformType": "",
"identifier": "",
"onlineStatus": 0,
"audioGain": 0,
"registerIp": "",
"zoneId": "",
"zoneName": ""
}