How to connect ESP-01 to read a connected relay switch?

Once you have programmed a OTA-capable code all following up updating the code can be done by OTA Over The Air