The Messenger of Allah ﷺ said, "Whoever relates a hadith while believing it to be a lie is himself one of the liars."
حدثنا وكيع قال قال شعبة وحدثنا الحكم عن عبد الرحمن بن أبي ليلى
قال رسول الله ﷺ من حدث بحديث وهو يرى أنه كذب فهو أحد الكاذبين
Its isnad is sahih. It was mentioned previously at 20039.