All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad, sallallaahu ‘alayhi wa sallam, is His slave and Messenger.
This Hadeeth as you quoted it in the question was reported by Al-Khateeb Al-Baghdaadi in Taareekh Baghdaad, but we have not found any scholar assessing whether it is Saheeh (sound) or Dha‘eef (weak).
Indeed, the history literature cannot be relied upon as it comprises everything that was reported without verification of its authenticity. Imaam Ahmad said: "There are three literatures that have no basis: (the literature on) the Maghaazi (battles of the early Islamic community), the Malaahim (great Islamic wars) and Tafseer (interpretation of the Quran)."
Ibn Taymiyyah said clarifying what Imaam Ahmad had meant: "Because the Ahaadeeth in these books are generally Mursal Ahaadeeth." (a Mursal Hadeeth is a Hadeeth narrated by a Tabi'i [successor of the Prophet's Companions]).
Allaah Knows best.