利用swagger2构建的API文档 (1.0)

Download OpenAPI specification:Download

用restful风格写接口

mqtt授权管理接口

Mqtt Auth Controller

添加用户ACL授权

query Parameters
access
string
Enum: "ALL" "PUBLISH" "SUBSCRIBE"
topics
Array of strings
username
string

Responses

用户ACL授权列表

query Parameters
username
string

用户名

Responses

修改用户ACL授权

query Parameters
access
string
Enum: "ALL" "PUBLISH" "SUBSCRIBE"
topics
Array of strings
username
string

Responses

删除ACL

path Parameters
username
required
string

username

Responses

添加用户认证

query Parameters
clientid
string
password
string
username
string

Responses

用户认证列表

query Parameters
username
required
string

username

Responses

修改用户认证

query Parameters
clientid
string
password
string
username
string

Responses

删除用户认证

path Parameters
username
required
string

username

Responses

添加用户SuperUser授权

query Parameters
clientid
string
password
string
username
string

Responses

产品审核对象功能接口

Product Approval Controller

新增评审

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

dto

company
string
productId
integer <int32>
reportUrl
string

Responses

Request samples

Content type
application/json
{
  • "company": "string",
  • "productId": 0,
  • "reportUrl": "string"
}

批量通过审批

query Parameters
ids
required
string

ids

header Parameters
tokenInfo
string

tokenInfo

Responses

批量驳回审批

query Parameters
ids
required
string

ids

rejectReason
required
string

rejectReason

header Parameters
tokenInfo
string

tokenInfo

Responses

撤销审批

path Parameters
productId
required
integer <int32>

productId

header Parameters
tokenInfo
string

tokenInfo

Responses

通过产品ID查询单条数据

path Parameters
productId
required
integer <int32>

productId

Responses

通过ID查询单条数据

path Parameters
id
required
integer <int32>

id

Responses

根据审批id获取产品审批详细信息

path Parameters
approvalId
required
integer <int32>

approvalId

msgNotificationId
required
integer <int32>

msgNotificationId

Responses

分页查询

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

dto

company
string
keyword
string

搜索条件

pageNo
integer <int32>

页码

pageSize
integer <int32>

页数

productStatus
integer <int32>
secondCategoryId
integer <int32>

Responses

Request samples

Content type
application/json
{
  • "company": "string",
  • "keyword": "string",
  • "pageNo": 0,
  • "pageSize": 0,
  • "productStatus": 0,
  • "secondCategoryId": 0
}

通过审批

path Parameters
id
required
integer <int32>

id

header Parameters
tokenInfo
string

tokenInfo

Responses

驳回审批

path Parameters
id
required
integer <int32>

id

query Parameters
rejectReason
required
string

rejectReason

header Parameters
tokenInfo
string

tokenInfo

Responses

重新提交评审

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

dto

id
integer <int32>
reportUrl
string

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "reportUrl": "string"
}

更新数据报告

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

产品接口

Product Controller

新增产品

Request Body schema: application/json

reqDto

appId
integer <int32>

接入平台: 1000,自研接入层配网,1001,美的接入层配网..其它

brand
string

品牌

categoryId
integer <int32>

设备类型ID

certType
integer <int32>

证书授权方式 1标准协议 2自定义协议

connectType
string

联网方式:1-wifi;2-BEL,3-以太网,4-Modbus,5-5G,6-4G,7-ZB,8-NBiot,9-LoRa

imageUrl
string

产品图标

initialize
integer <int32>

可实例化 0否 1是

isVirtual
integer <int32>

是否虚拟产品 0否 1是

modelNum
string

设备技术型号

name
string

产品名称

nodeType
integer <int32>

节点类型:1直连设备 2网关 3子设备

secondCategoryId
integer <int32>

设备二级类型ID

tenantId
integer <int32>
thirdCategoryId
integer <int32>

设备三级类型ID

thirdModelNum
string

第三方设备型号

Responses

Request samples

Content type
application/json
{
  • "appId": 0,
  • "brand": "string",
  • "categoryId": 0,
  • "certType": 0,
  • "connectType": "string",
  • "imageUrl": "string",
  • "initialize": 0,
  • "isVirtual": 0,
  • "modelNum": "string",
  • "name": "string",
  • "nodeType": 0,
  • "secondCategoryId": 0,
  • "tenantId": 0,
  • "thirdCategoryId": 0,
  • "thirdModelNum": "string"
}

