But a group of migrants earlier this year drew the attention of President Trump, who posted messages on Twitter warning that they posed a threat to American sovereignty. He used their migration to help justify the deployment of the National Guard to the southwest border of the United States.

That caravan, which also included many Hondurans and at one point numbered an estimated 1,200 before diminishing in size, eventually reached the northern border of Mexico, with an enormous international media contingent in tow. After a tense standoff at the border crossing in Tijuana, several hundred migrants were eventually allowed through to petition for asylum in the United States, while others melted back into Mexican society, returned to their home countries or attempted to cross into the United States illegally.

During that migration, Mr. Trump also threatened Honduras, saying foreign aid to that nation, as well as to “the countries that allow this to happen,” was “in play.”

Honduras, where gangs exercise widespread control in certain neighborhoods, has one of the world’s highest homicide rates, though the numbers have been falling in recent years after hitting a peak in 2011. The rate plunged by more than a quarter in 2017, according to the Honduran government, which attributed the drop to an effort by security forces to attack drug traffickers and gangs.