This paper develops a stochastic programming model that integrates the day-ahead optimal bidding problem with the most recent regulation rules of the Iberian Electricity Market (MIBEL) for bilateral contracts, with a special consideration for the new mechanism to balance the competition of the production market, namely virtual power plants auctions (VPP). The model allows a price-taker generation company to decide the unit commitment of the thermal units, the economic dispatch of the bilateral contracts between the thermal units and the generic programming unit (GPU) and the optimal sale/purchase bids for all units (thermal and generic) observing the MIBEL regulation. The uncertainty of the spot prices is represented through scenario sets built from the most recent real data using scenario reduction techniques. The model was solved with real data from a Spanish generation company and spot prices, and the results are reported and analyzed.