A captain's century from Tom Latham has guided the Blackcaps home to wrap up their one-day series against Bangladesh at Christchurch's Hagley Oval.
Chasing 272 for victory, Latham arrived at the crease with his side in all sorts of trouble, but produced a brilliant innings that he would've dreamed of to bring up his fifth ODI century.
A much-improved performance from the Tigers pushed the Blackcaps all the way, but Latham was just too good, guiding his side home to win by five wickets in the first ever day-nighter at the venue.
Standing in for the injured Kane Williamson, Latham won his second successive toss and had no hesitation sending in a Bangladesh side, who were low on confidence, after a poor showing in the opening game at Dunedin.
When Liton Das (0 off four) was caught in just the second over, it looked like more of the same, but the Tigers fought back and showed resilience.
The tourists were making an emotional return to Hagley, where they were supposed to play New Zealand in the final test of their 2019 tour, but the match was abandoned, after Bangladesh players and staff narrowly avoided the Al Noor Mosque during the Christchurch shootings.
Captain Tamim Iqbal (78 off 108) and Soumya Sarkar (32 off 46 balls) combined for 81-run partnership to put their side in control.
Even when Soumya went, stumped off the bowling of Mitchell Santner (2/51), Mushfiqur Rahim (34 off 59) continued the momentum.
A moment of controversy came in the 15th over, when Iqbal looked like he was caught and bowled by Kyle Jamieson (1/36). Sent upstairs as a clean catch, the third umpire strangely ruled the big quick wasn't in full control of the ball.
Iqbal made the Kiwis pay for that second life, as he upped the scoring rate to have the visitors on track for a big score, before a moment of brilliance saw the skipper go.
Jimmy Neesham (0/73) pulled out some soccer skills that Lionel Messi would've been proud of to send the Tigers skipper on his way, run out.
The tourists didn't slow down, as Mohammad Mithun (73 off 57) produced the performance of the innings, with a range of shots to see his side through to 271/6.
In reply, the Blackcaps were up against it, as they needed a record chase for Hagley Oval to wrap up the series.
The hosts didn't start well, with Martin Guptill (20 off 24), Henry Nicholls (13 off 18) and Will Young (1 off 7) all gone early, and their team in all sorts of trouble at 53/3.
But the key fourth-wicket partnership between Tom Latham (110 off 108) and Devon Conway (72 off 93) put on 113 to ease any Kiwi nerves.
Conway has taken to international cricket like a duck to water and continued his brilliant form this summer to bring up a maiden ODI fifty, but Bangladesh got a lifeline, when Iqbal produced a brilliant runout to send the Kiwi No.3 on his way.
The visitors will look back on overs 36-38, when they put down three regulation catches, including the Kiwi skipper on 58 and Neesham on three.
The tourist then mixed in poor fielding and an 18-run over that swung the game in the Kiwis' favour.
From then on, the home side was on top, with Neesham (30 off 34) and Latham guiding their them to a series victory with 10 balls to spare.
The Tigers were better than three days earlier, but not enough claim their first victory on these shores, adding to their dreadful record in New Zealand with 28 straight losses in all formats.
Blackcaps 275/5 (Latham 110, Conway 72, Neesham 30, Mahedi 2/42) Bangladesh 271/6 (Iqbal 78, Mithun 73, Mushfiqur 34, Santner 2/51)
Join us on Friday at 11am for the third ODI between the Blackcaps and Bangladesh.