获取品牌列表

Responses

新增品类

Request Body schema: application/json

reqDto

createMan
required
string

创建人

imageUrl
string

分类图标

name
required
string

分类名称

parentId
integer <int32>

父级id

Responses

Request samples

Content type
application/json
{
  • "createMan": "string",
  • "imageUrl": "string",
  • "name": "string",
  • "parentId": 0
}

品类名称重复校验,true为重复

Request Body schema: application/json

reqDto

id
integer <int32>
name
required
string

分类名称

parentId
integer <int32>

父级id

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "name": "string",
  • "parentId": 0
}

获取品类树结构

Request Body schema: application/json

body

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

编辑品类

path Parameters
id
required
integer <int32>

id

Request Body schema: application/json

reqDto

imageUrl
required
string

分类图标

name
required
string

分类名称

updateMan
required
string

编辑用户

Responses

Request samples

Content type
application/json
{
  • "imageUrl": "string",
  • "name": "string",
  • "updateMan": "string"
}

删除品类

path Parameters
id
required
integer <int32>

id

Responses

判断产品名称或者modelNum是否重复,true为重复

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

reqVo

id
integer <int32>

id,修改判重时传入

modelNum
string

产品id,name 和 modelNum二选其一

name
string

产品名称, name 和 modelNum二选其一

tenantId
integer <int32>

租户号

thirdModelNum
string

第三方设备型号

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "modelNum": "string",
  • "name": "string",
  • "tenantId": 0,
  • "thirdModelNum": "string"
}

获取根分类的子类列表

path Parameters
id
required
integer <int32>

id

Responses

获取根分类列表

Responses

获取根分类的子类列表

Request Body schema: application/json

requestBody

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

getReverseMap

Responses

dataRepair

query Parameters
productKey
string

productKey

Responses

开发产品

path Parameters
id
required
integer <int32>

id

Responses

禁用产品

path Parameters
id
required
integer <int32>

id

Responses

启用产品

path Parameters
id
required
integer <int32>

id

Responses

根据id查询产品信息

path Parameters
id
required
integer <int32>

id

Responses

根据productKey查询产品信息

path Parameters
productKey
required
string

productKey

Responses

根据productKey判断是否存在产品

path Parameters
productKey
required
string

productKey

tenantId
required
integer <int32>

tenantId

Responses

根据分类获取产品列表

path Parameters
classifyId
required
integer <int32>

classifyId

Responses

lua脚本启用开关修改

path Parameters
id
required
integer <int32>

id

Request Body schema: application/json

reqDto

luaSwitch
required
integer <int32>

lua脚本启用开关 0否 1是

Responses

Request samples

Content type
application/json
{
  • "luaSwitch": 0
}

产品分页

Request Body schema: application/json

reqDto

keyword
string

关键字

nodeTypeList
Array of integers <int32> [ items <int32 > ]

设备类型

pageNo
integer <int32>

页码

pageSize
integer <int32>

页数

publishStatus
integer <int32>

发布状态:1未发布,2已发布

secondCategoryIdList
Array of integers <int32> [ items <int32 > ]

产品品类

standard
integer <int32>

标准化 0否 1是

Responses

Request samples

Content type
application/json
{
  • "keyword": "string",
  • "nodeTypeList": [
    ],
  • "pageNo": 0,
  • "pageSize": 0,
  • "publishStatus": 0,
  • "secondCategoryIdList": [
    ],
  • "standard": 0
}

获取平台列表

Responses

发布产品

path Parameters
id
required
integer <int32>

id

Responses

根据产品ID删除产品

path Parameters
id
required
integer <int64>

id

Responses

根据productKey删除产品

path Parameters
productKey
required
string

productKey

Responses

修改产品标准化状态

Request Body schema: application/json

reqDto

id
required
integer <int32>

产品id

standard
required
integer <int32>

标准化:0移除标准化库,1移入标准化库

Responses

Request samples

Content type
application/json
{
  • "id": 0,
  • "standard": 0
}

物模型启用状态修改

path Parameters
id
required
integer <int32>

id

Request Body schema: application/json

reqDto

tdSwitch
required
integer <int32>

物模型启用开关 0否 1是

Responses

Request samples

Content type
application/json
{
  • "tdSwitch": 0
}

