Salim Abu Nadr reported,

Abdullah bin Abu Awfa wrote to him when he set out against the Haruriyyah, and I read the letter. It said,The Messenger of Allah ﷺ, on one of the days when he faced the enemy, waited until the sun had passed its zenith. Then he stood among the people and said, "People, do not wish to meet the enemy. Ask Allah for safety. But when you do meet them, be steadfast, and know that Paradise lies beneath the shade of swords."Then he said, "O Allah, Revealer of the Book, Mover of the clouds, Defeater of the confederates, defeat them and grant us victory over them."

Azami 11145

Sahih

عن سالم أبي النضر مولى عمر بن عبيد الله- وكان كاتبا له- قال

كتب إليه عبد الله بن أبي أو فى حين خرج إلى الحرورية فقرأته فإذا فيه: إن رسول الله ﷺ في بعض أيامه التي لقي فيها العدو، انتظر حتى مالت الشمس، ثم قام في الناس، فقال: أيها الناس لا تمنوا لقاء العدو، وسلوا الله العافية، فإذا لقيتموهم فاصبروا، واعلموا أن الجنة تحت ظلال السيوف، ثم قال: اللهم منزل الكتاب، ومجري السحاب، وهازم الأحزاب، اهزمهم، وانصرنا عليهم.

الأعظمي 11145صحيح
Contents
Reference
Commentary
Ayat
Collection
Jami al-Kamil
Book
Supplications, remembrances, and prayer upon the chosen Prophet ﷺ
Chapter
Supplications of jihad
Section
Supplication when encountering the enemy
Numbering
Jami al-Kamil 11145 (2nd edition)
Azami 11145