Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
quran:5:7

And remember the favor of Allah upon you and His covenant with which He bound you when you said, "We hear and we obey"; and fear Allah. Indeed, Allah is Knowing of that within the breasts.  

And remember God’s grace upon you, through Islam, and His covenant, His pledge, which He made, He bound, with you when you said, to the Prophet (s) upon pledging allegiance to him: ‘We hear and we obey’, all that you command and forbid, of what we love and what we despise. And fear God, in His covenant, lest you break it. Surely God knows what is in the breasts, that is, what is in the hearts ˹of people˺, all the more reason for ˹Him to have knowledge of˺ other things.
القرآن:٥:٧

وَاذْكُرُوا نِعْمَةَ اللَّهِ عَلَيْكُمْ وَمِيثَاقَهُ الَّذِي وَاثَقَكُمْ بِهِ إِذْ قُلْتُمْ سَمِعْنَا وَأَطَعْنَا ۖ وَاتَّقُوا اللَّهَ ۚ إِنَّ اللَّهَ عَلِيمٌ بِذَاتِ الصُّدُورِ  

{واذكروا نعمة الله عليكم} بالإسلام {وميثاقه} عهده {الذي واثقكم به} عاهدكم عليه {إذ قلتم} للنبي ﷺ حين بايعتموه {سمعنا وأطعنا} في كل ما تأمر به وتنهى مما نحب ونكره {واتقوا الله} في ميثاقه أن تنقضوه {إن الله عليم بذات الصدور} بما في القلوب فبغيره أولى.