22Joshua summoned them, and said to them, “Why did you deceive us, saying, ‘We are very far from you,’ while in fact you are living among us? 23Now therefore you are cursed, and some of you shall always be slaves, hewers of wood and drawers of water for the house of my God.” 24They answered Joshua, “Because it was told to your servants for a certainty that the LORD your God had commanded his servant Moses to give you all the land, and to destroy all the inhabitants of the land before you; so we were in great fear for our lives because of you, and did this thing. 25And now we are in your hand: do as it seems good and right in your sight to do to us.” 26This is what he did for them: he saved them from the Israelites; and they did not kill them. 27But on that day Joshua made them hewers of wood and drawers of water for the congregation and for the altar of the LORD, to continue to this day, in the place that he should choose.
1When King Adoni-zedek of Jerusalem heard how Joshua had taken Ai, and had utterly destroyed it, doing to Ai and its king as he had done to Jericho and its king, and how the inhabitants of Gibeon had made peace with Israel and were among them, 2he became greatly frightened, because Gibeon was a large city, like one of the royal cities, and was larger than Ai, and all its men were warriors. 3So King Adoni-zedek of Jerusalem sent a message to King Hoham of Hebron, to King Piram of Jarmuth, to King Japhia of Lachish, and to King Debir of Eglon, saying, 4″Come up and help me, and let us attack Gibeon; for it has made peace with Joshua and with the Israelites.” 5Then the five kings of the Amorites – the king of Jerusalem, the king of Hebron, the king of Jarmuth, the king of Lachish, and the king of Eglon – gathered their forces, and went up with all their armies and camped against Gibeon, and made war against it.
6And the Gibeonites sent to Joshua at the camp in Gilgal, saying, “Do not abandon your servants; come up to us quickly, and save us, and help us; for all the kings of the Amorites who live in the hill country are gathered against us.” 7So Joshua went up from Gilgal, he and all the fighting force with him, all the mighty warriors. 8The LORD said to Joshua, “Do not fear them, for I have handed them over to you; not one of them shall stand before you.” 9So Joshua came upon them suddenly, having marched up all night from Gilgal. 10And the LORD threw them into a panic before Israel, who inflicted a great slaughter on them at Gibeon, chased them by the way of the ascent of Beth-horon, and struck them down as far as Azekah and Makkedah. 11As they fled before Israel, while they were going down the slope of Beth-horon, the LORD threw down huge stones from heaven on them as far as Azekah, and they died; there were more who died because of the hailstones than the Israelites killed with the sword.
12On the day when the LORD gave the Amorites over to the Israelites, Joshua spoke to the LORD; and he said in the sight of Israel, “Sun, stand still at Gibeon, and Moon, in the valley of Aijalon.” 13And the sun stood still, and the moon stopped, until the nation took vengeance on their enemies. Is this not written in the Book of Jashar? The sun stopped in mid-heaven, and did not hurry to set for about a whole day. 14There has been no day like it before or since, when the LORD heeded a human voice; for the LORD fought for Israel.
15Then Joshua returned, and all Israel with him, to the camp at Gilgal.