Two Jordanians have been killed and an Israeli wounded by gunfire in a residential building in the heavily fortified Israeli embassy compound in Jordan's capital Amman, the kingdom's Public Security Directorate said.

The shooting took place on Sunday evening in a residential building used by embassy staff.

On Monday, Israel's Foreign Ministry said a security guard shot and killed the Jordanians in a confrontation.

Police said that the two Jordanians worked for a furniture company and entered the embassy compound to carry out repairs.

Israeli media say the guard opened fire, killing the 17-year-old Jordanian. The reports say the Jordanian owner of the apartment was hit by gunfire inadvertently and later died.

The Israeli was in "unstable" condition, reported news site Hala Akhbar, linked to the Jordanian military.

READ MORE: Jordanian sentenced to life for killing US trainers

"We have started a large-scale investigation into the incident and ordered the prosecutor general to look at all the details," the police said in a statement.

Jordanian security forces were deployed in the streets around the embassy, police said.

Mounting tensions

The incident comes at a time of mounting tensions between Israel and the Muslim world over metal detectors Israel installed around the al-Aqsa Mosque.

Earlier on Sunday, Jordan requested an urgent meeting for Arab foreign ministers to discuss the situation.

Thousands of Jordanians took to the streets of Amman after Friday prayers to denounce the Israeli measures at the al-Haram al-Sharif mosque compound.

Jordan is the official custodian of Muslim holy sites in Jerusalem.