The Division of Spoils and Dishonesty regarding them - Section 2 Mishkat al-Masabih 4018
Arabic hadith text
وَعَنِ ابْنِ عَبَّاسٍ أَنَّ النَّبِيَّ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ تَنَفَّلَ سيفَه ذَا الفَقارِ يومَ بدْرٍ رَوَاهُ أَحْمد وَابْن مَاجَهْ وَزَادَ التِّرْمِذِيُّ وَهُوَ الَّذِي رَأَى فِيهِ الرُّؤْيَا يَوْم أحد
Translation
Ibn 'Abbas said that the Prophet got his sword Dhul Fiqar as private booty at the battle of Badr. Ibn Majah transmitted it, and Tirmidhi added that it was that about which he had the vision at the battle of Uhud.