“He was calm, cool and collected,” said conservative radio host Howie Carr, who spoke with Trump on Thursday at Mar-a-Lago soon after the news first broke, as the president dined with GOP House leader Kevin McCarthy. “I had no idea there was anything out of the ordinary going on until I got home.”

As rocket attacks against U.S. bases in Iraq intensified over the last two months, the president had granted the Pentagon extraordinary latitude: The U.S. military had his permission to kill Soleimani the next time it had an opportunity to do so, according to a senior defense official who was not authorized to speak on the record.

“We had authority before the strike to take that action,” said the official, who wouldn’t say how recently Trump gave the Pentagon that authorization—whether it was hours, weeks or even months earlier. As recently as New Year’s Eve, the president was telling reporters that he didn’t want war with Iran.

For a man U.S. officials have portrayed as a terrorist mastermind, an evil genius responsible for the deaths of hundreds of Americans, Soleimani often flaunted his influence as he jetted between Tehran, Baghdad and Beirut for meetings with local potentates.

“I don’t think it was so hard [to find him] because he was not below the radar in the last two or three years,” said a former senior Israeli government official, who noted that Soleimani had previously moved around under strict operational secrecy. “But the last two or three years, he worked in the open.”

Former national security adviser John Bolton, a vocal advocate of regime change in Iran, described the killing of Soleimani as “long in the making.”

“We’ve known every minute of every day where Soleimani is for years—there’s no moment of any given day where five or six intelligence agencies can’t tell you where he is,” a Republican foreign policy hand said. “It’s been one of his talking points: The Americans can find me any time, they just don’t dare hit me.”

That calculation proved misguided in the wee hours of January 3 in Iraq, where Soleimani landed amid spiraling tensions between U.S.- and Iranian-allied factions. “He arrived at the airport and we had a target of opportunity, and based on the president’s direction, we took it,” the senior defense official said.

U.S. officials had received “an intelligence-based assessment that drove our decision-making process,” Secretary of State Mike Pompeo said on Friday, describing how the recent killing of an American contractor had changed the Trump team’s calculations about the “intelligence flow” they were receiving about Soleimani’s activities in Iraq.

U.S. officials, briefing conservative think-tank experts on Friday, said the U.S. had "exquisite intelligence" on a plot to strike Americans in Iraq, Syria and Lebanon, according to someone familiar with the call. By killing Soleimani, the officials said, they disrupted such plans.

A night of confusion and rumors

The first dispatches from Baghdad on Thursday evening were cryptic. “Several Katyusha rockets have been fired at Baghdad airport, causing multiple casualties amid tensions with US,” the AP alert read.

Then, suggestions that something major had just gone down began trickling in. Word that someone—presumably the United States—had just killed Iran’s pre-eminent strategist first posted online shortly before 7 p.m. in Washington.

As journalists scrambled to confirm and make sense of the rumors flying around, Iraqi state television announced that Soleimani, along with several of Iran’s top Iraqi allies, had been killed. A BBC reporter shared a grisly image purporting to show Soleimani’s mangled hand, complete with his signature ruby ring; other photographs claiming to be of the remains of the convoy he was traveling in circulated online.

Photographs taken around this time showed President Trump huddling with McCarthy and White House aides Jared Kushner, Hogan Gidley and Dan Scavino at Mar-a-Lago.

“A memorable and historic evening at The Winter White House. Proud of our President!” McCarthy posted later on his Instagram feed.

It wasn’t until 9:46 p.m. on Thursday that the U.S. government officially confirmed Soleimani’s death, in the form of a terse, 163-word Pentagon press release emailed to reporters.

“At the direction of the President, the U.S. military has taken decisive defensive action to protect U.S. personnel abroad by killing Qasem Soleimani, the head of the Islamic Revolutionary Guard Corps-Quds Force, a U.S.-designated Foreign Terrorist Organization,” the statement read.

The president’s only comment on Thursday evening was to post an online image of the American flag 14 minutes earlier—an unusually coy tweet for the typically prolix commander in chief.

But his television surrogates were quick to supply their inside accounts.

Dialing into Fox News from his vacation, conservative commentator Sean Hannity—a close Trump confidant—shared what he’d heard from “one person familiar that was in the room.”

“The president said, ‘Our people will be protected. This will not be Benghazi,’” Hannity relayed.

“At one point,” the Fox host continued, “the president asked the question among some of his military and Cabinet and intelligence and State Department people, ‘Well, how long is it going to take to mobilize?’ And the words [came back from the president], ‘That’s not fast enough,’ and everybody said, ‘Yes, sir.’ And they got it done in really record time.”

