  We perform the calibration of the X-ray luminosity--mass scaling relation on
a sample of 344 CODEX clusters with $z<0.66$ using the dynamics of their member
galaxies. Spectroscopic follow-up measurements have been obtained from the
SPIDERS survey, leading to a sample of 6,658 red member galaxies. We use the
Jeans equation to calculate halo masses, assuming an NFW mass profile and
analyzing a broad range of anisotropy profiles. With a scaling relation of the
form $L_{\rm{X}} \propto \text{A}_{\rm{X}}M_{\text{200c}}^{\text{B}_{\rm{X}}}
E(z)^2 (1+z)^{\gamma_{\rm{X}}}$, we find best fit parameters $
\text{A}_{\rm{X}}=5.7^{+0.4}_{-0.5}
(\pm0.6)\times10^{43}\,\mathrm{erg\,s^{-1}}$,
$\text{B}_{\rm{X}}=2.5\pm0.2(\pm0.07)$,
$\gamma_{\rm{X}}=-2.6^{+1.1}_{-1.2}(\pm0.74)$, where we include systematic
uncertainties in parentheses and for a pivot mass and redshift of
$3\times10^{14}M_\odot$ and 0.16, respectively. We compare our constraints with
previous results, and we combine our sample with the SPT SZE--selected cluster
subsample observed with \XMM\, extending the validity of our results to a wider
range of redshifts and cluster masses.
