As party leaders stumbled out of the last 24-hour non-stop marathon session, they looked relieved, rather than euphoric.
Angela Merkel's conservative bloc had finally agreed a coalition deal with the centre-left Social Democrats (SPD) to form a government.
But this is a marriage of convenience. Not one of love. And certainly not of passion. It's the least bad option simply because neither side fancies the alternatives: a minority government is seen as unstable; and fresh elections would lead to months of uncertainty and could kill off French President Emmanuel Macron's plans to reform the eurozone.
So the resulting deal is a not a grand vision for a new Germany, but a list of pragmatic compromises that can benefit both sides — a laundry list of tax giveaways and spending pledges. These promises are not popular with Germany's business leaders, who say they will harm German competitiveness. But they may make many people's lives easier.
There is one more hurdle before a government can be installed. Almost half-a-million SPD members will vote on the deal first. If they vote no, then this agreement collapses, and parties start again from scratch. The most likely outcome would be fresh elections, which would mean no permanent government until autumn — a whole year after the first set of elections.
With this threat hanging over the negotiations, the SPD, despite having won just 20.5% of the vote, has managed to push through a considerable number of left-wing policies. And in an attempt to get the Social Democrats on board, Angela Merkel's conservative CDU/CSU bloc has given them control over an unusually high number of powerful government ministries.
Read more on this subject:
Now SPD leader Martin Schulz has to convince his party base that he hasn't betrayed left-wing values simply to get into government. This is a challenge not made any easier by his decision to become foreign minister, having previously vowed never to serve in a Merkel-led cabinet.
Outside of Germany this deal could have a big impact on the EU. The promised spending spree on infrastructure and services will likely boost Germany's economy further, and the tax cuts may give an added boost to German consumer spending.
Key ministries have gone to the centre-left Social Democrats, including finance — which could mean more German support for struggling eurozone economies, helping the French president's plans to reform the EU.
Mr Macron wants to create a common eurozone budget and a eurozone finance minister - but Germany has so far been wary of any move that might lead to what it calls a "transfer union", used to prop up indebted governments. An SPD-led finance ministry could be much more amenable to Mr Macron's proposals.
But when it comes to Brexit, it's doubtful this government will change Berlin's stance. All Germany's mainstream parties are united in saying they want a good deal with the UK, while at the same time stressing the single market should not be undermined by cherry-picking.
It's the domestic issues that matter for German voters. And this is where any advantages of a grand coalition can also be its pitfalls.
A compromise between two parties from opposite sides of the political spectrum is very good at finding something for everyone. But the danger is that by trying to please everyone, you end up pleasing no one.