President Trump threatened Monday to permanently halt U.S. funding to the World Health Organization and “reconsider” the country’s membership in the United Nations body if it does not “commit to major substantive improvements” within the next 30 days.

In a letter to the WHO posted in a late-night tweet, Trump said the global health agency floundered in its early responses to the coronavirus outbreak. In particular, he continued to attack the organization and its director general, Tedros Adhanom Ghebreyesus, accusing them of being too soft on China, where the virus is believed to have originated.

Trump temporarily suspended U.S. payments in April for 60 days, an unpopular move that critics said was aimed at distracting from his own administration’s response to the pandemic. His ultimatum Monday, which came as WHO member countries conferred about the pandemic, may provoke more backlash at the international level.

The president did not specify what changes were needed for him to restore U.S. donations, the WHO’s largest single source of funding. But he said discussions between the United States and the agency’s leaders were already underway.

“It is clear the repeated missteps by you and your organization in responding to the pandemic have been extremely costly for the world,” Trump wrote.

WHO was “considering the contents of the letter,” it said in a statement.

Although Trump at first praised China’s efforts to combat the outbreak earlier this year, he has since shifted to slamming the WHO for allegedly promoting misinformation from Beijing. His letter reiterated many of his accusations.

“The only way forward for the World Health Organization is if it can actually demonstrate independence from China,” Trump wrote.

The Chinese government immediately hit back and said the United States was using China as an excuse to shirk financial obligations that had been jointly determined by WHO member states.

“The unilateral U.S. move to stop funding is a violation of its own international obligations,” Foreign Ministry spokesman Zhao Lijian told reporters Tuesday. “We are still in a critical juncture, and supporting the WHO is upholding multilateralism and supporting international anti-pandemic cooperation to save lives.”

The Trump administration, Zhao added, was “trying to mislead the public, smear China and shift blame for its own incompetent response.”

Trump’s letter laid out the results of a probe by his administration into the WHO’s virus response. Among other new claims listed in a five-month timeline, he said the Lancet medical journal had published credible reports on an outbreak in Wuhan, China, as early as December.

But Richard Horton, chief editor of the well-known publication, said Tuesday that the journal did not publish its first reports on the coronavirus until late January.

The United States makes mandatory payments to maintain its membership in the WHO in addition to larger voluntary donations, which in total amount to about 15 percent of the agency’s budget.

Approximately $400 million in annual funds have been halted since the president’s April announcement. Administration officials have looked to redirect the WHO payments to other nongovernmental public health organizations, The Washington Post reported.

That move has sparked concerns that the United States could lose influence on the international stage to China, which has pledged to commit an additional $30 million — about one-third beyond its existing biennial donation — to the WHO.

In recent weeks, U.S. officials have appeared to loosen ties with the agency in other ways. The State Department removed mentions of the WHO from virus fact sheets, The Post reported, and staffers were ordered to “cut out the middle man” for public health initiatives previously managed through the WHO.

Trump’s letter came hours after the WHO’s member nations gathered virtually on Monday. Speaking at Tedros’s invitation, Chinese President Xi Jinping pledged to dispense $2 billion in aid and future Chinese-made vaccines.

Agreeing to cooperate with an independent probe into its pandemic response, Xi also called on the assembly to rally behind the WHO.

Trump declined an invitation to talk at the summit.

Xi’s speech, which did not acknowledge the virus’s apparent roots in China, was widely reported domestically.

On Tuesday, Chinese state media revved into gear on official channels and on social media to portray the Chinese president as a world leader who cared for the global “community” and the WHO as an indispensable agency that coordinated the international response and offered technical guidance.

Xi’s message to the world was “China is sincere, China is responsible, China is contributing,” state broadcaster anchor Guo Zhijian declared on Weibo.

Gerry Shih in Seoul contributed to this report.