The White House and Senate leaders reached a deal early Wednesday morning on a massive stimulus package they hope will keep the nation from falling into a deep recession because of the coronavirus crisis.

The revamped Senate proposal will inject approximately $2 trillion into the economy, providing tax rebates, four months expanded unemployment benefits and a slew of business tax-relief provisions aimed at shoring up individual, family and business finances.

The deal includes $500 billion for a major corporate liquidity program through the Federal Reserve, $377 billion in small business aid, $100 billion for hospitals and $150 billion for state and local governments.

ADVERTISEMENT

It will also give a one-time check of $1,200 to Americans who make up to $75,000. Individuals with no or little tax liability would receive the same amount, unlike the initial GOP proposal that would have given them a minimum of $600.

The agreement caps five days of intense negotiations that started Friday morning when Senate Majority Leader Mitch McConnell Addison (Mitch) Mitchell McConnellOcasio-Cortez to voters: Tell McConnell 'he is playing with fire' with Ginsburg's seat McConnell locks down key GOP votes in Supreme Court fight Video shows NYC subway station renamed after Ruth Bader Ginsburg MORE (R-Ky.) convened Republican and Democratic colleagues, with talks stretching late into the evening each of the following four days.

“At last we have a deal. ... The Senate has reached a bipartisan agreement," McConnell said during a speech on the Senate floor after 1:30 a.m. on Wednesday, pledging that the Senate would pass the package later in the day.

Senate Democratic Leader Charles Schumer Chuck SchumerRepublican senator says plans to confirm justice before election 'completely consistent with the precedent' Video of Lindsey Graham arguing against nominating a Supreme Court justice in an election year goes viral Graham signals support for confirming a Supreme Court nominee this year MORE (N.Y.) hailed the legislation as "the largest rescue package in American history."

“This bill is far from perfect, but we believe the legislation has been improved significantly to warrant its quick consideration and passage,” he said.

The final talks were conducted among McConnell, Schumer, Treasury Secretary Steven Mnuchin Steven Terner MnuchinLawmakers fear voter backlash over failure to reach COVID-19 relief deal United Airlines, unions call for six-month extension of government aid House Democrats plan to unveil bill next week to avert shutdown MORE, White House legislative affairs director Eric Ueland and incoming White House chief of staff Mark Meadows Mark Randall MeadowsAirline CEOs plead with Washington as layoffs loom Trump reacts to Ginsburg's death: 'An amazing woman who led an amazing life' Trump carries on with rally, unaware of Ginsburg's death MORE.

ADVERTISEMENT

Schumer kept in close touch throughout the process with Speaker Nancy Pelosi Nancy PelosiAs families deal with coronavirus, new federal dollars should follow the student Sunday shows - Ruth Bader Ginsburg's death dominates Hypocrisy rules on both sides over replacing Justice Ginsburg MORE (D-Calif.), who introduced her own $2.5 trillion bill Monday.

"Ladies and gentleman, we're done. We have a deal," Ueland told reporters, breaking the news after one of the final meetings in McConnell's office after midnight.

Ueland noted that staffers would work into Wednesday morning to finish the text of the bill, but that when it came to some of the negotiation's largest sticking points they already have language agreed to "or we know exactly where we're going to land."

Mnuchin said early Wednesday morning that President Trump Donald John TrumpBiden leads Trump by 36 points nationally among Latinos: poll Trump dismisses climate change role in fires, says Newsom needs to manage forest better Jimmy Kimmel hits Trump for rallies while hosting Emmy Awards MORE was "pleased" with the deal and urged Pelosi to take up the Senate bill and pass it without changes.

"This is a very important bipartisan legislation that is going to be very important to help American workers, American business. ... We couldn't be more pleased. Spoken to the president many times today, he's very pleased with this legislation and the impact this is going to have," he told reporters.

Pressed if that meant Trump would sign it if it reaches his desk in its current form, he added: "Absolutely."

