A new agreement between the U.S. and Guatemala would require any migrants who pass through that country to seek asylum there, the White House announced Friday. If the law takes effect, migrants who are apprehended in the U.S. would be deported Guatemala despite their country of origin.

A similar "Safe Third Country" agreement has been in place between the U.S. and Canada since 2004.

The agreement comes after Guatemala's Constitutional Court blocked that country's president from declaring Guatemala a safe third country for asylum-seekers. As of early Friday evening, the details of the agreement have yet to be formally released.

Get Breaking News Delivered to Your Inbox

"Look, we've been dealing for many years, I would say, with Guatemala and with other countries, and we are now at a point where we are — we just get along. And they're doing what we've asked them to do and I think it's gonna be a great thing for Guatemala," Mr. Trump told reporters in the Oval Office.

Friday's announcement is a change from Wednesday, when the president said that Guatemala had backed away from talks about a safe third country agreement.

Guatemalan President Jimmy Morales said the agreement aims to slow "irregular migration."

"Thanks to the working groups we have established, officials from the two governments have agreed to support actions that aim to mitigate irregular migration," he said in a statement.

It's not yet clear how this agreement will be carried out. Guatemalan immigration officials from the Guatemalan Migration Institute and Office of International Migration Affairs tell CBS News that there are currently only eight employees at the asylum agency that is responsible for handling asylum applications.

More than 235,000 Guatemalans have been apprehended at the southern border so far this year. Guatemala is the country with the largest number of unaccompanied minors and families attempting to cross into the U.S.

U.S. Rep. Norma J. Torres, the only member of Congress born in Guatemala, told CBSN in an interview that the agreement was "an insult to common sense."

"It is inconsolable to think Guatemala — the country that has one of the highest murder rate in the world… could be a safe country for people coming from Venezuela, from Cuba and some countries that are in deep trouble. To think that [Guatemala] is a country that is going to accommodate asylum seekers from anywhere else in the world — that is ridiculous," Torres told CBSN.

She noted that Guatemala doesn't have the infrastructure or health care system to accommodate asylum seekers and added that there is a food crisis.

Torres said she believed a deal had been reached because Mr. Trump "bullied" the government of Guatemala. "Who knows what else is in this agreement or what was done behind closed doors to get the Guatemalan government to agree to this?" Torres asked.

The decision is already being criticized by humanitarian groups. Refugees International President Eric Schwartz condemned the announcement as a violation of U.S. law and declared Guatemala unsafe for migrants.

The "safe third country" agreement with Guatemala "is very alarming," Schwartz said in a statement, because Guatemala "is in no way safe for refugees and asylum seekers, and all the strong-arming in the world won't make it so."

He went on to say that the agreement "violates U.S. law and will put some of the most vulnerable people in Central America in grave danger," and further, the arrangement "would make a mockery of the notion that those fleeing persecution in Central America have any recourse."

Mr. Trump has long expressed frustration with Central American countries and their failure to halt migration to the U.S., and is regularly looking for new ways to keep his campaign promise of securing the border.

Angel Canales contributed to this report.