The West Indies were scenting victory in the first Test against New Zealand after making two key breakthroughs towards the end of the fourth day in Antigua.
New Zealand began their second innings facing a fight to avoid defeat after conceding a 171-run first-innings deficit, but they looked on course to achieve just that as Martin Guptill and Brendon McCullum took them up to 170 for one in the final session.
However, Guptill (67) and McCullum (84) both fell before the end as New Zealand closed on 199 for three - a lead of just 28 heading into the final day.
Spinner Sunil Narine broke the 123-run second-wicket partnership when he had opener Guptill caught by Assad Fudadin at short leg.
That was Narine's seventh victim of the match, having earlier added Daniel Flynn (20) to his maiden five-wicket Test haul from the first innings.
Kemar Roach then bowled McCullum 16 runs short of what would have been a seventh Test century, leading to New Zealand sending out nightwatchman Neil Wagner (four not out) to join captain Ross Taylor (11no) for the closing overs.
Test debutant Wagner had also performed nightwatchman duties in the first innings after the tourists had lost the wickets of Guptill and Taylor when well-set late on day one.
Earlier today, the West Indies added a further 80 runs to their first-innings advantage before being bowled out for 522 in the morning session.
Starting the day on 442 for six in their reply to the Black Caps' 351 all out, the home side pushed on with overnight pair Narsingh Deonarine and captain Darren Sammy doing most of the damage.
Deonarine moved from 54 to 79 before he was bowled by Chris Martin with the total on 497 and then, after Narine had come and gone for four, the big-hitting Sammy made exactly 50 - his third Test half-century - with four fours and three sixes.
Sammy was the penultimate man out, falling caught and bowled to Daniel Vettori with the score on 516, before Doug Bracewell trapped Ravi Rampaul lbw for one to wrap up the innings and bring about the lunch interval.