© Richard Drew / AP U.S. Ambassador Nikki Haley addresses the United Nations Security Council, Monday, Sept. 17, 2018, at U.N. headquarters.

CBS News' Fin Gomez, Kathryn Watson, Pamela Falk, Emily Tillett and Grace Segers contributed to this report.

Nikki Haley, U.S. ambassador to the United Nations, is leaving her post at the end of the year, President Trump announced in the Oval Office Tuesday morning. Haley's replacement is unclear, although Mr. Trump said he will likely select the new ambassador in the next two or three weeks.

Haley told reporters she will not run for office in 2020 and instead campaign for the president, in an attempt to quash speculation that she might chart her own political course challenging him.

"I will say this for all of you that are going to ask about 2020 — no, I am not running for 2020," the ambassador told reporters. "I can promise you what I will be doing is campaigning for this one. So I look forward to supporting the president in the next election."

Mr. Trump, meeting with Haley in the Oval Office, informed reporters Tuesday Haley had told him about six months ago that she wanted a break. The president said Haley has been "very special" to him, they hate to lose her, and the two will be in constant touch. Mr. Trump said hopefully Haley can come back to his administration in the future, adding, "You can have your pick."

Nikki Haley calls U.N. ambassadorship the "honor of a lifetime"

Mr. Trump said a number of people would like to do Haley's job, and claimed it's a more "glamorous" position than it was a couple years ago.

Haley, for her part, said the post had been an honor of a lifetime. Haley said the U.S. is strong again in a way the nation should be proud of. Haley also said nothing is set in terms of where she will land next. Haley said "there's no personal reason" for her impending departure, it's just "very important" for government officials to know when it's time to step aside and let someone else rotate in with renewed energy.

"You know, my family is very supportive so there's no personal reason," Haley said. "I think that it's just very important for government officials to understand when it's time to step aside. And I have given everything I've got these last eight years and I do think that sometimes it's good to rotate in other people that can put that same energy and power into it."

Nikki Haley's resignation letter

In her resignation letter, Haley enumerated accomplishments of her time at the United Nations.

"We achieved great successes at the UN," she wrote. "We passed the toughest sanctions against any country in a generation, pressuring North Korea toward denuclearization. We passed an arms embargo on South Sudan that will help reduce violence and hopefully bring peace to that troubled country. We stood up for our ally Israel and began to roll back the UN's relentless bias against her. We reformed UN operations and saved over $1.3 billion. We spoke out resolutely against dictatorships in Iran, Syria, Venezuela, Cuba, and yes, Russia. Through it all, we stood strong for American values and interests, always placing America first. I am proud of our record.

Mobile app users can read the full letter here.

Reaction to Haley's departure

Members of the administration were equally warm in their reception of Haley, sending messages of gratitude following news of her departure. Vice President Mike Pence echoed the president's message on Tuesday, commending Haley's "frank and clear-eyed assessments of global threats" in her role at the United Nations.

Heartfelt thanks to Ambassador @NikkiHaley for her extraordinary service as the US Ambassador to the @UN. My full statement below: pic.twitter.com/Lo7lIYd1Ri — Vice President Mike Pence (@VP) October 9, 2018

Mr. Trump's eldest daughter Ivanka tweeted, too, saying Haley had served the country with "dignity and distinction" calling her a "bold reformer" in the UN. Haley specifically noted her friendship with Ivanka and her husband Jared in her comments on Tuesday, referring to the president's son-in-law as a "hidden genius."

Mr. Trump suggested to reporters Tuesday afternoon that Ivanka would make a "dynamite" replacement for Haley, but that if he nominated her he would be accused of nepotism. Ivanka took herself out of the running for UN ambassador shortly thereafter, tweeting that her father "will nominate a formidable replacement for Ambassador Haley. That replacement will not be me.

Meanwhile Secretary of State Mike Pompeo called Haley a "great partner" for the past few months they had been working together, adding that he "wishes her very well in whatever comes next."

CBS News has confirmed that Pompeo and National Security Adviser John Bolton were caught unawares by Haley's announcement that she would resign.

Haley's impending departure came as a shock to Washington, amid crucial times for foreign policy, and one month ahead of November's midterms. Axios first reported Haley's resignation.

Haley has charted her own course during the Trump administration, backing the president but also admitting in a recent op-ed that sometimes she disagrees with him. Her op-ed was a response to an anonymous op-ed published in the New York Times from someone who identified as a senior administration official. Haley's op-ed was headlined, "When I challenge the president, I do it directly. My anonymous colleague should have, too."

"I, too, am a senior Trump administration official," Haley wrote in her op-ed. "I proudly serve in this administration, and I enthusiastically support most of its decisions and the direction it is taking the country. But I don't agree with the president on everything. When there is disagreement, there is a right way and a wrong way to address it. I pick up the phone and call him or meet with him in person."

Haley was an opponent of Mr. Trump's during the 2016 presidential race, and endorsed Sen. Marco Rubio when she left the race. Since then, the two made amends — although, as Haley noted, she and the president were not always in lock-step agreement.

Related story: