Turkish gunman Mehmet Ali Agca today revealed details about meetings in prison with Italian secret service agents, a Catholic priest, and a prominent left-wing terrorist in the period before he implicated three Bulgarian officials in the attempted assassination of Pope John Paul II.

Giving evidence as the papal conspiracy trial entered its fifth week, Agca repeatedly contradicted important points of his earlier testimony and again claimed that he was Jesus Christ. He challenged the Italian court to allow him to prove his claim by resurrecting "a scientifically dead person" in the presence of President Reagan and the secretary general of the United Nations.

"If you reject me, men of this planet earth, I will bring about the definitive collapse of the whole of Christianity and of western civilization. I am not a liar. I am not mad," he shouted defiantly after being pressed to tell the truth by the judge and the prosecutor.

Today's performance by Agca appeared to exasperate presiding Judge Severino Santiapichi, who has shown considerable patience until now with the man who tried to assassinate the pope in May 1981. Santiapichi threatened at one point to describe Agca as a liar in his final report unless the Turk cooperated fully with the court.

"There comes a moment when you have to choose," said Santiapichi, who sentenced Agca to life imprisonment as well as strict "isolation" for a year in July 1981 for shooting the pope.

The court session highlighted the problem of sorting out when Agca is telling the truth from when he is lying. Agca has acknowledged mixing true and false testimony in a morass of detail that has confused judges, lawyers, and journalists alike during the three-year investigation.

Agca is giving testimony in the trial of three former Bulgarian officials in Rome and four Turks, Agca's alleged accomplices in the papal plot. All have denied involvement in the conspiracy to kill the pope.

Apparently frustrated by obvious falsehoods in Agca's account of the events leading up to the assassination attempt, Santiapichi today began asking him about his contacts in prison in Italy. Defense lawyers for the Bulgarians have claimed that Agca must have been fed details about their clients in prison by people with an interest in slandering the Soviet Bloc.

Agca repeated earlier denials that anyone had encouraged him to invent a "Bulgarian connection" to the papal conspiracy. Asked to describe a meeting he had with two Italian secret service agents while in prison in December 1981, he said they had limited themselves to appealing to him to cooperate with the justice authorities.

Agca, who is a Moslem, also told the court that he had contacts with a Franciscan prison chaplain but that they had not discussed the assassination attempt. This was apparently a reference to the Rev. Mariano Santini, who has since been arrested for alleged Mafia connections.

Agca said that he had learned Italian from Giovanni Senzani, a leading member of the extreme left-wing terrorist group known as the Red Brigades, who was held in a nearby prison cell. He said he and Senzani had exchanged books, magazines, and newspapers during the period of June to December 1982.

Agca first implicated Bulgaria in the assassination attempt in May 1982, but it was not until October and November of that year that he first identified his three alleged Bulgarian accomplices. He picked them out from a photo album of 56 Bulgarians which was initially prepared by the Italian secret services on behalf of a judge investigating possible links between Bulgaria and the terrorist group led by Senzani.

Senzani, Santini, and a deviant faction in the Italian secret service have all been mentioned by left-wing Italian newspapers and Soviet Bloc propagandists as possible channels of information to Agca. No convincing evidence has yet been produced, however, to support the assertion that Agca was coached by them in prison.

Agca today also named a third Turkish accomplice in St. Peter's Square on the day of the assassination attempt -- previously identified by the pseudonym "Akif" -- as Omer Ay. This marked a further reversal of testimony by Agca, who only last week said that Ay, a right-wing Turkish terrorist now in prison in Turkey, had not been involved in the papal plot.