In Joshua 8:1 God told Joshua, "Go up and take the city of Ai. I've given it to you." Even when God has already given you victory, you still have to go and take it.

Joshua chose 30,000 men to attack the city of Ai, whose total population was only 12,000. God had already guaranteed victory, so I wonder why Joshua thought he needed so many? Perhaps to give more men the opportunity to redeem themselves and develop their faith in YHWH.

Joshua 8:3,25