Donald Trump immortalized his larger-than-life legacy as a real estate mogul in his autobiography The Art of the Deal. As he tells it, his story epitomized the wealth, excess, and decadence of the 1980s.

Then came the economic slowdown of the early 1990s.

Trump saw his net worth tank, finding himself deeply in debt, personally on the hook for $1 billion. Trump immortalized his turnaround in his books, The Art of the Comeback and Surviving at the Top.

The real story of how Trump escaped his debt — through restructuring, in which he gave banks and lenders larger interest in his holdings for easier debt payments — doesn't make for as good of story as a dramatic tale Trump has told in his books, numerous motivational speeches, and interviews reviewed by BuzzFeed News.

In these stories, Trump claims that a personal connection — starting with a chance meeting with one of the most hard-nosed bankers in New York — was crucial to his staving off financial ruin.

It's the Parable of the Mysterious Mean Banker.

But on different occasions, key details of the story have changed. In one version of the story, Trump met the banker on a golf course. In another telling, it was over a dinner he decided to attend at the last minute at the Waldorf-Astoria in New York.

At dinner, the moral of the story is that it is possible for people to make their own luck. On the golf course, the moral is about the importance of golf.

Various takes on the former version of the story appear in his 2009 book Think Like A Champion, and in 2011 and 2012 speeches to the National Achievers Congress. In the story, Trump claims he initially resisted attending the dinner, until his secretary prevailed upon him to go.

"I said, 'Bankers, ugh, shit.'" Trump said in the 2011 speech. "I owe them $9.2 billion, okay? Have no intention of paying it. And I have to go to a bankers' dinner. It's true. So I say, 'I don't want to go. I'm not going.' She [the secretary] said, 'No, you gotta go.' And you know, on top of it, it's black tie. So now, on top of everything, I also have to put on a tuxedo to get abused."

At the Waldorf dinner, Trump says he found himself sitting between a nice banker and a mean banker. The mean banker, Trump says, has bankrupted dozens of debtors before him (in one telling it's 39; in another it's 32). The mean banker will barely acknowledge Trump's presence.

"He was a bad guy," Trump said. "He was bankrupting everybody instead of working it out. So I'm sitting next to him. I figured out it was him. Because I said, 'What's your name?' He looks at me. He didn't want to even give it. He was insulted, but I never met him. Think about it. I owe him $179 million bucks. I never met the banker. So the evening goes by and I started working on him hard."

By the end of the night, the banker has grown to like Trump and asks him to meet at his office on the following Monday.

"I went to his office and in five minutes, we worked out a deal for a lot of money," Trump said, adding that, without making that deal, he might not have been able to make deals with his numerous other creditors.

"Did I make my own luck?" Trump concludes in the 2012 NAC speech. "I went, I didn't want to go, I really fought it, I put on the tuxedo, I sat next to a guy, in a way I was lucky I sat next to him. But the end result was, I made my own luck. If I didn't go, it's not gonna happens. So that's — I think it's an important story."

Asked if he knew which banker Trump might have been talking about, reporter Wayne Barrett, whose 1991 biography of the tycoon investigated the mogul's business dealings, said the story didn't ring true. "No banker was more important to Donald than Conrad Stephenson" of Chase, Barrett said. Trump, however, did not meet Stephenson by chance at dinner in the early '90s. According to Barrett's book, they met through Trump's father, Fred, and Stephenson worked on many of Trump's early real estate deals.

In May 1990, Barrett reported, Stephenson even held a dinner at the Waldorf-Astoria where Trump was the honoree. Trump was seated next to Stephenson at the dinner, sponsored by the Realty Foundation. (In one speech, Trump claimed the encounter occurred at an event held by the "American Bankers Associations," though the organization says they have no record of having hosted a dinner at the Waldorf-Astoria in the early 1990s.)

Barrett further reports that, in 1987, Trump sold Stephenson an apartment in the building Trump Parc at a discount.

"So his inducements to bankers might include a bit more than a golf tip," Barrett quips, referring to the version of the story where Trump claims he got in the good graces of the mean banker using his golf expertise.

This was the version of the tale Trump told NBC's Golf Channel earlier this year.

"One story that I relate to people about golf, there was one banker who was really looking to do bad numbers on me," Trump said. "And as I playing this day and they said we need another person and this guy was at the course. It was the weirdest thing, I mean, not a member. And they said, 'Would you like to join the group?' And when he saw I was in the group he wanted to get it out, but then he decided to join. He was a terrible golfer. A villainous banker. He was not a friend of mine."

Then, Trump says, he taught the banker how to do a proper swing. After this the banker hit the ball well. The banker then decided to work with Trump on his debts.

"And he sees me the next day and he goes, 'Could we work it all out? Come on.' We had lunch, I worked it out with him in about ten minutes. Without golf that wouldn't have happened and who knows? Maybe I wouldn't be sitting here. Who knows?"

Trump recounted the same story to NewsMax in 2012.

"Afterward, this banker said to me, 'Donald, let's meet next week and straighten out this business problem,'" said Trump to NewsMax. "And I made a fantastic deal with him and made my comeback. I was no longer on a $400,000-a-month living allowance from the banks. Without golf, I might not be sitting here with you and discussing the state of our country and presidential politics."

Meanwhile in Trump's 1997 book, The Art of the Comeback, the story is re-told with slightly varying details. Trump concludes the tale by marveling at the ease with which he solved his problems.

"We signed the next day, and hundreds of millions of dollars' worth of problems went away," Trump wrote. "Just like that. Pfff!"

The Trump campaign didn't respond to a request for comment.