“What you have gained, an appreciation and thanks for the nuclear negotiation body and officials is befitting, and can be the basis for the next wise steps,” he said. “Undoubtedly, the … prayers and the backing of the Iranian nation was the factor in this success, and will be in the future. God willing, persistence against those who want too much has to always be the criteria for the straight path of the officials, and will always be, God willing.”

The Ayatollah’s letter may be his way protecting President Rouhani from hardliners who oppose any deal with the West.

“Khamenei does have, as best as any outsider can tell, all of the power he needs to force this through the system, to overcome the opposition of the hardliners. [But] we’ve never seen Khamenei actually overrule the hard-liners on an issue of this kind of importance,” Kenneth Pollack of the Brookings Institution told The Washington Post.