A police inspector organised a mock arrest of a teenager, had him locked in a police cell and threatened him with a charge of rape if he didn't leave the country, the Crown says.
Inspector Hurimoana Dennis and Sergeant Vaughan Perry are on trial at the High Court in Auckland where they have denied charges of kidnapping.
Crown prosecutor Brian Dickey said Mr Dennis wanted to help a family but he over-stepped the mark.
"So the Crown says to you, this is a pretty serious case of the abuse of that power - of the New Zealand police force, of the uniform and, of course, the rank."
Mr Dickey said the family of the 17-year-old didn't approve of his 15-year-old girlfriend. That caused a rift between the young man and his family and he ended up staying at the home of his girlfriend.
There were arguments between the families, one of which boiled over into a nearby public reserve and the police were called.
One of the officers who showed up was Inspector Hurimoana Dennis - a friend of the 17-year-old's family.
That's when, as Mr Dickey put it, things "blew up".
Later, police were again called in, this time by the 17-year-old's mother, who laid a complaint against her own son, alleging he was having a sexual relationship with a minor - his 15-year-old girlfriend.
"Look, it's dubious to propose that she did so out of concern for the victim in the matter, which of course is the underage girl. She did so for her own reasons," Mr Dickey said.
The investigation concluded no charges should be laid and the senior detective told the 17-year-old the outcome.
But Mr Dickey said Mr Dennis didn't let the matter end there. He had a constable pick the 17-year-old up and bring him to the Auckland central police station, where his mother and grandfather were waiting in an interview room.
Mr Dickey said the 17-year-old was told he could either stay in New Zealand and be charged with rape or leave and start a new life in Australia.
"The inspector told him, he would take him down to the police cells and charge him with rape and that he would be held in the cells overnight and he would go to the court the following day."
Mr Dickey said Sergeant Vaughan Perry took the young man through the process and included having his details entered into the computer, having his clothes and shoes removed and being given a yellow-coloured wrist band, which he was told was a tracking device.
He was then put in a police cell - a cell the jury will visit tomorrow - before telling Mr Dennis he would move to Australia.
But once there, the young man had his passport taken off him by family members. It was some time until he could convince them to return his passport, on the pretext of wanting to open a bank account.
Instead, the young teenager returned to New Zealand, touching down at Auckland International Airport on a direct flight from Sydney.
But Mr Dennis was told by family members that the teenager was on his way back and alerted his colleagues at the airport.
"He was then ushered off the aircraft by airline staff and he was met by constables Postlewaight and Heenan at the gate...The constables were both in uniforms and [had] side arms with the glock pistol."
Mr Dickey said the young man believed he had no choice but to do what the officers asked of him.
That included attending another meeting with his family, and Mr Dennis, where he was told by Mr Dennis that he was not to see his girlfriend and not to return until after his eighteenth birthday.
Unbeknownst to him, his girlfriend's family were only metres away in the arrival lounge, still waiting for him to appear. Instead of reunion, the teenager was put back on the next flight to Sydney.
But Mr Dennis' lawyer Steve Bonnar said the teenager's version of events was far from the truth.
Mr Bonnar said his client was an experienced police officer who was only trying to re-establish the young man's ties with his family.
"One of his strategic goals was to keep young Māori men out of the system and one of the roles of an iwi liaison officer, which is what he was, is to get involved when necessary."
The young man was breaking the law by having sex with a minor and Mr Dennis was only trying to stop him becoming another statistic, he said.
Mr Perry's lawyer, Todd Simmonds, said his client was following the directions of two senior police officers and believed the teenager was taking part in a role-play and had given his consent.
The trial is due to hear from 25 witnesses and is set down for up to four weeks.