As it turned out, the encounter with Cruz was also recorded, according to sources familiar with the investigation.
It was May 24, 2011, and perhaps the most-talked-about bill in the legislature at the time was one that would require voters to show photo identification at the polls.
Cruz was against voter ID - as was virtually every other Democrat in the Capitol.
Ali visited Cruz in his office, tucked off the grand marble staircase that wraps around the Capitol rotunda. According to people who have read transcripts of the conversation, the scene unfolded in this way:
The two men talked for a while, then Ali suggested they take a walk outside. Once in the hallway, Ali tried to hand Cruz $1,000 cash in an envelope.
"I need a 'no' vote on this," he said.
Cruz whispered back: "I can't do this thing, man."
Ali replied: "I told you I was bringing something for you."
"Check," Cruz said.
In an interview Wednesday, Cruz said he wanted to make sure that any money he accepted came in a check for his campaign fund, as required by law.
About an hour later, Ali called Cruz back to tell him he would be asking him to back other bills in the future. He said that he didn't have his checkbook, but that he did have some money orders. Would Cruz want those?
Cruz told Ali he would have that conversation with him "some other time."
That was their last meeting, Cruz said.
In Wednesday's interview, Cruz, who represents the 180th District in North Philadelphia, said he did not know Ali well. He said Ali showed up at one of his fund-raisers and said he wanted to be helpful and donate money.
Cruz said Ali, whom he described as "very suave," would drop hints that he had money and boats and houses. He even offered to pay for trips. "Anywhere I wanted to go," Cruz recalled.
"I don't take nobody's money," Cruz said Wednesday. "If you are going to donate money to the campaign, it has to be a fund-raiser, it has to be a check, we are going to declare it, and it never touches my hands. I never, ever, ever touch money."
In his 14 years in the Capitol, Cruz said, his hallway encounter with Ali marked the first time anyone had tried to hand him an envelope stuffed with cash. Sure, lobbyists had tried to take him to lunch or dinner or drinks, but no one, he said, had ever offered him an outright bribe.
"It was scary," he said.
After that day, Cruz said, he never saw Ali again.
On Sunday, when he read an Inquirer story about Ali's undercover role in a sting that caught five Philadelphia Democrats - including four of his House colleagues - on tape taking money, Cruz realized he had been targeted.
The first person he called was his mother.
He said he told her that Ali had offered him money, but that he didn't accept it.
"I said, 'Mom, I didn't do it,' " said Cruz.
She replied: "I raised you kids well."