In response to light a solar cell generates an electrochemical potential which provides the thermodynamic driving force for extraction of work. This is the fundamental operation of a solar cell and is independent of the nature of the incident light — be it from the sun, a LED or a laser — because information regarding the initial photon distribution is rapidly lost as the electronic system thermalise to a new equilibrium state. This process is called thermalisation.
The instant after absorption, the electronic distribution directly matches the spectral distribution; this is non-thermal as it cannot be described by a temperature. Rapidly a thermal distribution forms with temperature hotter than the material. Eventually, this excess energy is dissipated an a fully thermalised distribution with a non-zero electrochemical potential is formed.
In thermodynamics we need to define the boundary of our “system”. For energy conversion we must include the incident light source too. This is because different light sources will have different spectral distributions and hence bring with them different amounts of heat and entropy. In general the more entropy associated with the incident light, the more inefficient the energy conversion process.
Solar cells can have very highly monochromatic efficiencies for this reason.
So what type of engine is a solar cell. It’s unique, is neither a pure heat engine nor a pure chemical engine. In the endoreversible scheme it looks like this,
The input is a hot body with temperature $T_1$ and zero chemical potential, where $T_1>T_2$, that emits light which generates a chemical potential in the solar cells $\mu_3$ that drives an engine. There is no temperature gradient across the engine. But there is a temperature gradient across the full system.
So I can understand why people refer to them as heat engines, but I also understand that’s a bit misleading because it only tells half the picture.
So what about if a solar cell is illuminated by a laser, then there is no temperature gradient!?
Laser light is described by a temperature and a chemical potential. The seminal paper on this is P Wurfel, The Chemical Potential of Radiation in which thermodynamics of thermal, luminescent and laser light are discussed.
A suitable endoreversible model of this case would be to replace the hot body in the diagram with an emitter described by $T_3$, which could be greater or less than $T_2$, and a chemical potential $\mu_2$. Provided that there is net positive energy current exchanged between the laser and the solar cell, work can be extracted.
In the limiting case of no temperature gradients in the system, provided that $\mu_2 > \mu_1$, work can be extracted because of the positive gradient in chemical potential.
However, this is no longer a solar cell! Although power-over-fibre products benefit from the high efficiency of solar cells when illuminated by monochromatic light. From the endoreversible model we can see why; the entropy of the incident light is very low, allowing the engine to operate more efficiently.
This paper is also relevant, A De Vos, Is a solar cell an endoreversible engine?