更新产品

Request Body schema: application/json

reqDto

appId
integer <int32>

接入平台: 1000,自研接入层配网,1001,美的接入层配网..其它

brand
string

品牌

categoryId
integer <int32>

设备类型ID

certType
integer <int32>

证书授权方式 1标准协议 2自定义协议

connectType
string

联网方式:1-wifi;2-BEL,3-以太网,4-Modbus,5-5G,6-4G,7-ZB,8-NBiot,9-LoRa

id
integer <int32>

主键ID

imageUrl
string

产品图标

initialize
integer <int32>

可实例化 0否 1是

isVirtual
integer <int32>

是否虚拟产品 0否 1是

modelNum
string

设备技术型号

name
string

产品名称

nodeType
integer <int32>

节点类型:1直连设备 2网关 3子设备

secondCategoryId
integer <int32>

设备二级类型ID

tenantId
integer <int32>
thirdCategoryId
integer <int32>

设备三级类型ID

thirdModelNum
string

第三方设备型号

Responses

Request samples

Content type
application/json
{
  • "appId": 0,
  • "brand": "string",
  • "categoryId": 0,
  • "certType": 0,
  • "connectType": "string",
  • "id": 0,
  • "imageUrl": "string",
  • "initialize": 0,
  • "isVirtual": 0,
  • "modelNum": "string",
  • "name": "string",
  • "nodeType": 0,
  • "secondCategoryId": 0,
  • "tenantId": 0,
  • "thirdCategoryId": 0,
  • "thirdModelNum": "string"
}

应用授权管理

Sys App Tenant Controller

新增应用授权

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysAppTenantAddReq

appName
string

应用名称

appUrl
string

应用地址

describes
string

描述

icon
string

应用图标

publish
string

是否公用

state
integer <int32>

状态

type
string

应用类型

version
string

应用版本

Responses

Request samples

Content type
application/json
{
  • "appName": "string",
  • "appUrl": "string",
  • "describes": "string",
  • "icon": "string",
  • "publish": "string",
  • "state": 0,
  • "type": "string",
  • "version": "string"
}

查询

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

列表

header Parameters
tokenInfo
string

tokenInfo

Responses

分页

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

pulsar认证应用授权接入

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysAppTenantAuthReq

appKey
string

应用Key

sign
string

摘要签名

timestamp
string

时间戳

Responses

Request samples

Content type
application/json
{
  • "appKey": "string",
  • "sign": "string",
  • "timestamp": "string"
}

删除应用授权

path Parameters
appTenantId
required
string

appTenantId

header Parameters
tokenInfo
string

tokenInfo

Responses

应用管理接口

Sys Application Controller

新增应用

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

applicationAddReq

appName
string

应用名称

appUrl
string

应用地址

describes
string

描述

icon
string

应用图标

publish
string

是否公用

state
integer <int32>

状态

type
string

应用类型

version
string

应用版本

Responses

Request samples

Content type
application/json
{
  • "appName": "string",
  • "appUrl": "string",
  • "describes": "string",
  • "icon": "string",
  • "publish": "string",
  • "state": 0,
  • "type": "string",
  • "version": "string"
}

查询

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

列表

header Parameters
tokenInfo
string

tokenInfo

Responses

分页

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

删除应用

path Parameters
id
required
integer <int32>

id

header Parameters
tokenInfo
string

tokenInfo

Responses

更新应用

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysApplicationUpdateReq

appId
string

应用ID

appName
string

应用名称

appUrl
string

应用地址

describes
string

描述

icon
string

应用图标

state
integer <int32>

状态

version
string

应用版本

Responses

Request samples

Content type
application/json
{
  • "appId": "string",
  • "appName": "string",
  • "appUrl": "string",
  • "describes": "string",
  • "icon": "string",
  • "state": 0,
  • "version": "string"
}

报表接口

Report Controller

查询统计数量接口

header Parameters
tokenInfo
string

tokenInfo

Responses

设备激活趋势

query Parameters
周期
required
integer <int32>

cycleDay

header Parameters
tokenInfo
string

tokenInfo

Responses

设备类型统计

header Parameters
tokenInfo
string

tokenInfo

Responses

产品分类排行

header Parameters
tokenInfo
string

tokenInfo

Responses

授权接口

Account Controller

用户登录

