[Machine] The Messenger of Allah ﷺ used to perform three tawafs around the Kaaba first when performing Hajj or Umrah. Then, he would walk four rounds between Safa and Marwa, and then pray two prostrations. This is narrated by Ibn 'Abbad, and in another narration by Shuja'. It did not mention what comes after that.
أَنَّ رَسُولَ اللهِ ﷺ كَانَ إِذَا طَافَ فِي الْحَجِّ وَالْعُمْرَةِ أَوَّلَ مَا يَقْدَمُ فَإِنَّهُ يَسْعَى ثَلَاثَةَ أَطْوَافٍ بِالْبَيْتِ ثُمَّ يَمْشِي أَرْبَعًا ثُمَّ يُصَلِّي سَجْدَتَيْنِ ثُمَّ يَطُوفُ بَيْنَ الصَّفَا وَالْمَرْوَةِ لَفْظُ حَدِيثِ ابْنِ عَبَّادٍ وَفِي رِوَايَةِ شُجَاعٍ أَنَّهُ كَانَ إِذَا طَافَ فِي الْحَجِّ وَالْعُمْرَةِ أَوَّلَ مَا يَقْدَمُ فَإِنَّهُ يَسْعَى ثَلَاثَةَ أَطْوَافٍ بِالْبَيْتِ وَيَمْشِي أَرْبَعًا لَمْ يَذْكُرْ مَا بَعْدَهُ