1 Kings 8:31-35
English Standard Version
Chapter 8
31"If a man sins against his neighbor and is made to take an oath and comes and swears his oath before your altar in this house, 32then hear in heaven and act and judge your servants, condemning the guilty by bringing his conduct on his own head, and vindicating the righteous by rewarding him according to his righteousness.
33"When your people Israel are defeated before the enemy because they have sinned against you, and if they turn again to you and acknowledge your name and pray and plead with you in this house,
34then hear in heaven and forgive the sin of your people Israel and bring them again to the land that you gave to their fathers.