Read 1 Kings 1 today.

This chapter includes the account of how Solomon became the successor to King David. It is a messy affair. Which reminds me that the biblical history of Israel is messy, as is all history. There are moments when the actions of the people involved make us rejoice, and there are moments when their actions bring us to tears. The Bible contains the whole story, not just the flattering ones.
1 Kings 1:5, 7, 38-40, 50-53 NLT
[5] About that time David’s son Adonijah, whose mother was Haggith, began boasting, “I will make myself king.” So he provided himself with chariots and charioteers and recruited fifty men to run in front of him.
[7] Adonijah took Joab son of Zeruiah and Abiathar the priest into his confidence, and they agreed to help him become king.
[38] So Zadok the priest, Nathan the prophet, Benaiah son of Jehoiada, and the king’s bodyguard took Solomon down to Gihon Spring, with Solomon riding on King David’s own mule. [39] There Zadok the priest took the flask of olive oil from the sacred tent and anointed Solomon with the oil. Then they sounded the ram’s horn and all the people shouted, “Long live King Solomon!” [40] And all the people followed Solomon into Jerusalem, playing flutes and shouting for joy. The celebration was so joyous and noisy that the earth shook with the sound.
[50] Adonijah was afraid of Solomon, so he rushed to the sacred tent and grabbed on to the horns of the altar. [51] Word soon reached Solomon that Adonijah had seized the horns of the altar in fear, and that he was pleading, “Let King Solomon swear today that he will not kill me!”
[52] Solomon replied, “If he proves himself to be loyal, not a hair on his head will be touched. But if he makes trouble, he will die.” [53] So King Solomon summoned Adonijah, and they brought him down from the altar. He came and bowed respectfully before King Solomon, who dismissed him, saying, “Go on home.”