You can shut down a phone by AT command but cannot turn it ON by AT command because the power is off and it wil not accept AT commands.
What I did was to use a reed relay and soldered its contacts across the power button. Then the microcontroller can press the power button to turn the phone ON. For some phones, you will need 2 relays since they use 2 buttons to power ON. It is a crude method but I cant think up of any other easy method.