Numbers 22:2

And Balak the son of Zippor saw all that Israel had done to the Amorites.

Balak the son of Zippor was the king of the Moabites at that time. Israel, returning from the conquest of Bashan, had encamped in preparation for invading Canaan on the very borders of Moab, pitched in the plains of Moab on this side of Jordan by Jericho, beside the Jordan above its entrance into the Dead Sea opposite the plain of Jericho. Balak saw that Israel was a powerful people and learned that they had destroyed the Amorites and taken possession of their land, including territory the Amorites had wrested from Moab that was now in Israel's possession.

Though Moab had not been molested by Israel, Moab had watched with troubled forebodings what happened in surrounding countries, that the Amorites before whom Moab had been forced to retreat were conquered by the Hebrews and that the hosts of Bashan had yielded before the mysterious power enshrouded in the cloudy pillar and their giant strongholds were now occupied by the Hebrews. Because of what he saw, Balak and all Moab were exceedingly terrified, filled with terror, and in trouble. Moab dared not risk attack on Israel because appeal to arms was hopeless against the supernatural agencies working for Israel, and therefore determined, as Pharaoh had done, to enlist the power of sorcery to counteract the work of God by bringing a curse upon Israel.

In that setting Balak conducted Balaam from one point to another in repeated, vain efforts to move him from steadfastness and turn the blessing of Israel into a curse. He succeeded no better than those who tried to move Luther from the word of God by compromise, for human applause and the fear of man are alike powerless to shake one who is firm as a rock and sustained by a divine power. The verse sets the context for the account of Balaam, who worked contrary to God because of selfishness and covetousness.