The Messenger of Allah ﷺ said, "When Allah completed the creation, He wrote in His book, which is with Him above the Throne, 'My mercy has prevailed over My wrath.'"
حدثنا يزيد أخبرنا محمد عن أبي الزناد عن الأعرج
قال رسول الله ﷺ لما قضى الله الخلق كتب في كتابه فهو عنده فوق العرش إن رحمتي سبقت غضبي
Its isnad is sahih. It is a longer version of 7297, and we have already covered some of its narrations there. We add here that Muslim narrated it, 2:324, through Mughira bin Abdul-Rahman from Abu Zinad, in similar wording. Bukhari narrated it, 13:325, through Amash from Abu Salih, from Abu Hurairah. It will come again in the Musnad several times, including at 7520, through the route of Warqa, from Abu Zinad.