Surah 4

Surah 4:59

"You who believe! Obey God, and obey the messenger and those (who have) the command among you. If you argue about anything, refer it to God and the messenger, if you believe in God and the Last Day. That is better and fairer in interpretation."

4.59 – You who believe! Obey God, and obey the messenger
Commands to obey “the messenger” appear several times in Sūra 4 (also vv. 13, 69; cf. vv. 14, 42). Such verses became very important in the writings of the influential Muslim jurist al-Shāfi‘ī (d. 820), who insisted they gave divine authority to the sayings (“hadith”) attributed to Muhammad. See the summary of commands to obey the messenger at 64.12.
Shi‘ite Muslims, on the other hand, believe that the phrase “and those (who have) command among you” refers to the line of twelve “Imams” who lead the Shi‘a community.

- from The Quran with Christian Commentary: A Guide to Understanding the Scripture of Islam