NEW YORK — Donald Bain, a prolific author and ghost writer whose credits included such popular crime series as “Murder, She Wrote” and the racy best-seller “Coffee, Tea or Me?”, has died.

Bain’s literary agent, Bob Diforio, said Bain died Oct. 21 in White Plains, New York. Diforio said Saturday that Bain was 82 and died of congestive heart failure.

Bain was a native of Mineola, New York, and a graduate of Purdue University who had an extensive background in public relations, broadcasting and film production before he began working on books.

He had more than 100 credits, mostly as a ghostwriter, including the tie-in novels to the “Murder, She Wrote” television series that starred Angela Lansbury and Margaret Truman’s “Capital Crimes” thrillers. He was also the uncredited author of “Coffee, Tea Or Me?”, the million-selling novel about the exploits of two airline attendants.

Published in 1967, the book was originally promoted as the real-life adventures of “Trudy Baker” and “Rachel Jones.” But Bain revealed years later that he was the author and the events described in the novel were almost entirely invented. Bain was working in public relations at the time for American Airlines and contributed an introduction when the book was reissued in 2004.

In recent years, Bain published a novel under his own name, “Lights Out!”, and the memoir “Murder HE Wrote: A Successful Writer’s Life.” After Margaret Truman died, in 2008, he continued “Capital Crimes,” receiving credit for “Undiplomatic Cover” and other novels.

Bain was married twice, most recently to Renee Paley-Bain, who died last year.