3 So Adoni-Zedek king of Jerusalem sent a message to Hoham king of Hebron. He also sent it to Piram king of Jarmuth, Japhia king of Lachish, and Debir king of Eglon. The king of Jerusalem begged these men,
4 “Come with me and help me attack Gibeon. Gibeon has made a peace agreement with Joshua and the Israelites.”
5 Then these five Amorite kings joined their armies. They were the kings of Jerusalem, Hebron, Jarmuth, Lachish and Eglon. These armies went to Gibeon, surrounded it and attacked it.
6 The Gibeonites sent a message to Joshua in his camp at Gilgal. The message said: “We are your servants. Don’t let us be destroyed. Come quickly and help us! Save us! All the Amorite kings from the mountains have joined their armies. They are fighting against us.”
7 So Joshua marched out of Gilgal with his whole army. His best fighting men were with him.
8 The Lord said to Joshua, “Don’t be afraid of those armies. I will allow you to defeat them. None of them will be able to defeat you.”
9 Joshua and his army marched all night to Gibeon. So Joshua surprised them when he attacked.