Who hits the phone when, at the start of a seemingly hopeless federal election campaign, a rogue backbencher openly mocks your official “talking points” on breakfast television? Who calms the troops when a veteran MP calls for an outbreak of anti-asylum-seeker rhetoric to sandbag marginal seats?

Inside the Prime Minister’s Office, the shit sandwiches all fall on the plate of one man, Julia Gillard’s chief of staff and fixer extraordinaire Ben Hubbard. And on the other side of Parliament House, silently punching the air and honing her small-target strategy, lies his opposite number, veteran Tony Abbott counsel Peta Credlin.

This power duo oversee a shape-shifting tableau during election campaigns — trying to knock each other off beam at the same time as pushing their own personal brands of crafted cant. Playing horse whisperer and sounding board to the boss. Controlling a coffee-chugging cabal of self-important staffers (30, in Hubbard’s case) champing at the bit to live out the latest episode of House of Cards. Constant teleconferences. And then there’s the dreary logistics — liaising with the campaign office to decide on the campaign “announceables” to provide continuous footage for an ADHD-afflicted news media.

If these secretaries on steroids stuff up they’ll see the blowback almost immediately — each night, what Labor strategist Bruce Hawker calls the “Praetorian guard” pore over tracking polls to see how little they’ve cut through in the eyes of the agitated electorate. Get it wrong and they’ll be kicked to the kerb by party powerbrokers. But get it right and they snare the ultimate political prize: unprecedented covert influence to shape the nation’s future in a presidential system in all but name.

Former Kevin Rudd press secretary Lachlan Harris explained to The Power Index that “inside the PMO, you really don’t get anyone more powerful than the chief of staff … Alister Jordan was a powerful CoS, and with Credlin and Hubbard now you get a sense that what that would be like at the top of the tree.”

At election time, prime ministerial offices become feudal courts — all that matters is closeness to the king or queen. “Proximity and access, that‘s what defines power in these situations, the inner circle of advisers will actually jockey to compete in a constructive way for your attention,” Harris says.

Neither Credlin nor Hubbard agreed to speak on the record for this piece. Both have been previously profiled by The Power Index, and you get the sense that they’d prefer if their backroom machinations stayed shuttered. There’s also long-serving Christine Milne CoS Ben Oquist, a former Bob Brown campaign volunteer turned Greens media adviser who, nearly 20 years later, is still trying to shape the minor party’s image. He didn’t return repeated calls.

“As chief of staff you just try and take a helicopter view and try and keep on moving … there is now a constant news cycle with stuff coming out of left field all of the time.”

The CoS role, invented by Franklin D. Roosevelt in 1939, is a deeply personal one that takes the idea of frank and fearless advice to new levels – “the best person for the job is someone who’s exactly opposite to you who you trust with your life,” remarked a wizened Labor observer. Hubbard has worked on and off for Gillard for years while Credlin’s loyalty to Abbott is total.

An experienced Canberra source with coalface knowledge of the election grind told The Power Index that when the campaign kicks in “it all becomes just a crazy period basically. It doesn’t matter which side you are, it’s very intense, it’s very much a co-ordinating role — there’s lots of different sorts of moving bits. As chief of staff you just try and take a helicopter view and try and keep on moving … Every day is a new day, and there is now a constant news cycle with stuff coming out of left field all of the time.”

Inside the increasingly desperate Gillard government, all heads are now turning to the genial Hubbard, the man most likely to give his beleaguered boss a leg up. After taking the reins from predecessor Amanda Lampe in early 2011, he set about redesigning the office, recruiting chief spinners John McTernan and Eamonn Fitzpatrick and consulting widely with an inner circle of Labor MPs headed by Deputy PM Wayne Swan and including frontbenchers Brendan O’Connor and Anthony Albanese.

Much has been written about Credlin, the “scariest woman in Canberra“, who apparently micromanages her charge’s movements down to the nanosecond. But for all the talk of central control, there’s little doubt her “gang of four plus one” — Abbott, chief spinner Andrew Hirst, husband and federal director Brian Loughnane and Deputy Opposition Leader Julie Bishop — has so far managed to stay out of trouble. Unless Abbott gets caught out committing a monstrous gaffe between now and September, Credlin will soon be moving into Hubbard’s office.

Asked to identify a strategic approach, a senior Coalition staffer revealed a plan based around the “real issues” confronting middle Australia: “For five days a week and maybe Saturdays and Sundays, Tony will be out. Some people say he doesn’t do the media interviews … Well, he does compared to every bit of research I’ve seen. He might be talking to some Sydney journo. but he’s still out of Canberra. That’s about keeping him race fit.”

On the Labor side a senior strategist outlined their plan — acknowledging the electoral brickbats but asking voters to focus on the future: “When you come to a third term everyone has a got a reason not to like you in a funny kind of way, even when your supporters kind of go, ‘Well I liked this, I didn’t like that’. Grievances just accumulate with years so you’ve got to absolutely prevent an election becoming a referendum on you, it’s got to be a choice, a choice of two futures. That kind of frame of choice, not referendum is really really, really important.”

While the CoS cops the blame if the approach fails — only the campaign directors are more likely to be sacked when a bid for power goes awry — it’s not exactly fair to single them out either. When the election bus splutters into gear on August 12 it’ll be all hands on deck and most of the senior roles become seriously blurred.

Former Gillard strategy chief Nick Reece has a soft spot for his former colleagues still slaving at the coalface:

“You need to have a massive work ethic and a deep commitment to the cause … They are doing these jobs at the most senior levels because they are very good at what they do. Most days they get it right, some days they get it wrong. That’s what happens when you are frequently making high pressure, high-stakes judgment calls.”

But as Ben Hubbard learned this week, even the best calls can fall flat when party discipline evaporates. And there’s still 100 days to go.