USC-MSA web (English) : Book 50, Hadith 5
Narration text is preserved in its supplied Arabic and English. Translated interfaces and reading guides do not add narration translations in other languages.
إِذَا مَرِضَ الْعَبْدُ بَعَثَ اللَّهُ تَعَالَى إِلَيْهِ مَلَكَيْنِ فَقَالَ انْظُرَا مَاذَا يَقُولُ لِعُوَّادِهِ . فَإِنْ هُوَ - إِذَا جَاءُوهُ - حَمِدَ اللَّهَ وَأَثْنَى عَلَيْهِ رَفَعَا ذَلِكَ إِلَى اللَّهِ عَزَّ وَجَلَّ - وَهُوَ أَعْلَمُ - فَيَقُولُ لِعَبْدِي عَلَىَّ إِنْ تَوَفَّيْتُهُ أَنْ أُدْخِلَهُ الْجَنَّةَ وَإِنْ أَنَا شَفَيْتُهُ أَنْ أُبْدِلَ لَهُ لَحْمًا خَيْرًا مِنْ لَحْمِهِ وَدَمًا خَيْرًا مِنْ دَمِهِ وَأَنْ أُكَفِّرَ عَنْهُ سَيِّئَاتِهِ "
Yahya related to me from Malik from Zayd ibn Aslam from Ata ibn Yasar that the Messenger of Allah (ﷺ) said, "When the slave is ill, Allah ta'ala sends two angels to him." He said, "They look at what he says to his visitors. If he praises Allah and lauds Him, when they come to him, they take that up to Allah, the Mighty, the Majestic, and He knows best, and He says, 'If I make my slave die, I will make him enter the Garden. If I heal him, I will replace his flesh with better flesh and his blood with better blood and I will efface his evil actions.'"
Full reference and source
USC-MSA web (English) : Book 50, Hadith 5 Arabic : Book 50, Hadith 1718
View source on Sunnah.com (opens in a new tab)