Thermodynamics of nanoscale devices is an active area of research. Despite their noisy surrounding they often produce mechanical work (e.g. micro-heat engines), display rectified Brownian motion (e.g. molecular motors). This invokes research in terms of experimentally quantifiable thermodynamic efficiencies. Here, a Brownian particle is driven by a harmonic confinement with time-periodic contraction and expansion. The system produces work by being alternately (time-periodically) connected to baths with different dissipations. We analyze the system theoretically using stochastic thermodynamics. Averages of thermodynamic quantities like work, heat, efficiency, entropy are found analytically for long cycle times. Simulations are also performed in various cycle-times. They show excellent agreement with analytical calculations in the long cycle time limit. Distributions of work, efficiency, and large deviation function for efficiency are studied using simulations. We believe that the experimental realization of our model is possible.