Late Wednesday night, the Senate unanimously passed the largest economic stimulus package in American history. The House of Representatives is set to take up the measure on Friday as the country faces the novel coronavirus outbreak. President Trump has been cheerleading the bill from the White House and is expected to sign it quickly when it reached his desk.

"This is a wartime level of investment into our nation," Senate Majority Leader Mitch McConnell said Wednesday morning in announcing the deal.

The bill itself runs 880 pages and includes a range of far-reaching provisions, including $1,200 government checks for individuals making under $75,000 a year and an expansion of unemployment insurance.

The most contentious part of the negotiations leading up to the bill’s passage were provisions to send hundreds of billions of dollars directly to impacted businesses.

The initial proposal from McConnell last week was repeatedly slammed as a “$500 billion slush fund” by Democrats who held up the bill until changes were made. Treasury Secretary Steven Mnuchin and fellow Republicans ultimately agreed to a range of oversight measures for how companies will be eventually able to spend the money.

"Like all compromises, this bill is far from perfect, but we believe the legislation has improved significantly," Senate Minority Leader Chuck Schumer said after the deal was announced.

Once the bill is signed into law, “we’re going to operate at lightning speed,” Mnuchin said on Wednesday. Loans could begin processing by next week and the IRS could direct deposit some of the checks in the next three weeks, he said.

Here’s a rundown of what’s in the deal.

A ‘special provision’ for airlines

The deal includes $46 billion for the airline industry; $25 billion of which will be for passenger airlines, $4 billion for cargo companies, and $17 billion for companies deemed important to national security.

Sen. Pat Toomey (R-PA), during a conference call with reporters Wednesday, confirmed that much of the money will likely be extended “in the form other than a loan” – in other words, a grant. The Treasury Department has the option of distributing the money as a loan “but that is not likely,” he said.

Story continues

Airline CEOs recently promised to stop stock buybacks and paying dividends in exchange for help from the federal government.

Toomey pushed back on a report that the $17 billion for national security firms was earmarked for Boeing. He also said there is a chance the government will take common stock as part of the deal with Boeing or other companies for some period of time, but taking any stock with voting rights is “expressly prohibited.”

Trump has repeatedly signaled that Boeing will be a key recipient of financial help. “We'll be helping Boeing, we'll be helping the airlines,” he recently said. The airlines industry was singled out for special treatment because “airlines do provide significant resources and national security issues,” Mnuchin said Monday, adding, “I believe that's something that's very important to Americans.”

Hundreds of billions more for businesses

Other impacted industries, from the cruise industry (if they are US-based) to hotels to restaurants, have a range of ways to get government cash.

Previous stimulus efforts put $50 billion aside for the Small Business Administration. That “money's already starting to be approved,” an SBA official told Yahoo Finance last Friday.

This bill ramps things up aggressively with hundreds of billions of dollars in loans now expected to be available in the coming weeks and months.

Sen. Marco Rubio (R-Fl.), Chairman of the Senate Committee on Small Business and Entrepreneurship, was one of the leaders pushing the small business provisions.

“This is not a program where you are going to the SBA, you are not going to a tent somewhere in a disaster area or some government office or some government website,” he said on the Senate floor over the weekend. “You are going to a bank, to a financial institution.”

The banks will then, according to the plan, be able to process cash assistance quickly, either through the SBA or through a new program that will be set up specifically to administer some of this money. The deal includes a $350 billion “Paycheck Protection Program” for small businesses as well as a $454 billion fund for a new lending agency.

Sen. Marco Rubio (R-FL) talks to reporters after leaving a meeting with fellow Republican senators and Treasury Secretary Steven Mnuchin during negotiations on a $2 trillion economic stimulus. (Chip Somodevilla/Getty Images)

Mnuchin added that any FDIC-insured bank will be able to process loans and once a business shows it’s payroll, “you get the money instantaneously.”

What’s still a bit of a mystery is exactly how this new lending agency will work. The new entity will administer the $46 billion to the airlines mentioned above. In addition, there will be $454 billion for the Treasury Secretary to dole out, which will be "broadly available" to a range of companies.

