Joshua the son of Nun sent out of Shittim two men as spies secretly, saying, Go, view the land, and Jericho. They went and came into the house of a prostitute whose name was Rahab, and lay there.
It is significant that the king's representatives were very easily deceived by Rahab, indicating that the king himself considered her to be dependable.