获取项目下设备模型列表

GET /api/projects/$projectId/models

获取项目下设备模型列表

请求样例

GET /api/projects/a0e280c9-3b20-4c6e-99bd-be862133c7d2/models HTTP/1.1
Host: 60.205.223.53:8443
Authorization: Bearer xxx.xxxx.xxx
Cache-Control: no-cache

响应参数

参数名 类型 必填 描述 限制
result List<DeviceMode> 设备模型列表,DeviceMode参见创建设备模型章节

响应样例

{
    "returnCode": 0,
    "result": [
        {
            "createdBy": "admin@glodon.fei",
            "createdTime": 1507618002021,
            "tenantId": "b0d9addd-4221-4a7e-a49f-4615891d533f",
            "id": "e60cd356-7511-4cb0-9f2d-217e7732359a",
            "name": "测试模型",
            "description": "模型测试",
            "deviceType": "ROOT",
            "imageUrl": "http://private-iot-glodon.oss-cn-beijing.aliyuncs.com/system/model.png",
            "attributesMap": {...},
            "actionsMap": {...},
            "gatewayId": "mqtt",
            "metadata": {},
            "deleted": false
        },
        {
            "createdBy": "admin@glodon.fei",
            "updatedBy": "admin@glodon.fei",
            "createdTime": 1507771538285,
            "updatedTime": 1507771928903,
            "tenantId": "b0d9addd-4221-4a7e-a49f-4615891d533f",
            "id": "e26590c4-a260-4934-98c9-871592aa19c4",
            "name": "小黑板",
            "description": "esp8266-12f",
            "deviceType": "Light",
            "imageUrl": "http://private-iot-glodon.oss-cn-beijing.aliyuncs.com/system/model.png",
            "attributesMap": {...},
            "actionsMap": {...},
            "gatewayId": "mqtt",
            "metadata": {},
            "deleted": false
        }
    ]
}