Jonah was a prophet of God who predicted the restoration of the ancient boundaries of the kingdom. He exercised his ministry very early in the reign of Jeroboam II, and thus was contemporary with Hosea and Amos; or possibly he preceded them, and consequently may have been the very oldest of all the prophets whose writings we possess.
At the time of Jonah Israel was strong and prosperous, but her well-being was threatened by the growing power of Assyria. Ninevah, Assyria’s capital, was the greatest city in the world. Israel feared and hated Assyria and these were prejudices that Jonah shared.
When God commanded Jonah to go to Ninevah to warn the city of his coming judgment upon it, Jonah did not want to go. He thought he could run away from God by leaving Israel behind and booked passage on a ship sailing to Tarshish (Spain). He was to learn that God was not localized to Israel as God sent a fierce storm. Jonah was thrown overboard. He was swallowed by a great fish which God had prepared. For three days, Jonah was in the belly of this sea creature, where he had time to repent of his rebellion. When the sea creature finally vomitted Jonah upon the land, the prophet went to Ninevah.
In Ninevah, Jonah preached, “Yet forty days and Ninevah shall be overthrown.” All the people repented from the king to the poorest person. Jonah sat outside the city waiting for God to destroy it. When God did not punish Ninevah because of the repentance of its people, Jonah became angry with God for showing clemency on the people at which point the book ends. The moral for those who don't get it is that God will turn from his judgments upon nations when they turn to him in repentance.