And Yahweh gave it also, with its king, into the hand of Israel. He struck it with the mouth of the sword and all the souls who were in it. He left none remaining in it. He did to its king as he had done to the king of Jericho. Bible

“He struck it.” The “He” is purposely ambiguous. The third person masculine singular could be Yahweh, it could be Joshua as the leader of the army, or it could refer to Israel as a collective fighting group. Actually, all were involved.

“the mouth of the sword.” Used to show great destruction, as if the sword was eating its victims (see commentary on Josh. 6:21).

Commentary for: Joshua 10:30