Their evidence is ayah 159 of Surah 'Al Imran'...
Their evidence is ayah 159 of Surah 'Al Imran': “It was by some mercy of Allah that thou wast gentle to them; hadst thou been harsh and hard of heart, they would have scattered from among thee.
So pardon them, and pray forgiveness for them, and take counsel with them in the affair; and when thou art resolved put thy trust in Allah, surely Allah loves those who put their trust.” (3: 159) The answer to this is that this ayah also gives clear evidence that the Prophet (S) is not subject to the opinion of the majority.
In other words, the right of jurisdiction belongs to the Prophet even in social matters, and he has a duty, after consultation, to put his view into practice, not the opinion of others, since it says: “Take counsel with them in the affair, and when thou art resolved, put thy trust in Allah.” If it had been otherwise, and the view of others was to be acted upon.
it should have said: “When the opinion of people has been obtained on a matter, accept it and carry it out.” But we see that the ayah was not revealed in this sense. What is more, there is evidence in history, the view of the Sunnis. For example, in the peace of Hudaybiyyah. The Prophet of Islam (S) left Medina to visit the Ka'bah. Near Mecca, the representatives of the unbelievers of the Quraysh met with him and said that the Quraysh were not prepared to admit him into Mecca.
He replied that he had not come for war, but only to visit the Ka'bah. After much discussion, the Quraysh were prepared to make a peace treaty, and the Prophet, with some special conditions, agreed, although the Muslims were not happy with the agreement and wanted to enter Mecca that day.[^2] The Prophet then told the Muslims; “I am the slave and Prophet of Allah .
I will never turn away from the command of Allah, nor will He let me go.”[^3] Here, an honest reasonable question would be, what then is the meaning of the Prophet consulting with people at all? His consultations were part of a policy both of respecting and showing the value of the views of the people, and of using reason and thought in the way of progress of Islam.
Also, when faced with some obstructions by some of the tribal leaders, consultations were held with them, because, by the value, which they gave to consultation, and by the fact that they saw themselves sharing in the work, they desisted from their destructiveness.