The MQTT device tracker entity can link to a zone based on the the GPS coordinates. It was also possible to link a (custom) zone by specifying the zones tracker is in.
As Home Assistant deprecated the use of the location_name attribute, bases on the state, I want to provide an alternative that can link the device tracker by specifying the zones. These zones must exist in Home Assistant and are all zone entities. Entities have a name and entity_id like zone.home. The PR I have opened: Deprecate` state_topic` and `value_template` for MQTT device tracker and add support for `in_zones` attribute via `json_attributes_topic` by jbouwh · Pull Request #172660 · home-assistant/core · GitHub supports Entity name (e.g My home), entity_id (zone.home) and the zone object_id (zone) to identify the zone in HA. But may be that is not needed.
We'd like to have some feedback what would be the best fit here.