Request Body schema: application/json

dto

password
string
username
string

Responses

Request samples

Content type
application/json
{
  • "password": "string",
  • "username": "string"
}

Token校验

header Parameters
Authorization
required
string

Authorization

Responses

消息中心接口

Msg Notification Controller

读取未读消息

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

msgNotificationCountReq

tenantId
integer <int64>

企业ID

Responses

Request samples

Content type
application/json
{
  • "tenantId": 0
}

消息中心分页查询

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

msgNotificationPageReq

msgType
Array of strings

消息类型

pageNo
integer <int32>

页码

pageSize
integer <int32>

页数

Responses

Request samples

Content type
application/json
{
  • "msgType": [
    ],
  • "pageNo": 0,
  • "pageSize": 0
}

标记消息为已读

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

msgNotificationReadReq

msgNotificationIds
Array of integers <int64> [ items <int64 > ]

通知消息ID

Responses

Request samples

Content type
application/json
{
  • "msgNotificationIds": [
    ]
}

新增通知消息

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

msgNotificationSaveReq

businessId
string

业务id(产品id)

businessRejectReason
string

业务驳回原因

businessRejectState
string

业务驳回状态

businessUserId
string

业务申请人id

description
string

详细描述

messageName
string

消息简述

messageType
string

消息类型audit 审核,update 更新说明,activity活动通知,other 其他

productName
string

产品名称

tenantId
integer <int32>

企业id

Responses

Request samples

Content type
application/json
{
  • "businessId": "string",
  • "businessRejectReason": "string",
  • "businessRejectState": "string",
  • "businessUserId": "string",
  • "description": "string",
  • "messageName": "string",
  • "messageType": "string",
  • "productName": "string",
  • "tenantId": 0
}

消息通信接口

Mq Rule Controller

新增消息通信配置

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

mqRuleAddReq

bridgeType
string

通信类型MQ,DB

name
string

topic名称

productType
string

产品ID

pushType
string

消息中间件类型 PULSAR,KAFKA,ROCKETMQ,MYSQL

tenantId
integer <int32>

租户ID

thingId
string

设备MAC

topic
string

topic

type
string

Topic类型

Responses

Request samples

Content type
application/json
{
  • "bridgeType": "string",
  • "name": "string",
  • "productType": "string",
  • "pushType": "string",
  • "tenantId": 0,
  • "thingId": "string",
  • "topic": "string",
  • "type": "string"
}

新增命名空间

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

ruleJson

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

新增租户

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

ruleJson

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

发布消息通信规则

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

mqRulePublishReq

ruleId
integer <int32>

消息通信规则ID

Responses

Request samples

Content type
application/json
{
  • "ruleId": 0
}

系统按钮接口

Sys Menu Btn Controller

新增按钮

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuBtnAddReq

apiUrl
string

请求URL

btnCode
string

按钮编码

btnName
string

按钮名称

btnType
string

按钮编码

menuId
string

菜单

Responses

Request samples

Content type
application/json
{
  • "apiUrl": "string",
  • "btnCode": "string",
  • "btnName": "string",
  • "btnType": "string",
  • "menuId": "string"
}

查询按钮

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

删除按钮

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuBtnDeleteReq

id
integer <int32>

按钮ID

Responses

Request samples

Content type
application/json
{
  • "id": 0
}

更新菜单

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuBtnUpdateReq

apiUrl
string

请求URL

btnCode
string

按钮编码

btnName
string

按钮名称

btnType
string

按钮编码

menuId
string

菜单

Responses

Request samples

Content type
application/json
{
  • "apiUrl": "string",
  • "btnCode": "string",
  • "btnName": "string",
  • "btnType": "string",
  • "menuId": "string"
}

系统菜单接口

Sys Menu Controller

新增菜单

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuAddReq

appId
integer <int32>

应用ID

code
string

菜单编码

component
string

菜单路由

icon
string

菜单图标

identifier
string

菜单唯一标志

name
string

菜单名称

parentId
integer <int32>

父菜单path

path
string

菜单path

redirect
string

重定向URL

sort
integer <int32>

菜单排序

state
integer <int32>

菜单状态

Responses

Request samples

Content type
application/json
{
  • "appId": 0,
  • "code": "string",
  • "component": "string",
  • "icon": "string",
  • "identifier": "string",
  • "name": "string",
  • "parentId": 0,
  • "path": "string",
  • "redirect": "string",
  • "sort": 0,
  • "state": 0
}

