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:4:166

But Allah bears witness to that which He has revealed to you. He has sent it down with His knowledge, and the angels bear witness ˹as well˺. And sufficient is Allah as Witness.  

When the Jews were asked about his ˹Muhammad’s˺ prophethood (s) and they denied him, the following was revealed: But God bears witness, He makes clear ˹the truth of˺ your prophethood, with what He has revealed to you, of the miraculous Qur’ān; He has revealed it, enveloped, through His knowledge, that is, ˹He has revealed it˺ knowing it fully, or ˹He has revealed it˺ with His knowledge therein; and the angels also bear witness, to you; and God suffices as a Witness, to this.
القرآن:٤:١٦٦

لَٰكِنِ اللَّهُ يَشْهَدُ بِمَا أَنْزَلَ إِلَيْكَ ۖ أَنْزَلَهُ بِعِلْمِهِ ۖ وَالْمَلَائِكَةُ يَشْهَدُونَ ۚ وَكَفَىٰ بِاللَّهِ شَهِيدًا  

ونزل لما سئل اليهود عن نبوته ﷺ فأنكروه {لكن الله يشهد} يبين نبوتك {بما أنزل إليك} من القرآن المعجز {أنزله} ملتبسا {بعلمه} أي عالما به أو فيه علمه {والملائكة يشهدون} لك أيضا {وكفى بالله شهيدا} على ذلك.