As the clock ticked down to an eventual government shutdown at midnight Saturday, Trump invited Schumer to the White House to hear him out. Schumer went to meet with Trump on Friday afternoon, with no others present except Kelly and Schumer's chief of staff. They negotiated over 90 minutes while dining on cheeseburgers, according to various accounts. Republican congressional leaders did not attend the meeting.

White House chief of staff John Kelly played a major role in President Donald Trump shooting down the framework of a last-minute deal floated by Senate Minority Leader Chuck Schumer to fund the government Friday.

White House chiefs of staff often play a major role in negotiating with Congress. Kelly, a retired Marine general, is known for his discipline, as well as his organizational and management abilities. However, he is not widely considered a political operator like Rahm Emanuel, a former congressman and Clinton administration veteran who worked for President Barack Obama, or Andrew Card, President George W. Bush's first chief of staff and a veteran of previous Republican administrations.

Yet, as immigration came to the forefront in negotiations, Kelly, a hardliner on the subject and Trump's former secretary of Homeland Security, became more involved in influencing policy and the president's positions. In recent weeks, Kelly has participated in immigration talks with the No. 2 ranking House and Senate members on both sides of the aisle.

Ahead of the shutdown, Schumer and most of his caucus were threatening to vote against a House-passed stopgap spending bill that would keep the government open until Feb. 16 and reauthorize the Children's Health Insurance Program for six years. They wanted to reach a deal on an immigration proposal that would shield hundreds of thousands of young undocumented immigrants from deportation, which would include increased border security funding and changes to extended family migration and the visa "lottery" system to appease Republicans.

Early Saturday morning, Schumer said he offered terms to Trump that he thought could result in a deal, even yielding on including funding for the president's proposed barrier on the U.S.-Mexico border. While neither the president nor the senator left the meeting saying they had a deal, both cited progress afterward. According to the New York Times, Schumer thought he had coaxed Trump into agreeing to a three- to four-day extension of funding, which would include money for disaster relief and health-care provisions, to enable sides to reach a more long-lasting deal.

"In my heart, I thought we might have a deal tonight," Schumer said.

Kelly, who has participated in rounds of congressional negotiations on funding, then reassured Republicans that Trump had not struck a deal without them, as some had feared he could. He called Senate Majority Whip John Cornyn, R-Texas, to say Trump and Schumer had not reached a solution, according to Politico.

"He told me that the president told Schumer to come back and talk to [House Speaker] Ryan and [Senate Majority Leader] McConnell. [Trump] wasn't going to get in the middle of it," Cornyn said, according to the news outlet. "Sounds like Gen. Kelly had it under control."

Later in the day after more exchanges between the White House and Schumer, Kelly called the senator to say the framework of the agreement he proposed was too liberal for Republicans, a person familiar with the call said. In fact, Kelly had an extensive list of objections to the potential deal, according to the Times.

Nearly all of Schumer's caucus — and four Republicans, too — voted against the House-passed bill late Friday. Congress could not reach a deal before funding lapsed on Saturday.

Senators on both sides of the aisle — particularly Lindsey Graham of South Carolina — have expressed frustration with apparent inconsistency from Trump on what he wants in an immigration deal. Democrats and most Republicans in Congress support some type of legislation to shield the immigrants brought to the U.S. illegally as children.