When the Prophet ﷺ would come out from the privy, he would say, "I seek Your forgiveness."
حدثنا عمرو بن محمد الناقد حدثنا هاشم بن القاسم حدثنا إسرائيل عن يوسف بن أبي بردة عن أبيه
أن النبي ﷺ كان إذا خرج من الغائط قال غفرانك
No references are available.
Its isnad is sahih. Tirmidhi transmitted it in the chapter on Purification, in the section on what one says upon leaving the toilet, and Ibn Majah, hadith 300, both from the hadith of Israil bin Yunus, with the same wording. Tirmidhi said, "Gharib hasan." Ibn Khuzayma graded it sahih, hadith 90, as did Ibn Hibban (al-Ihsan), 1441, and Ibn Jarud, hadith 42, and Hakim, 1/185, and Dhahabi concurred with him.