help needed! proof of concept: drink heater/ cooler

It seems like it may be possible, but what would you use to cool off the drink? I know that you could wire a heating element to the drink, but what if it's too hot? Could the entire device be like a box? Combination of microwave and refrigerator/freezer?