One of the most conservative outside groups in American politics just spent money to thank a Senate Democrat for a recent vote.

And not just any Democrat; a Senate Democrat that Republicans desperately want to unseat in November as part of their effort to keep control of their precarious majority in the Senate.

Americans for Prosperity, backed by conservative billionaires Charles and David Koch, announced Friday that it's launching a digital ad campaign to thank Sen. Heidi Heitkamp (D-N.D.) for co-sponsoring a bill that rolls back regulations placed on banks after the 2008 financial crisis.

“This was a bipartisan effort made possible by lawmakers like Heidi Heitkamp who put politics aside to work together,” said AFP president Tim Phillips in a statement. “While we don’t agree with Sen. Heitkamp on everything, particularly her vote against tax relief, we commend her for taking a stand against the leaders of her party to do the right thing.”

This ad is especially remarkable, given what AFP has made its singular goal over the past few years: gaining and keeping Republican control of the Senate. AFP has spent millions to that end, and in 2014, Republicans did take back the Senate.

In 2018, Republicans are at risk of losing that majority. Republicans hold a slim two-seat majority in the Senate, and Democrats are making a handful of Republican-held seats competitive even as they are forced to defend 10 Senate Democrats who hold seats in states that Donald Trump won in 2016.

AFP isn't suddenly backing a Democrat for Senate. That would be really earth-shattering. But as part of its effort to brand itself as more bipartisan and focus on policy over politics, AFP is giving shout-outs to Democratic senators who support policies it supports, and senators who are in tough 2018 midterm elections very much appreciate those shout-outs.

"We're not an appendage of any party," Phillips said in a separate interview. "And whether it's an election year or non-election year, there are going to be people we thank for doing the right thing, regardless of what party they're in."

Like Heitkamp. She is trying to get reelected in a state that Trump won by more than 35 points. She's the only Democrat holding statewide office in North Dakota, and she, more than any other red-state Democratic senator, has received a remarkable amount of help from Republicans to keep her job.

In September, President Trump invited Heitkamp on Air Force One to a rally in North Dakota, then on stage at that rally. Once on stage, he branded her for the crowd as a “good woman” right in front of her future challenger, Rep. Kevin Cramer (R-N.D.).

“Everyone’s saying: What’s she doing up here? But I’ll tell you what: Good woman, and I think we’ll have your support — I hope we’ll have your support. And thank you very much, senator. Thank you for coming up,” Trump said.

At the time, Trump was pressuring her and other red-state Democratic senators to vote for Republicans' tax bill. None of them did. And AFP spent hundreds of thousands attacking Heitkamp for that vote.

But in May, Heitkamp was by Trump's side again as he signed into law the banking deregulation bill she co-sponsored. She was the only Democrat in the room, and her smile indicated she was happy to be pictured next to the president — and perhaps that she knew this would be in a campaign ad soon.

Trump has a penchant for elevating people he likes personally, regardless of their politics or — in the case of some of his advisers — their qualifications. And Trump definitely seems to like Heitkamp. He invited her to chat after he won the election, where she sure seemed open to crossing party lines to serve in his administration.

Heitkamp stayed in her job, but Trump hasn't been shy about giving her the political equivalent of a high-five when he can.

AFP insists it's playing no such favoritism with Heitkamp.

But its ad does come as the organization has been frustrated with how Republicans have governed Washington since winning control of it in November — specifically presiding over rising deficits and being slow to act on Koch priorities like criminal justice changes, rolling back banking regulations and opening up experimental drugs to terminally ill patients.

In recent weeks, Congress has moved on much of that legislation — but only after failing to repeal the Affordable Care Act and barely getting a tax overhaul bill over the line.

Regardless of the intent behind this ad, it inevitably will be interpreted through the lens of the 2018 midterms. And that is very good news for Heitkamp.