We study theoretically the performance of electrically pumped self-organized quantum dots as a gain material in the mid-IR range at room temperature. We analyze an AlGaAs/InGaAs based structure composed of dots-in-a-well sandwiched between two quantum wells. We numerically analyze a comprehensive model by combining a many-particle approach for electronic dynamics with a realistic modeling of the electronic states in the whole structure. We investigate the gain both for quasi-equilibrium conditions and current injection. Comparing different structures we find that steady-state gain can only be realized by an efficient extraction process, which prevents an accumulation of electrons in continuum states, that make the available scattering pathways through the quantum dot active region too fast to sustain inversion. The tradeoff between different extraction/injection pathways is discussed. Comparing the modal gain to a standard quantum-well structure as used in quantum cascade lasers, our calculations predict reduced threshold current densities of the quantum dot structure for comparable modal gain. Such a comparable modal gain can, however, only be achieved for an inhomogeneous broadening of a quantum-dot ensemble that is close to the lower limit achievable today using self-organized growth.