The NIT started out in 1938 and was originally administered by the Metropolitan Basketball Writers Association. A few years later, administration was passed over to the Metropolitan Intercollegiate Basketball Association, which was and still is made up of of representatives from the five New York schools - Fordham, St. John’s, NYU, Manhattan and Wagner. These are the folks that do the inviting.
The NIT was much bigger in prestige in the early years a little because it was a bit older than the NCAA tournament, but mostly because it was based in New York City. The entire tournament was held there, so it got tons of exposure. And teams loved going to it because of that exposure. Players loved going to it not only for the exposure, but because the NIT was the bigger tournament and made more money largely due to location, it gave better welcome packages to participating teams - I believe watches and such were fairly common. The NCAA only gave out a medal. The NCAA tournament couldn’t compete with any of that, so for the most part, the top teams played in the NIT, although, a few decided to both.
Since the NCAA is mostly in the business of making money, they had to figure out a way to make their tournament the top dog. Since they couldn’t compete with the money or locatio of the NIT, they simply used their rule-making ability to start to snuff out the NIT’s prestige.
In 1951 they expanded from 8 teams to 16 then to 22 in 1953. That same year, they made a rule that teams could only participate in one postseason tournament - either the NIT or the NCAA. Well, teams were still picking to go to the NIT so the NCAA started to tighten its grip a bit. They adopted the “Expected Participation Rule” that said that all NCAA institutions were expected to choose NCAA events over any other.
Over the next two decades, the NCAA tournament continuously expanded and they eliminated the rule that said only conference champions could participate. More schools participating meant more exposure and more revenue, meaning greater financial benefits for the teams participating.
In 1981 the NCAA brought the hammer down and effectly eliminated any notion of the NIT as a competitor to the NCAA tournament. They created the “Commitment to Participate” rule which basically stated that any team invited to participate in the NCAA tournament MUST accept or they were not able to participate in any other tournament. When combined with the rule that said you could only participate in one postseason tournament, the NCAA effectively used its monopoly status to end any competition. The NCAA gets first choice of teams to invite and so the NIT no longer has any shot of landing any of the top teams.
As for gambling, the NCAA loves it (as does the NFL). They do everything they can to make gambling easier, like requiring teams to disclose injuries because the more people that are gambling on your sport the more people are going to watch and the more of an event you become. Of course, given various point shaving scandals, the NCAA has to put on the public face that they don’t approve so as to maintain the “integrity” of the sport.