In this letter, we address the problem of the integrability of a continuum model for granular media at equilibrium. By the means of a formal integrability analysis, we show that the equilibrium limit of such models can be cast into a gradient equation with zero right-hand side. In turn, this implies that the model of interest is inherently Frobenius integrable, in the absence of additional compatibility conditions. Moreover, the quantity inside the gradient is identified with the granular material's Gibbs free energy. Consequently, the integrability for the model at hand is equivalent to setting the Gibbs free energy of the granular material constant throughout the domain. In other words, integrability is equivalent to the definition of equilibrium employed in statistical physics.