The Messenger of Allah ﷺ said, "I have been granted victory through awe-inspiring fear, I have been given the gift of concise yet comprehensive speech, and while I was sleeping, the keys to the treasures of the earth were brought and placed in my hand."
حدثنا إسحاق بن عيسى أخبرنا ابن لهيعة عن عبد الرحمن الأعرج
قال رسول الله ﷺ نصرت بالرعب وأوتيت جوامع الكلام وبينما أنا نائم أوتيت بمفاتيح خزائن الأرض فوضعت في يدي
Its isnad is sahih. It has already appeared at 7620, and it is found in Nasai 6/3 no. 3087, in the chapter on jihad, on the obligation of jihad, and in Abdul-Razzaq 11/99 no. 20033, and Ibn Abu Shayba 11/432 no. 11688, in the chapter on virtues.