Rats are a pain to get rid of. They're often way too smart for a bait trap unless you have an infestation then at least a few would be desperate enough to go for it.
Removing the source of the problem would almost likely significantly reduce the problem. I used to leave out a tray of feed in the coop overnight and I would get a rat visit the tray overnight - I know this because it'll leave some poo behind to "insult" me. Once the food was removed I didn't see anymore poo.
Having a cat around helps a lot too. My 15 lb cat does a pretty good job at keeping the rodent population down. My almond and fruit trees used to get raided before I had him petrol my backyard at night. He's killed several mice since I had chooks about 3 months ago. He leaves his kill in a clearing next to the chook run for me to see in the morning. A couple of weeks after the rat visitation, he caught it and another mouse and left them side-by-side for me to see. Grose but cool at the same time as I never thought he was capable of killing rats!
If you're thinking of getting cats, try to get a larger one like mine, or breeds like Maine Coon or Ragdoll which are both bred to specifically hunt rats. But I would suggest you only let it out after dusk and before dawn to avoid killing birds.