Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

Authorities have identified the gunman responsible for the deadly attack on an Istanbul nightclub, Turkey's foreign minister said on Wednesday, as police detained more people in connection with the shootings.

The gunman escaped after killing 39 people and wounding almost 70 in the New Year's Eve attack on the Reina nightclub, one of the city's most exclusive.

The main suspect in the Istanbul nightclub attack appears in an image released by Turkish police. Dogan News Agency via AFP - Getty Images

ISIS has claimed responsibility for the shooting, identifying the attacker as "a heroic soldier of the caliphate." The group said the rampage had been carried out "in response to a call" from its leader, Abu Bakr al-Baghdadi, although it didn't say whether it directed or merely inspired the perpetrator. They did not identify the attacker by name or provide proof he was acting on their behalf.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

"The identity of the person carrying out the attack in Ortakoy has been determined," Turkish Foreign Minister Mevlut Cavusoglu said in an interview with the state-run Anadolu news agency. Turkish authorities have yet to make the suspect's identity public and he remains at large.

Police on Wednesday detained at least five suspected ISIS militants believed to be linked to the nightclub attack, state media reported. The operation was launched in the Aegean port city of Izmir, the Anadolu agency said.

The private Dogan news agency said the police operation targeted three families who had arrived in Izmir about 20 days ago from Konya — a city in central Turkey where the gunman is thought to have been based before carrying out the attack. It said 27 people, including women and children, were taken into custody.

Related: Uneasy Peace Between Turkey, ISIS Descends Into 'Open War'

At least 14 people were previously detained in connection with the attack, including two foreigners stopped Tuesday at the international terminal of Istanbul's Ataturk Airport after police checked their cellphones and luggage, according to Anadolu.

Turkish media reports on Tuesday suggested that the gunman's wife was in custody.

In his first address to the nation since the attack, President Recep Tayyip Erdogan said he believed the purpose of the attack was to deepen fault lines within Turkish society, but suggested that the country would not be divided.

Late on Tuesday, Turkey's parliament voted to extend by a further three months a state of emergency that was declared in the aftermath of the failed July 15 coup.