I am a Kenyan planning to travel from Guangzhou airport, China to Nairobi, Kenya and back with Oman Air with a transfer at Muscat. Do I need a transit visa at Muscat?
As stated by Timatic, the database used by airlines:
Visa required, except for holders of onward tickets for a max. transit time of 6 hours.
So, because your trip is in a single booking, you do not need a visa.