There were about 40 authors of the books of the Bible, all inspired by God. We know who most of them were, although there are some anonymous writers.
Moses is thought to have compiled the first five books of the Old Testament: Genesis, Exodus, Leviticus, Numbers, and Deuteronomy. As Deuteronomy describes the death of Moses, it must have been completed by someone else.
We do not know who wrote the books of Joshua, Judges, and Ruth, but they are thought to have been written (or compiled) before or during the time of King David.
The writers of Samuel, Kings, Esther, and Job are also unknown.
The Psalms were written by David, Moses, Solomon, the sons of Korah, the sons of Asaph and Ethan the Ezrahite. There are also some Psalms that were written anonymously.
King Solomon wrote Song of Solomon, Ecclesiastes and most of Proverbs (although chapters 30 and 31 of Proverbs were written by Agur and Lemuel.)
The prophets Isaiah, Jeremiah, Ezekiel, Daniel, Hosea, Joel, Amos, Obadiah, Jonah, Micah, Nahum, Habakkuk, Zephaniah, Haggai, Zechariah and Malachi wrote the books that are named after them.
Jeremiah also wrote Lamentations while Ezra wrote Ezra, Nehemiah and possibly Chronicles.
In the New Testament, the gospels (Matthew, Mark, Luke and John) have no named authors but are thought to have been written by the people whose names they bear. The writer of Luke also wrote the book of Acts.
Paul is responsible for Romans, 1&2 Corinthians, Galatians, Ephesians, Philippians, Colossians, 1&2 Thessalonians, 1&2 Timothy, Titus, and Philemon.
The apostle Peter wrote 1&2 Peter and the apostle John wrote 1,2&3 John as well as Revelation.
The books of James and Jude are usually credited to James and Jude the half-brothers of Jesus.
Hebrews is anonymous and there is considerable debate about who wrote it.