Read state of a valve irrigation

Is it possible to read a state of a irrigation valve?
The valve is connected to a traditional wired irrigation system (no smart, no wifi).
I’d like to read the state of a valve in home assistant if is it possible… Maybe with an esp32 between irrigation system and valve to read if there is 0 or 12v?but how…? Is there an already ready solution on the web?

You’ll have to tell us a whole lot more info on how the valve works.

Sounds like it is a job for an opto-isolator connected to a esp8266 or esp32, providing it is in wifi range.

Of course, just because there is 12v across the terminals, doesn’t actually mean the valve has activated. You can get flow meters too.