A teenager, who had a sudden desire to rob, arranged to meet a man via an app on his phone and then attacked him in his car.
The victim, a man aged 58, had to fight for his life.
Mold Crown Court heard how the victim thought that he was going to die.
He described it like something out of a movie when the teenager Reece Charles Wyn, 18, produced a beer bottle, put it to his neck, and demanded money.
Wynne, of Bryn y Ffynnon Farm, Alltami Road, Sychyn near Mold, who admitted robbery at an earlier hearing, was sentenced to two and a half years youth custody.
The judge, Miss Recorder Gaynor Lloyd, said that after drinking with friends Wyn had an “urge to rob”
In order to fulfil that desire he used an app to meet someone – and the victim happened to be the person who lived nearest to him
Within 20 minutes they had arranged to meet, the victim picked him up, they went to his home and was then being driven back home when the attack happened.
At 9.45 p.m. he asked to be dropped off near Sychdyn and then robbed the driver out of the blue.