Immigration and Customs Enforcement says a fugitive who escaped from ICE at JFK Airport earlier this week was taken back into custody Friday.

Mohamadou Mbacke, 31, was apprehended by ICE officials at a coffee shop near an Amtrak station in Chicago, the agency said.

The agency says the citizen of Senegal escaped ICE custody at JFK Airport on Tuesday, where he was scheduled to get on a plane out of the country.

According to a criminal complaint, while in the gate area at the airport, Mbacke received permission from the deportation officers with him to sit about eight to 10 rows away from them. Mbacke then departed the gate area without the officers' permission, according to the criminal complaint.

ICE officials say video showed Mbacke getting into a cab at approximately 9 p.m. Tuesday and departing the airport.

Mbacke lawfully entered the U.S. in 2005 but violated the terms of his status, ICE says. The agency says he has convictions for weapons and firearm offenses and was ordered to be deported in 2015.