I’ve been trying out multiple capabilities from https://smartthings.developer.samsung.com/docs/api-ref/capabilities.html#Capabilities-Reference such as “Lock”, “Door Control”, “Valve”, and “Window Shade”. However they all give the same error when I press their respective buttons: “A network or server error occurred. Try again later.” The only capability that doesn’t have this error is “Switch”. Why is the problem occurring, and how can it be fixed?
metadata {
definition (name: "Test", namespace: "Test", author: "Alex Feng", cstHandler: true) {
capability "Lock"
capability "Switch"
capability "Door Control"
capability "Valve"
capability "Window Shade"
}
simulator {
// TODO: define status and reply messages here
}
tiles {
// TODO: define your main and details tiles here
}
}
// parse events into attributes
def parse(String description) {
log.debug "Parsing '${description}'"
// TODO: handle 'lock' attribute
// TODO: handle 'switch' attribute
// TODO: handle 'door' attribute
// TODO: handle 'valve' attribute
// TODO: handle 'windowShade' attribute
// TODO: handle 'supportedWindowShadeCommands' attribute
}
// handle commands
def lock() {
log.debug "Executing 'lock'"
// TODO: handle 'lock' command
}
def unlock() {
log.debug "Executing 'unlock'"
// TODO: handle 'unlock' command
}
def on() {
log.debug "Executing 'on'"
// TODO: handle 'on' command
}
def off() {
log.debug "Executing 'off'"
// TODO: handle 'off' command
}
def open() {
log.debug "Executing 'open'"
// TODO: handle 'open' command
}
def close() {
log.debug "Executing 'close'"
// TODO: handle 'close' command
}
def pause() {
log.debug "Executing 'pause'"
// TODO: handle 'pause' command
}