In an emailed statement about the Garratts’ detention, Global Affairs Canada, the department that handles Canada’s diplomatic relations, declined to comment on the question of an exchange, but said, “Senior government officials were raising the case at every opportunity.”

The Chinese Embassy in Ottawa denied that the Garratts’ detention was linked to Mr. Su. “We don’t think it is related to any other cases,” an embassy spokesman said in an email.

According to the Garratts’ account, after signing the investigation document Mr. Garratt was driven to the couple’s apartment, where agents ransacked their possessions, grilled him about the contents of the kitchen cabinets and then carted off schoolbooks and computers in the family’s suitcases. After a heated exchange, the men allowed Mr. Garratt to take a pair of Bibles back to the detention center.

His wife was already at the compound, an extralegal detention center on the outskirts of the city, confined to a separate isolation cell that had a couch, a bed and a small window covered in opaque plastic. During the next six months, they said, they never knew the other was there.

But neither was ever alone.

Rotating pairs of guards sat on the couch in each of their cells, staring silently at them and writing down their every move. Harsh lights remained on 24 hours a day. To stay sane, Ms. Garratt said, she prayed, read books provided by the Canadian Consulate and each day drew a cryptic picture of something she was grateful for in the back of her Bible, afraid anything written would be confiscated.

They each faced daily six-hour interrogations by a team of three men. Armed with years of emails, Skype messages and surveillance records, the interrogators accused the Garratts of “hosting” foreign diplomats at their coffee shop, taking orders from Canada’s intelligence agency and stealing state secrets, the couple said.