It sounded familiar but I’m no expert. Here’s what Encyclopedia Mythica has to say about it:
Tiresias
by James Hunter
Tiresias was the son of Everes and the nymph Chariclo; he was a blind prophet, the most famous soothsayer of ancient Greece.
The most famous account of the origin of his blindness and his prophetic talent is as follows. When Tiresias was walking in the woods one day, he came upon two great serpents copulating; he struck them with his staff, and was thereupon transformed into a woman. Seven years later, she/he passed by the same place and came upon the same two serpents copulating; she/he struck them again with the staff and was turned back into a man. Some time later, Zeus and Hera were arguing over who had more pleasure in sex, the man or the woman: Zeus said it was the woman, while Hera claimed men got more pleasure from the act. To settle the argument, they consulted Tiresias, since he had experienced life as both sexes, and Tiresias sided with Zeus. In her anger, Hera struck Tiresias blind. Since Zeus could not undo the act of another deity, he gave Tiresias the gift of prophecy in compensation.
Another account says that Tiresias accidentally saw Athena naked, and she covered his eyes with her hands, thus rendering him blind. When Tiresias’ mother Chariclo asked Athena to restore her son’s sight, the goddess could not undo her own action but gave him the gift of prophecy as compensation.
There are many tales about individual prophecies of Tiresias: he predicted the manner of Narcissus’ death; he tried to warn Oedipus of the rashness of that king’s inquiries about his parents; he predicted that the sacrifice of Menoeceus, son of Creon, would permit the forces of Eteocles to repulse the army of the Seven Against Thebes. Tiresias eventually died from drinking from the spring Tilphussa, but even after death his shade was able to offer valuable prophecy to the hero Odysseus.