Islamist militants killed 20 people, most of them foreigners, inside an upmarket restaurant in Bangladesh's capital, before security forces stormed the building and ended a 12-hour standoff on Saturday.
Among the dead were nine Italian nationals and three students attending college in the United States.
One victim was identified as Indian citizen Tarushi Jain, 19, who was studying at the University of California at Berkeley, according to India's minister of external affairs, Sushma Swaraj.
The other two were Emory University students, Abinta Kabir, of Miami, Florida, and Faraaz Hossain who were studying at the campus in Oxford, Georgia.
Hossain was a 2016 graduate of the school's Oxford College and a rising junior at the university's Goizueta Business School, and was from Dhaka.
The university said that Kabir was in Dhaka visiting friends and family.
"The Emory community mourns this tragic and senseless loss of one of our university family. Our thoughts and prayers go out on behalf of Abinta and her family and friends for strength and peace at this unspeakably sad time," the university said.
Islamic State said it was responsible for one of the most brazen attacks in the South Asian nation's history, but that claim has yet to be confirmed.
It marks a major escalation in a campaign by militants over the past 18 months that had targeted mostly individuals advocating a secular or liberal lifestyle in majority-Muslim Bangladesh.
The gunmen, who stormed the busy restaurant in Dhaka's diplomatic area late on Friday night, ordered all Bangladeshis to stand up before they began killing foreigners, a source briefed on the police investigation said.
Among the dead was the wife of an Italian businessman killed by a machete. She was found by her husband after he spent all night hiding behind a tree outside the cafe while the gunmen were inside, Agnese Barolo, a friend who lives in Dhaka and spoke to him, told Reuters.
Seven Italians were in the cafe when the attack started, including several working in the garment industry, Italian media have reported, while seven Japanese citizens were unaccounted for.
The killing of foreigners will likely shatter the confidence of the expatriate community in Bangladesh, many of whom work for multinationals in the country's $26 billion garment sector that accounts for around 15 percent of the economy. Bangladesh is the world's second largest apparel exporter after China.
Thirteen hostages were rescued, including one Japanese and two Sri Lankans, the army said.
Army spokesman Colonel Rashidul Hasan said he could not yet confirm the nationalities of those who had died. Most of them had been killed by "sharp weapons".
Hasan said initially that it seemed all the victims were foreigners but now the army believed some locals were among the dead as well.
Six gunmen were killed during the police operation and one was captured, Prime Minister Sheikh Hasina said in a TV broadcast after the army concluded its operation to clear the cafe. Two police were killed in the initial assault.
Islamic State, which has claimed a series of machete attacks on minority groups in Bangladesh over the past year, posted photos of bodies and blood smeared across floors that it said were dead foreigners killed in the assault.
Police did not immediately confirm whether the pictures were from the site of the massacre.
Gowher Rizvi, an adviser to Hasina, told Reuters security forces had tried to negotiate with the gunmen.
The hostage crisis began when security guards in the Gulshan district of Dhaka, popular with expatriates, noticed several gunmen outside a medical center, Rizvi said. When the guards approached, the gunmen ran into a building housing the restaurant, packed with people waiting for tables, he said.
Ali Arsalan, co-owner of the restaurant, said his staff told him the attackers yelled "Allahu Akbar" (God is Great) as they stormed the building, split between Holey Artisan Bakery and the O'Kitchen Restaurant.
The restaurant was regarded as a tranquil place that was safe to visit in an increasingly dangerous city.
Police said the assailants exchanged sporadic gunfire with police outside for several hours after the gunmen attacked the restaurant around 9:00pm on Friday.
A police officer at the scene said when security forces tried to enter the premises at the beginning of the siege they were met with a hail of bullets and grenades that killed at least two of them.
A cafe employee who escaped told local television about 20 customers were in the restaurant at the time, most of them foreigners. Some 15 to 20 staff were working at the restaurant, the employee said.
The rescued Japanese man was eating dinner with seven other Japanese, all of whom were consultants for Japan's foreign aid agency, a Japanese government spokesman said. The fate of the other seven remained unknown.
Japan's Prime Minister Shinzo Abe said the Japanese aid workers "were giving their all for the development of Bangladesh".
Bangladesh has seen a spate of murders in recent months claimed by Islamic State and al Qaeda on liberals, gays, foreigners and religious minorities.
A Hindu priest was hacked to death on Friday at a temple in Jhinaidah district, 300 km (188 miles) southwest of Dhaka.
Local authorities say no operational links exist between Bangladeshi militants and international jihadi networks. They say two local militant groups, Ansar-al-Islam and Jamaat-ul-Mujahideen, have been behind the violence over the past 18 months. Ansar pledges allegiance to al Qaeda, while Jamaat-ul-Mujahideen claims it represents Islamic State.
"The bottom line is Bangladesh has plenty of local, often unaffiliated, militants and radicals happy to stage attacks in ISIS's name," said Michael Kugelman, South Asia associate at The Wilson Centre in Washington D.C., using an acronym commonly used for Islamic State.
Islamic State had claimed more attacks in Bangladesh than in Pakistan or Afghanistan, he said.
The restaurant assault also comes after Bangladesh hanged an Islamist party leader, Motiur Rahman Nizami, on May 11 for genocide and other crimes committed during a 1971 war of independence from Pakistan. That has drawn an angry reaction and some scattered violence from supporters.
Foreign diplomats and human rights groups have warned that Bangladesh's ongoing war crime tribunals and the government's pressure on the Bangladesh Nationalist Party have created a backlash domestically, according to Brad Adams, Asia director at Human Rights Watch.
Follow VICE News on Twitter: @vicenews