WASHINGTON — Lisa Murkowski had heard enough.

As President Trump pressed her and her fellow Senate Republicans last week to fall in line behind a repeal of the Affordable Care Act in the interest of party loyalty and protecting the Republican brand, she felt compelled to speak up.

“With all due respect, Mr. President,” she said, according to some of the people at the private White House lunch, “I didn’t come here to represent the Republican Party. I am representing my constituents and the state of Alaska.”

Mr. Trump did not appreciate the pushback. Ms. Murkowski was one of just two members of her party to vote against a critical procedural step on Tuesday. Afterward, Mr. Trump voiced his displeasure on Twitter: “Senator @lisamurkowski of the Great State of Alaska really let the Republicans, and our country, down yesterday,” he wrote Wednesday morning. “Too bad!”

But it may be that it’s too bad for Mr. Trump, because he picked on someone unlikely to be rattled by his attack or by accusations that she deserted her fellow Republicans. Ms. Murkowski already survived a political near-death experience in 2010 when she lost a primary race to a Tea Party challenger and was essentially abandoned by the Republican Party.