Here’s how the bill itself described it: “the Secretary is authorized to make loans, loan guarantees, and other investments in support of eligible businesses, States, and municipalities that do not, in the aggregate, exceed $500,000,000,000”.

Toomey was a central negotiator on this portion of the package and gave some insight into how this “big credit facility” will work. The money “will be available across categories, across sectors and industries,” and “it’s the single biggest piece in this whole thing,” he said.

Businesses of all sizes, many of which are facing the prospect of bankruptcy, will be able to participate in the different programs.

There is also a crucial change in how the $350 billion in “Paycheck Protection” loans will work. Some of these loans appear set to eventually be forgiven and effectively become grants.

As the bill says: “An eligible recipient shall be eligible for forgiveness of indebtedness” for payroll costs, covered mortgage interest payments, covered rent payments, and covered utility payments.

“They are going to be able to take an SBA loan that will give them two months of payroll and some overhead,” Mnuchin said recently. “And if they hire the workers back or they keep their workers hired, the government will forgive that loan.”

Provisions to ban stock buybacks

A lot of that cash, especially the funds from the new lending facility, will find its way into a range of publicly-traded companies. The deal includes provisions to stop these companies from using that cash for stock buybacks or executive bonuses (or at least expose them to public scrutiny if they do).

"Every loan document will be public and made available to Congress very quickly so we can see where the money is going," Schumer said Wednesday on the Senate floor.

Senate Minority Leader Chuck Schumer (D-NY) before a meeting about the phase 3 coronavirus stimulus bill. (Drew Angerer/Getty Images)

The bill creates “within the Department of the Treasury the Office of the Special Inspector General for Pandemic Recovery” focused on oversee of these funds. The bill also creates a five-person congressional panel. The structure is similar to what was done for the Troubled Asset Relief Program of a decade ago.

Neil Barofsky, who was the special inspector general for TARP, noted in a Yahoo Finance interview Tuesday that “putting the entity in place, is a first step,” he said, adding “but then there has to actually be real oversight, real transparency.”

Schumer’s office also made sure to note to reporters that the deal will “prohibit businesses controlled by the President, Vice President, Members of Congress, and heads of Executive Departments from receiving loans or investments from Treasury programs.”

Other stimulative measures

Hundreds of billions more dollars will also indirectly flow to businesses. First and foremost, lawmakers hope that the $1,200 checks will be spent across a range of industries.

The deal also includes a massive expansion of unemployment insurance. Schumer called the agreement "unemployment compensation on steroids," and said the maximum unemployment benefit will be increased by $600 per week to ensure “that laid-off workers, on average, will receive their full pay for four months.”

This unemployment insurance provision was the subject of some Congressional wrangling on Wednesday but a last-minute amendment to lessen these benefits was defeated.

The plan also includes a massive infusion of cash into the health-care industry. Health care providers, community health centers, and hospitals are set to receive over $130 billion to fight the virus while states and localities are set to receive another $150 billion.

Overall, Washington is hoping that the deal will set the stage for a robust economic recovery. If not, Congress will need to looks towards a ‘phase 4’ package.

Sen. Chuck Grassley told Yahoo Finance on Wednesday that he wants to wait and see before thinking about another bill. He thinks the country will have a good sense in a few months time. “If things are turning around at that point, then the answer is no,” he said about another bill. “But if we are in the same place three or four months from now as where we are today, we are going to have to do more.”

This story has been updated as more details about the final bill were made public.

Follow the news here.

Ben Werschkul is a producer for Yahoo Finance in Washington, DC.

Read more:

Why Trump's call to restart the economy in April is being derided as 'totally nuts'

Small Business Administration: $50B coronavirus lifeline 'already starting to be approved'

Why businesses might ‘walk away’ from Trump’s coronavirus aid if there are strings attached

Read the latest financial and business news from Yahoo Finance

Follow Yahoo Finance on Twitter, Facebook, Instagram, Flipboard, LinkedIn, YouTube, and reddit.