When John Moeller first heard about the pretzel incident, he thought he was toast.

It was 13 January 2002, the memories of the 9/11 attacks still fresh, and President George W Bush was doing what millions of other Americans were doing: trying to feel normal for a little while. He was watching football on TV.

Alone in his White House quarters, Bush was popping pretzels while watching an NFL playoff game. One didn't go down right, and the president crashed to the floor after briefly losing consciousness. The fall caused only minor facial injuries – and perhaps a bruised ego.

Download the new Independent Premium app Sharing the full story, not just the headlines

Despite the passing, freakish nature of the incident, reporters wouldn't let it go. They were on the story like, well, mustard on pretzels. They wanted to know the source of the salty treat. The White House remained mum. "You're not going to get us to cough it up," press secretary Ari Fleischer deadpanned to the New York Times.

As a sous-chef in the White House kitchen, Moeller was one of the few people in the United States to know the bakery that produced the pretzel. Moeller, in fact, was the one who had introduced the snack to the White House, back during the Clinton administration. The handmade beauties came from Hammond Pretzel Bakery in Lancaster, Pennsylvania, near where Moeller grew up in Pennsylvania Dutch country. "Chelsea went wild on it for a little while," Moeller says about his hometown pretzel. Hillary Clinton wrote the bakery a letter, thanking it for the healthful and tasty treat.

Then came president Bush's snack-related scare, which practically caused Moeller to start choking himself. His first thought upon hearing the news: "Am I going to be working here tomorrow?"

Moeller kept his job, but he got another lesson in the tenuous status of the White House kitchen staff, which "serves at the pleasure of the president", as the oft-repeated phrase goes. What does that mean in real terms for the men and women who work at the White House, feeding the First Family and their many guests and dignitaries from around the world? It means that politics, personal tastes or even a pretzel can potentially send a chef packing from 1600 Pennsylvania Ave.

Particularly the executive chef, the person who leads the small, full-time White House culinary team. The position has become increasingly political over the years, and Moeller, who worked in the White House kitchen from 1992 to 2005, remembers when the head chef gig shifted from a mere job to a post invested with palpable symbolism.

It was in late 1992, just weeks after Moeller started his job in the George HW Bush White House. Alice Waters, founder of Chez Panisse restaurant and earth mother of the US locavore movement, sent a letter to the president-elect Bill Clinton and Hillary Clinton, urging them to install an American chef. The letter was signed by dozens of top chefs, including Wolfgang Puck, who was born in Austria.

At the time, Pierre Chambrin, a Frenchman, was leading the kitchen; feeling the outside pressure, "Pierre grew despondent and finally said, 'I've decided to leave,' " Moeller writes in his new book, Dining at the White House: From the President's Table to Yours, a pull-back-the-curtain look at cooking for the world's most powerful family.

It took more than a year, but Waters finally got her American chef. Chambrin eventually was replaced by Walter Scheib, a native of Oakland, California, who introduced his own spin on American cuisine.

Waters's letter "maybe did politicise the position more than it had been in the past. It became more volatile than it had been," says Moeller, 52, as we sit in Paul bakery, a very French shop not far from the White House. Henry Haller, for example, served as executive chef for the White House for 21 years before retiring in 1987.

"I see a lot more interviews with White House chefs and stuff like that, where before we were just working," Moeller adds. "We served at the pleasure of the president . . . and very rarely would we get any fanfare."

These days, cooking for the First Family may have its politics (and perks), but it remains a demanding job, requiring a chef who can plan and prepare both massive, high-profile state dinners and quotidian family meals. It also requires an unassuming chef who doesn't insist on forcing flavours on a president and family members who have their own likes and dislikes at the dinner table. The job, in essence, is that of a glorified personal chef.

Moeller likes to share an anecdote to explain why a White House chef needs to be ego-free. The Clintons, Moeller remembers, had just hired a new cook, and he was eager to impress. Chelsea Clinton wanted pancakes for breakfast. The newbie noticed real maple syrup in the refrigerator and was about to grab it. Moeller told him to forget it: Chelsea liked the imitation, bottled syrup.

"And he fought me about it," Moeller recalls. "I said, 'OK, fine. Put it up there.' It went up, and it came back two minutes later. . . . I said, 'You know and I know [real maple syrup] might be the better-quality thing. That is maybe something we do on the outside for people, but we're in a home. This is what she wants. We're going to give them what they want.' "

White House cooks may have to swallow their pride, but on occasion, they also have a chance to influence the president's palate. Moeller says that when a cook first starts, he or she is briefed on presidential food preferences, including dishes and ingredients to avoid. Everyone on the staff knew, for instance, never to serve broccoli to George HW Bush.

But Moeller also knew that the elder Bush was a well-travelled man who knew a lot about cuisine. So one evening, Moeller decided to take a risk. He prepared the president an Asian-flavoured meal: miso soup, California rolls, salmon teriyaki and other dishes. He even had White House carpenters build geta serving boards for a Japanese-style presentation.

"Afterwards, the president came back, and he shook my hand," Moeller remembers. "He goes, 'John, in the four years that I've been here, I've never had a meal like that. Thanks a lot. That was fun.'"

White House chefs have also been early adopters of practices that have only recently taken root in the public's consciousness. Local and regional sourcing for ingredients? Moeller says he was buying produce not only from farms in Pennsylvania Dutch country, but also from farms in Montgomery County, long before farmers' markets dotted the landscape. He even harvested ingredients from his own garden.

"I used to always let them know, 'Hey, those beets came from my garden," Moeller says about the Clintons. "The First Lady used to like that."

The kitchen staff was also a pioneer in menu labeling. Long before the US government mandated that chain restaurants with 20 or more locations start listing calorie counts, the Clinton White House demanded the same thing for its family dinner menus, Moeller says. (Joke all you want about now veg-only Bill Clinton's love of fast food when he was on the road; Moeller swears the president ate more healthy foods at the White House: "I'd make a couple of burgers from time to time, absolutely, but it was only once in a blue moon.")

"We read through books, and we were calculating the caloric value for every dish", Moeller recalls about the calorie mandate. "We attached that to all the menus that we presented."

Despite his many years of service, Moeller never rose to the position of White House executive chef. He says he was acting head chef for several months in 2005, after Scheib was reportedly fired for not meeting First Lady Laura Bush's "stylistic requirements".

Moeller didn't get the job. The Bush White House selected Filipino native Cristeta Comerford, the first woman to hold the position. She was another veteran of the White House kitchen, originally hired in 1995 under Scheib. Moeller says he has no hard feelings about being passed over, though he does wonder whether the White House was under pressure to hire a woman, by groups such as Les Dames d'Escoffier.

Whether politics played into the decision or not, Moeller opted to leave the White House several months after Comerford took over. "I figured it might be a good segue to just move on and start to do my own thing again," says Moeller, who now has his own catering company back in Lancaster, home of those infamous pretzels.

A version of this article appeared in the 'Washington Post'