California officials are praising workers for rescuing a 13-year-old boy who fell into a river of sewage in Los Angeles.

The boy, Jesse Hernandez, spent more than 12 hours in the city’s large underground sewage system. It is filled with refuse liquids and other waste materials, some of them poisonous.

Jesse had been playing at a public park with other children during a family gathering on Sunday. At one point, the children were on pieces of wood that covered an opening leading to the sewer system. One of the wooden planks broke.

The boy fell about eight meters down and landed in fast-moving sewage, said Brian Humphrey, a spokesman for the Los Angeles Fire Department.

The other children quickly told adults what had happened. The adults then called an emergency telephone line for help.

Rescuers immediately began searching for Jesse underground. They set cameras on floatation devices, which they put into the sewage system.

Rescuers finally found Jesse after seeing images of handprints on a pipe. A crew of sanitation workers hurried to the area and opened a manhole.

“The first thing they heard was ‘Help!’” said Adel Hagekhalil, an official with the Los Angeles sanitation department.

The crew lowered down a long hose to Jesse, who was about three meters deep in the pipe. The boy held onto the line while workers pulled him up.

By the time workers found Jesse, about 700 meters of pipes had been inspected during a 12-hour period.

Jesse was found less than two kilometers from where he fell in. He was taken to a hospital for a full physical examination and to be reunited with his family.

More than 100 people took part in the search for Jesse. In addition to the major rescue effort, Humphrey credited the boy for being able to survive.

Not only did he survive being pushed through sewage moving at speeds of 24 kilometers an hour, Jesse was able to find a small area of breathable air and wait there until he was found, officials said.

“Many would call it miraculous,” Humphrey said of Jesse’s survival. He added that the chances of someone surviving such an event are low.

Los Angeles Mayor Eric Garcetti was among those closely watching the rescue effort.

On Twitter, Garcetti praised rescuers and thanked Jesse’s family for their “patience and optimism” during the frightening experience.