A policeman and the gunman were wounded, but the embassy said none of its employees was hurt. Sarajevo Mayor Alija Behmen said the gunman "got off a tram with a Kalashnikov and started shooting at the American Embassy."
Witnesses told Bosnian television that the man urged pedestrians to move away, saying he was targeting only the embassy. He wore a beard and was dressed in an outfit with short pants that reveal his ankles typical for followers of the conservative Wahhabi branch of Islam. One police officer guarding the building was wounded before police surrounded the gunman.
After a 30-minute standoff, the sound of a single shot echoed and AP video showed the shooter slump to the ground. Police arrested the wounded man who one of Bosnia's three presidents said is a foreigner and took him away in an ambulance as pedestrians cowered behind buildings and vehicles.
Hospital spokeswoman Biljana Jandric told The Associated Press the gunman had a minor wound to his leg, and would spend the night at the hospital before being released into police custody. Bosnian TV identified the shooter as Mevlid Jasarevic, from Novi Pazar, Serbia. It said he is a Wahhabi follower. Serbian Interior Minister Ivica Dacic confirmed his identity.
The Wahhabis are an extremely conservative branch which is rooted in Saudi Arabia and linked to religious militants in parts of Afghanistan and Pakistan.