Theresa May has seen off a threatened rebellion on Brexit with last-minute concessions which could give MPs a bigger say on the final withdrawal agreement and make a "no-deal" European Union exit all but impossible.
Some lawmakers tried to shout him down and accused the government of wanting too much power.
In the tense atmosphere where it was not clear which way the vote would go, the government secured its victory only after offering concessions to one of the leaders of a group of Conservative lawmakers who were threatening to vote against May. As the clock ticked down to the vote, two rebels stood up to say they were satisfied with what the government had offered them. Opposition lawmakers are trying to change the draft to bind the United Kingdom more closely to the EU's trade rules. Now the focus shifts to the price of the rebels' compliance, and it could be a high one for the beleaguered prime minister.
The EU is expecting her to have made progress by a summit in June and both sides want to reach a deal by October.
She has already agreed to give MPs a vote on the final Brexit deal, but says it will be a yes or no decision - meaning that rejecting it could see Britain crash out of the EU.More news: Amazon steps up Prime rollout at Whole Foods
Around a dozen Tory Remainers said that May had promised them that the government would accept two parts of the amendment by Grieve, a former attorney general: a vote on the final deal and a statement from ministers to seek approval from parliament for the next steps if no deal is reached by November 30 of this year. Rebel ringleader Dominic Grieve had signalled he was prepared to lead a revolt and inflict a second Brexit defeat on the Government.
His competing amendment could force ministers to hand over control of its Brexit strategy to parliament if there is no deal by mid-February.
Lee said that within government he "found it virtually impossible to help bring sufficient change to the course on which we are bound".
"Thirdly, we must under all circumstances respect the result of the referendum".
Justice minister Phillip Lee is the first minister to resign over the government's Brexit policy. Next up are the July votes on the trade and customs bills where rebels will aim to force the Government to keep the United Kingdom in the customs union.More news: Trump's Twitter rant against Trudeau garners global reactions
May's officials will begin work Wednesday on the wording of a new clause in her key piece of legislation preparing for the divorce from the European Union.
The Prime Minister appeared to have defused a potentially explosive row over the EU customs union on Monday night as Tory pro-Europe rebels Sir Oliver Letwin and Nicky Morgan and Brexiteers Jacob Rees-Mogg and Sir Bill Cash came together to table a separate compromise amendment backing "a customs arrangement" with the EU.
A Commons defeat on the issue would have been a significant blow to May's authority and risked triggering a leadership crisis for the prime minister. After losing her party's majority in parliament at an ill-judged election a year ago, she now relies on the support of a small Northern Irish party and the distance between victory and defeat is narrow.
In the event, Dr Lee abstained on the crucial vote, saying he was "delighted" the Government had agreed to introduce an amendment giving Parliament "the voice I always wanted it to have in the Brexit process".More news: Led joint bid wins right to host 2026 World Cup