Gettyimages 2152513862

NEW YORK — The Phillies’ lopsided game from the bottom of the second through the bottom of the eighth was the latest example of their depth and resilience.

With two runs in the ninth inning against Edwin Diaz, one of baseball’s electric powerhouses, the Phillies tied the game on a red-hot Bryson Stott’s solo home run and Alec Boehm’s groundout. Cody Clemens scored the tying run, pinch-hit for Edmundo Sosa and singled a batter after Stott’s homer.

Orion Kerker pitched back-to-back days for the first time this season and went 1-2-3 through the teeth of the Mets’ order in the bottom of the ninth, retiring Francisco Lindor, Pete Alonso and JD Martinez. Stott more heroics in more innings. Kerkering made it easier than it used to be.

Stott fell behind in an 0-2 count to Mets reliever Sean Reed-Foley in the top of the 10th but fought back to dig a sacrifice fly to deep right field. With the go-ahead run, Bryce Harper crossed the plate and Jose Alvarado gave the Mets a 5-4 win.

Manager Rob Thomson said: “It was a great win. “We’re going to keep winning games in different ways, getting contributions from all kinds of people. That’s who they are. They’re going to keep fighting, they’re going to keep fighting.”

You don’t think of Stott as a player who can carry an offense, but he basically has this past week. He has driven in 11 runs in his last eight games. He’s reached in 12 of his last 19 plate appearances, and narrowly missed three innings before doing it Monday night.

“That dude is a stick,” Marsh said. “He showed day-in and day-out last year.” It was only a matter of time before it started clicking and there is no better time than now.

“It started with Stotter. He set the tone for us and then we rallied and rallied behind him. Diaz is so talented. He’s like a genius, incredible talent, so close. It was big for us to get to him tonight.”

The 29-13 Phillies are unbeaten in a streak since April 23-24 at Cincinnati.

It was a surprising start from Christopher Sanchez, who threw just 10 pitches in a 1-2-3 first inning but needed 50 over the next four games. He allowed two runs in the bottom of the second and the third inning was a rollercoaster.

Sanchez plated the first four batters in the bottom of the third with a double, single and two walks. With the bases loaded at first, Brett Batey struck out and gingerly walked off the mound to have his arm checked by a trainer. From time to time, he would have a pimple that would pop up and need to be massaged. Sanchez responded by hitting three straight on nine pitches.

After seemingly never getting out of third, Sanchez pitched a 1-2-3 fourth and was retired in the top of the fifth, giving himself a “quality start” if not for a two-out error. In the sixth. The Phillies needed the extra length because Spencer Turnbull, the only real long man in Reupen, pitched in relief on Sunday, so he probably won’t be available Monday because he’s not used to going back.

“The biggest thing I’m proud of is overcoming adversity,” Thompson said. “He got into trouble, long innings in the second and third, and he just sat back and kept humming. That’s the growth of this guy. He’s really something.”

“Loading the bases and getting out of it with those three strikes saved the game,” Marsh added.

The Phillies were again out of the starting lineup Monday with Kyle Schwarber (lower back soreness) and JT Rilmuto (right knee soreness). Trea Turner won’t miss another month with hamstring strain. The Phillies have done an amazing job of playing through injuries to key players like Harper, Rhys Hoskins, Alvarado and Ranger Suarez lately, but at the same time they’ve been without their top three players.

Schwarber pinch hit in the ninth inning. He will be back in action Tuesday afternoon, Thompson said. Realmuto is day-to-day and Tuesday’s stage is TBD.

In the finale of the first game of this two-game home-and-home series, the Phillies have Aaron Nola on the mound at 1:10 p.m. The first right-hander the Phillies faced in five games, Jose Buto, left for the Mets.

“I don’t think we have anybody (left) off the bench except JT,” Stott said. “The bullpen guys came in and did their job, threw strikes, got shutouts. Sanchez going those five innings and a couple outs was huge. It was a great performance by him and his guys off the bench.”