President Donald Trump's administration can enforce its new restrictions for people crossing through Mexico to seek asylum in the US while lawsuits challenging the policy play out, a federal judge ruled on Wednesday.

The proposal at issue prevents most migrants at the southern border from seeking asylum in the U.S. if they passed through another country first.

U.S. District Judge Timothy Kelly, who was appointed by Trump, denied a request for a temporary restraining order against the policy in United States District Court for the District of Columbia on Wednesday.

Kelly said the immigrant advocate groups behind the suit did not show that their work would be irreparably harmed if the policy moved forward.

The groups sued on behalf of themselves as nonprofit groups that offer services to immigrants who would be unable to seek asylum under the new restrictions.

The White House Press Secretary told DailyMail.com: 'Today’s ruling in the United States District Court for the District of Columbia is a victory for Americans concerned about the crisis at our southern border.'

A separate hearing on a similar suit was scheduled later on Wednesday in San Francisco before U.S. District Jon Tigar who has already barred less restrictive policies on asylum from taking effect and could act to block the new asylum policy.

Tigar was appointed by former resident Barack Obama.

President Donald Trump's (pictured) administration can enforce its new restrictions for people crossing through Mexico to seek asylum in the US while lawsuits challenging the policy play out, U.S. District Judge Timothy Kelly, who was appointed by Trump, ruled on Wednesday. The latest proposal to bar people passing through another country from seeking asylum in the US targets the tens of thousands of Central American adults and children who cross Mexico every month to try to enter the U.S. It also would affect asylum-seekers from Africa, Asia, and South America

The White House Press Secretary said: 'The court properly rejected the attempt of a few special interest groups to block a rule that discourages abuse of our asylum system.

'The rule properly encourages migrants to seek asylum in other countries they have traveled through before reaching the United States and makes those who fail to do so ineligible for asylum, thereby foreclosing opportunistic claims by those who want to exploit our asylum system in an effort to immigrate unlawfully to the United States.'

The ruling in D.C. was an unusual victory for the administration, even if a temporary one.

Federal courts have repeatedly stopped the administration from enforcing many of its proposals cracking down on people crossing the border.

The latest proposal to bar people passing through another country from seeking asylum in the US targets the tens of thousands of Central American adults and children who cross Mexico every month to try to enter the U.S. It also would affect asylum-seekers from Africa, Asia, and South America.

The White House Press Secretary said: 'Tens of thousands of migrants making opportunistic asylum claims have not only exacerbated the crisis at our southern border but also have harmed genuine asylum seekers, who are forced to wait years for relief because our system is clogged with meritless claims.'

The plan has exceptions.

If someone has been trafficked, if the country the migrant passed through did not sign one of the major international treaties that govern how refugees are managed (though most Western countries have signed them) or if an asylum-seeker sought protection in a country but was denied, then a migrant could still apply for U.S. asylum.

The policy went into effect on Tuesday, one day after it was announced, though some officials said it was only being put in place in one location.

Hundreds of immigrants still showed up at U.S. border crossings trying to request asylum but with their prospects uncertain.

The policy went into effect on Tuesday, one day after it was announced. A separate hearing on a similar suit was scheduled later on Wednesday in San Francisco before U.S. District Jon Tigar who has already barred less restrictive policies on asylum from taking effect and could act to block the new asylum policy. Tigar was appointed by former resident Barack Obama. A United States Customs and Border Protection Officer checks the documents of migrants before being taken to apply for asylum in the United States, on International Bridge 1 in Nuevo Laredo, Mexico on July 17

Legal groups argued the approach was barred by federal law establishing how people can seek asylum.

'We are disappointed in the court’s decision today,' said Claudia Cubas, litigation direction for the Capital Area Immigrants’ Rights Coalition.

U.S. law allows refugees to request asylum when they arrive, regardless of how they did so. There is an exception for those who have come through a country considered to be 'safe.'

At the northern border, the U.S. and Canada have a 'safe third country' agreement that limits people who arrive in one country from seeking asylum in the other.

The U.S. has sought to reach the same agreement with Mexico and Guatemala, but Guatemala’s high court blocked a possibly agreement. Mexico has said no agreement has been decided.

Top U.S. officials say their latest plan would discourage migrants from leaving their countries, which is necessary to reduce the numbers of people that U.S. border agents are detaining.

Reports of squalid conditions at some U.S. border detention facilities have sparked mass outrage, and advocates accuse the administration of unnecessarily detaining people seeking asylum and mistreating people in custody.