It is narrated from Sayyiduna Ibn Mas'ud (may Allah be pleased with him) that the Prophet (peace and blessings of Allah be upon him) taught me the Tashahhud for the middle and end of the prayer, and when the Prophet (peace and blessings of Allah be upon him) would sit on his left buttock in the middle or at the end of the prayer, he would say: «التَّحِيَّاتُلِلّٰهِوَالصَّلَوَاتُوَالطَّيِّبَاتُالسَّلَامُعَلَيْكَأَيُّهَاالنَّبِيُّوَرَحْمَةُاللّٰهِوَبَرَكَاتُهُالسَّلَامُعَلَيْنَاوَعَلَىعِبَادِاللّٰهِالصَّالِحِينَأَشْهَدُأَنْلَاإِلٰهَإِلَّااللّٰهُوَأَشْهَدُأَنَّمُحَمَّدًاعَبْدُهُوَرَسُولُهُ» "All verbal, physical, and bodily acts of worship are for Allah alone. O Prophet (peace and blessings of Allah be upon him)! Peace be upon you, and may Allah's mercy and blessings descend upon you. Peace be upon us and upon the righteous servants of Allah. I bear witness that there is no deity except Allah, and that Muhammad (peace and blessings of Allah be upon him) is Allah's servant and His Messenger." Then, if it was the middle of the prayer, the Prophet (peace and blessings of Allah be upon him) would stand up after reciting the Tashahhud, and if it was the end of the prayer, after the Tashahhud, the Prophet (peace and blessings of Allah be upon him) would supplicate for whatever he wished, then he would say the Salam.
Hadith Referenceمسند احمد / مسند المكثرين من الصحابة / 4382
Hadith Gradingحکم دارالسلام:صحيح، وهذا إسناد حسن من أجل ابن إسحاق وقد صرح بالتحديث، فانتفت شبهة تدليسه.