Ashrafi said other conditions included the government working to expel the French envoy through parliament in two to three month time and Pakistan not sending its ambassador to Paris.
All protesters and their leaders arrested would be set free immediately, the spokesman said, shortly after he was released.
The Islamist group that has made blasphemy its rallying cry had sealed one of the main entrances to the capital, demanding the government sever diplomatic ties with France and expel its ambassador.
Protests broke out in several Muslim countries over France's response to a deadly attack last month on a teacher who showed cartoons mocking the Prophet Mohammad to pupils during a civics lesson.
For Muslims, depictions of the Prophet are blasphemous.
There is a history of violent reaction to alleged incidents of blasphemy in Pakistan, where insulting the Prophet Mohammad carries a mandatory death penalty.