They came to the synagogue with empty bellies — and eclectic taste buds.

For the hungry and adventurous, the program announced. On the menu: faux-butter poached brains with garbanzo beans; veal intestines, duck liver and kidneys, and goat testicles; slow-cooked ox tail in sherry wine mousseline; Mexican chipotle chocolate-covered locusts.

All of this is perfectly kosher. The Orthodox rabbi said as much as he expounded upon the Talmudic sources of each dish in the May 5 “Halakhic Dinner” at Congregation Shearith Israel, also known as the Spanish & Portuguese Synagogue on Manhattan’s Upper West Side .

Hundreds came to the imposing synagogue to learn with their stomachs. And they paid as much as $140 a head for the privilege of picking at innards while exploring the outer limits of the kosher laws.

Most seemed to finish the evening satisfied, even packing up brains and locusts for leftovers.

But some of those kosher adventurers have fallen ill in what appears to be an outbreak of food poisoning, and they took to social media to swap stories.

“Chills, cramps, and pain,” wrote one attendee on Facebook. Others described diarrhea and intense flu-like symptoms that lasted several days. Baruch Moser, another dinner-goer, wrote last week: “Got sick on Wednesday and getting progressively worse. Today is day number 7. Been to the (doctor) and waiting on lab results.”

One guest, a 35-year-old construction manager who asked to remain anonymous, was drawn to the dinner for a simple reason: “What other time will you be eating goat testicles?” he asked. And he was very happy that he went — though he has had his fill of testicles (“they’re not all they’re cracked up to be,” he concluded).

But when he began to feel a “sharp burning underneath my belly-button” a few days later, he went to the hospital. “I thought I was having appendicitis,” he explained. Even now, more than two weeks after the event, he has not fully recovered, saying he still feels “like garbage.”

Dani Klein, a food enthusiast and founder of the blog YeahThatsKosher.com, was thrilled to sample these “new kosher foods that are not easy to find,” he told the Forward. But then his wife, Arielle, came down with the bug, which was diagnosed by her doctor as Campylobacter, an infectious bacterial organism often spread by undercooked poultry.

According to the CDC’s website, symptoms of infection typically include a week of “diarrhea, cramping, abdominal pain, and fever within two to five days after exposure to the organism” — as well as bloody diarrhea, nausea, and vomiting.

Christopher Miller, the NYC Department of Health’s Press Secretary, told the Forward that the department is “currently investigating and working with the synagogue.” He declined to say how many people were infected or whether the department had determined the source of the outbreak.

Barbara Reiss, executive director of the Spanish & Portuguese Synagogue, told the Forward that she knows of only one guest who fell ill, and she doesn’t have any reason to believe it’s linked to the feast.

“We are awaiting the results of the City’s investigation and obviously would be terribly distressed to learn that anyone fell ill from these exotic foods, which any stomach might be unaccustomed to,” Reiss said.

The synagogue is housed in a regal structure on Central Park West and boasts a unique pedigree, dating itself to 1654 as the first Jewish congregation in North America. The synagogue is headed by Rabbi Dr. Meir Soloveichik, who gave the invocation at the 2012 Republican National Convention.

Rabbi Soloveichik has written in the past about the theological significance of eating locusts, arguing that “Judaism uses the animal world as a medium for symbolizing the Jewish distinction from the nations,” and so that act of distinction must extend down to the insects, too: “God wishes for the Jew…to be confronted constantly by his Jewishness; it is therefore critical that he be permitted to eat some insects among the vast majority of those forbidden.”

Whether or not they saw the locusts on their plates as the symbolic Jews of the insect world, many guests commended the rabbi’s scholarly notes. Dani Klein called the meal “insightful,” saying he especially appreciated the interludes of discussion and learning “why they’re kosher and where those animals played a role in the Torah.”

Others seemed content to bewilder their Instagram followers with pictures of cooked testicles or a half-chewed thorax bathed in chocolate.

Remarkably, despite the severe after-effects suffered by some, several attendees said they were still quite pleased with their exotic dinner.

“I got horribly sick,” said Rachael Fried, 27, a designer in Manhattan, who brought home some leftover locusts for a possible midnight snack, “but I would do it again. It was an incredible experience and I enjoyed it immensely.”

Even the construction manager who is still feeling the bug — he’s awaiting his lab results — said he does not regret going, citing his own curiosity and the rabbi’s astute comments.

He did, however, learn another important lesson.

“I will not be eating goat testicles again and it has nothing to do with being sick,” he firmly declared.