Congress is under intense pressure to quickly pass the deal and reassure both the markets and an American public rattled by the spread of the coronavirus, with the United States having more than 55,000 confirmed cases as of Tuesday night, according to John Hopkins University.

The deal hammered out by negotiators provides $30 billion in emergency education funding, $25 billion in emergency transit funding and creates an employee retention tax credit to incentivize businesses to keep workers on payroll during the crisis.

It will also provide $25 billion in direct financial aid to struggling airlines and $4 billion for air cargo carriers, two industries that have taken a big hit in the economic downturn.

Senate Republicans on Tuesday were characterizing the direct assistance as “snap loans” instead of grants, to avoid the stigma of the proposal being called a bailout, but it has yet to be determined how the government would be compensated.

The bill bans stock buybacks for any corporation that accepts government loans during the term of their assistance plus one year.

Schumer added a provision to ban businesses owned by the president, vice president, members of Congress and the heads of federal executive departments from receiving loans or investments through the corporate liquidity program. The prohibition also applies to their children, spouses and in-laws.

ADVERTISEMENT

The legislation creates an inspector general and oversight committee for the corporate assistance program, similar to what was done for the Troubled Asset Relief Program of a decade ago, according to the senior administration official.

The deal comes two days after talks appeared to unravel when Democrats accused Republicans of walking away from negotiations and drafting the bill on their own. Schumer and Pelosi announced early Sunday afternoon that there was no agreement after they met with Mnuchin, McConnell and House Minority Leader Kevin McCarthy Kevin Owen McCarthyTrump asked Chamber of Commerce to reconsider Democratic endorsements: report The Hill's Morning Report - Sponsored by The Air Line Pilots Association - White House moves closer to Pelosi on virus relief bill Trump's sharp words put CDC director on hot seat MORE (R-Calif.) in the Capitol.

But Schumer and Mnuchin met at least five times Monday as they worked until midnight. Mnuchin was back in the Capitol at 9:30 a.m. Tuesday, when he and Meadows met with McConnell before restarting his shuttle diplomacy with Schumer.

And Pelosi appeared cautiously optimistic on Tuesday that the Senate would reach a deal that could also get support in the House.

"I'm optimistic that we can get something done. I've praised Chuck and Senate Democrats for staying strong," Pelosi told MSNBC's Andrea Mitchell. "We've been working together in terms of the policy issues there, great progress has been made."

But the days-long talks weren’t without plenty of drama. Tempers flared when the discussions hung up on disagreements over the length of unemployment assistance, restrictions on executive pay and stock buybacks and a Democratic push to require distressed corporations that accept taxpayer assistance to keep workers on payroll.

ADVERTISEMENT

Republicans were furious when the negotiations dragged beyond McConnell’s stated goal of passing a bill on Monday and Democrats twice blocked procedural motions to move on to a largely GOP-drafted stimulus plan. Democrats temporarily blocked Republicans from speaking on the Senate floor, a tactic Sen. Tom Cotton Tom Bryant CottonBattle lines drawn on precedent in Supreme Court fight Sunday shows - Ruth Bader Ginsburg's death dominates Chris Wallace presses Cotton on 'any hypocrisy' between comments on Supreme Court vacancy in 2016 and today MORE (R-Ark.) could be overheard calling “bullshit.”

“Are you kidding me?” a visibly enraged McConnell asked from the Senate floor.

Still, as Monday wore on, Schumer kept hopes of a deal alive. The Democratic leader told members during a conference call that he expected to reach a deal with Mnuchin. They both stressed as they left the Capitol around midnight, and hours later when they returned, that they expected a deal on Tuesday.

“We’re looking forward to closing a bipartisan deal today. The president wants us to get this done today,” Mnuchin said.

