Turkish police have arrested a female suspect after an attack on the US consulate building in Istanbul.

Two assailants, a woman and a man, opened fire on the US diplomatic mission in Istanbul's Sariyer district. The woman was injured when police shot back and was later arrested in a nearby building where she was hiding.

No one else was hurt in the attack. The US consulate said on Twitter it was working with Turkish authorities to investigate the incident and announced it is closed to the public until further notice.

"We're still working to find out what's going on," a spokesman for the US embassy in Ankara told AFP. Police cordoned off streets around the consulate building, which is located in the European side of the city.

According to some unconfirmed reports, the two attackers are members of the far-left Revolutionary People's Liberation Party/Front (DHKP/C), a virulently anti-US and anti-Nato organisation that has waged a long-running war against the Turkish state and its security apparatus. The group claimed responsibility for January's suicide attack in Istanbul's tourist district of Sultanahmet that left the female bomber and a policeman dead.

Earlier on Monday (10 August), two gunmen and a senior officer from police bomb squad were killed after a vehicle packed with explosives was detonated at a police station in the Sultanbeyli district on Istanbul's Asian side. The bombing also injured ten people, including seven police officers.

The two attackers were killed by police but their political affiliation was not clear.

Turkey has stepped up military operations against the banned Kurdistan Workers Party (PKK) and Islamic State (Isis). The PKK has claimed credit for killing 20 people, including police officers and security, in Turkey over the past few weeks in revenge against airstrikes.

UPDATE: The female militant who was arrested after attacking the US consulate has been identified as Hatice Asik, 51, a DHKP-C member who has been arrested and released in the past.