The current global challenge of climate change has made renewable energy usage very important. There is an ongoing drive for the deployment of renewable energy resource at the domestic level through feed-in tariff, etc. However, the intermittent nature of renewable energy has made storage a key priority. In this work, a community having a solar farm with energy storage embedded in the house of the energy consumers is considered. Consumers within the community are aggregated in to a local virtual power plant. Genetic algorithm was used to develop an optimized energy transaction for the virtual power plant with respect to differential pricing and renewable generation. The results show that it is feasible to have a virtual power plant setup in a local community that involve the use of renewable generation and embedded storage. The results show that both pricing and renewable generation window should be considered as a factor when setting up a virtual power plant that involve the use of storage and renewable generation at the community level. Also, when maximization of battery state of charge is considered as part of an optimization problem in a day ahead market, certain trade-off would have to be made on the profit of the virtual power plant, the incentive of the prosumer, as well as the provision of peak service to the grid.