We typically don't write code for users, just point you in the right direction. The suggestions to create a new 'status' feed that gets updated when your relay is actually toggled is a good one. You publish to that feed on the device right after it toggles the relay.axiomnote wrote:so nobody wants to help me with the code or nobody knows how to do it?
The /get topic is also the right approach for refreshing the state on the device as soon as it turns on. The linked documentation should show you how to implement it on your device as well.
Here is an example to update a feed from your device:
https://github.com/adafruit/Adafruit_IO ... sh.ino#L64