James utilized the counsel of someone outside his own jurisdiction and said as much
Acts 15:14, that he was basing his statement on Peter’s words. And when he said in v. 19 that “we should not trouble the Gentiles,” he is only referring to the Jews, specifically from Judea (v. 1), who were teaching otherwise. It was they who should stop troubling Gentiles. James reaffirms that he was making a judgement specifically regarding these Judeans in his jurisdiction who caused the problem (v. 24). Peter’s knowledge about including Gentiles was directly related to the vision he had in
Acts 10, when God revealed to him to include that which he previously thought unclean, namely Gentiles. Later in the chapter, he applies it:
Acts 10:44-47 While Peter was still saying this, the Holy Spirit fell on all who heard the word. And the believers from among the circumcised who came with Peter were amazed, because the gift of the Holy Spirit had been poured out
even on the Gentiles. For they heard them speaking in tongues and extolling God. Then
Peter declared, “Can any one forbid water for baptizing these people who have received the Holy Spirit just as we have?” And he commanded them to be baptized in the name of Jesus Christ.
Again, in
Acts 11:2-17 Peter explained his revelation on baptizing Gentiles. James recognized this revelation coming from Peter and so made his local judgement accordingly. Peter had already been baptizing the uncircumcised prior to the Jerusalem council.
Here’s a good article breaking down the matter as well.