City Hall is contradicting reports that Dr. Oxiris Barbot, the embattled former health commissioner, had quit in protest over disputes with Mayor Bill de Blasio, saying that she was informed over the weekend that the administration "was moving in a different direction."

On Tuesday morning, the city's health department announced that Barbot had resigned, releasing an internal email she had written to the agency's more than 6,000 staff members. The change in leadership comes at a crucial juncture for the city, as it prepares to reopen public schools and refines its large-scale contact tracing program that has struggled at the outset.

“To set the record straight, this was not a resignation in protest," said Bill Neidhardt, the mayor's press secretary, in a statement. "The decision had been made by the Mayor well before her letter today. Over the weekend, Dr. Barbot was told the administration was moving in a different direction."

"This lead time is clear given Dr. Chokshi’s immediate appearance from City Hall," he added, referring to the appearance of Barbot's successor, Dr. Dave Chokshi, at a press conference added to the mayor's schedule after Barbot's resignation made news.

Chokshi seemed primed for the event, reading from a prepared statement.

Nearly nine hours after that briefing, the comments from City Hall offered a blunter response than the ones the mayor had delivered under repeated questioning about whether Barbot had either been fired or asked to resign.

De Blasio did not respond directly but he did suggest she was asked to leave, referring to her resignation as "timed to create a new approach to where we have to go."

"You have to keep refining, you have to keep learning from experience," he added. "You have to learn how to put together the best team."

A source close to the Health Department told Gothamist that Barbot had in fact been under pressure to resign for some time and that she had recently learned that the mayor had tapped her replacement.

The two have reportedly feuded over how to manage the coronavirus crisis. Tensions between Barbot and the mayor peaked in May, when the latter stripped the health department of contact tracing duties, instead asking the city's public hospital system to take the lead.

Barbot's own resignation letter to the mayor, which was provided to the New York Times, referred to her clash with the mayor over that decision.

“I leave my post today with deep disappointment that during the most critical public health crisis in our lifetime, that the health department’s incomparable disease control expertise was not used to the degree it could have been," she wrote.

“Our experts are world renowned for their epidemiology, surveillance and response work. The city would be well served by having them at the strategic center of the response not in the background.”

Barbot was also scrutinized after the New York Post reported an anonymous source as saying that during a heated argument about mask supplies for the NYPD, she had said to Chief of Department Terence Monahan, “I don’t give two rats’ asses about your cops."

In response to the story, a police union leader called Barbot a "bitch."

The remark drew condemnation from City Council members, including Speaker Corey Johnson. De Blasio denounced the comment but said he would investigate the incident between Monahan and Barbot.

"If what is being reported is accurate, the commissioner needs to apologize to the men and women of the NYPD, unquestionably," he said at the time.

Barbot wound up issuing a public apology.

Although Barbot had been health commissioner for less than two years, she has worked for nearly two decades in New York City's public health system. She started in 2003 as the medical director of the Office of School Health at the Department of Health and Department of Education. In 2018, she was promoted to commissioner after serving as the first deputy, becoming the first Latina in that role.

On Tuesday, there was little acknowledgement of Barbot's achievements during her tenure. Rather the administration appeared eager to move on.

"We appreciate her service and are looking forward to the next chapter," the mayor's office said.