WASHINGTON — Conservative justices on the Supreme Court on Tuesday appeared to side with President Donald Trump and his decision to rescind an Obama-era program that allows about 700,000 undocumented immigrants to live and work in the United States without fear of deportation.

Solicitor General Noel Francisco, arguing on behalf of the US government, said the Deferred Action for Childhood Arrivals policy, commonly known as DACA, was a "temporary stopgap measure" that could be ended at any time.

The Trump administration has also argued that DACA, which defers deportation for undocumented immigrants who were brought to the US as children, is illegal because former president Barack Obama overstepped his authority in 2012 when he created the program. But justices on Tuesday were considering whether the courts can review the administration's choice to end DACA and, if so, whether the decision was legal.

The administration cited two DACA-related programs — Deferred Action for Parents of Americans and Lawful Permanent Residents (DAPA) — that the 5th Circuit ruled against when it upheld an injunction blocking them from going into effect. The lower court said states that had sued the Obama administration over the two programs were "likely" to prevail on some of their claims.

Chief Justice John Roberts, who may be a decisive vote, wondered if the Trump administration had already done enough in arguing that DACA was illegal when it relied on the previous court rulings.

"Is it enough ... to say, 'Look, I've got a decision from the 5th Circuit that tells me this is illegal, it's been affirmed by the Supreme Court by an equally divided vote'? That's enough for me to say we're not going to do it?" he said.

Several conservative justices also appeared to agree that the Department of Homeland Security had sufficiently made its case for rescinding DACA, which it argued was a discretionary program that didn't require review.

Lower courts have so far disagreed with that premise, ruling that, under the Administrative Procedure Act, government agencies can't make decisions that are "arbitrary and capricious." Instead, they have to give a reasonable explanation for why they chose to take a certain action.

But Justice Brett Kavanaugh said former DHS secretary Kirstjen Nielsen's explanation for rescinding DACA, as well as her conclusion that the agency should use its discretion to end the program regardless of whether it's legal, "was a very considered decision."

Plaintiffs in the case argued that the courts do have the authority to review Trump's decision because his administration had argued DACA is illegal, and so there was no "discretionary choice to make."

Attorneys for the plaintiffs also argued that the government did not offer a full explanation for why it wanted to end DACA, and that doing so would cause a huge disruption for thousands of people whose family members, coworkers, and employees would lose their protected status.

Trump has been trying to end the special protections for DACA recipients for the past two years. A ruling on the case is expected to come next summer during the height of the 2020 presidential campaign.

