When anything came to the Prophet ﷺ which caused pleasure (or, by which he was made glad), he prostrated himself in gratitude to Allah.
عَنِ النَّبِيِّ ﷺ أَنَّهُ كَانَ إِذَا جَاءَهُ أَمْرُ سُرُورٍ أَوْ بُشِّرَ بِهِ خَرَّ سَاجِدًا شَاكِرًا لِلَّهِ
When anything came to the Prophet ﷺ which caused pleasure (or, by which he was made glad), he prostrated himself in gratitude to Allah.
عَنِ النَّبِيِّ ﷺ أَنَّهُ كَانَ إِذَا جَاءَهُ أَمْرُ سُرُورٍ أَوْ بُشِّرَ بِهِ خَرَّ سَاجِدًا شَاكِرًا لِلَّهِ
It was narrated from Abu Bakrah that when the Prophet ﷺ heard news that made him happy, or for which one should be happy, he would fall down prostrate in gratitude to Allah, the Blessed and Exalted.
أَنَّ النَّبِيَّ ﷺ كَانَ إِذَا أَتَاهُ أَمْرٌ يَسُرُّهُ أَوْ يُسَرُّ بِهِ خَرَّ سَاجِدًا شُكْرًا لِلَّهِ تَبَارَكَ وَتَعَالَى
[Machine] The translation of the given phrase is: "The Messenger of Allah ﷺ used to prostrate in gratitude to Allah Almighty whenever something pleasing or joyful came to him."
كَانَ رَسُولُ اللَّهِ ﷺ «إِذَا أَتَاهُ أَمْرٌ يَسُرُّهُ أَوْ يُسَرُّ بِهِ خَرَّ سَاجِدًا شُكْرًا لِلَّهِ ﷻ»