A teenager who planned a violent armed attack on their South Island school was prevented because people took their concerns to authorities.
A police raid on a teenager's house uncovered a military-style semi-automatic rifle, modified shotgun and three explosive devices in their bedroom.
Police also found sketches of the then-17-year-old's Tasman-area school layout with targets marked, objectionable imagery of children, and a letter addressed to "investigators" in which the teen identified as a terrorist.
The raid was carried out in 2018, but details have only now been released.
The teenager, whose identity is suppressed, pleaded guilty to a series of charges, including unlawful possession of explosives, firearms and restricted weapons. In December last year they were sentenced to two years of intensive supervision for those offences and an offence against the Films, Videos and Publications Act.
Police say they received tips the teenager had shared pictures holding a shotgun and posted extremist and inflammatory social media messages, and referred to blowing up a school and executing a shooting, court documents show.
Assistant Commissioner Mike Johnson said the complaints were taken extremely seriously.
"The work of a number of investigative staff enabled police to make an arrest and defuse any threat to the community."
Investigators described the teen's activities as especially disturbing because the plans were not only documented, but the teen had collected the weapons, clothing, knives and ammunition needed to carry out the plans.
The teen had a firearms licence allowing them to own recreational firearms and ammunition. But the modified AR 15 military-style semi-automatic rifle found in the gun locker in their bedroom, which they had the key to, required licence endorsements they didn't have.
The teen admitted to owning the improvised bombs found in their bedroom, which Army disposal experts said could have caused serious injury.
"The case highlights the significant value of information provided by the public and we thank all those who reported their concerns to police," Johnson says.
"It also demonstrates how important it is for parents and caregivers to keep a close eye on what young people are doing online."