Obrador implemented the huge policy changes before the deal was even announced. It was visible across the spectrum as military secured the southern Mexican border, invaders were actually bused back where they came from and accounts of traffickers were frozen (with arrests). Of course, these are things that "should" have been in effect always.
So here you have Mexico, basically split into zones that are run by warlord drogistas. And having by and large gone through the oil—now a net importer. With the gringos having pulled their collective heads out of their butts and talking smack up north. With important Mexicans being named at the Nexium trial. Waddaya wanna bet that some little secrets were bandied about by our people to speed things up with Obrador.
So they are playing ball, but you can bank on the fact that they were offered incentives at the same time, carrot or stick. So help in building the southern Mexico economic zone, with the prior agreed trade deal implemented too. And maybe real help in destroying the cartels.
At the same time, the oil is running out but the silver is not. Mexico is the world's leading silver producer. That silver may be Mexico's only card, but it is a major card that gives some leverage. The metal is disappearing from the crust–all will be gone within a generation, even as the need for it explodes, and even as PMs are about to be the centerpiece of the new global trade settlement system. POTUS, being the deal maker supreme, highly likely brought silver into the overall deal that resulted in Mexico instantly saying, "Si, Jefe." It's a win/win if our side helps them through their other serious problems and receives a nice, favored deal on AG trade.