New York City Mayor Bill de Blasio violated the immigration laws of the United States and Mexico last month during a trip to the southern U.S. border, Customs and Border Protection alleged in a new letter that was obtained by The Associated Press.

What are the details?

The agency alleged that de Blasio and his security detail violated both countries' border laws on June 21 when they illegally crossed into Mexico — and then back into the U.S. — on foot near the El Paso, Texas, port of entry. De Blasio was at the border to visit an immigrant detention facility that held children.

The AP explained:

According to the letter, a uniformed Border Patrol agent noticed a group on the Rio Grande River flood plain south of the Tornillo, Texas, Port of Entry, taking photos of the holding facility. The agent asked if anyone from Border Patrol or public affairs was there to authorize their presence. A New York Police Department inspector said no, according to the letter, and when the agent asked the group how they arrived, they pointed to Mexico. The agent told them they’d crossed the border illegally and asked them to remain there while he got a supervisor and took them to an official crossing for an inspection per federal law, according to the letter. But the group disregarded the order and drove back to Mexico, according to the letter.

The incident happened one day after President Donald Trump signed an executive order ending the separation of illegal immigrant children from their parents. De Blasio has criticized Trump's "zero tolerance" immigration policy, even calling for the abolition of the Immigration and Customs Enforcement agency.

The New York Police Department provides the security detail for de Blasio. The New York City mayor visited the border and the local detention facility with 20 other mayors from across the country.

How did de Blasio respond?

The mayor's office sharply rebuked the idea de Blasio violated the law. Spokesman Eric Phillips told the AP that de Blasio and his team has authorization to be where they were.

"The mayor crossed the border with the direct approval and under the supervision of the border patrol supervisor at this port of entry," Phillips said. "Any suggestion otherwise is a flat-out lie and an obvious attempt by someone to attack the Mayor because of his advocacy for families being ripped apart at the border by the Trump Administration."