Free electron lasers operating in the soft and hard X-ray regime provide capabilities for ultrafast science in many areas, including X-ray spectroscopy, diffractive imaging, solution and material scattering, and X-ray crystallography. Ultrafast timeresolved applications in the picosecond, femtosecond, and attosecond regimes are often possible using single-shot experimental configurations. Aside from X-ray pump and X-ray probe measurements, all other types of ultrafast experiments require the synchronized operation of pulsed laser excitation for resonant or nonresonant pumping. This Perspective focuses on the opportunities for the optical control of structural dynamics by applying techniques from nonlinear spectroscopy to ultrafast X-ray experiments. This typically requires the synthesis of two or more optical pulses with full control of pulse and interpulse parameters. To this end, full characterization of the femtosecond optical pulses is also highly desirable. It has recently been shown that two-color and two-pulse femtosecond excitation of fluorescent protein crystals allowed a Tannor-Rice coherent control experiment, performed under characterized conditions. Pulse shaping and the ability to synthesize multicolor and multipulse conditions are highly desirable and would enable XFEL facilities to offer capabilities for structural dynamics. This Perspective will give a summary of examples of the types of experiments that could be achieved, and it will additionally summarize the laser, pulse shaping, and characterization that would be recommended as standard equipment for time-resolved XFEL beamlines, with an emphasis on ultrafast time-resolved serial femtosecond crystallography.