Ricardo Martinelli, a former president of Panama, was taken into custody by United States marshals on Monday night at his home near Miami, raising the likelihood that he could be sent home to face charges of corruption and illegal spying.

Mr. Martinelli, who left Panama in 2015 and was living in Coral Gables, Fla., is to appear Tuesday before a federal magistrate for an extradition hearing, the Marshals Service said.

Mr. Martinelli’s office issued a statement saying that the former president had requested political asylum in the United States. “The United States is a democracy where laws and the rights of citizens are respected,” the statement said.

The government of Panama sent a request to the United States in September for Mr. Martinelli’s return. Officials said his home had been under surveillance for the last two weeks.