WASHINGTON — Defense Secretary Jim Mattis will resume his role as the reassurer for American allies this week when he heads to Mexico, where he will try to mend relations after President Trump failed to quickly offer condolences for the earthquake on Friday that killed at least 96 people and severely damaged thousands of homes.

Mr. Mattis will also try to signal to Mexican officials that ties between the United States and its southern flank remain strong. After four days without word from Mr. Trump about the 8.2-magnitude earthquake in Oaxaca State, Mexico on Monday rescinded its offer of aid to the United States for people affected by Hurricane Harvey.

Mr. Trump had not responded to that offer of help — when it was made, he was tweeting that Mexico was one of the “highest crime nations in the world.” But Gov. Greg Abbott of Texas had said his state would accept the help.

But the offer was withdrawn when Mexico’s Foreign Ministry said in a statement on Monday that it needed the money to help care for victims of the earthquake, which was followed by Hurricane Katia.