"Now when Balaam saw that it pleased the Lord to bless Israel, he did not go as at other times, to seek to use sorcery, but he set his face toward the wilderness. And Balaam raised his eyes, and saw Israel encamped according to their tribes; and the Spirit of God came upon him." (v.1-2)
What’s amazing here is that "the Spirit of God came upon" this false prophet (Balaam) at all. Meaning, God speaks to and through mankind at His good pleasure to accomplish His purposes.
In Numbers 22:21-33, the Lord spoke to Balaam through a donkey, and here in this chapter, God speaks through this donkey of a man, to the coalition leaders of Moab and Midian, letting them know their days were numbered.
We live because God ordains it (v.23). His purpose is to give all a chance to be "born again," to be "born of the Spirit," to "believe," to have "everlasting life,” as Jesus later revealed and encouraged all in John Chapter 3. That is why you live.
The opportunity is yours through faith in the Lord Jesus Christ, that you may have everlasting life.
The Truth: “He who believes in Him is not condemned; but he who does not believe is condemned already, because he has not believed in the name of the only begotten Son of God. And this is the condemnation, that the light has come into the world, and men loved darkness rather than light, because their deeds were evil.” (John 3:18-19)