Security System Capability

I created a new device handler from the Security System template which seems to provide a nice toggle for an alarm system. I am creating an integration for the popular DIY DSC alarms utilizing the Envisalink IP interfaces. I have everything working with a Switch capability but I was very interested in this undocumented Security System Capability. Does anyone have an example or any documentation on this capability?

I’ve had a little play with that. As there is also a ‘dead’ capability named Alarm System which matches the known attributes and commands for working with the Smart Home Monitor, I rather assumed Security System might be intended for SmartThings Home Monitor, and my limited experiments certainly suggest it doesn’t really have any broader utility at the moment. I guess perhaps we aren’t really supposed to have noticed it.

There are various, as yet undocumented, security things starting to appear on the radar, like the r:security:locations:*:armstate scope for tokens, and the SECURITY_ARM_STATE subscription type.

Update: In case anyone was wondering …

{
    "id": "alarmSystem",
    "version": 1,
    "status": "dead",
    "name": "Alarm System",
    "attributes": {
        "alarmSystemStatus": {
            "schema": {
                "type": "object",
                "properties": {
                    "value": {
                        "title": "AlarmSystemState",
                        "type": "string",
                        "enum": [
                            "away",
                            "off",
                            "stay"
                        ]
                    }
                },
                "additionalProperties": false,
                "required": [
                    "value"
                ]
            },
            "enumCommands": [
                {
                    "command": "sendEvent(alarmSystemStatus,off)",
                    "value": "off"
                },
                {
                    "command": "sendEvent(alarmSystemStatus,stay)",
                    "value": "stay"
                },
                {
                    "command": "sendEvent(alarmSystemStatus,away)",
                    "value": "away"
                }
            ]
        }
    },
    "commands": {
        "sendEvent(alarmSystemStatus,off)": {
            "arguments": []
        },
        "sendEvent(alarmSystemStatus,stay)": {
            "arguments": []
        },
        "sendEvent(alarmSystemStatus,away)": {
            "arguments": []
        }
    }
}
{
    "id": "securitySystem",
    "version": 1,
    "status": "live",
    "name": "Security System",
    "attributes": {
        "securitySystemStatus": {
            "schema": {
                "type": "object",
                "properties": {
                    "value": {
                        "type": "string",
                        "enum": [
                            "armedAway",
                            "armedStay",
                            "disarmed"
                        ]
                    }
                },
                "additionalProperties": false,
                "required": [
                    "value"
                ]
            },
            "enumCommands": [
                {
                    "command": "armStay",
                    "value": "armedStay"
                },
                {
                    "command": "armAway",
                    "value": "armedAway"
                },
                {
                    "command": "disarm",
                    "value": "disarmed"
                }
            ]
        },
        "alarm": {
            "schema": {
                "type": "object",
                "properties": {
                    "value": {
                        "title": "String",
                        "type": "string",
                        "maxLength": 255
                    }
                },
                "additionalProperties": false,
                "required": [
                    "value"
                ]
            },
            "enumCommands": []
        }
    },
    "commands": {
        "armStay": {
            "arguments": [
                {
                    "name": "bypassAll",
                    "optional": false,
                    "schema": {
                        "type": "boolean"
                    }
                }
            ]
        },
        "armAway": {
            "arguments": [
                {
                    "name": "bypassAll",
                    "optional": false,
                    "schema": {
                        "type": "boolean"
                    }
                }
            ]
        },
        "disarm": {
            "arguments": []
        }
    }
}
3 Likes

That that helps a ton. I am still not able to wire up armAway and armStay. I get a popup that says ‘network error occurred try later’. I tried prototypes with different parameters but still the same thing. (see below) This disarm works fine.

def armStay() {
log.debug “Executing ‘armStay’ 0”
sendEvent(name: “securitySystemStatus”, value: “armedStay”)
}
def armStay( bypass ) {
log.debug “Executing ‘armStay’ 1”
sendEvent(name: “securitySystemStatus”, value: “armedStay”)
}
def armStay( bypass, attr2) {
log.debug “Executing ‘armStay’ 2”
sendEvent(name: “securitySystemStatus”, value: “armedStay”)
}
def armStay( bypass, attr2, attr3) {
log.debug “Executing ‘armStay’ 3”
sendEvent(name: “securitySystemStatus”, value: “armedStay”)
}

Any idea appreciated, thanks again.

–Greg

Tagging @nayelyz @erickv

Both of these are used by the groovy platform. It’s possible the live capability is also in use by the new platform.

Hi,

Same problem here in september 2021. The ArmStay and ArmAway security mode produce a network error in the app and nothing is called in the device handler. Disarm is working. I’m only using the capability “Security System” and tried the no parameter function signature and with the bypassAll argument.

Any ideas on this since 2020?

Thank you!

Simon

I’ve been playing with this capability, and it seems like the real problem is that armAway and armStay require a boolean parameter be passed. The capability presentation doesn’t offer any way to set it though, so there’s no way to call those commands through the app. I was able to call both successfully through webCoRE so long as I sent a boolean parameter. If bypassAll were set with optional:true then this would be a viable capability. Everything else works - disarm command can be called through the app and the attributes display properly when set.

"name": "bypassAll",
"optional": false,

Your observations are correct. I noticed the same thing in my tests. I hadn’t tried from webCoRE though and the fact that the application calls the version of the function with the “bypassAll” argument without providing it makes sense! This is surely the reason for the error message and it would be really helpful if it could be fixed!

And you know what? I discovered that if you control the same alarm system via SmartThings Home Monitor instead of using the device interface in the app, the Arm (Stay) and Arm (Away) mode are activated correctly and without any errors.

1 Like

I was really confused by what you meant here but… wow. I see it now. Nice find. I have two devices using this capability, and the armAway/armStay/disarm commands for both devices are automatically called when STHM status changes. I wonder whether that’s intended behavior or if this will get changed at some point in the future.