In the space of a week, U.S. President Donald Trump’s tariffs on steel and aluminum went from a “no exemptions” plan to one filled with carve-outs for Canada, Mexico and likely other allies, plus hundreds of products not available domestically.

People familiar with the shift say Trump’s mind was changed by a furious last-ditch lobbying campaign from the Canadian government, Republican lawmakers, business groups and even the United Steelworkers — the very union whose members stand to benefit most from the tariffs.

Trump said on Friday he was ready to work out an exception for Australia. Japan, South Korea, the European Union and Brazil called for similar treatment.

The exemptions for Canada and Mexico, which are temporary, were also seen as being prompted in part by the North American Free Trade Agreement talks, where U.S. negotiators could use the prospect of making them permanent as a bargaining chip.

“I have to think that the exclusion was probably also granted because we’re going to be a little more accommodating to them at the (NAFTA) negotiating table,” said Mark Warner, a Canadian trade lawyer.

RELATED STORIES Australia set to secure exemption from U.S. tariffs

Asked whether Canada had offered any concessions to secure an exemption, a Canadian government official said that there was no evidence of this and that Canada had not changed its NAFTA negotiating line.

A Mexican government official also denied that any concessions were offered to Washington. Forcing Mexico to pay the tariffs, however, would make it very difficult to complete NAFTA talks, the official said. “If you do that, kiss good-bye any possibility of … well, basically anything.”

NAFTA’s legal structure, which offers its members tariff-free access to each other’s markets, was a major complication in applying the tariffs to Canada and Mexico, according to a prominent Washington trade lobbyist, who spoke on condition of anonymity due to the sensitivity of the matter. “I do think the possibility of NAFTA partners walking away from the table mattered quite a bit,” the lobbyist said.

Trump first drew the link between the metals tariffs and NAFTA on Monday. Less than 24 hours after White House adviser Peter Navarro declared that there would be no exceptions to the tariffs, Trump tweeted that they may come off for Canada and Mexico “if a new and fair NAFTA agreement.”

Adding new elements to the negotiations to create wiggle room on big decisions was a Trump tactic familiar to David Bozell, a supporter of the president. “If he doesn’t see that there’s room to maneuver, he’ll create some,” said Bozell, president of For America, a conservative grass-roots political group.

In the days leading up to Thursday’s announcement, the biggest trade move of Trump’s presidency, key industry players and trading partners were still in the dark about the contours of the plan.

United Steelworkers President Leo Gerard had voiced opposition to tariffs on Canada, whose steel and aluminum industries are fully integrated with those of the United States and where workers are represented by the Pittsburgh-based union.

Yet USW members were already traveling to Washington to appear with Trump at the White House signing ceremony before the union knew if it could fully support the plan.

“We didn’t know exactly what the exclusion was until it got announced,” said Gerard, who is Canadian. “We kept making the case that Canada wasn’t the enemy.”

Canada’s Liberal government also had sprung into action to defend NAFTA and cross-border steel and aluminum trade once it became clear that Trump was serious about imposing tariffs.

Prime Minister Justin Trudeau called Trump on Monday to “forcefully defend” the interests of Canadian workers and to stress that the tariffs would not help talks to modernize the NAFTA trade pact, according to a government official who spoke on the condition of anonymity.

Trudeau also spoke on Thursday with U.S. Senate Majority Leader Mitch McConnell and House of Representatives Speaker Paul Ryan, prominent Republican critics of the tariffs, the prime minister’s office said.

Canadian Cabinet members also kept phone lines “humming” with their U.S. counterparts in an all-out push that recalled a lobbying effort in April 2017 to persuade Trump not to withdraw from NAFTA but to pursue re-negotiation instead.

“We are reaching out to people in the United States and asking: ‘Are you aware that you run a steel trade surplus with Canada? Do you know quite how much U.S. steel Canada buys?” said another person familiar with Canada’s lobbying effort.

According to U.S. Census Bureau data, the United States exported $4.35 billion worth of iron and steel mill products to Canada in 2017, against $3.69 billion worth of Canadian imports.

Republican congressional sources said Ryan and House Ways and Means Committee Chairman Kevin Brady had been pressing Trump all week to avoid across-the-board steel and aluminum tariffs that would hurt U.S. allies, and were working to suggest ways to narrow the tariffs further.

But an administration official insisted on Wednesday that Trump’s final tariff proclamations had not been softened, saying the “flexible but firm” approach allows exemptions for allies, but must be offset by higher tariffs on remaining countries.

“We have structured these proclamations in a way which are unequivocally designed to defend our aluminum and steel industries,” the official said.