The donkey replied, “Am I not the same donkey on which you have ridden all your life? Have I ever treated you like this before?” “No,” he answered.
Balaam answered, “Because you have made a fool of me! If I had a sword, I would kill you.”
Then the Lord let Balaam see the angel standing there with his sword; and Balaam threw himself face downward on the ground.
and was rebuked for his sin. His donkey spoke with a human voice and stopped the prophet's insane action.