This morning the US House of Representatives approved, by a reasonably comfortable 269-161, the compromise debt agreement worked out over the weekend by President Barack Obama and the opposition Republicans. The Senate is expected to agree tonight, allowing the US government to continue paying its bills.

Opposition in the house came from the more intransigent members on both sides — 66 Republicans and 95 Democrats. The Senate, with its Democrat majority, has been more eager for compromise throughout, so approval there should not be a problem.

With the immediate crisis over, attention turns more to who the political winners and losers are likely to be. The presidential election is just 15 months away, and while that might sound like a long time, the nature of the American system is that it will dominate the political landscape for the whole of that time. The key feature that the White House held out for (and got) in the weekend’s agreement was that there would not have to be another vote on the debt ceiling before the election.

Despite that win, Democrats seem more discontented with the deal than Republicans. And indeed if you start from the premise that tax increases are good and spending cuts bad, plus a Keynesian benevolence towards debts and deficits, then this looks like a pretty bad outcome.

But there’s basically no evidence that Obama ever shared that point of view. Despite the right’s attempt to demonise him as a tax-and-spend socialist, he has always looked much more like a fiscal conservative.

He’s quite happy to cut spending, but has different priorities to the Republicans in both specifics and timing — for obvious reasons, he prefers any political or economic damage from spending cuts to happen after the election.

That was another win for the president; the cuts will be heavily “backloaded” into future years, by which time either the economy will have improved or, if it hasn’t, there will be a Republican president who’ll have to deal with it.

And there’s a further benefit as well: Obama got the Republicans to agree that the automatic cuts, to come into effect if there’s no bipartisan agreement later this year, would include reductions in the defence budget. Not only is that a good thing in itself, it drives a wedge into the Republicans between those who are serious about cutting the deficit and those (hitherto the majority) who are in hock to the defence establishment.

Bill Kristol at the Weekly Standard speaks for the latter and almost descends into self-parody when he calls the deal “a terrible precedent in treating defence as a pot of money to be slashed if various spending-control mechanisms don’t work”. But there are elements in the “tea party” that have no love for the military, and the Democrats will do whatever they can to foster such dissension among their opponents.

In all, that’s not a bad outcome for the administration. Certainly it can be argued that Obama shouldn’t have got himself into this situation in the first place — that he should never have made the initial concession of treating the debt ceiling increase as a negotiable matter.

But it’s too late to worry about that; that mistake, if it was a mistake, has already been made.

As Jon Chait put it this morning: “Obama should have avoided the hostage scenario, but once he blundered into it, he managed to escape on relatively favourable terms.”

In the first flush of what looked like a Republican victory, there was some talk about Obama now being more beatable come the election, with the corresponding thought that the contest for the Republican nomination had to be taken more seriously.

Intrade’s most recent odds favour the Democrats only about 57-43, whereas for most of the year they have been trading above 60. Interestingly, however, the Republicans seem further away from settling on a candidate: long-time front-runner Mitt Romney is now neck-and-neck with Texas governor Rick Perry, who is yet to declare his candidacy.

The picture could easily shift in coming weeks, but at the moment the big loser looks like being Tea Party candidate Michele Bachmann. From the Tea Party’s point of view, the deal was neither so good as to boost their morale, nor so bad as to fill them with righteous indignation. And if Republican voters should come more to the view that the election is winnable, that’s probably going to count against nominating someone from their crazy wing.