I don't understand why more people have not taken the time to actually understand what happened with Tim Donaghy. Even after all this time most posters seem totally ignorant of the facts and write him off as a crooked liar whose actions are total outliers. But if you are going to talk about the integrity of the league you need to understand what happened with him, so I will break it down for you:
- Tim Donaghy liked to bet on NBA games (like a lot of players, probably like some refs; and of course wrong and illegal)
- As he was illegally laying bets, the mob discovered him to be an NBA ref and aggressively blackmailed him into giving them tips about who to favor in specific games, including - but not limited to - ones he reffed himself
- the FBI was tapping the mob's phones and discovered Donaghy feeding them info by accident
now here are the 2 most important facts about Donaghy:
1. the FBI has confirmed on 60 Minutes that Donaghy had a 75% success rate against the spread picking winners in games he did not refereeTo pick 75% against the spread is absolutely unheard of and statistically impossible unless:
a) Donaghy was colluding with other refs to fix games he was not reffing (there is no evidence whatsoever that this happened except perhaps the hundreds of phone calls to Scott Foster just before games and their meaning as discussed here 
http://www.foxnews.com/story/2008/07/14/disgraced-former-nba-referee-tim-donaghy-phone-calls-to-second-ref-raise.html) or
b) his knowledge of the internal directives, feuds and refereeing assignments gave him such a clear insight into who was going to win that he could get it right 
against the spread  75% of the time
The second one is the one Donaghy affirms happened and which he has talked about in great detail in terms of the how and who and why, with a clear and explicit awareness of the direct hand of the NBA in shaping the conditions and internal politics that led him to be able to pick winners against the spread so accurately
2. Donaghy agreed to a plea bargain with the FBI that required him to tell the whole truth and nothing but the truth about everything that he did. He took the deal to avoid a 25 year jail term knowing that if he lied or omitted anything he would spend most of his life in jail as a result. Not only that he knew they had many hours of wiretapped recordings of him and there was no way to wiggle out of it.Now you can believe that he is a liar, but you need to understand the immense amount of pressure on him to tell the truth and the amount of verification of what he said that was done and reported on by the FBI.
You can interpret the above however you like, but personally I believe the NBA knows as well as Donaghy did the impact of their refereeing assignments and directives, and that 
sometimes it assigns and guides referees for strategic purposes to enhance the league's competitiveness, increase the brand power of stars and generally build a more profitable business. 
I'm a big fan of the game but I think to pretend this is not how things work is to be naive. I think the players know it and everyone in the league knows it. Sometimes to win your biggest challenge is changing the narrative so that now it is working in your favour.
Anyway, this is not to say every game or series is rigged, not at all. Definitely not. But in various ways is the NBA a player in its own game? Absolutely.