What would be the kind books that would come up for inclusion? I find it interesting that many gospels and books and letters were circulated by early christians and that most were excluded.
I am sure the criteria varied locally but for the proto-orthodox churches that produced our NT, the two most important considerations were whether the book was accepted as genuinely apostolic and whether it was contained reliable teaching. For the churches defining themselves as catholic and orthodox, it means that the teaching had to be construed as orthodox and not heretical (however "heresy" was defined at the time, and naturally this varied widely). And since orthodoxy was popularly defined as apostolic (cf. the title of Irenaeus' apologetic work Proof of the Apostolic Preaching), the two factors were self-reinforcing. So, if we consider a book like 1 Clement or the letter from Polycarp, these were well-esteemed as containing valuable orthodox teaching, but since they were written by disciples of the apostles and thus were not truly apostolic, they ultimately did not make the cut (although 1 Clement was included in some early codices of the Bible). The Shepherd of Hermas was also not apostolic and its teaching, while not heterodox, was later criticized as too lenient of sin (this too was included in some editions of the Bible). Then there were books that were not really apostolic like the Pastorals, the Epistula Apostolorum, the Preaching of Peter (the version that was quoted authoritatively by Clement of Alexandria), the Apocalypse of Peter, 2 Peter, and so forth that made an authorial self-claim of being apostolic and which were also pretty much "orthodox" in teaching -- some were accepted into the NT whereas some were not. The case of 2 Peter is interesting because it was canonized despite doubts on its authenticity (and cf. the Apocalypse of Peter being more popular in some quarters than Revelation), whereas the Gospel of Peter was rejected as spurious on a rather unfair charge of docetic teaching. Some anonymous books were canonized through popular association with apostles. Hebrews is anonymous and even implies in one passage that it is post-apostolic but through popular association with Paul, it was accepted into the NT (interestingly, the church at Rome rejected it for a long time, possibly on account of firsthand knowledge that it wasn't written by Paul, as they were probably the original recipients of the letter), whereas Barnabas was also anonymous and attributed to an apostle but which did not ultimately achieve general acceptance. As far as the gospels were concerned, a four-gospel canon emerged rather early -- as witnessed by the gospel harmonies used by Justin Martyr and the author of 2 Clement, the Diatessaron of Tatian, the Muratonian fragment, and possibly through the testimony of Papias. The many gospels produced by non-orthodox groups, particularly those classed as "gnostic", were written by the time this fourfold canon took shape, they come from a very different religious perspective from the others and were probably not as well circulated. There were some gospels (such as the Egerton Gospel and the fragmented gospel of POxy 840) that look quite synoptic-like and "orthodox" -- unlike the Sethian and Valentinian gospels designed to impart specialized secret teaching -- but these also did not attain general acceptance, possibly because they were not generally circulated or because the emergence of a four-gospel canon discouraged their circulation.
Bear in mind too that there were not two binary categories of canonical and non-canonical; there was a more subtle distinction between homologoumena, antilegomena, and notha.....a book could be non-canonical but also regarded as inspired and scriptural. A book could be accepted for reading but not public teaching, whereas some books were banned outright.
If anyone reads up on the history of the canon either hebrew or greek as books in the bible, you will find there wasn't much debate people KNEW in those times which were the inspired ones. When the canon came to be officially recognised they just looked at the ones that were accepted as the canon and the ones we have are it, these other appocrypha were NEVER in the running.
Oh there was quite a lot of debate about the antilegomena, including many of the books that made it into our NT (particularly among the general epistles). One must be careful not to retroject our current understanding of canon into the early post-apostolic period. But many books classed as notha were certainly rejected outright in churches self-identifying as orthodox.
There was some debate over revelation if I am correct i'm a little rusty on this subject.
Of course. Just as there was debate and doubt over books like Hebrews, James, Jude, 2-3 John, the Apocalypse of Peter, 2 Peter, the Acts of Paul, Barnabas, the Didache, the Gospel According to the Hebrews, the Shepherd of Hermas; all of these were classed together at one time or another as antilegomena with the same disputed-but-not-heretical status. To this day, 2-3 John, 2 Peter, and Revelation are not universally accepted in the Nestorian church.
But yes, books like the Gospel of Mary, the Gospel of Philip, the Gospel of Judas, etc. would not have had any chance of making it into the NT of the orthodox churches, no more than 1-2 Timothy or Titus would have made it into whatever notion of "canon" the Sethian gnostics had.