编辑设备基本信息
POST
/api/device/modify
请求参数
Header 参数
Authentication
string
必需
示例值:
{{token}}
Body 参数application/json
name
string
名称
location
object
位置信息
address
string
地址
longitude
number
经度
latitude
number
纬度
id
string
必需
deptId
string
分组id
productModel
string
可选
示例
{
"id": "787d3d7093da4ad481a2fdd9324da879",
"name": "设备你好",
"deptId": "000000",
"location": {
"address": "",
"longitude": null,
"latitude": null
}
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'ssiot.cc/api/device/modify' \
--header 'Authentication: 在用户管理中创建或通过login接口获取' \
--header 'Authentication;' \
--header 'Content-Type: application/json' \
--data-raw '{
"id": "787d3d7093da4ad481a2fdd9324da879",
"name": "设备你好",
"deptId": "000000",
"location": {
"address": "",
"longitude": null,
"latitude": null
}
}'
返回响应
🟢200成功
application/json
Body
object {0}
示例
{}
修改于 2023-05-19 01:35:13