  Competing density waves play an important role in the mystery of
high-temperature superconductors. In spite of the large amount of experimental
evidence, the fundamental question of whether these modulations represent
charge or pairing density waves (CDWs or PDWs) is still debated. Here we
present a method to answer this question using momentum and energy-resolved
resonant X-ray scattering maps. Starting from a minimal model of density waves
in superconductors, we identify distinctive signatures of incipient CDWs and
PDWs. The generality of our approach is confirmed by a self-consistent solution
of an extended Hubbard model with attractive interaction. By considering the
available experimental data, we claim that the spatial modulations in cuprates
have a predominant PDW character. Our work paves the way for using X-ray to
identify competing and intertwined orders in superconducting materials.
