I recently finished a book called Rahab's Story. This is an account of Rahab from the book of Joshua from Zondervan's NIV Teen Devotional Bible.
(2:1) Then Joshua son of Nun secretly sent two spies from Shittim. "Go, look over the land," he said, "especially Jericho." So they went and entered the house of a prostitute named Rahab and stayed there.... (3) So the king of Jericho sent this message to Rahab: "Bring out the men who came to you and entered your house because they have come to spy out the whole land." (4) But the woman had taken the two men and hidden them. She said, "Yes, the men came to me, but I did not know where they had come from. (5) At dusk, when it was time to close the city gate, the men left. I don't know which way they went. Go after then quickly. You may catch up with them." (8) Before the spies lay down for the night, she went up on the roof (9) and said to them, "I know that the L-rd has given this land to you and that a great fear of you has fallen on us, so that all who live in this country are melting in fear because of you.... (12) Now then, please swear to me by the L-rd that you will show kindness to my family, because I have shown kindness to you. Give me a sure sign (13) that you will spare the lives of my father and mother, my brothers and sisters, and all who belong to them, that you will save us from death." (14) "Our lives for your lives!" the men assured her. "If you don't tell what we are doing, we will treat you kindly and faithfully when the L-rd gives us the land." ...(6:21) They [the Israelites] devoted the city to the L-rd and destroyed with the sword every living thing in it-- men and women, young and old, cattle, sheep, and donkeys. (22) Joshua said to the two men who had spied out the land, "Go into the prostitute's house and bring her out and all who belong to her, in accordance with your oath to her." (23) So the young men who had done the spying went in and brought out Rahab, her father and mother and brothers and all who belonged to her. They brought out her entire family and put them in a place outside the camp of Israel.... (25) But Joshua spared Rahab the prostitute, with her family and all who belonged to her, because she hid the men Joshua had sent as spies to Jericho-- and she lives among the Israelites to this day.