Brig. Gen. Esmail Qaani, head of the foreign-ops Quds Force division of Iran’s terrorist Islamic Revolutionary Guard Corps (IRGC), surfaced in Iraq on Saturday for meetings with Shiite militia groups loyal to Tehran. Qaani’s visit was part of a complex power struggle over the Iraqi prime minister’s office.

Qaani kept a low profile throughout much of the U.S.-Israeli conflict with Iran. He seemed to disappear entirely in March, leading to speculation he had been killed by an airstrike, but he sent a congratulatory message to his forces in early April for supposedly administering “regrettable lessons to the enemies of humanity.”

Qaani’s predecessor, Brig. Genl Qassem Soleimani, was liquidated by a U.S. airstrike near the airport in Baghdad, Iraq, in January 2020. Soleimani was in Iraq to coordinate attacks on American positions with Iran’s puppet Shiite militia groups, most of which became deputy members of the Iraqi military under the rubric of “Popular Mobilization Forces” (PMF) when the Iraqi government was desperate for manpower to fight the insurgent Islamic State.

Iran’s proxies in Iraq have occasionally launched attacks against American bases since Soleimani’s death, rebranding themselves as the “Islamic Resistance in Iraq” (IRI).

The IRI launched drone attacks on behalf of Iran during the conflict in March. Most of their targets were in the Iraqi Kurdistan region, where the U.S. has bases, including at the Erbil International Airport.

The largest of the Iraqi Shiite militias, Kataib Hezbollah (KH), said it wanted to drag the U.S. into “a long war of attrition,” after which the militias would “leave no American presence in the region generally, especially in Iraq.” The founder of KH, Abu Mahdi al-Muhandis, was killed in the same airstrike that eliminated Soleimani in 2020.

The National reported that Qaani was in Baghdad on Saturday to hold meetings with “pro-Tehran militias and political leaders.” The meeting had a heavy political dimension because Iraq is currently struggling to fill the prime minister’s office, and the power of the Shiite militias gives Tehran effective veto power over candidates.

“Brig Gen Qaani’s presence in Baghdad is significant. He has not been seen publicly since the outbreak of the Iran war and his visit signals Tehran’s direct involvement in shaping Iraq’s government and orchestrating the activities of armed factions,” The National noted.

Qaani issued a fiery statement in which he declared Iraq was “too great for anyone to interfere in its affairs, especially war criminals, particularly those who have committed crimes against humanity.”

“The selection of the prime minister rests entirely with the Iraqi people,” he declared, even though the entire point of his visit was to make it clear that the weakened government in Tehran still has a say in the matter.

According to Iraqi Shiite politicians who met with Qaani, a major goal of his visit was to rally the Shiites under Iran’s leadership and get them to set aside their squabbles, so they could use their combined strength to seat a prime minister in Iraq.

So far, the Iraqi Shiites have only managed to keep the prime minister’s office vacant. After five months of political turmoil, Iraq held a presidential election this month, and the winner was Nizar Amidi of the Patriotic Union of Kurdistan party. The first round of voting was close, but Amidi was the runaway winner in the second round of voting.

Under the Iraqi constitution, the president has only 15 days to form a government and seat a prime minister, working with the largest bloc in parliament. This usually causes a great deal of post-election scrambling, as various parties form alliances to declare themselves the “largest bloc” and gain the power to appoint a prime minister. To date, no Iraqi government has ever been formed within the 15-day timetable, and the process has been known to drag out for almost a year.

Iraqi Kurds are currently fragmented by their own internal disagreements, so Amidi lacks the muscle to form a government led by his own party and regional interests. Also, Iraq has been burdened with the same kind of sectarian power-sharing balancing act as Lebanon, so the president is usually Kurdish, the speaker of parliament is usually a Sunni Arab, and the prime minister is usually a Shiite.

The largest bloc at the moment is a group of Shiite parties known as the Shia Coordination Framework, but its members have been unable to agree on a candidate for prime minister.

The current caretaker prime minister, Mohammed Shia al-Sudani, has a good deal of support to continue in the office, but many legislators in the Shia Coordination Framework prefer Nouri al-Maliki, a former prime minister who is more openly pro-Iran than Sudani.

The United States is strongly opposed to Maliki, which is a major reason why Qaani turned up in Baghdad on Saturday to mutter about the malign influence of “war criminals.”

In January, President Donald Trump directly told Iraq not to name Maliki as prime minister, calling him a “very bad choice” and pointing out that Iraq “descended into poverty and total chaos” the last time he was in power. He threatened to withdraw all U.S. support for Iraq if Maliki became prime minister again.

According to Al Jazeera News, Qaani paid a surprise visit to Baghdad at the invitation of Sudani, who asked him to talk the Shia Coordination Framework out of nominating Maliki or his ally Bassem al-Badri for prime minister. Badri is apparently a popular choice with the Shiite power brokers because he does not lead a party of his own. Before Qaani’s visit on Saturday, he had very nearly secured the support he needed to take the office.

Qaani made a point of visiting Baghdad while U.S. envoy Tom Barrack was there.

“The simultaneous arrival of these rival mediators underscores the precarious state of Iraqi sovereignty as the country’s rival Shiite factions remain paralyzed by internal competition and external economic pressures,” Kurdistan24 said.

The day before Qaani’s visit, the U.S. Treasury Department announced new sanctions against seven Iraqi militia commanders, including commanders from KH.

“We will not allow Iraq’s terrorist militias, backed by Iran, to threaten American lives or interests. Those who enable these militias’ violence will be held accountable,” said Treasury Secretary Scott Bessent.

Kurdistan24 reported that Maliki was “visibly angry” at the suggestion that he should withdraw in favor of Badri as a compromise candidate, while Sudani is making a play to remain as a prime minister who could be friendly to Iran’s interests without alienating the United States. The U.S. has only publicly stated that Maliki is unacceptable, so it was not clear if Barrack was in Baghdad to push for any particular alternative candidate.