Under the electricity market environment, this paper analyses the optimal purchasing strategy of the electricity supply company, taking random variables like spot price and ultimate customer demand into consideration. With a variety of option contracts and real-time electricity retail market, an electricity supply company is also an option buyer. This paper gives the optimal option contract combination based on the different profits derived from each option contract, introduces the solutions to calculate the optimal purchasing quantity for each option contract, and proves that the electricity supply company will increase its profit when the option contract types increase. In the end, a numerical example demonstrate the application of the conclusion.