Sometimes, the quickest way to an objective isn't the most honorable. When the spies needed access, they found a willing guide.
The spies from the tribe of Joseph (specifically Ephraim, as noted in Judges 1:22) were on a mission to conquer cities that belonged to the Canaanites. They weren't looking for a fight in the open, but a way in.
When they encountered a man leaving the city, their immediate thought wasn't to force him, but to entice him. Their offer, 'we will deal kindly with you,' was essentially a bribe. They were promising safety and perhaps even reward in exchange for information about the city's weakest point or a secret entrance.
This strategy of using internal treachery was common in ancient warfare, especially when direct assault was too risky. The spies leveraged the man's fear or greed to achieve their goal quickly.