  Exclusive production of transversely polarized heavy vector mesons in deep
inelastic scattering at high energy is calculated at next-to-leading order
accuracy in the Color Glass Condensate framework. In addition to the first QCD
correction proportional to the strong coupling constant $\alpha_s$, we
systematically also include the first relativistic correction proportional to
the heavy quark velocity squared $v^2$. When combined with our previously
published results for longitudinal vector meson production at next-to-leading
order accuracy, these results make phenomenological calculations of heavy
vector meson production possible at the order $\mathcal{O}(\alpha_s v^0,
\alpha_s^0 v^2)$. When applied to $\mathrm{J}/\psi$ and $\Upsilon$ production
at HERA and at the LHC, a good agreement between the next-to-leading order
calculations and experimental data is found. Additionally, we demonstrate that
vector meson production can provide additional constraints compared to
structure function analyses when the nonperturbative initial condition for the
Balitsky-Kovchegov evolution equation is extracted.
