Lifepo4 state of charge

I would like to measure the state of charge of lifepo4 battery.
Based on the measurement i would like to switch a relay like a shelly pm on or off.
Best way to measure SOC is a smart shunt.
However I unable to find one that entegrates with smartthings.
Suggestions?