26 Then Abimelech went to him from Gerar, and Ahuzzath one of his friends, and Phichol the chief captain of his army. 27 And Isaac said unto them, Wherefore come ye to me, seeing ye hate me, and have sent me away from you? 28 And they said, We saw certainly that the Lord was with thee: and we said, Let there be now an oath betwixt us, even betwixt us and thee, and let us make a covenant with thee; 29 That thou wilt do us no hurt, as we have not touched thee, and as we have done unto thee nothing but good, and have sent thee away in peace: thou art now the blessed of the Lord. 30 And he made them a feast, and they did eat and drink. 31 And they rose up betimes in the morning, and sware one to another: and Isaac sent them away, and they departed from him in peace. 32 And it came to pass the same day, that Isaac’s servants came, and told him concerning the well which they had digged, and said unto him, We have found water. 33 And he called it Shebah: therefore the name of the city is Beer-sheba unto this day.
The king spoke flattering of himself and his court, mentioning that they have done “nothing but good” to Isaac, which was clearly untrue. Isaac had been told to go away from Abimelech because he had been increasing in strength more quickly than Abimelech was comfortable with. Then, out in the wild, Isaac had had to compete with the herdmen for the ownership of his own wells. He had been insulted and hurt by these people on more than one occasion, which explains his skepticism when approached by this entourage of the king.
The king’s motive in this scene seems clear. Even after being cast out into the wild, Isaac had increased under the hand of the Lord. His growth in wealth and power had made the king even more uneasy, and so the ruler deemed it wise to obtain a treaty of peace before things got out of hand. The fact that the king brought with him the captain of his armies makes me wonder if Isaac was being forced to choose between a peace treaty or a declaration of war!
In short, the king was not here out of sincere friendship, he was here for his own motives. But Isaac was mature enough to look past the offenses of the past and do what was prudent for him, his household, and the people of Gerar. A pledge of peace really is the best outcome for everyone. So he hosts a feast for his guests, agrees to the pact, and a delicate situation is resolved.
And then, as if in response to his decency, Isaac is blessed with yet another well. He named it Shebah, which means oath. But I do not believe he was naming it after the oath he had just made with the king of the philistines. I imagine he named it after the oath that actually mattered to him, the one that had caused him to flower in the desert, the one that blessed him with wells when he treated his rude neighbors with decency. He was referring to the oath between him and God.