MEXICO CITY (Reuters) - Mexico and the United States have signed three accords to improve bilateral customs procedures and expedite the flow of agricultural produce across their almost 2,000-mile (3,220-km)border, the two governments said on Monday.

Slideshow ( 9 images )

In a joint news conference with U.S. Homeland Security Secretary Kirstjen Nielsen, Mexico’s Foreign Minister Luis Videgaray said the first agreement aimed to promote joint cooperation to stop illegal merchandise crossing the border.

The two agreed to implement programs of joint inspections of cargo between the neighbors, whose bilateral trade is worth half a trillion dollars a year.

“It’s about creating efficiencies,” Videgaray said.

Finally, the governments signed an accord that would promote the trade of agricultural goods, the minister added.

Nielsen said the two countries were also working on about 20 further memorandums of understanding and letters of intent.

Border security needs to be ramped up to halt the illicit flow of arms, Mexico’s Interior Minister Alfonso Navarrete said in a subsequent joint news conference with Nielsen.

“There needs to be much more caution taken... to reduce gradually but conclusively the high levels of violence when arms enter Mexico illegally,” Navarrete added.

The neighboring nations also need to share the responsibility of attending to refugee and asylum cases, he said.

Mexican-U.S. relations have been strained by U.S. President Donald Trump’s insistence that Mexico pay for the southern border wall he wants built to keep out illegal immigrants.

Tensions have also been stirred by Trump’s repeated threats to dump the 24-year-old North American Free Trade Agreement (NAFTA) if it is not reworked to his satisfaction.

NAFTA has encouraged companies to relocate to lower-cost Mexico at the expense of U.S. manufacturing workers, he argued.

In January, Reuters reported that Mexico and the United States were looking into whether armed U.S. federal air marshals could be deployed on commercial cross-border flights, the latest example of Mexico seeking to ingratiate itself to its northern neighbor.