Toggle lights based on a MQTT text msg

Can you clarify what you mean by this?

Please follow Community Questions Guidelines 9 & 11 by sharing the, properly formatted, automation configuration you have tried.