Thank you for asking a question on www.thisisyourbible.com
What the scripture says about Balaam indicates that he was a genuine prophet of God.
Numbers 22:8 And he said unto them, Lodge here this night, and I will bring you word again, as the LORD shall speak unto me: and the princes of Moab abode with Balaam.
He uses the covenant name YHWH (translated LORD).
God certainly spoke to him.
Numbers 22:9 And God came unto Balaam, and said, What men are these with thee? 10 And Balaam said unto God, Balak the son of Zippor, king of Moab, hath sent unto me, saying, 12 And God said unto Balaam, Thou shalt not go with them; thou shalt not curse the people: for they are blessed. 13 And Balaam rose up in the morning, and said unto the princes of Balak, Get you into your land: for the LORD refuseth to give me leave to go with you.
The second time that Balak’s men come to him God puts him to the test.
Numbers 22:20 And God came unto Balaam at night, and said unto him, If the men come to call thee, rise up, and go with them; but yet the word which I shall say unto thee, that shalt thou do.
The instruction was to go only ‘if the men come to call thee’. From the text it seems Balaam didn’t wait to see if the men would call for him but got up, saddled his ass and went.
Numbers 22:21 And Balaam rose up in the morning, and saddled his ass, and went with the princes of Moab.
This was the reason that God was angry with him.
Numbers 22:22 And God’s anger was kindled because he went:
After three messages from God and three blessings upon Israel, Balak was understandably miffed and Balaam proceeds to pronounce a prophecy from God on ‘what this people shall do to thy people in the latter days’.
Numbers 24:10 And Balak’s anger was kindled against Balaam, and he smote his hands together: and Balak said unto Balaam, I called thee to curse mine enemies, and, behold, thou hast altogether blessed them these three times. 11 Therefore now flee thou to thy place: I thought to promote thee unto great honour; but, lo, the LORD hath kept thee back from honour. 12 And Balaam said unto Balak, Spake I not also to thy messengers which thou sentest unto me, saying, 13 If Balak would give me his house full of silver and gold, I cannot go beyond the commandment of the LORD, to do either good or bad of mine own mind; but what the LORD saith, that will I speak? 14 And now, behold, I go unto my people: come therefore, and I will advertise thee what this people shall do to thy people in the latter days.
In all this Balaam was a genuine prophet of God and gave God’s message faithfully. Afterwards to get Balak’s rewards he advised him to ensnare the Israelites by whoredom of the Midianite women and idol worship of BaalPeor, bringing God’s anger on Israel and a plague in which 24,000 died. That it was Balaam’s advice to Balak is shown in Numbers 31:16.
Numbers 31:16 Behold, these caused the children of Israel, through the counsel of Balaam, to commit trespass against the LORD in the matter of Peor, and there was a plague among the congregation of the LORD.
Balaam was slain in the retribution taken on the Midianites
Numbers 31:8 And they slew the kings of Midian, beside the rest of them that were slain; namely, Evi, and Rekem, and Zur, and Hur, and Reba, five kings of Midian: Balaam also the son of Beor they slew with the sword.
God tells Israel through Joshua:
Joshua 24:9 Then Balak the son of Zippor, king of Moab, arose and warred against Israel, and sent and called Balaam the son of Beor to curse you: 10 But I would not hearken unto Balaam; therefore he blessed you still: so I delivered you out of his hand.
Three inspired comments in the New Testament confirm that Balaam earned the wages of unrighteousness by his evil counsel.
2 Peter 2:15 Which have forsaken the right way, and are gone astray, following the way of Balaam the son of Bosor, who loved the wages of unrighteousness;
Jude 1:11 Woe unto them! for they have gone in the way of Cain, and ran greedily after the error of Balaam for reward, and perished in the gainsaying of Core.
Revelation 2:14 But I have a few things against thee, because thou hast there them that hold the doctrine of Balaam, who taught Balac to cast a stumblingblock before the children of Israel, to eat things sacrificed unto idols, and to commit fornication.
From all this it is reasonable to conclude that Balaam was a genuine prophet of God and fell (like Judas) because of his love of money.
1 Timothy 6:10 For the love of money is the root of all evil: which while some coveted after, they have erred from the faith, and pierced themselves through with many sorrows.
I hope this helps.