Use POST command to set raspberry pi pin state. Use GET to check the state of the pin and decide whether to display the red circle.