You want to control an AC based on the temperature in the room... that's called a thermostat

Most ACs have them built in.
I actually couldn't find a portable AC that turns off completely based on temperature, the fan stays running. I'll be using a Wemo to control it based on time/outside temp at least. But additionally I'd like to monitor the room temp remotely.