Sunan an-Nasa'i, Volume 2, Book 13, Hadith 1214 (DarusSalam)

'Abdullah bin Nujayy narrated that his father said: "Ali said to me: 'I was so close to the Messenger of Allah, closer than anyone else. I used to come to him at the end of every night, before dawn, and say: "As-salamu 'alayka ya Nabiyy Allah (Peace be upon you, O Prophet of Allah)." If he cleared his throat I would go back to my family, otherwise I would enter upon him.'"

أَخْبَرَنَا الْقَاسِمُ بْنُ زَكَرِيَّا بْنِ دِينَارٍ، قَالَ حَدَّثَنَا أَبُو أُسَامَةَ، قَالَ حَدَّثَنِي شُرَحْبِيلُ، - يَعْنِي ابْنَ مُدْرِكٍ - قَالَ حَدَّثَنِي عَبْدُ اللَّهِ بْنُ نُجَىٍّ، عَنْ أَبِيهِ، قَالَ قَالَ لِي عَلِيٌّ كَانَتْ لِي مَنْزِلَةٌ مِنْ رَسُولِ اللَّهِ صلى الله عليه وسلم لَمْ تَكُنْ لأَحَدٍ مِنَ الْخَلاَئِقِ فَكُنْتُ آتِيهِ كُلَّ سَحَرٍ فَأَقُولُ السَّلاَمُ عَلَيْكَ يَا نَبِيَّ اللَّهِ فَإِنْ تَنَحْنَحَ انْصَرَفْتُ إِلَى أَهْلِي وَإِلاَّ دَخَلْتُ عَلَيْهِ ‏.‏

sunnah.com