A woman lifted up her young child to the Messenger of Allah ﷺ and asked, "Messenger of Allah, does this child have a valid Hajj?"He replied, "Yes, and you will have a reward."
أخبرنا محمد بن المثنى قال حدثنا يحيى قال حدثنا سفيان عن محمد بن عقبة عن كريب
أن امرأة رفعت صبيا لها إلى رسول الله ﷺ فقالت يا رسول الله ألهذا حج قال نعم ولك أجر
Muslim narrated it in Hajj, chapter on the validity of the Hajj of a child and the reward of one who takes him for Hajj, hadith 1336/411, from the hadith of Sufyan Thawri, with the same chain, and it is also in Sunan al-Kubra, hadith 3625.