He nearly lost everything because of his drug addiction, but his friends helped to pull him back from 'the brink'.
The other team 'brought them to the brink of' defeat. [=came very close to defeating them]
an animal that has been 'brought/pulled back from the brink of' extinction
(..) - Let's begin. - In my travels, I have seen the future. And it is a strange future, indeed. The world, ladies and gentlemen, is on the brink of new and terrifying possibilities. What you're about to witness is not magic. It's purely science. I'd like to invite you (..)2006 The Prestige