  We prove that the generating function of overpartition $M2$-rank differences
is, up to coefficient signs, a component of the vector-valued mock Eisenstein
series attached to a certain quadratic form. We use this to compute analogs of
the class number relations for $M2$-rank differences. As applications we split
the Kronecker-Hurwitz relation into its "even" and "odd" parts and calculate
sums over Hurwitz class numbers of the form $\sum_{r \in \mathbb{Z}} H(n -
2r^2)$.
