I can’t see what was posted above anymore, but the DeviceCheck API lets app developers store 2 binary digits (that means 4 different states: 00, 01, 10 or 11) per device on Apple’s servers. So, no, these don’t get erased during a Factory Reset as they’re stored on Apple’s servers. But your phone will.
Have they not heard of the TS100 or the Pinecil?
Both run an open-source firmware and work with any USB-C PD battery pack and still allow you to configure the temperature.