After months of negotiations and sharp warnings, this week is a pivotal moment for the future of the Iran nuclear agreement as President Donald Trump faces a critical self-imposed deadline.

In January, Trump waived sanctions on Iran again, as the deal requires, but he warned that it would be the last time unless Congress and Europe addressed what he called the deal's "flaws." On Saturday he’ll face a new round of sanctions waivers, forced to decide between keeping the agreement alive or finally withdrawing the U.S. – although he tweeted Monday that he would announce his decision Tuesday at 2 p.m.

It’s been a long, complicated road to this point, so here’s a refresher on the issue.

HOW DID WE GET THE IRAN DEAL?

Since the Ayatollah came to power in 1979, Iran has been under progressively more constrictive U.S. sanctions that were especially ramped up under George W. Bush and Barack Obama. But starting in 2007, European allies began to join the U.S. in economically pressuring Iran over its nuclear and missile programs. Multinational corporations soon followed suit by withdrawing their businesses.

By 2013, after years of failed talks, increasing tension and sanctions, and Iran boosting its nuclear program, the country finally entered serious negotiations with the P5+1 – the five permanent members of the United Nations Security Council – the U.S., the U.K., France, China, and Russia – plus Germany, with the European Union involved as well.

Together, they reached an initial agreement, called the Joint Plan of Action, in November 2013. Iran took initial steps to draw down its nuclear program while the U.S. and Europe offered some sanctions relief and unfroze Iranian funds. As the agreement was implemented throughout 2014, negotiations dragged on into 2015.

On July 14, 2015, the final agreement was announced – the Joint Comprehensive Plan of Action, often known by the acronym JCPOA. Six days later, the UN Security Council passes a resolution endorsing the deal. And on October 18, the parties marked Adoption Day, with Implementation Day the following winter, January 16.

WHAT DOES THE IRAN DEAL DO?

The JCPOA is not a treaty, but an agreement with series of commitments for both sides. The gist is that in exchange for sanctions relief, Iran agreed to restrictions on its nuclear program.

Iran agreed to never build a nuclear weapon as a signatory of the Non-Proliferation Treaty and it must always allow the International Atomic Energy Agency to surveil its centrifuges, which are critical to enriching the concentrated uranium that creates a nuclear weapon.

But after certain periods of time, Iran could start to rebuild a civilian nuclear program. By 2025, the number of centrifuges Iran is allowed to have would be lifted; by 2030, the limits on enrichment would expire.

Most critics saw the very premise of the deal as a concession – that a rogue regime like Iran was allowed to have any nuclear program – or charged that these "sunset clauses" mean Iran is only delayed from getting a nuclear bomb. Supporters saw it as pragmatic, a way to ensure Iran never developed a nuclear bomb secretly because their limited civilian nuclear program would now be subject to international inspections by the IAEA, a U.N. organization – and the deal itself forbids them from pursuing a nuclear bomb.

Other critics complain Iran got all the benefit up front – the sanctions relief and access to international business, in exchange for only a promise. Trump himself often mentions the pallets of cash, telling Fox News in April that Obama "made a horrible deal giving $150 billion, giving $1.8 billion in cash — in actual cash carried out in barrels and in boxes from airplanes."

The $150 billion was not money from the U.S., but Iranian assets that the U.S. unfroze – and it is estimated to have been closer to $56 billion, not $150 billion, according to the Treasury Department. In addition, the U.S. and Iran agreed to a one-time payment of $1.7 billion, not $1.8 billion, from the U.S. for a $400 million arms deal that the U.S. never completed, plus interest; it was reportedly delivered on pallets, not barrels and boxes.

Either way, critics say Iran has made all the gains, while supporters say the long-term "get" for the U.S. is worth the price of sanctions relief -- a non-nuclear-armed Iran.

WHAT DOES TRUMP OPPOSE IN THE DEAL?

Candidate Trump didn’t always talk about tearing up the Iran deal, unlike some of his Republican primary opponents. His new Secretary of State Mike Pompeo also identified himself in the "fix the deal" camp during his confirmation hearing.

To that end, the Trump administration had laid out three issues with the deal it saw as most pressing: Sanctioning Iran for its ballistic missile program, strengthening the IAEA's inspections, and eliminating those "sunset clauses." When Trump most recently signed sanctions waivers in January, he said it would be his last time unless Europe helped the U.S. deal with these issues.

Since then, his administration has been negotiating with the U.K., France, and Germany. The two sides have come close to an agreement, but what makes a "fix" so difficult, even among allies, is that Europe wants to build on the agreement while Trump wants a new foundation – and to get rid of the old one.

"They want to have a new start," a European diplomat told ABC News Monday. "They believe you cannot build a second pillar – a future JCPOA – as long as the current one is in existence."

WHAT HAPPENS IF THE U.S. WALKS AWAY?

No one really knows, but it depends on how Trump exits and how Iran reacts.

As the president, Trump could choose to stop all sanctions waivers at once and hit Iran with everything – all the sanctions the U.S. has lifted as part of the deal. Another more likely option is to not sign the sanctions waivers that are up for renewal this Saturday, May 12. Those sanctions hit the Iranian central bank and penalize countries that purchase oil from Iran if they do not reduce those purchases after 180 days.

That option could give the administration more time to find a "fix" with the Europeans – but Trump's critics argue that would already put the U.S. in violation of the deal, allowing Iran to exit as well.

What's unclear is whether the U.S.'s allies would go along with it and to what extent. Europe maintains that the deal is working and points out that the IAEA has certified several times now that Iran is complying, so it's highly unlikely they'd slap sanctions back on too.

The other issue is how Iran reacts. Foreign Minister Javad Zarif has warned that if Trump doesn't waive sanctions, it'll be the end of the deal -- and Iran will restart its centrifuges. But on Monday, President Hassan Rouhani said his country would be willing not to abandon the nuclear deal even if the U.S. pulls out, saying, "What we want for the deal is that it's preserved and guaranteed by the non-Americans," the Europeans, Chinese, and Russians.

The deal's proponents add that the danger here is if the U.S. exits and Iran restarts its nuclear program, the world may not be able to know. Without the deal's inspections, the IAEA would not be able to surveil Iran's nuclear sites and demand access to undeclared sites. As a Non-Proliferation Treaty signatory, Iran would have to allow some inspections, but at that point, it's an open question if Iran will comply -- or even leave the treaty.

One certainty is that it would put the Trump administration and Europe at odds again, another division that damages the transatlantic alliance.