Sunan Abi Dawud 970
Narration text is preserved in its supplied Arabic and English. Translated interfaces and reading guides do not add narration translations in other languages.
إِذَا قُلْتَ هَذَا أَوْ قَضَيْتَ هَذَا فَقَدْ قَضَيْتَ صَلاَتَكَ إِنْ شِئْتَ أَنْ تَقُومَ فَقُمْ وَإِنْ شِئْتَ أَنْ تَقْعُدَ فَاقْعُدْ "
Narrated Abdullah ibn Mas'ud:
Alqamah said that Abdullah ibn Mas'ud caught hold of his hand saying that the Messenger of Allah (ﷺ) caught hold of his (Ibn Mas'ud's) hand and taught him the tashahhud during prayer. He then narrated the (well known ) tradition (of tashahhud). This version adds: When you say this or finish this, then you have completed your prayer. If you want to stand up, then stand, and if you want to remain sitting, then remain sitting.
Full reference and source
Sunan Abi Dawud 970 In-book : Book 2, Hadith 581 English translation : Book 3, Hadith 965
View source on Sunnah.com (opens in a new tab)