Isis has released a video through its Amaq news agency which purports to show the Tehran terror attack from inside the Iranian parliament building.

Apparently filmed by the assailants, the short clip shows the injured or dead body of a man in business attire lying on the floor of an office room as a man with an assault rifle walks past.

The fighters can be heard shouting in Arabic, rather than Farsi, as gunshots ring out and alarms go off in the background. "Oh God, thank you... Do you think we will leave? No! We will remain, God willing," one of them says.

Tehran was hit by twin terror attacks on Wednesday morning involving gunmen and suicide bombers at both parliament and the tomb of Ayatollah Ruhollah Khomeini in the south of the city.

Iran's state news agency has put the combined death toll at 12, and another 30 people are reported to have been injured.

The four gunmen at parliament had been surrounded and killed by security forces five hours after the attack began, the interior ministry said on Wednesday afternoon, adding that they had entering the building - where parliament was in session - dressed as women.

The governor of Tehran said one assailant had blown themselves up and another shot dead at the shrine to Ayatollah Khomeini, the leader of Iran's 1979 Islamic Revolution.

Smoke is seen coming from parliament during a terror attack claimed by Isis in Tehran on 7 June 2017 (REUTERS) (Reuters)

The intelligence ministry said security forces had arrested another "terrorist team" planning a third attack, but did not give further details.

Terror incidents are rare in the Iranian capital, and the attacks are the first of their kind claimed by Isis on Iranian soil.

Isis is at war with Iran-backed forces in both Syria and Iraq, and views Shia Islam as heretical. In recent months there has been a marked step up in propaganda targeting majority-Shia Iran on the militant Sunni group's news networks, as well as messaging in Persian aimed at recruiting Iranian Sunnis.