WASHINGTON — The ground rules were simple: Senators wishing to voice their opinion needed to wait their turn and could speak only once they had grabbed hold of a Masai tribal talking stick.
As their colleagues went on the airwaves or rushed to the Senate floor to noisily trade blame over a government shutdown, about two dozen centrist senators from both parties crammed for hours into the Capitol Hill office of Senator Susan Collins, Republican of Maine, to try to chart a civil way out of what Senator Mitch McConnell had called a “box canyon.”
“I needed order,” Ms. Collins said in an interview on Monday, referring to the hand-carved wooden talking stick from Africa — a gift from Senator Heidi Heitkamp, Democrat of North Dakota.
Apparently it worked. By Monday afternoon, when the Senate voted overwhelmingly to end the three-day shutdown, the group convened by Ms. Collins was credited with nudging together the Senate leadership toward a deal to reopen the federal government in exchange for a promise from Republican leaders to address the fate of young, undocumented immigrants known as Dreamers.
At least for now, the group, which calls itself the Common Sense Coalition, fulfilled the hope — long talked about but rarely realized — that a centrist contingent could bridge an otherwise deeply divided Senate. The question was whether it could hold together long enough to forge a much grander bargain over a disparate set of pressing issues before Congress: Raising limits on domestic and military spending, providing disaster relief to storm-ravaged states and a more comprehensive immigration deal to address the Dreamers and border security.
“The effort has resulted in the government reopening. That was the critical first step,” said Senator Lisa Murkowski, Republican of Alaska. “But now the real work begins.”
At a nearly giddy news conference just off the Senate floor on Monday, Democrats and Republicans gushed over the possibilities and spoke of meetings to come.
“Susan’s office is Switzerland,” Senator Lindsey Graham, Republican of South Carolina, said. “It is the one place we can all go and feel good.”
Senator Chris Coons, a Delaware Democrat, was just as effusive: “We can make a lasting difference in how the Senate of the United States works,” he said before snapping a picture of the group on his iPhone. “We can get it back to working.”
The group’s maneuvering offered members of both parties an escape hatch from a bitter dispute that Republicans and Democrats said could have easily stretched on days longer.
The coalition, which was first formed amid an earlier government shutdown, in the fall of 2013, began to stir to life on Friday afternoon, as it became clear the Senate would be unable to stave off a shutdown. Ms. Collins approached Senator Joe Manchin III, the West Virginia Democrat and the coalition’s co-chairman, on the Senate floor, and within hours a group of 17 senators were crowded into her office to sketch out terms of engagement.
The group eventually came to include a broad swath of institutionally minded senators, including the Republicans Jeff Flake of Arizona, Johnny Isakson of Georgia and Mike Rounds of South Dakota, and the Democrats Amy Klobuchar of Minnesota, Tim Kaine of Virginia and Doug Jones of Alabama.
Members of the group spent the weekend shuttling between Ms. Collins’s overcrowded office, where they snacked on Girl Scout cookies and popcorn, and the office suites of Mr. McConnell and Senator Chuck Schumer, the party leaders. As the weekend wore on, the group kept growing, up to 25 by Monday — crowded enough that one senator had to sit on a credenza.
They cycled through a series of ideas: Further shortening the length of the short-term spending bill; attaching a bill to protect Dreamers to another piece of must-pass legislation; demanding that Mr. McConnell put an immigration bill authored by Mr. Graham and Senator Richard J. Durbin, Democrat of Illinois, on the floor for a vote. Each was eventually deemed untenable.
By Sunday afternoon, the group had settled on a compromise that would fund the government for three weeks alongside a commitment by Mr. McConnell that the Senate would move expeditiously to take up the immigration issue. The challenge was getting the leaders to agree.
Mr. McConnell signaled Sunday night that he was listening to their suggestion, saying on the Senate floor that it was “my intention” to move ahead with immigration legislation.
But Democrats, led by Mr. Schumer, wanted more. The issue was whether the majority leader could be trusted to keep his word. Democrats have not forgiven Mr. McConnell for blocking the Supreme Court nomination of Merrick B. Garland for almost a year in hopes that a Republican would be elected to the White House.
Asked Monday morning how much of an issue that mistrust was, Mr. Manchin was clear. “Uh, most of it,” he said.
Mr. Schumer asked Ms. Collins to meet him in his office late Sunday after Mr. McConnell’s remarks and said he needed more clarity and assurance from the majority leader. Mr. Flake, who had initially supported the shutdown along with most Democrats, worked into the night with Ms. Collins to edge Mr. McConnell toward a more explicit statement.
Monday morning, he firmed up his pledge enough to win over Democrats, saying that the Senate’s immigration debate would have “a level playing field at the outset and an amendment process that is fair to all sides.” Behind the scenes, Republicans in the bipartisan group who had tied their interests to Democrats vouched for Mr. McConnell’s word.
“I said before, ‘Trust but verify,’” Senator Angus King of Maine, an independent who caucuses with Democrats, said of Mr. McConnell. “He made this commitment publicly in the Senate floor. He was much more specific than he was last night. And frankly I think this is an important opportunity for him to demonstrate that he will carry through.”
By the time Democratic and Republican senators met privately with their respective caucuses later Monday morning, it was clear it was enough to get to yes. Mr. Schumer told Democrats he would support reopening the government.
Not all Democrats were convinced. Senator Kamala D. Harris, Democrat of California and one of more than a dozen liberal Democrats who voted against the funding bill, said Mr. McConnell’s comments on Sunday night “fell far short of the ironclad guarantee” she needed.
But Mr. Flake said the Republican leader had made clear to Democrats he had done what he could do.
“Standing on the floor and saying we are going to proceed to an immigration bill in this environment with this kind of attention being paid to it is a pretty good promise,” he said.