President Trump's jaw-dropping interview with three reporters from The New York Times started as an off-the-record meet and greet session.

Trump "wanted to get to know the D.C. players at The Times," said one of several sources familiar with the Oval Office meeting.

But the reporters approached it at least partly as an interview opportunity. The trio came with many questions, and the meeting quickly became a news-breaking interview.

While the president insisted on keeping some of his comments "off the record," barring the reporters from quoting the comments, he allowed most of the conversation to be "on the record," quoted and attributed to him.

"It was an ongoing negotiation," another one of the sources said.

Both the reporters and the president seemed pleased at the outcome. But Trump's comments -- lashing out at his own Justice Department officials and issuing a warning to special counsel Robert Mueller -- left administration officials bewildered and left commentators gobsmacked.

Many were left wondering: Why did the president agree to this interview?

Anderson Cooper asked the question aloud on CNN shortly after the interview came out: "Why on God's green earth does the President of the United States give this interview today of all days?"

Cooper noted that the White House's focus was "supposed to be on health care" and the administration's self-proclaimed "Made in America" week. But the interview instantly changed the subject and generated hours of news coverage.

On Thursday there was even some West Wing finger-pointing about who allowed the interview. The only White House aide in the room was Hope Hicks, Trump's director of strategic communications. But the meeting was on the president's internal schedule, so it shouldn't have come as a surprise.

There could be legal ramifications. Some experts said Trump's lawyers likely would have advised him to avoid questions about Russia-related investigations.

But Trump was in good spirits, according to the Times reporters, and was eager to talk.

Maggie Haberman, one of the three interviewers, tweeted on Thursday, "POTUS may not always be doing what some on staff want when he does these interviews. But he knows what he is doing. And he likes engaging."

Haberman, based in New York, has known Trump for years and has interviewed him several times since inauguration day.

But Trump, a voracious reader of The Times, expressed interest in meeting DC-based reporters.

Peter Baker, the newspaper's chief White House correspondent, and Michael Schmidt, a Washington reporter who broke several stories about fired FBI director James Comey's interactions with Trump, joined Haberman for the Wednesday afternoon meeting.

"Mike and I were meeting him for the first time," Baker told Slate on Thursday.

Related: Fox News turns to Hillary Clinton amid negative news for Trump

"Hi fellas. How you doing?" Trump said on the Times' audio recording of the session.

The audio released by the Times is grainy, which suggests it was recorded on a phone or tape recorder, not with professional audio equipment.

One of the sources said the "meet and greet" then "turned into an interview."

As the discussion went along, the reporters repeatedly asked "can we put that on the record?," and Trump agreed -- a credit to both the reporters and the president.

There are several breaks in the Times' edited transcript of the interview, indicating times that Trump insisted on speaking "off the record."

The transcript raised the prospect of "quote approval," a controversial practice wherein journalists allow sources to OK quotes after the fact.

"There was no quote approval," Elisabeth Bumiller, the paper's Washington bureau chief, said in response to questions from CNNMoney on Thursday.

"Interviews can go off-the-record at certain points," Bumiller said. "Our reporters repeatedly pushed for everything to be on the record as the interview happened. President Trump agreed to be on the record for the vast majority of the time."

She declined to comment on the interview's meet-and-greet origins.

Baker told Slate that the president "has a way of going on and off" the record "with great fluidity, which is a challenge."

"Our preference is that we don't go off and stick to 'on the record' so there is never any questions about what an interview subject is saying, but you know, it's his office, and it's a little hard to stop somebody from doing it."