If his bid for freedom was to avoid getting the snip, it didn’t work.

The male baboon that led a daring escape at Royal Prince Alfred Hospital on Tuesday has had his vasectomy.

Watch the video above

NSW Health Minister Brad Hazzard confirmed in a Tweet on Thursday the primate had undergone successful surgery.

“Baboon ‘Houdini’ update: vasectomy has been completed this morning as planned,” Hazzard tweeted.

“Procedure went well. He is now sleeping/resting. His two female family members are relaxed and happy.”

More on 7NEWS.com.au

Police were called to a car park near Royal Prince Alfred Hospital in Camperdown around 5.30pm on Tuesday after reports of three baboons on the loose.

The trio was contained by police and medical experts before handlers from Taronga Zoo tranquillised them.

Health NSW has launched an investigation into the incident.