Assalamu Alaykum Wa Rahmatullah.
The Awliya are bestowed the knowledge of the unseen by the Prophet SallAllahu Alayhi Wa Sallam.
With reference to Kitab al-Aqaa’id by Shaykh Abu Abdillah Shirazi Alayhi al-Rahmah, the commentary of Mishkat states, “The servant of Allah continuously transferred from one state to another until he attains the spirituality by which he gets to know the Ghayb.” (vol.2, p. 6)
Shah Abd al-‘Aziz Muhaddith al-Dehlawi Alayhi al-Rahmah writes in his Tafsir, “Having information of the proptected Tablet (Al-Lawh al-Mahfudh) and having the ability to see what is inscribed on it is also continuously narrated to have been possessed by some Awliya of Allah.” (Tafsir Azizi, Surah al-Jin)
Imam Ibn Hajar al-Makki Alayhi al-Rahmah writes in Kitab al-‘Alaam, “It is possible for the distinguished servants of Allah to know the unseen of a certain affair or judgement. This has been proved by many Awliya and is well-known.”
Imam Sha’rani writes in al-Yawaqit Wa al-Jawahir, “The Mujtahideen have a strong grasp of the unseen knowledge.”
Here are few examples.
Imam Sayyidi Abu al-Hasan Nur al-Din ‘Ali Bin Yusuf Shatnufi RadiAllahu Anhu (who is titled ‘Al-Imam al-Awhad’ by the Imam of the Science of Rijal Shams al-Din Dhahabi and by Imam Jalauddin al-Suyuti) mentioned (with authentic chains of narrations) in his renowned book, ‘Bahjat al-Asrar’:
1. Hadrat Shaikh Abul Qaasim states that once Shaikh Abu Bakr, Shaikh Abul Khair, Shaikh Ibn Mahfooz, Shaikh Abu Hafs Umar, Shaikh Abul Aas Ahmad Imkaani, Shaikh Abdul Wahab and himself (RadiAllahu Anhum) were all in the presence of the great al-Ghawth al-A’zam RadiAllahu Anhu. It was a Friday, the 30th of Jamadi-ul-Aakhir 560 A.H. During this time, Shaikh Qaasim RadiAllahu Anhu states that a young handsome youth came into the blessed court of the great Saint. He sat with great respect, and then said: “O Friend of Allah! May there be Salaams upon you. I am the month of Rajab, and I have come to give you glad tiding that this is a good month for the people. They should thus do many good deeds in this month.” Shaikh Qaasim states that on another occasion, a youth again came to al-Ghawth al-A’zam RadiAllahu Anhu and with great respect said, “I am the month of Shabaan. I have not brought any glad tidings, but have come to inform you that in this month the people of Arabia will be in difficulty. There will be wars fought in Khurasaan and there will be sickness in Iraq through which many people will die.” Shaikh Qaasim states that after a few days, news reached Baghdad of these happenings in Arabia and Khurasaan and he states that during that time a disease spread in Iraq killing scores of people.
From this incident we learn that Shaykh Abdul Qadir al-Jilani RadiAllahu Anhu was being informed about the event that were to take place in the future.
2. Abu al-Hasan ‘Ali Bin Hasan al-Samiri narrates from his father, who narrates from his father that Shaykh Jaghir RadiAllahu Anhu would display many Karamat and he constantly was in the State of Kashf (Unveiling). Once I went to him and some cows went pass. He pointed towards one of the cows and said, “That will bear a black calf on whose head will be some whiteness. it will give birth on such and such a day and time. And it will be presented to us. The poor people will sacrifice it on this day, and so and so will eat its meat.”
He then pointed towards another cow and said about the calf in its womb.
The narrator says, “By Allah! It happened exactly the way the Shaykh described.”
This is another explicit narration illustrating the Ilm-e-Ghayb of the Awliya.
Please also refer to the following article: