Thailand confirmed Thursday it had returned three Iranians jailed over a 2012 bomb plot in Bangkok, in an announcement that came after Tehran freed an Australian-British lecturer imprisoned for alleged spying.

The kingdom's corrections department said two of the men -- Masoud Sedaghatzadeh and Saeid Moradi -- were transferred as prisoners while the third, Mohammad Khazaei, was granted a royal pardon in August.

Thai officials have not explicitly linked the transfer with the release of Middle East scholar Kylie Moore-Gilbert, who returned to Australia after two years in detention in Iran on espionage charges.

But Iranian state TV said Wednesday that Moore-Gilbert was swapped for three Iranians.

Thai police officers escort Mohammad Kharzei during an investigation into the bomb plot / © AFP/File

The trio freed by Thailand had all been jailed over a botched bomb plot that Israel linked to a spate of attacks on its diplomats around the world.

The plot came to light on Valentine's Day 2012 when a huge explosion ripped the roof off a house in suburban Bangkok after bombs apparently detonated accidentally inside.

Moradi, aged 29 at the time, threw a bomb at police as he fled the scene but succeeded only in blowing his own legs off, while Khazaei, then 43, made it to the airport before being apprehended.

In 2013 a Bangkok court jailed Moradi for life for attempted murder and sentenced Khazaei to 15 years for possession of explosives.

Expert witnesses told the court that quantities of C4 high explosives were found concealed in radios at the house, though Moradi claimed he found the bombs by chance and was trying to dispose of them when they went off.

- Escape to Malaysia -

Sedaghatzadeh fled to Malaysia before being extradited and convicted of possessing explosives. He too was sentenced to 15 years, backdated to begin on February 15, 2012.

Two other suspects in the case are believed to have fled to Iran, and Malaysian officials said Sedaghatzadeh was trying to do the same when he was arrested.

Israel accused Tehran of waging a terror campaign over the plot, which emerged a day after bomb attacks on its diplomats in India and Georgia.

A Thai foreign ministry spokesman said the return of the two Iranians still serving sentences was "bilateral cooperation" with Tehran under an existing prisoner exchange treaty.

The Iranian embassy confirmed that four Iranian prisoners had been transferred "recently" under the treaty but gave no further details.

Moore-Gilbert was arrested by Iran's hardline Islamic Revolutionary Guard Corps in 2018 after attending an academic conference and later charged with espionage and sentenced to 10 years in jail.

The first images of her after release emerged from Iranian state television late Wednesday, sparking elation from friends and family who had campaigned for her freedom and maintained her innocence.

Footage broadcast by Iran's Irib news agency from Tehran airport showed Moore-Gilbert wearing a headscarf and a face mask which she removed to confirm her identity.

Irib also showed footage of three men -- one of them in a wheelchair -- draped in Iranian flags and being greeted as heroes by officials.