To achieve moderately roasted beans, you have to roast them for 10 minutes in an air fryer. You must not roast beans for more than 10 minutes. Before putting coffee beans in the basket, you must preheat the air fryer.