24v ac to 5v dc power supply

Indeed, rectifier + buck converter, like this one, would be the most sensible. Nothing special for the rectifier, as the 24V side should be around 150 mA only for a 3W output. There must be similar buck converters with fixed 5V output as well.
This specific module has a 100µF input cap - this may or may not be enough to smooth the input, this buck converter should be able to handle some ripple on the input, it's rated 5-60V after all.