He then brought as much (money) as he promised. The Prophet (ﷺ) asked: From where did you acquire this gold? He replied: From a mine. He said: We have no need of it; there is no good in it. Then the Messenger of Allah (ﷺ) paid (the debt) on his behalf.
In-book : Book 23, Hadith 3
English translation : Book 22, Hadith 3322