{
    "schema": "devcap1.schema.json",
    "manufacturername": "innr",
    "modelid": "SP 120",
    "vendor": "innr",
    "product": "SP 120 smart plug",
    "sleeper": false,
    "status": "Gold",
    "path": "/devices/innr/sp_120.json",
    "subdevices": [
        {
            "type": "$TYPE_ON_OFF_PLUGIN_UNIT",
            "restapi": "/lights",
            "uuid": [
                "$address.ext",
                "0x01"
            ],
            "items": [
                {
                    "name": "attr/id"
                },
                {
                    "name": "attr/lastannounced"
                },
                {
                    "name": "attr/lastseen"
                },
                {
                    "name": "attr/manufacturername"
                },
                {
                    "name": "attr/modelid"
                },
                {
                    "name": "attr/name"
                },
                {
                    "name": "attr/swversion"
                },
                {
                    "name": "attr/type"
                },
                {
                    "name": "attr/uniqueid"
                },
                {
                    "name": "state/alert"
                },
                {
                    "name": "state/on",
                    "refresh.interval": 360
                },
                {
                    "name": "state/reachable"
                }
            ]
        },
        {
            "type": "$TYPE_CONSUMPTION_SENSOR",
            "restapi": "/sensors",
            "uuid": [
                "$address.ext",
                "0x01",
                "0x0702"
            ],
            "fingerprint": {
                "endpoint": "0x01",
                "profile": "0xc05e",
                "device": "0x0010",
                "in": [
                    "0x0006",
                    "0x0008",
                    "0x0702"
                ],
                "out": [
                    "0x0019"
                ]
            },
            "items": [
                {
                    "name": "attr/id"
                },
                {
                    "name": "attr/lastannounced"
                },
                {
                    "name": "attr/lastseen"
                },
                {
                    "name": "attr/manufacturername"
                },
                {
                    "name": "attr/modelid"
                },
                {
                    "name": "attr/name"
                },
                {
                    "name": "attr/swversion"
                },
                {
                    "name": "attr/type"
                },
                {
                    "name": "attr/uniqueid"
                },
                {
                    "name": "config/on"
                },
                {
                    "name": "config/reachable"
                },
                {
                    "name": "state/consumption",
                    "refresh.interval": 360,
                    "parse": {
                        "at": "0x0000",
                        "cl": "0x0702",
                        "ep": 1,
                        "eval": "Item.val = Attr.val * 10;"
                    }
                },
                {
                    "name": "state/lastupdated"
                }
            ]
        },
        {
            "type": "$TYPE_POWER_SENSOR",
            "restapi": "/sensors",
            "uuid": [
                "$address.ext",
                "0x01",
                "0x0b04"
            ],
            "fingerprint": {
                "endpoint": "0x01",
                "profile": "0xc05e",
                "device": "0x0010",
                "in": [
                    "0x0B04"
                ]
            },
            "items": [
                {
                    "name": "attr/id"
                },
                {
                    "name": "attr/lastannounced"
                },
                {
                    "name": "attr/lastseen"
                },
                {
                    "name": "attr/manufacturername"
                },
                {
                    "name": "attr/modelid"
                },
                {
                    "name": "attr/name"
                },
                {
                    "name": "attr/swversion"
                },
                {
                    "name": "attr/type"
                },
                {
                    "name": "attr/uniqueid"
                },
                {
                    "name": "config/on"
                },
                {
                    "name": "config/reachable"
                },
                {
                    "name": "state/current",
                    "refresh.interval": 360
                },
                {
                    "name": "state/lastupdated"
                },
                {
                    "name": "state/power",
                    "refresh.interval": 360
                },
                {
                    "name": "state/voltage",
                    "refresh.interval": 360
                }
            ]
        }
    ],
    "bindings": [
        {
            "bind": "unicast",
            "src.ep": 1,
            "cl": "0x0006",
            "report": [
                {
                    "at": "0x0000",
                    "dt": "0x10",
                    "min": 1,
                    "max": 300
                }
            ]
        },
        {
            "bind": "unicast",
            "src.ep": 1,
            "cl": "0x0702",
            "report": [
                {
                    "at": "0x0000",
                    "dt": "0x25",
                    "min": 1,
                    "max": 300,
                    "change": "0x0000000A"
                }
            ]
        },
        {
            "bind": "unicast",
            "src.ep": 1,
            "cl": "0x0B04",
            "report": [
                {
                    "at": "0x0505",
                    "dt": "0x21",
                    "min": 1,
                    "max": 300,
                    "change": "0x00000001"
                },
                {
                    "at": "0x0508",
                    "dt": "0x21",
                    "min": 1,
                    "max": 300,
                    "change": "0x00000064"
                },
                {
                    "at": "0x050B",
                    "dt": "0x29",
                    "min": 1,
                    "max": 300,
                    "change": "0x00000001"
                }
            ]
        }
    ]
}
