Set switch mqtt read-only mode

do not work

I want to explain that this is not a command.
if it receives an “off” payload the switch must switch to OFF
off
if it receives an “on” payload the switch must switch to ON
on
thank you