Iran acknowledged last May that it had discussed the issue of imprisoned Iranian-Americans with Trump administration officials at a meeting in Vienna on compliance with the nuclear accord. Another effort was made at a similar meeting in Vienna in December, The Wall Street Journal reported on Thursday, but that overture and others were rejected.

At least four American citizens and two permanent residents of the United States are known to be held in Iranian prisons. A fifth American, Robert A. Levinson, has been missing in Iran for more than a decade.

Mr. Trump has repeatedly posted on Twitter about the fate of two Iranian-Americans in particular: Baquer Namazi, 81, a former Unicef diplomat; and his son Siamak. They were convicted by an Iranian court in October 2016 of collaborating with a hostile power — meaning the United States — after a closed trial. Their convictions and 10-year sentences were upheld last November on appeal. The precise nature of the accusations against them has never been disclosed.

Mr. Taraghi refused to provide more details about the prisoners the Trump administration had been seeking to have released, but he said that Iranian officials had been contacted on numerous occasions.