It was written over many decades by many people....male people.
THE COUNCIL OF NICAE decided what would be included and what would be excluded. Politics in the church was always active and powerful. Even then there was SPIN. THere were NO WOMEN on that council.
Men wrote what we are told GOD inspired them to write. MEN decided which versions of which inspired writers would be sanctified as being worthy of being included. Notice the almost complete absence of women? THAT WAS NOT GOD'S doing. GOD does not PREFER men to women. Unless your version of GOD does in which case if that belief comforts you by all means cling to it.
So the BIBLE as it finally evolved, YOUR VERSION, is absolutely THE WORD OF GOD? Okay. Whatever you say.
Let me get this straight. There's an omnipotent God who created the entire universe; who brought things into existence than never were just by speaking. And yet somehow isn't able to keep humans from messing up His word? If that's true, then technically we're more powerful that he is. If that's true then he really isn't a god.
The bible was penned by 40 men over a period of around 1500 years. That means many of the writers didn't see or talk to each other. Yet in all 66 books, there isn't one single contradiction. Now, it’s completely impossible for two people to write about the same thing and not contradict each other at least once - even if they’re in the same room. Moreover, the bible accurately prophesied about many things long before they ever happened. How can anyone accurately know the future unless they were told by someone who already knew? The only conclusion is that although people penned the bible, it wasn’t “written” by them (used their own words).
While the bible does contain history, its purpose wasn’t intended to be just another history book. Its purpose was/is to tell us what our creator is like and how we can be with Him forever. And it does just that.