It can be removed without moving the master cylinder - remove the battery and put a mirror under the brake master cylinder and you'll be able to see the sensor plug.
It is going to introduce a little air to the master cylinder and brake fluid will drip out of where the sensor is supposed to go until it is replaced.
It took me a while to bleed out the air but I let the cylinder go dry while I waited for epoxy to cure.
The actuator IS NOT SECURE IN THE SENSOR
Once you remove the sensor do not tip or tilt it. The actuator will fall.
I lost my actuator, I epoxied the sensor so that I could stick it in my master cylinder and not have leaks. And cut the line to the sensor itself.
No brake light on my dash and master cylinder seems to work fine without the actuator, just wont have a pre-warning light if there's an issue.
Furthermore -
Just removing the reservoir cap won't require you to re-bleed anything as long as there is no leaks in your brake lines.
The sensor on the brake master cylinder is not for the brake light when your handbrake is on. That's separate as your hand brake is manual it does not go through the master cylinder at all and triggers a different sensor.
The sensor on the bottom of the master cylinder is to warn you you have an imbalance in your lines, like maybe a stuck caliper or something, or for fluid. To just make the light go off after a flush you should just have to unplug the sensor from the electrical part and clear codes on the car, then re-plugin the sensor.