In 2017, the authorities say, the three wove an irresistible yarn. Posting to GoFundMe, a crowdfunding site, Ms. McClure and Mr. D’Amico said that she had run out of gas while driving home in the Philadelphia area, and that Mr. Bobbitt, a homeless veteran, had spent his last $20 to buy gasoline for her. The couple said they wanted to raise $10,000 to thank him and get him off the streets.

GoFundMe allows anyone to suggest a cause worthy of donations, whether it’s classroom supplies, life-or-death medical care or a border wall. With thousands of causes competing for attention, users often rely on emotional appeals to stand out.

This time, it worked. Buoyed by social media and coverage from the international news media, 14,347 people donated $402,706 to the campaign within three weeks.

From there, the story became much less inspiring.

Federal prosecutors say Ms. McClure and Mr. D’Amico rapidly spent most of the money on the likes of gambling, vacations, a luxury car, clothing and expensive handbags, much of which was later seized. The authorities said the couple set up a bank account for Mr. Bobbitt in December 2017 and deposited just $25,000; the couple later justified that as a way to keep him from spending it all at once.

Mr. Bobbitt sued the couple in August, saying that he had ultimately received just $75,000, including the value of a camper he temporarily lived in, and that they had spent the rest. GoFundMe announced in September that it would help cover the costs to make sure Mr. Bobbitt got all of the money he was due.