  We provide a novel experimental method to quantitatively estimate the
electron-phonon coupling and its momentum dependence from resonant inelastic
x-ray scattering (RIXS) spectra based on the detuning of the incident photon
energy away from an absorption resonance. We apply it to the cuprate parent
compound NdBa$_2$Cu$_3$O$_6$ and find that the electronic coupling to the
oxygen half-breathing phonon mode is strongest at the Brillouin zone boundary,
where it amounts to $\sim 0.17$ eV, in agreement with previous studies. In
principle, this method is applicable to any absorption resonance suitable for
RIXS measurements and will help to define the contribution of lattice
vibrations to the peculiar properties of quantum materials.
