Sunan an-Nasa'i 1061
It was narrated from Anas that:
The Prophet (ﷺ) fell from a horse onto his right side, and they entered upon him to visit him. The time for prayer came, and when he had finished praying he said: "The Imam is appointed to be followed, so when he bows, then bow, and when he stands up, then stand up, and when he says: 'Sami' Allahu liman hamidah (Allah hears the one who praises Him)' then say: 'Rabbana wa lakal-hamd (Our Lord, and to You be the praise).'"
أَخْبَرَنَا هَنَّادُ بْنُ السَّرِيِّ، عَنِ ابْنِ عُيَيْنَةَ، عَنِ الزُّهْرِيِّ، عَنْ أَنَسٍ، أَنَّ النَّبِيَّ صلى الله عليه وسلم سَقَطَ مِنْ فَرَسٍ عَلَى شِقِّهِ الأَيْمَنِ فَدَخَلُوا عَلَيْهِ يَعُودُونَهُ فَحَضَرَتِ الصَّلاَةُ فَلَمَّا قَضَى الصَّلاَةَ قَالَ ‏
"‏ إِنَّمَا جُعِلَ الإِمَامُ لِيُؤْتَمَّ بِهِ فَإِذَا رَكَعَ فَارْكَعُوا وَإِذَا رَفَعَ فَارْفَعُوا وَإِذَا قَالَ سَمِعَ اللَّهُ لِمَنْ حَمِدَهُ فَقُولُوا رَبَّنَا وَلَكَ الْحَمْدُ ‏"‏ ‏.‏