It is too early to know whether this afternoon's shooting in Papakura's town centre is linked to ongoing gang tensions in Auckland, police say.
A man has been taken to hospital with critical injuries after the incident on Great South Road, near the District Court.
Police were called to the firearms incident on Great South Rd just before 1pm. Papakura police station is next door to the courthouse.
The person has been taken to hospital.
At least eight armed officers guarded the scene for a number of hours and speaking to people inside the bar next door to the courthouse.
Inspector Matt Hoyes said the situation may have been upsetting for people in the community.
Officers were working hard to understand what had happened and to locate everyone involved, he said.
There would be an increased police presence in the area as enquiries were carried out, Hoyes said.
Nearby Unichem pharmacy manager Devika Sharma said she did not hear the shooting, but looked outside and saw a man lying on the ground outside the courthouse being treated by paramedics.
Another woman who worked 50 metres from the court said she did not hear shots fired.
But customers soon told her there were a lot of police gathered nearby.
Police had shut off a stretch in the centre of Papakura town, on Great South Rd, and were armed with guns, she said.
They were turning cars away at a roundabout outside the court.
The woman said it was "scary" and "a surprise".
Another woman who worked across the roundabout from the court said she saw a man being pulled into an ambulance on a stretcher.
She and co-workers walked outside when they heard sirens, and saw police and ambulances rushing to the court, and a police helicopter hovering above.
The woman said she and her colleagues did not hear any gunshots "whatsoever" and it was "quite strange".
The shooting "was a bit of a worry", she said.
Motorists and the public were asked to avoid the area, as cordons were in place.