The suspects ran away emptyhanded from the Chartwell Shopping Centre in Hamilton around 2:30 a.m. after only one of the bombs exploded and a second partially detonated, police said. The ATM was only slightly damaged.
Security footage showed the suspects walking up to the ATM with two packages containing the bombs and tried to detonate them simultaneously, according to police.
Police inspector Andrea McBeth said the "unsophisticated" pipe bombs were each about 30 centimeters (1 foot) long and not very powerful, calling the incident “nothing more than an attack on an ATM machine,” the New Zealand Herald reported.
Yolanda Julius, who lives across the street from the mall, told the paper that a loud “boom” woke her and her husband up around 2:45 a.m.
"We got out of bed because we thought it was an accident and saw two guys running away in the car park," Julius said.
Authorities temporarily closed the mall and some nearby streets until they determined the area was safe. A military bomb disposal team was called to the site and disposed of the five unexploded bombs.
Police said they were in the early stages of the investigation and did not release descriptions of the suspects.
The Associated Press contributed to this report.