1 KINGS 13
1 And, behold, there came a man of Elohim out of Judah by the word of Yahweh unto Bethel: and Jeroboam stood by the altar to burn incense.
Jeroboam's policy was to widen the breach between the two kingdoms, and sever the links that held them together -- the common interest which was the one great object of the Law to combine and interlace. To that end he sacrificed the most sacred and inviolable privileges and obligations of the covenant people, by forbidding his subjects to resort to the temple of He who set him in power, by elevating common people as priests, by himself acting as high priest to the imitation of Egyptian gods he had set up in the name of Yahweh (as did Aaron in the matter of the golden calf beforehand).
He met a situation that could only be satisfactorily handled in faith, by his own earthly diplomacy -- and so failed. The great sin of Jeroboam was not merely idolatry (for Solomon and Rehoboam were both guilty of that) but compromise, a policy of expediency which perverted Truth by superimposing upon it pagan principles.
...Jeroboam believed that the end justified the means. So the king's apostasy was publicly rejected by disfellowshipment, enacted by the nameless prophet recorded in this chapter.
18 He said unto him, I am a prophet also as thou art; and an angel spake unto me by the word of Yahweh, saying, Bring him back with thee into thine house, that he may eat bread and drink water. But he lied unto him.
But though we, or an angel from heaven, preach any other gospel unto you than that which we have preached unto you, let him be accursed - Gal 1: 8.