Secretary of State Rex Tillerson was on the verge of resigning this past summer amid mounting policy disputes and clashes with the White House, multiple senior administration officials who were aware of the situation at the time told NBC News.

The report prompted a response from Tillerson, who said he never considered resigning and President Donald Trump said he maintained "total confidence" in his secretary of state.

The tensions came to a head around the time President Donald Trump delivered a politicized speech in late July to the Boy Scouts of America, an organization Tillerson once led, the officials told NBC News.

Just days earlier, Tillerson had openly disparaged the president, referring to him as a "moron" after a July 20 meeting at the Pentagon with members of Trump’s national security team and Cabinet officials, according to three officials familiar with the incident.

While it's unclear if he was aware of the incident, Vice President Mike Pence counseled Tillerson, who is fourth in line to the presidency, on ways to ease tensions with Trump, and other top administration officials urged him to remain in the job at least until the end of the year, according to some of the dozen current and former senior administration officials who spoke to NBC News for this report.

Tillerson did not deny calling the president a moron when asked about it at an unscheduled news conference at the State Department on Wednesday.

"I'm not going to deal with petty stuff like that," he said. Tillerson denied that he has ever considered resigning as secretary of state.

"The vice president has never had to persuade me to remain as secretary of state because I have never considered leaving the post," Tillerson said, saying that there were "a few specifics that have been erroneously reported."

However, the report only said Pence counseled Tillerson on their tensions.

Pence, in a statement to NBC News, also denied "discuss the prospect of the Secretary's resignation from the administration."

Of Trump, Tillerson said he's learned "he loves his country, he puts Americans and America first, he's smart, he demands results wherever he goes and he holds those around him accountable for whether they've done the job he's asked him to do."

He added that he will not "try to sow dissension to advance" his agenda, as others in Washington do.

Earlier, Tillerson's top State Department spokesman, R.C. Hammond, said Tillerson did not consider quitting this past summer. He denied that Tillerson called Trump a “moron.” Hammond said he was unaware of the details of Tillerson’s meetings with Pence.

As Tillerson was expected to speak, Trump tweeted that "NBC news is #FakeNews and more dishonest than even CNN."

After Tillerson's remarks, Trump tweeted: "The @NBCNews story has just been totally refuted by Sec. Tillerson and @VP Pence. It is #FakeNews. They should issue an apology to AMERICA!"

NBC News reporter Carol Lee said on MSNBC that the team of reporters stands by their reporting: "We've extensively reported on this. We talked to a dozen people for this story."

An NBC News representative added, "we stand by our reporting."

Asked about Tillerson’s comments while in Las Vegas later on Wednesday, Trump expressed "total confidence" in the secretary of state.

"I’m very honored by his comments," Trump said. As he did on Twitter, Trump again dismissed NBC News’ report as "fake news."

The chairman of the Senate Foreign Relations Committee, Sen. Bob Corker, R-Tenn., wouldn't talk about private conversations he's had with Tillerson, but told NBC News he believes Tillerson, Defense Secretary James Mattis and White House chief of staff John Kelly "help separate our country from chaos and I support them very much."

Corker, who is not seeking re-election, added that the Trump administration is "an incredibly frustrating place" and feels that Tillerson isn't being supported appropriately, leaving him "trying to solve many of the world's problems a lot of time without a lot of the support or help I'd like to see him have."