In this work, we describe the design and flight performance of the REFOS instrument (from Russian REntgenovskiy FOto Spektrometr; in English "X-ray Photo Spectrometer"). REFOS is a soft X-ray spectrophotometer that registers full-disk integrated solar spectra (“Sun as a star”). It operates on board the Impulse-1 nanosatellite, which was launched on 24 June 2023. REFOS has a 1.2 – 30 keV spectral range, a 0.123 keV nominal full width at half-maximum (FWHM) resolution at 5.9 keV, and a cadence of 16 s. We illustrate the instrument flight performance using the spectra of the X5.0 flare that occurred on 31 December 2023 at 21:55 UT. For this flare, REFOS registered a meaningful signal in all of its energy bins. During the flare impulsive phase, the instrument clearly distinguishes non-thermal emission. During the flare peak, the spectrum exhibits signatures of the non-Maxwellian electron distribution. The observed continuum allows diagnosing the plasma temperature, and the observed spectral lines allow studying abundances of the Mg, Si, S, Ar, Ca, Fe, and Ni.