Former politician Tommy Sheridan was secretly recorded discussing allegations about his private life, a court has heard.
George McNeilage, who went to school with Mr Sheridan and was his best man, said he made the tape in November 2004.
He sold it for £200,000 to the News of World, which Mr Sheridan successfully sued for libel over a story accusing him of adultery.
Mr Sheridan, former Scottish Socialist Party leader, is on trial for perjury.
Mr McNeilage told the High Court in Glasgow that he initially decided to video tape Mr Sheridan because of the way he had spoken about some "good, good people".
He kept it secret until he saw a newspaper article in which Mr Sheridan denounced members of the SSP as "scabs" following his libel win.
Mr McNeilage said he felt "physically sick" when he saw the comments, and decided to contact the News of the World about the tape.
The tape was made when Mr Sheridan called Mr McNeilage to ask him to meet for a discussion.
Mr McNeilage described how he set up a video camera and hid it among building debris at a house he was renovating. Mobile phone records indicated the meeting took place on 18 November 2004.
He subsequently offered the tape - which apparently showed Mr Sheridan "confessing" to visiting a sex club - to the editor of the Scottish News of the World, Bob Bird.
But he made Mr Bird strip to his boxer shorts before allowing him to see the tape to check he was not wearing a wire, because he did not trust him.
Under cross-examination from Sheridan, who is conducting his own defence, Mr McNeilage said Sheridan`s suggestion that the tape was a fake were "absolute fantasy land".
He told the politician: "I know it's me and you, you know it's me and you.
"You're the real fraud. Socialists need to have empathy, you need to have real feelings, and you don't have real feelings."
Mr Sheridan won £200,000 damages in 2006 after the newspaper printed the allegations about his private life.
The perjury trial, before Lord Bracadale, continues.