ISLAMABAD (AP) — China on Tuesday advised its citizens in Afghanistan to leave the country “as soon as possible," following a coordinated attack by Islamic State militants the previous day on a Chinese-owned hotel in the heart of Kabul.

The Chinese advisory appeared to be a setback for Afghanistan's Taliban rulers who seek foreign investments in hopes of halting the downward spiral of the Afghan economy since their takeover of the country more than a year ago.

The militant Islamic State group — a key rival of the Taliban — claimed responsibility for the attack Monday afternoon on Kabul Longan Hotel, which left three assailants dead and at least two hotel guests injured as they tried to escape by jumping out of a window.

Plumes of smoke rose from the 10-story building in the central Shar-e Naw neighborhood, according to images posted on social media as the attack unfolded. Residents reported explosions and gunfire.

Taliban forces rushed to the area and blocked all roads leading to the site. Khalid Zadran, the Taliban-appointed spokesman for the Kabul police chief, said the attack lasted several hours, followed by a clean-up operation.

On Tuesday, Chinese Foreign Ministry spokesperson Wang Wenbin called the attack “egregious in nature” and said China was “deeply shocked.”

Beijing demanded a “thorough investigation” and urged the Taliban government “to take resolute and strong measures to ensure the safety of Chinese citizens, institutions and projects in Afghanistan,” Wang said.

The Chinese Embassy in Kabul sent its team to the site to help with the rescue, treatment and accommodations for the victims of the attack, Wang added.

“In view of the current security situation in Afghanistan, the Ministry of Foreign Affairs once again advised Chinese citizens and institutions in Afghanistan to evacuate from Afghanistan as soon as possible,” Wang said.

The Taliban swept across the country in August 2021, seizing power as U.S. and NATO forces were in the last weeks of their final withdrawal from Afghanistan after 20 years of war.

Since their takeover, the international community has balked at extending official recognition to the former insurgents who have broken promises of pursuing a more moderate path forward, including reopening schools to girls beyond the sixth grade and safeguarding minority rights.

The Taliban government has recently also made statements saying it intends to implement Islamic law, or Sharia, as it did when the Taliban previously ruled Afghanistan in the late 1990s. In the past weeks, the Taliban have carried out executions and public floggings on several occasions of those convicted in Taliban courts of crimes such as murder and adultery.

China has economic and mining interests in the country though those familiar with past talks between the Taliban and Chinese officials say Beijing wants Taliban commitments to prevent China’s Uyghur opponents from setting up operations in Afghanistan.

Chinese firms, with strong government backing, have tentatively sought to pursue opportunities in exploiting Afghanistan’s vast, undeveloped resource deposits, especially the Mes Aynak mine that is believed to hold the world’s largest copper deposit.

In October, Taliban-appointed government spokesman Zabihullah Mujahid highlighted China as a key part of Afghanistan’s economic development. China has also revealed its aspirations to play a leading role in Afghanistan following the withdrawal of U.S. forces — Chinese Foreign Minister Wang Yi at a regional conference recently led calls for the United States to unfreeze Afghan assets held abroad and end sanctions on the Taliban government.

There was no information on the identities of the injured Chinese guests at the Kabul hotel or what they were doing in Afghanistan.

The IS statement, carried by one of the militant Telegram channels used by the group, said two of its members targeted the hotel because it is frequented by diplomats and owned by “communist China."

It further claimed IS attackers detonated two bags with explosives that were left in the hotel earlier, including one in the main hall, and set fire to a part of the hotel. The militant group offered no proof for its claims.

There were conflicting reports as to the casualty numbers. Taliban officials said three assailants were killed; the IS claim said only two of its members took part in the attack, identifying them by name and posting their photographs. According to Mujahid, the Taliban government spokesman, two foreign residents were injured when they jumped out of hotel windows.

However, the Emergency Hospital in Kabul said in a tweet Monday that it received 21 casualties, including the bodies of three people.

The IS regional affiliate — known as the Islamic State in Khorasan Province — has increased its attacks since the Taliban takeover of Afghanistan in August 2021.

___

Associated Press writers Maamoun Youssef in Cairo and Riazat Butt in Karachi, Pakistan, contributed to this report.

The ɫֱ Press. All rights reserved.