Florida Rep. Matt Gaetz, another of the president’s close allies on Capitol Hill who was with him at Mar-a-Lago, described the president’s mood on Thursday evening as “very focused.”

“I think he was really dialed into the ways in which Soleimani was planning to kill Americans, to harm our diplomats and to throw the entire region into civil war,” Gaetz said on Fox News. “I think we understand that this is a big moment in time. He appreciates the gravity of that.”

The White House seems to have informed only its closest congressional allies ahead of the move, with top Hill Democrats complaining that they hadn’t been informed in advance.

PHOTOS: The world reacts to Qassem Soleimani's death | Vahid Salemi/AP Photo

“I was briefed about the potential operation when I was down in Florida,” Sen. Lindsey Graham (R-S.C.), who was with the president at Mar-a-Lago earlier this week, told Fox News on Friday morning. “I appreciate being brought into the orbit.”

Defense Secretary Mark Esper appeared to warn Iran of the coming strikes hours beforehand on Thursday, amid a discussion of the recent attacks on U.S. bases by Iraqi militias tied to Iran.

“Do I think they may do something? Yes. And they will likely regret it,” Esper told reporters. “And we are prepared to exercise self-defense, and we are prepared to deter further bad behavior from these groups, all of which are sponsored and directed and resourced by Iran.”

In what might have been a sign of preparation for the strike, Pompeo cancelled a trip to Ukraine and several other countries this week to monitor the tensions in Iraq.

State Department officials summoned the Iraqi ambassador to the U.S. for a meeting Thursday afternoon, according to a person familiar with the situation. It was not clear what exactly was discussed.

“I think it’s been in the works for a while because I don’t think it was a last-minute thing,” a Middle Eastern official said. “I don’t think they were like, ‘Oh we just found him, let’s take him out.' I think it was to mitigate an action that was actually in the works.”

“Tracking Solemani was likely something that was being done from at least May, when the major stream of threats emerged,” a former defense official said.

Actually targeting Soleimani posed a more formidable challenge, though, according to retired Lt. Gen. Michael Nagata, a former senior special operations commander in the Middle East who retired as strategy head at the National Counterterrorism Center last summer. “That depends on being able to know not only where he is, but where he’s going to be at a specific time in the future,” Nagata said.

That, in part, was why “we never decided to go after him personally” before, Nagata said – especially in earlier years when Soleimani maintained a lower profile and traveled less often, the military was reluctant to devote surveillance assets to a target few believed any president would ever allow to be struck.

“Soleimani was the spider at the center of the web, so there were recurring conversations over the years about what it would take to do something about him,” Nagata explained. “But what you had to grapple with was, ‘This is going to divert time, energy and resources from other tasks, and for a mission that I have no confidence we’re going to go through with.’”

Consultation with Israel

Pompeo held several phone calls with Israeli Prime Minister Benjamin Netanyahu in recent weeks, suggesting that Israel was not surprised by the strike against Soleimani.

Before departing on Thursday morning for Greece, Netanyahu told reporters in Israel, “We are in continuous contact with our great friend the U.S., including my conversation yesterday afternoon. I want to make one thing clear: We fully support all of the steps that the U.S. has taken as well as its full right to defend itself and its citizens.”

By Friday morning, Pompeo was dialing up his counterparts in foreign capitals, including Moscow and Beijing, to stress that the strike was a “defensive action” and that the U.S. hopes for a de-escalation in the crisis. Esper spent Friday explaining the rationale for the strike by phone to defense ministers in Baghdad, Berlin, London, Ottawa, and Riyadh, according to Pentagon spokesperson Alyssa Farah. The German, Canadian and British militaries all have troops in Iraq alongside the U.S. who could be at risk if Iran retaliates against the coalition troop presence.

Iranian officials were warning of a severe reaction, and the Parliament in Baghdad was voting to bar U.S. troops from Iraq even as U.S. officials were planning to send more forces to the region. European diplomats traded anxious phone calls, warning about the potential for further regional chaos.

And Trump himself was finally weighing in, explaining and justifying the decision with a barrage of tweets and retweets. “He should have been taken out many years ago!” the president wrote.

Asked about the U.S. plan for managing the potential blowback from Iran, a U.S. defense official said, “Your guess is as good as mine. The ball’s in Iran’s court at this time. We’re waiting to see what their response is.”

Nancy Cook, Quint Forgey and Caitlin Oprysko contributed reporting.