The Messenger of Allah ﷺ was cupped while he was in a state of ihram and fasting.
حدثنا بشر بن هلال البصري حدثنا عبد الوارث بن سعيد حدثنا أيوب عن عكرمة
احتجم رسول الله ﷺ وهو محرم صائم
No references are available.
[Sahih]. Bukhari also reported it in the Book of Fasting, Chapter on Cupping and Vomiting for the Fasting Person, no. 1939, from the hadith of Abdul-Warith, with the same wording. Muslim also reported it, no. 1202, from a different hadith on the authority of Ibn Abbas, with the same wording.