THERE ARE untold writers who spend their careers worshipping at the altar of Broadway and would likely sacrifice a body part or two for the chance to see their work staged on the Great White Way, especially if that brought fame, fortune and awards with it.

Then there's Marshall Brickman.

As co-author of "Jersey Boys," the Tony-winning musical about 1960s pop-rock princes Frankie Valli and the Four Seasons, he's partly responsible for one of the biggest musical-theater hits of the early 21st century. But to hear him tell it, conjuring a theatrical smash was never on his to-do list.

"Growing up, Broadway was the thing you went down in order to get to Greenwich Village," said the 69-year-old Brickman, perhaps best-known as Woody Allen's fellow 1977 Oscar winner for their "Annie Hall" script.

Brickman said his involvement with "Jersey Boys," which opens a 10-week run tomorrow at the Forrest Theatre, was, in standard showbiz fashion, simply a function of luck and timing.

"I was drafted into this thing [in early 2004] by my co-writer, Rick Elice," Brickman explained during a recent phone call. "Somebody contacted him on behalf of the Four Seasons. We had been looking for something to do together."

He added that when Elice invoked the Four Seasons, "I did the Vivaldi joke," a reference to the 18th-century Italian composer whose themed collection of violin concertos, "The Four Seasons," is a Baroque-era masterpiece.

As a one-time folk-music artist whose collaborators included a pre-Mamas & the Papas John and Michelle Phillips, Brickman said he "wasn't really acquainted" with Valli's Four Seasons. But once he delved into their catalog, "it knocked me over."

The next step for the two writers was a meeting with Valli and Bob Gaudio, the keyboardist who composed (often with lyricist Bob Crewe) and produced the group's incredible canon of early-'60s hits, including "Sherry," "Dawn," "Ronnie," "Rag Doll," "Walk Like a Man" and "Big Girls Don't Cry."

The sit-down, Brickman remembered, included enough wine to get all the parties to the point that "everyone started loosening up and talking about what it was like growing up in Jersey." (Brickman grew up in Brooklyn.)

Brickman's takeaway from the powwow was that "the group was never really certified by the rock intelligentsia, never interviewed by Rolling Stone."

Brickman and Elice discovered a compelling, if obscure, tale of friendship, betrayal, gangsters, sex and, most important, some of the most beloved music of a generation defined by its rock 'n' roll. "We told them, 'If you let us tell your story, warts and all, this could be a home run - or at least a triple,' " Brickman said.

Although Gaudio and Valli were, according to Brickman, "cautious," they gave the scribes a green light. Which, as it turned out, meant very little at the time. After developing a story outline on "spec" (or speculation, meaning Brickman and Elice created it without being paid), they were met with nothing but apathy from the musical-theater community. "We shopped for a producer," said Brickman, "and nobody - nobody, nobody - was interested. We pounded the pavement, but nobody cared."

Finally, the pair connected with director Des McAnuff. He brought the Who's rock opera "Tommy" to Broadway, so he knew a thing or two about putting '60s rock into theatrical form. It didn't hurt, Brickman said, that "the first album he ever bought was a Four Seasons album."

McAnuff, continued Brickman, confidently told the writers, "I know how to do this; I'll give you a shot" at his home theater, the La Jolla Playhouse in Southern California. Although Valli, Gaudio and original member Tommy DeVito agreed to cooperate (the other charter member, Nick Massi, died of cancer in 2000), Brickman and Elice hardly had carte blanche with their story.

According to Brickman, the three Seasons didn't have creative control over the script, but "they had contractual approval over everything - and still do. Were we apprehensive they could pull the plug after they saw it for the first time in La Jolla? Yes."

Brickman said there was some editing done at the request of Valli and the others. "There were some things that were a little too close to the bone. They said: 'There are still some people living. See if you can find another way around that.' " Also complicating things for Brickman and Elice was the perspective each group member brought to the project. Brickman likened the experience to the classic 1950 Japanese film "Rashomon," which tells different stories about the same crime, because each character has a different version of it.

There were "contradicting memories of what happened told to us by three guys," Brickman said. "What we constructed was the story of the Four Seasons told by each of the guys - their version of what happened. We were very true to the essential [story]. You could call it a re-created documentary."

Working under such circumstances, Brickman noted, meant he and Elice couldn't relax "until we opened in La Jolla [in October 2004]. Then we were geniuses."

Despite writing under the omnipresent threat of a shutdown of the project, Brickman could only praise Valli, Gaudio and DeVito for their indulgence and cooperation. "It took a lot of courage for them to let us put their lives on stage," he said.

"Jersey Boys" opened in New York in November 2005 and was an instant hit that would win four Tony awards, including best musical. The authors didn't share in the Tony bonanza, but it didn't matter. The Broadway bug had bitten them.

Last December, Elice and Brickman, who also co-wrote "Sleeper," "Manhattan" and "Manhattan Murder Mystery" with Woody Allen, saw their second book musical, "The Addams Family," debut in New York, where it's still playing at the Lunt-Fontanne Theatre.

"I like that the process is totally different from making movies," Brickman said, explaining Broadway's appeal. "The real difference is the live audience. There is nothing like standing in the back of the theater with an audience that's really connecting to what you wrote. It's a real thrill."

And, there's another nice perk, too. "One of the best things," bragged Brickman, "is that I can walk to work."

Forrest Theatre, 1114 Walnut St., tomorrow through Dec. 12, showtimes vary, $54-$201.50, 215-893-1999, telecharge.com.