A Staten Island man would pick a name out of the phone book at random, say he was from the “doctor’s” office, and ask the person on the other end of the line to perform a rectal exam over the phone, according to authorities.

And at least one person went along with it.

Authorities say John Brady, 49, a construction worker from the borough’s Oakwood community, convinced a 34-year-old woman to give herself a self examination over the phone in January of 2007.

After the phone call, though, the woman realized Brady “did not represent a medical establishment,” court papers allege.

After an investigation by the Staten Island District Attorney’s NYPD detective squad, Brady was arrested Tuesday and charged with second-degree aggravated harassment.

Brady laid out his prank call strategy in a statement to a detective, court papers allege.

“I would go through the phone book and pick random numbers and make telephone calls,” Brady allegedly said. He’d ask them personal questions about their digestive system, then try to get them to follow his instructions, court papers allege.

Brady had already been arrested in September on aggravated harassment charges in connection with two other telephone calls, one from June 2007 and another from 2008, public records show, but it’s not clear if he’s accused of pulling the same prank during those calls as well.

If convicted at trial of second-degree aggravated harassment, he could face up to a year in jail.