查询菜单

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

获取所有菜单树

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuAllReq

appId
integer <int32>

应用ID(0为读取全部)

Responses

Request samples

Content type
application/json
{
  • "appId": 0
}

获取个人拥有菜单树

header Parameters
tokenInfo
string

tokenInfo

Responses

删除菜单

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuDeleteReq

appId
integer <int32>

应用ID

code
string

菜单编码

component
string

菜单路由

icon
string

菜单图标

identifier
string

菜单唯一标志

name
string

菜单名称

parentId
integer <int32>

父菜单path

path
string

菜单path

redirect
string

重定向URL

sort
integer <int32>

菜单排序

state
integer <int32>

菜单状态

Responses

Request samples

Content type
application/json
{
  • "appId": 0,
  • "code": "string",
  • "component": "string",
  • "icon": "string",
  • "identifier": "string",
  • "name": "string",
  • "parentId": 0,
  • "path": "string",
  • "redirect": "string",
  • "sort": 0,
  • "state": 0
}

更新菜单

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysMenuUpdateReq

appId
integer <int32>

应用ID

code
string

菜单编码

component
string

菜单路由

icon
string

菜单图标

identifier
string

菜单唯一标志

name
string

菜单名称

parentId
integer <int32>

父菜单path

path
string

菜单path

redirect
string

重定向URL

sort
integer <int32>

菜单排序

state
integer <int32>

菜单状态

Responses

Request samples

Content type
application/json
{
  • "appId": 0,
  • "code": "string",
  • "component": "string",
  • "icon": "string",
  • "identifier": "string",
  • "name": "string",
  • "parentId": 0,
  • "path": "string",
  • "redirect": "string",
  • "sort": 0,
  • "state": 0
}

系统角色接口

Sys Role Controller

新增角色

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

roleAddDto

description
string

描述

roleName
string

角色名称

roleType
string

角色类型

tenantId
string

租户ID

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "roleName": "string",
  • "roleType": "string",
  • "tenantId": "string"
}

授权角色按钮

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleMenuBtnAuthReq

btnIds
Array of integers <int32> [ items <int32 > ]

授权按钮

roleId
integer <int32>

角色ID

tenantId
integer <int32>

租户ID

Responses

Request samples

Content type
application/json
{
  • "btnIds": [
    ],
  • "roleId": 0,
  • "tenantId": 0
}

授权角色菜单

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleMenuAuthReq

menuIds
Array of integers <int32> [ items <int32 > ]

授权菜单

roleId
integer <int32>

角色ID

tenantId
integer <int32>

租户ID

Responses

Request samples

Content type
application/json
{
  • "menuIds": [
    ],
  • "roleId": 0,
  • "tenantId": 0
}

授权角色用户

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleUserDto

roleId
string

角色ID

tenantId
integer <int32>

租户ID

userIds
Array of strings

授权用户ID

Responses

Request samples

Content type
application/json
{
  • "roleId": "string",
  • "tenantId": 0,
  • "userIds": [
    ]
}

查询

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

获取租户拥有角色

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

tenantOwnerRolesDto

tenantId
integer <int64>

租户ID

Responses

Request samples

Content type
application/json
{
  • "tenantId": 0
}

获取用户拥有角色

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

userOwnerRolesDto

tenantId
integer <int64>

租户ID

userIds
Array of integers <int64> [ items <int64 > ]

查询用户id

Responses

Request samples

Content type
application/json
{
  • "tenantId": 0,
  • "userIds": [
    ]
}

获取用户拥有角色多企业集合

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

userOwnerRolesForTenantResp

tenantIds
Array of integers <int64> [ items <int64 > ]

租户ID

userId
integer <int64>

用户id

Responses

Request samples

Content type
application/json
{
  • "tenantIds": [
    ],
  • "userId": 0
}

企业初始化

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleInitTenantDto

tenantId
integer <int64>

租户ID

userId
integer <int64>

用户ID

Responses

Request samples

Content type
application/json
{
  • "tenantId": 0,
  • "userId": 0
}

列表

header Parameters
tokenInfo
string

tokenInfo

Responses

分页

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

删除角色

path Parameters
id
required
integer <int32>

id

header Parameters
tokenInfo
string

