City, state and federal officials exacerbated the problems by exempting the industry from regulations, The Times revealed. The city also filled in budget gaps by selling medallions and running ads promoting the permits as “better than the stock market.”

Ms. James said that the city continued to market the medallions at inflated prices even after internal warnings were raised.

During the last auction for medallions in 2014, the city sold 350 new medallions at the height of the market, generating $359 million in revenue. Since then, medallion prices have cratered, selling for a fraction of the record $1.3 million price in 2014. In many cases, they are worth far less than what their owners borrowed to buy them.

In 2018, New York became the first major American city to adopt a one-year moratorium on issuing new vehicle licenses for Uber, Lyft and other ride-hail services. It came three years after Mr. de Blasio attempted to adopt a similar cap but abandoned the effort after Uber waged a fierce campaign against him.

Since then, the city has extended the moratorium.

“This crisis has been ours to solve — working tirelessly to clean up the carelessness and greed of others,” Ms. Goldstein said. “If the attorney general wants to launch a frivolous investigation into the very administration that has done nothing but work to improve the situation, this is what she’ll find.”

But Ms. Desai said the city’s response has been slow and its efforts so far have generally been underwhelming. She noted that the city waived some small fees for taxi owners even as they drowned under huge debts.

“There has been no substantial financial relief — this restitution would be the first,” she said.

The city comptroller, Scott M. Stringer, said Ms. James had made “significant allegations” and that his office “takes these issues very seriously.”