NEW YORK — Mets pitcher Jacob deGrom will undergo season-ending surgery to repair the ulnar nerve in his right elbow later this week.

The starter had felt numbness in two of his fingers before being shut down after his Sept. 1 start, and felt pain Friday while throwing a ball into the infield as he shagged fly balls that day.

He finishes the season with a 7-8 record and 3.04 ERA.

DeGrom said the surgery would require approximately three months of recovery time and that he would be ready for spring training.

ATHLETICS: Right-hander Sonny Gray (strained right forearm) threw a bullpen session and if all goes well, the Oakland ace will face hitters in his next step of rehab.

The team is still hopeful of getting Gray into a game before the end of the season.

CUBS: Right-hander Pedro Strop is set to be activated off the disabled list Friday, solidifying Chicago’s bullpen for the playoffs.

Manager Joe Maddon said Strop would pitch Friday against St. Louis.

The Cubs plan to give Strop five appearances before the NL Central champions begin the postseason on Oct. 7.

Strop and Hector Rondon figure to share seventh- and eighth-inning duties for the Cubs to set up closer Aroldis Chapman. The 31-year-old Strop has a 2.89 ERA in his 50 appearances this season.

TIGERS: Detroit kept second baseman Ian Kinsler and designated hitter Victor Martinez out of the lineup Tuesday at Minnesota. Both have injuries stemming from being hit by pitches in their previous game.

Manager Brad Ausmus said Kinsler still felt “a little foggy” two days after a beaning by Cleveland right-hander Trevor Bauer knocked his helmet off and triggered concussion-like symptoms.

Martinez was also hit by Bauer in the same inning on the knee, which is still purple and swollen.

PIRATES: Catcher Chris Stewart had arthroscopic surgery on his left knee and is expected to be out 6-to-8 weeks.

The 34-year-old catcher had been on the disabled list since Sept. 13 with left knee discomfort. He was batting .214 in 34 games.