He addressed the people on the day of doubt and said, "I have sat with the companions of the Messenger of Allah ﷺ and questioned them, and they told me that the Messenger of Allah ﷺ said, 'Fast when you sight it and break your fast when you sight it, and perform the rites of pilgrimage accordingly. If it is obscured from you, then complete thirty days. If two witnesses testify to its sighting, then fast and break your fast.'"
أخبرني إبراهيم بن يعقوب قال حدثنا سعيد بن شبيب أبو عثمان وكان شيخا صالحا بطرسوس قال أنبأنا ابن أبي زائدة عن حسين بن الحارث الجدلي
أنه خطب الناس في اليوم الذي يشك فيه فقال ألا إني جالست أصحاب رسول الله ﷺ وساءلتهم وإنهم حدثوني أن رسول الله ﷺ قال صوموا لرؤيته وأفطروا لرؤيته وانسكوا لها فإن غم عليكم فأكملوا ثلاثين فإن شهد شاهدان فصوموا وأفطروا
[Sahih]. It is in Al-Kubra, no. 2426, and it has a defect that undermines it as recorded by Ahmad, 4/321. The hadith has very many corroborating witnesses.Yahya bin Zakariya bin Abu Zaida narrated it from Hajjaj (bin Artaah), from Husayn bin Harith, with this same wording.