tokenInfo

Responses

移除角色用户

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleUserRemoveDto

roleId
string

角色ID

tenantId
integer <int32>

租户ID

userIds
Array of strings

授权用户ID

Responses

Request samples

Content type
application/json
{
  • "roleId": "string",
  • "tenantId": 0,
  • "userIds": [
    ]
}

更新角色

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleUpdateDto

description
string

描述

id
integer <int32>

主键ID

roleName
string

角色名称

roleType
string

角色类型

tenantId
string

租户ID

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "id": 0,
  • "roleName": "string",
  • "roleType": "string",
  • "tenantId": "string"
}

更新角色用户

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleUserUpdateDto

roleId
string

角色ID

tenantId
integer <int32>

租户ID

userIds
Array of strings

授权用户ID

Responses

Request samples

Content type
application/json
{
  • "roleId": "string",
  • "tenantId": 0,
  • "userIds": [
    ]
}

设备接口

Device Controller

新增

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

entity

activateStatus
boolean

激活状态 0否 1是

activateTime
string <date-time>

激活时间

appId
integer <int32>

接入平台: 1000,自研接入层配网,1001,美的接入层配网..其它,从产品表中关联过来

categoryId
integer <int32>

品类ID,需要建一张表来维护品类

channelId
string

通道ID,对应设备的mqtt clientId

clientId
string

原产品表关联过来的字段,保留

createdBy
string

创建人

createdTime
string <date-time>

创建时间

customCategory
string

所属系统的字典

des
string

设备描述

devModel
string

设备技术型号,从产品表中关联过来

deviceCode
string

置业内部设备编码

deviceSecret
string

设备密钥,用于签名验签--保留

deviceType
integer <int32>

设备上云类型:1直连设备 2网关 3子设备,从产品表同步

deviceVer
string

设备版本

enable
boolean

是否启用 0否 1是

hardwareVer
string

硬件版本

id
integer <int64>

主键id

identifier
string

设备的mac地址,如果是第三方的设备,就是第三方唯一标识符

isOnline
boolean

在线状态 0离线 1在线

isRemoved
boolean

逻辑删除 0否 1是;

lastOfflineTime
string <date-time>

最后离线时间

lastOnlineTime
string <date-time>

最后在线时间

masterCode
string

父级设备编码

modelNum
string

设备型号--同dev_model,重复字段,保留

name
string

设备名

productKey
string

产品Key,跟表关联

productTenantId
integer <int64>

产品租户id,从产品表关联过来

protocol
integer <int32>

协议类型: 0 无联网功能 1.wifi设备、2.LORA 3.NB-IOT, 4.2G ,5 3G,6,4G,7 5G

protocolType
string

协议类型: 16位的字符串,标识设备的能力集,每一位表示一种能力,拥有为1,没有为0.

registerTime
string <date-time>

注册时间

sn
string

设备的SN标识,绝大部分时候跟identifier相同,部分时候不相同

tenantId
integer <int64>

租户id, 运营者租户ID

updatedBy
string

更新人

updatedTime
string <date-time>

更新时间

Responses

Request samples

Content type
application/json
{
  • "activateStatus": true,
  • "activateTime": "2019-08-24T14:15:22Z",
  • "appId": 0,
  • "categoryId": 0,
  • "channelId": "string",
  • "clientId": "string",
  • "createdBy": "string",
  • "createdTime": "2019-08-24T14:15:22Z",
  • "customCategory": "string",
  • "des": "string",
  • "devModel": "string",
  • "deviceCode": "string",
  • "deviceSecret": "string",
  • "deviceType": 0,
  • "deviceVer": "string",
  • "enable": true,
  • "hardwareVer": "string",
  • "id": 0,
  • "identifier": "string",
  • "isOnline": true,
  • "isRemoved": true,
  • "lastOfflineTime": "2019-08-24T14:15:22Z",
  • "lastOnlineTime": "2019-08-24T14:15:22Z",
  • "masterCode": "string",
  • "modelNum": "string",
  • "name": "string",
  • "productKey": "string",
  • "productTenantId": 0,
  • "protocol": 0,
  • "protocolType": "string",
  • "registerTime": "2019-08-24T14:15:22Z",
  • "sn": "string",
  • "tenantId": 0,
  • "updatedBy": "string",
  • "updatedTime": "2019-08-24T14:15:22Z"
}