As negotiations stretched late into the night Tuesday, McConnell called a group of GOP negotiators — Sens. Mike Crapo Michael (Mike) Dean CrapoBottom line Davis: The Hall of Shame for GOP senators who remain silent on Donald Trump Top GOP senator urges agencies to protect renters, banks amid coronavirus aid negotiations MORE (Idaho), Pat Toomey Patrick (Pat) Joseph ToomeyAppeals court rules NSA's bulk phone data collection illegal Dunford withdraws from consideration to chair coronavirus oversight panel GOP senators push for quick, partial reopening of economy MORE (Pa.) and Roger Wicker Roger Frederick WickerHillicon Valley: DOJ indicts Chinese, Malaysian hackers accused of targeting over 100 organizations | GOP senators raise concerns over Oracle-TikTok deal | QAnon awareness jumps in new poll Shakespeare Theatre Company goes virtual for 'Will on the Hill...or Won't They?' Republican Senators raise concerns over Oracle-TikTok deal MORE (Miss.) — back to the Capitol.

The final stages of the negotiations focused on putting conditions on corporate loans backstopped by the Treasury Department and Federal Reserve, such as restricting executive compensation and stock buybacks for companies that take taxpayer-funded assistance, according to an aide familiar with the talks.

ADVERTISEMENT

A last-minute fight over the Supplemental Nutrition Assistance Program (SNAP) cropped up as an eleventh-hour issue on Tuesday after Pelosi said that a deal for a 15 percent increase in funding was taken out of the bill. A boost in food assistance money is a top priority for progressives in her caucus and members of the Congressional Black Caucus.

And both sides accused the other of trying to get unrelated provisions in the bill, which could be the final major piece of legislation Congress passes for months.

Republicans accused Democrats of trying to include increased fuel emissions standards for airlines and expansion of wind and solar tax credits, while Democrats homed in on a provision in a draft circulated Sunday that would have blocked nonprofits who receive Medicaid, like Planned Parenthood, from the previous coronavirus package from receiving Small Business Administration assistance under the stimulus package.

One of the thorniest questions of the talks was how to deliver relief to the battered airline industry, whose representatives burned up the phone lines over the weekend and Monday calling senators.

“They’re calling everybody,” one Democratic senator said of the airlines’ intense lobbying push for direct grants in addition to loans.

Hundreds of billions of dollars in buffer capital for the Treasury Department will allow the Fed to hand out an additional $4 trillion in loans to distressed companies such as U.S. airlines and Boeing, the nation’s leading airplane manufacturer. Their stocks have been hit the hardest in the recent stock market selloff that had erased the gains made since Trump took office.

The Fed loan program, which Democrats bashed as a corporate bailout program and Mnuchin’s “slush fund,” was one of the biggest sticking points during the late rounds of the negotiations.

Republicans argued the Treasury Department needed $500 billion to help the Fed inject enough liquidity into the economy, while Democrats were enraged over a provision they said would let Mnuchin provide loans and guarantees and then wait six months before disclosing who got the assistance. Schumer noted in a letter to his caucus on Wednesday morning that they were able to get that provision removed.

Sen. Joe Manchin Joseph (Joe) ManchinNames to watch as Trump picks Ginsburg replacement on Supreme Court Momentum growing among Republicans for Supreme Court vote before Election Day Gardner on court vacancy: Country needs to mourn Ginsburg 'before the politics begin' MORE (D-W.Va.) touted that Democrats were able to get “better oversight,” saying “you can’t just ... go ahead and give all your corporate executives, based on the back of the taxpayers, free carte blanche.”

Some of the nation’s biggest companies could face bankruptcy without federal intervention.

Fitch Ratings downgraded its outlook for United Airlines to negative on Thursday amid fears about its ability to pay back loans. S&P Ratings downgraded Boeing’s credit rating to just two notches above junk on Monday.

Other major areas of disagreement were over how long to provide beefed-up unemployment benefits, how much to spend on hospitals and health care providers and how much to provide to cash-strapped state governments through stabilization funding.

The negotiations seesawed for days over unemployment benefits. In a concession to Democrats, the bill will include four months of boosted unemployment benefits, according to two sources briefed on the deal. Republicans initially proposed three months.

Updated at 1:52 p.m.