Iran killed an American contractor, wounding many. We strongly responded, and always will. Now Iran is orchestrating an attack on the U.S. Embassy in Iraq. They will be held fully responsible. In addition, we expect Iraq to use its forces to protect the Embassy, and so notified!

"Our first priority is the safety and security of US personnel," he tweeted. "The United States has acted quickly, prudently, and decisively, taking additional security measures to address threats to American diplomats and facilities in Baghdad."

Our first priority is the safety and security of U.S. personnel. The United States has acted quickly, prudently, and decisively, taking additional security measures to address threats to American diplomats and facilities in Baghdad. pic.twitter.com/1xexNc4iQb December 31, 2019

In the wake of US airstrikes in Iraq that killed members of the Iranian-backed Kataib Hezbollah, Iran is seizing the opportunity to use its clandestine networks in Iraq to push the US to leave the country. America has already left Iraq twice before, in the 1990s and in 2011. Iran wagers it can leverage the airstrikes to mobilize people against the US in Iraq.

On Tuesday morning, hundreds of protesters gathered outside the US Embassy in Baghdad. Along with well-known pro-Iranian politicians and militia leaders, such as Hadi al-Amiri, they proceeded to storm the embassy compound and set fires. On the embassy compound, they raised the flag of Kataib Hezbollah (the Hezbollah Brigades), a militia that US airstrikes had targeted. US forces remained inside throughout the afternoon as crowds swelled. The pro-Iranian protesters set up tents, hoping to stay at the compound to evict the US.

The US presence in Iraq has been opposed by Iranian-backed militias and also by politicians across the spectrum of parties for years. From Ali al-Sistani to Muqtada al-Sadr and pro-Iranian politicians, such as al-Amiri, Iran hopes it can use a variety of methods to evict the US.

On Tuesday, funerals were held for the members of Kataib Hezbollah killed in US airstrikes. The brigades and other pro-Iranian groups in Iraq have been responsible for more than a dozen attacks on bases and facilities where US forces are present. Since February, they have been aiming rockets at American forces. It began with harassing attacks in May, escalating in October and November. Salvos of Iranian-made 107-mm. rockets were used, fired from the back of improvised trucks.

Washington warned of a decisive response in May and December. In addition, the US sanctioned both Qais Khazali, head of the Asaib Ahl al-Haq militia, and Harakat Hezbollah al-Nujaba, another pro-Iran militia. Kataib Hezbollah had already been sanctioned. Then on December 27, a US contractor was killed when 32 rockets fired by the brigades hit the K-1 base. Four American soldiers were reportedly wounded. The US ordered hits on five of the brigades’ targets in Syria and Iraq.

The strikes were a larger retaliation than Iran had expected. Tehran had already mined ships in May and June and it downed a US drone in June. It did not expect that much would happen. Kataib Hezbollah is regularly in contact with the Islamic Revolutionary Guard Corps and its Quds Force commander Qasem Soleimani. But they were not on alert. The US airstrikes killed up to 30 Kataib members and wounded 50, according to Iranian reports.

In response, Iran is mobilizing. First, it encouraged Iraq’s prime minister, who resigned in late November but is running a caretaker government, to hold a National Security Council meeting. He says he had been phoned by US Secretary of State Mike Pompeo about the airstrikes and had opposed them, adding it was a dangerous escalation and a violation of Iraq’s sovereignty. Adel Abudl Mahdi told those assembled at his meeting that he had tried to warn the Popular Mobilization Units, of which Kataib Hezbollah is a part, that airstrikes were imminent.

Now the Iranian IRGC is entering the fray. It has said the PMU has a right to retaliate. The corps appeared to be speaking on behalf of Iraq and the PMU on Tuesday, indicating how the IRGC views Iraq almost as a colony – or at least as a place where what it says is also policy in Iraq. We know from Iranian intelligence leaks how confident Iran is of its control of Iraq’s government. Iranian intelligence officials openly talk about various ministers being pro-Iran or loyal to Iran. Tehran collects intelligence on the disposition of US forces in Iraq and has sought to bring those in Iraq, who formerly worked with the US, under their influence.

Since October, Iran has been on the defensive in Iraq because massive protests in Shi’ite areas of Iraq have targeted Iran’s consulates and the offices of groups including the Badr Organization, Asaib Ahl al-Haq and Kataib Hezbollah. Iraqis are angry at the role of pro-Iranian militias. The airstrikes have given Iran a moment to collect itself and try to change the narrative. It tried to mobilize protests in southern Iraq on Monday and Tuesday – and wants protesters to lay siege to the US Embassy in Baghdad.

Other Iraqi politicians have condemned the attacks. President Barham Saleh has critiqued them. Former prime minister Haider al-Abadi condemned the attacks, as well as Qais Khazali and the PMU commander in Anbar, Qassem Musleh. He told Al-Monitor “we heard a lot of discussion about the US and Israel planning to attack.” He said the government was weak and had allowed foreign interference in the country. The US attack will make the PMU stronger, Musleh said.

Sadr will now work to get US forces to leave Iraq, according to Reuters. Sistani was also angered by the airstrikes, saying the misbehavior of some who fired rockets was not an excuse for them. Now protesters have gathered outside the US Embassy in Baghdad. Rumors say US staff have been evacuated. The protesters are erecting tents and appear to want to stay for the long term.

Interior Minister Yassin al-Yasiri said the US had invited the “trouble” by attacking the militia. “These are the dangerous ramifications of this strike; what happened today is the danger that we were afraid of – and that the Americans should have been afraid of,” he said.

Iran’s goal now is to try to shift Iraqi focus from the protests over the last two months, where Iranian-backed militias killed 500 Iraqis and wounded 19,000, to try to get Iraqis angered over the US airstrikes. This will be a complex struggle for Iran because Iraq is a complex and divided country. But Tehran has feasted on these divisions and carved out its own IRGC in Iraq, seeking to slowly take over Iraqi institutions and the country’s economy.

Reuters contributed to this report.