Obedience to the command of Allah is an obligatory duty
Allah, the Exalted, says:
"But no, by your Rubb, they can have no Faith, until they make you (O Muhammad (PBUH)) judge in all disputes between them, and find in themselves no resistance against your decisions, and accept (them) with full submission.'' (4:65)
"The only saying of the faithful believers, when they are called to Allah (His Words, the Qur'an) and His Messenger (PBUH), to judge between them, is that they say: `We hear and we obey.' And such are the successful (who will live forever in Jannah).'' (24:51)
168. Abu Hurairah (May Allah be pleased with him) reported: When it was revealed to Messenger of Allah (PBUH): "To Allah belongs all that is in the heavens and all that is on the earth, and whether you disclose what is in your own selves or conceal it, Allah will call you to account for it,'' the Companions of Messenger of Allah (PBUH) felt it hard and severe and they came to Messenger of Allah (PBUH) and sat down on their knees and said: "O Messenger of Allah, we were assigned some duties which were within our power to perform, such as Salat (prayer), Saum (fasting), Jihad (striving in the Cause of Allah), Sadaqah (charity). Then this (the above mentioned) Verse was revealed to you and it is beyond our power to live up to it.'' Messenger of Allah (PBUH) said, "Do you want to say what the people of two Books (Jews and Christians) said before you: 'We hear and disobey?' You should rather say: 'We hear and we obey, we seek forgiveness, our Rubb and unto You is the return.''' And they said: "We hear and we obey, (we seek) Your forgiveness, our Rubb! And unto You is the return.'' When the people recited it and it smoothly flowed on their tongues, then Allah revealed immediately afterwards: "The Messenger (Muhammad (PBUH)) believes in what has been sent down to him from his Rubb, and (so do) the believers. Each one believes in Allah, His Angels, His Books, and His Messengers. (They say), 'We make no distinction between one another of His Messengers' - and they say, 'We hear, and we obey. (We seek) Your forgiveness, our Rubb, and to You is the return (of all)". When they did that, Allah abrogated this (Ayah) and Allah the Great revealed: "Allah burdens not a person beyond his scope. He gets reward for that (good) which he has earned, and he is punished for that (evil) which he has earned.'' (The Prophet (PBUH) said): "Yes. 'Our Rubb! Lay not on us a burden like that which You did lay on those before us (Jews and Christians)". (The Prophet (PBUH) said): "Yes. 'Our Rubb! Put not on us a burden greater than we have strength to bear". (The Prophet (PBUH) said): "Yes. 'Pardon us and grant us forgiveness. Have mercy on us. You are our Maula (Patron, Supporter and Protector) and give us victory over the disbelieving people".
He (the Prophet (PBUH)) said: "Yes".
Commentary: We learn from this Hadith that initially every person was answerable for thoughts and doubts even those which crossed his mind; something on which nobody had any control. The Companions of the Prophet (PBUH) were naturally disturbed on this situation. But when they heard and obeyed the orders of the Prophet (PBUH) then Almighty Allah revoked this order with the elaboration that He does not put anyone to trouble beyond his capacity. It is, therefore, essential for every Muslim to obey all the Injunctions of Allah because none of it is such that he is unable to carry out.