A gunman killed one and wounded two others when he opened fire on a guard post outside <a href="https://www.thenationalnews.com/business/energy/2023/01/17/masdar-signs-agreements-with-azerbaijan-to-develop-renewable-energy-projects/" target="_blank">Azerbaijan's</a> embassy in <a href="https://www.thenationalnews.com/world/europe/2023/01/24/un-nuclear-chief-headed-to-tehran-in-february/" target="_blank">Tehran</a>, the foreign ministry in Baku said on Friday as it denounced the "act of terrorism" and blamed Iran for failing to protect its mission. Police in Tehran said they had arrested a suspect and Iranian authorities condemned the incident but played down talk of any political motive for the attack. “The attacker broke through the guard post, killing the head of security with a Kalashnikov assault rifle,” Azerbaijan's foreign ministry said. A video posted on social media appeared to show a gunman running past a guard post and forcing his way into the embassy building, firing through a door. Tehran’s police chief, Gen Hossein Rahimi, blamed the attack on “personal and family problems”, according to Iranian state television. Iranian Foreign Minister Hossein Amirabdollahian, quoted on a government site, said that based on evidence and initial observations the gunman's motive was "completely personal". "Necessary security measures have been taken to continue normal activities at the embassy and diplomats of the Republic of Azerbaijan in Tehran," he said. However, the Azeri foreign ministry said it planned to remove its embassy staff from Tehran and summoned the Iranian ambassador in Baku to express its anger and demand justice. The incident comes two weeks after Azerbaijan appointed its first ambassador to Israel in the middle of <a href="https://www.thenationalnews.com/mena/2021/10/01/iran-holds-military-exercises-near-tense-azerbaijan-border/" target="_blank">escalating tensions with its large southern neighbour, Iran</a>. In a strongly worded statement, the ministry said an "anti-Azerbaijani campaign" in Iran had contributed to the attack, without elaborating, and accused Tehran of long ignoring its appeals to bolster security at the embassy. "Unfortunately, the latest bloody terrorist act demonstrates the serious consequences of the failure to give the necessary attention to our constant appeals in this regard," it said. In a separate statement on Twitter, Azerbaijan's President Ilham Aliyev demanded swift punishment for those involved in the "act of terrorism". Video purportedly from the scene of the attack showed an empty diplomatic police post near the embassy. The clips also appeared to show a wounded man in an SUV parked outside the embassy and another from inside the outpost showed a view past metal detectors of paramedics standing over what appeared to be a body in a small office. Azerbaijan’s Foreign Ministry said the attacker destroyed the embassy's guard post with assault rifle fire before being stopped by one of the wounded guards, whom authorities described as being in a satisfactory condition after being shot. The ministry said that “an investigation is currently under way into this treacherous attack”. "The recent anti-Azerbaijani campaign against our country in Iran has encouraged such attacks against our diplomatic mission. “There have been attempts to threaten our diplomatic mission in Iran before, and measures to prevent such situations and to ensure the safety of our diplomatic missions have been constantly raised before Iran,” the ministry said. “Unfortunately, the last bloody terrorist attack demonstrates the serious consequences of not showing proper sensitivity to our urgent appeals in this direction.” Azerbaijan’s Foreign Ministry said it would evacuate its diplomatic mission, accusing Iran of not taking reported threats against it seriously in the past. Iranian authorities, meanwhile, replaced Gen Rahimi as police chief hours later after footage emerged that appeared to show a police officer doing nothing to stop the attack. Mr Aliyev signed a presidential decree appointing Mukhtar Mammadov, a veteran official who has held posts in the foreign and education ministries, as Baku's first envoy to Israel after 30 years of bilateral relations. Israel has had an embassy in Baku since the early 1990s and has been a significant military backer of Azerbaijan in recent years, including diplomatic support for Baku in its stand-off with Armenia over the Nagorno-Karabakh region. Azerbaijan also supplies about 40 per cent of Israel's oil imports and Mr Aliyev and Israeli Prime Minister Benjamin Netanyahu regularly praise the strong relations between their countries. Mr Amirabdollahian last year accused Israel of <a href="https://www.thenationalnews.com/uae/azerbaijan-israel-won-t-use-our-bases-for-iran-strike-1.394927" target="_blank">establishing a military presence and secret alliance</a> with Azerbaijan. Baku rejected the claims, but Iran mounted large-scale military exercises along the border with Azerbaijan. Mr Aliyev responded by posing for photographs with Israeli kamikaze drones, which are manufactured in Azerbaijan.