President Trump cautioned that Mexico “better not” detain and disarm U.S. troops again, referring to a recent incident in which Mexican soldiers disarmed U.S. troops on American soil.

“Mexico’s Soldiers recently pulled guns on our National Guard Soldiers, probably as a diversionary tactic for drug smugglers on the Border,” Trump tweeted Wednesday. “Better not happen again! We are now sending ARMED SOLDIERS to the Border. Mexico is not doing nearly enough in apprehending & returning!”

[Read more: Trump doubles number of migrants in so-called 'mother of all caravans']

On April 13, Mexican troops confronted two Army soldiers in an unmarked Customs and Border Protection vehicle near Clint, Texas. The Mexican soldiers, who were armed with FX-05 Xiuhcoatl rifles, then detained, disarmed, and questioned the U.S. soldiers. A Beretta M9 service pistol was temporarily confiscated from one U.S. soldier, leaving the Americans unarmed.

American troops sent to the U.S.-Mexico border are required to undergo training to prepare for hazardous situations they may encounter, but there is no official protocol for handling encounters with a foreign military, senior defense official from Northern Command, or USNORTHCOM, said.

The official claimed the incident was unprecedented and said the Pentagon is looking closer at the standoff to "help us modify any instructions that we're giving the troops.”

"This is the first incident that we're aware of that the two militaries came together," the official told the Washington Examiner.