Looking for library example to control iot device with own state

Thanks. I’ll defenetly check it out.