A pack of baboons momentarily caused chaos in Sydney on Tuesday, breaking out of captivity and roaming around the city's streets before being recaptured.

The animals escaped while being transported to a research facility at the Royal Prince Alfred Hospital, which borders the University of Sydney, CNN affiliate SBS reported.

Police were called to the Camperdown area of the city at about 5:30 p.m. (1:30 a.m. ET).

Videos posted on social media showed three baboons running along sidewalks, to the bemusement of locals.

But New South Wales Police said they had recaptured the escapees shortly before 7 p.m. (3 a.m. ET).

"This is not a Mandrill!" the police said on Twitter.

"Earlier this afternoon, a troop of baboons escaped from a facility and were going bananas in Camperdown. Police and wildlife handlers now have the situation under control, so please let them do their job and don't be tempted to pry, mates," the force wrote.

A spokesperson for the force added that "the baboons are currently contained" and there is no risk to the public.

It is not the first time baboons have managed to escape their confines.

In 2018 four baboons escaped a biomedical research lab in San Antonio by climbing a 55-gallon barrel and jumping out of their enclosure.

Within 20 to 30 minutes, an animal care team from the Southwest National Primate Research Center had rounded up the rogue animals and returned them to their enclosure.