设备详情

Request Body schema: application/json

reqDto

deviceCode
string

内部设备编码

Responses

Request samples

Content type
application/json
{
  • "deviceCode": "string"
}

导出设备

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

查询

path Parameters
deviceId
required
string

deviceId

header Parameters
tokenInfo
string

tokenInfo

Responses

导入设备

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/x-www-form-urlencoded
file
string <binary>

Responses

设备日志

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

reqDto

deviceCode
string
endTime
string <date-time>

操作结束时间

keyword
string

查询字段

pageNo
integer <int32>

页码

pageSize
integer <int32>

页数

startTime
string <date-time>

操作开始时间

Responses

Request samples

Content type
application/json
{
  • "deviceCode": "string",
  • "endTime": "2019-08-24T14:15:22Z",
  • "keyword": "string",
  • "pageNo": 0,
  • "pageSize": 0,
  • "startTime": "2019-08-24T14:15:22Z"
}

分页

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

reqDto

activateEndTime
string <date-time>

激活结束时间

activateStartTime
string <date-time>

激活开始时间

endTime
string <date-time>

创建结束时间

isOnline
integer <int32>

在线状态 0离线 1在线

keyword
string

设备名称/设备SN码

pageNo
integer <int32>

页码

pageSize
integer <int32>

页数

startTime
string <date-time>

创建开始时间

Responses

Request samples

Content type
application/json
{
  • "activateEndTime": "2019-08-24T14:15:22Z",
  • "activateStartTime": "2019-08-24T14:15:22Z",
  • "endTime": "2019-08-24T14:15:22Z",
  • "isOnline": 0,
  • "keyword": "string",
  • "pageNo": 0,
  • "pageSize": 0,
  • "startTime": "2019-08-24T14:15:22Z"
}

删除

path Parameters
id
required
integer <int64>

id

header Parameters
tokenInfo
string

tokenInfo

Responses

更新

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

entity

activateStatus
boolean

激活状态 0否 1是

activateTime
string <date-time>

激活时间

appId
integer <int32>

接入平台: 1000,自研接入层配网,1001,美的接入层配网..其它,从产品表中关联过来

categoryId
integer <int32>

品类ID,需要建一张表来维护品类

channelId
string

通道ID,对应设备的mqtt clientId

clientId
string

原产品表关联过来的字段,保留

createdBy
string

创建人

createdTime
string <date-time>

创建时间

customCategory
string

所属系统的字典

des
string

设备描述

devModel
string

设备技术型号,从产品表中关联过来

deviceCode
string

置业内部设备编码

deviceSecret
string

设备密钥,用于签名验签--保留

deviceType
integer <int32>

设备上云类型:1直连设备 2网关 3子设备,从产品表同步

deviceVer
string

设备版本

enable
boolean

是否启用 0否 1是

hardwareVer
string

硬件版本

id
integer <int64>

主键id

identifier
string

设备的mac地址,如果是第三方的设备,就是第三方唯一标识符

isOnline
boolean

在线状态 0离线 1在线

isRemoved
boolean

逻辑删除 0否 1是;

lastOfflineTime
string <date-time>

最后离线时间

lastOnlineTime
string <date-time>

最后在线时间

masterCode
string

父级设备编码

modelNum
string

设备型号--同dev_model,重复字段,保留

name
string

设备名

productKey
string

产品Key,跟表关联

productTenantId
integer <int64>

产品租户id,从产品表关联过来

protocol
integer <int32>

协议类型: 0 无联网功能 1.wifi设备、2.LORA 3.NB-IOT, 4.2G ,5 3G,6,4G,7 5G

protocolType
string

协议类型: 16位的字符串,标识设备的能力集,每一位表示一种能力,拥有为1,没有为0.

registerTime
string <date-time>

注册时间

sn
string

设备的SN标识,绝大部分时候跟identifier相同,部分时候不相同

tenantId
integer <int64>

租户id, 运营者租户ID

updatedBy
string

更新人

updatedTime
string <date-time>

更新时间

Responses

Request samples

