How to force_update with mqtt auto discovery

I am using mosquitto mqtt with Sonoff S31 flashed with Tasmota. I need to set the force_update for some of these sensors. Is there a way to do this and use autodiscover for mqtt? Or do I need to setup these manually?

Thanks,

You could do it either way, manually or via discovery.

MQTT Discovery is not limited by the default information the device reports to its discovery topic. For example, let’s say your Sonoff device reports basic information to homeassistant/binary_sensor/gadget/config. The basic information is simply:

{"name": "gadget", "device_class": "motion"}

You can use an MQTT client, or an automation that runs whenever Home Assistant starts, to publish more information to homeassistant/binary_sensor/gadget/config.

{"name": "gadget", "device_class": "motion", "force_update": true, "qos": 1}

I ended up moving my S31 plugs out of auto discovery. I will probably move everything out of it.