Content type
application/json
{
  • "activateStatus": true,
  • "activateTime": "2019-08-24T14:15:22Z",
  • "appId": 0,
  • "categoryId": 0,
  • "channelId": "string",
  • "clientId": "string",
  • "createdBy": "string",
  • "createdTime": "2019-08-24T14:15:22Z",
  • "customCategory": "string",
  • "des": "string",
  • "devModel": "string",
  • "deviceCode": "string",
  • "deviceSecret": "string",
  • "deviceType": 0,
  • "deviceVer": "string",
  • "enable": true,
  • "hardwareVer": "string",
  • "id": 0,
  • "identifier": "string",
  • "isOnline": true,
  • "isRemoved": true,
  • "lastOfflineTime": "2019-08-24T14:15:22Z",
  • "lastOnlineTime": "2019-08-24T14:15:22Z",
  • "masterCode": "string",
  • "modelNum": "string",
  • "name": "string",
  • "productKey": "string",
  • "productTenantId": 0,
  • "protocol": 0,
  • "protocolType": "string",
  • "registerTime": "2019-08-24T14:15:22Z",
  • "sn": "string",
  • "tenantId": 0,
  • "updatedBy": "string",
  • "updatedTime": "2019-08-24T14:15:22Z"
}

设备注册接口

Device Register Controller

直连设备的HTTPS动态注册

Request Body schema: application/json

dto

deviceName
string

设备SN码

productKey
string

产品ID

random
string

随机数

sign
string

签名

signMethod
string

签名方法,目前支持hmacmd5、hmacsha1、hmacsha256

Responses

Request samples

Content type
application/json
{
  • "deviceName": "string",
  • "productKey": "string",
  • "random": "string",
  • "sign": "string",
  • "signMethod": "string"
}

设备证书接口

Device Cert Controller

新增

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

entity

deviceName
string

设备名

deviceSecret
string

设备密钥

id
integer <int64>

主键ID

mqttClientId
string

设备密钥

mqttPassword
string

设备密钥

mqttUserName
string

设备密钥

productKey
string

产品ID

Responses

Request samples

Content type
application/json
{
  • "deviceName": "string",
  • "deviceSecret": "string",
  • "id": 0,
  • "mqttClientId": "string",
  • "mqttPassword": "string",
  • "mqttUserName": "string",
  • "productKey": "string"
}

查询

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

列表

header Parameters
tokenInfo
string

tokenInfo

Responses

分页

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

删除

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

更新

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

entity

deviceName
string

设备名

deviceSecret
string

设备密钥

id
integer <int64>

主键ID

mqttClientId
string

设备密钥

mqttPassword
string

设备密钥

mqttUserName
string

设备密钥

productKey
string

产品ID

Responses

Request samples

Content type
application/json
{
  • "deviceName": "string",
  • "deviceSecret": "string",
  • "id": 0,
  • "mqttClientId": "string",
  • "mqttPassword": "string",
  • "mqttUserName": "string",
  • "productKey": "string"
}

默认系统角色接口

Sys Role Default Controller

新增默认角色

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

roleDefaultAddDto

description
string

描述

roleName
string

角色名称

roleType
string

角色类型

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "roleName": "string",
  • "roleType": "string"
}

授权默认角色按钮

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleMenuBtnAuthReq

btnIds
Array of integers <int32> [ items <int32 > ]

授权按钮

roleId
integer <int32>

角色ID

Responses

Request samples

Content type
application/json
{
  • "btnIds": [
    ],
  • "roleId": 0
}

授权默认角色菜单

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleMenuDefaultAuthReq

menuIds
Array of integers <int32> [ items <int32 > ]

授权菜单

roleId
integer <int32>

角色ID

Responses

Request samples

Content type
application/json
{
  • "menuIds": [
    ],
  • "roleId": 0
}

查询

path Parameters
id
required
string

id

header Parameters
tokenInfo
string

tokenInfo

Responses

列表

header Parameters
tokenInfo
string

tokenInfo

Responses

分页

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

jsonObject

property name*
additional property
object

Responses

Request samples

Content type
application/json
{
  • "property1": { },
  • "property2": { }
}

删除默认角色

path Parameters
id
required
integer <int32>

id

header Parameters
tokenInfo
string

tokenInfo

Responses

更新默认角色

header Parameters
tokenInfo
string

tokenInfo

Request Body schema: application/json

sysRoleDefaultUpdateDto

description
string

描述

id
integer <int32>

主键ID

roleName
string

角色名称

roleType
string

角色类型

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "id": 0,
  • "roleName": "string",
  • "roleType": "string"
}