BOSTON — Bruins center David Krejci revealed Monday that he played the final quarter of Boston’s recently completed season with a nagging hip injury that will require surgery this offseason.

“It’s been bothering me for 20 or so games,” Krejci said during the team’s breakup-day media availability at TD Garden. “But we have a good medical staff here, and they got me through games, so I felt like I was still in decent shape to play games and help the team, and there’s been games where I’ve felt pretty good. So I was able to finish the season (and would have been) ready to play playoff games.”

Krejci missed nearly a month with a shoulder injury suffered two games before the NHL Winter Classic, then saw his production tail off over the second half of the season. He scored just six goals over his final 37 games after returning to the lineup and went without one in 21 of his last 23 contests.

The 29-year-old alternate captain did rack up 24 assists post-injury, however, and finished tied with frequent linemate Loui Eriksson for second on the team in scoring with 63 points (17 goals, 46 assists). Krejci played in 72 of the Bruins’ 82 games after being limited to 47 in 2014-15.

“I’m looking at it kind of two ways,” Krejci said. “One is, yeah, it’s been a nagging injury from last year and missing that half a season. And then this year, I felt maybe the best I ever felt my first 50 games, and then I missed some games because of my shoulder injury, and after I came back, it was never the same.

“And the hip, the nagging injury kind of kept coming back, and it got to the point that we’ve been talking surgery for a while now. So it was frustrating, but at the same time, I had this surgery about six years ago on my other leg and never felt better (than I did) after it. I’m looking forward to getting it done in the next week or two and be the player that I can be.”

Krejci said his last surgery carried with it a four-month recovery period. He expects to be back on the ice in time for Bruins training camp and plans to compete for his native Czech Republic in the 2016 World Cup of Hockey, which begins Sept. 17 in Toronto.

“Yeah, if everything goes like it should, then I should be back even before camp,” Krejci said.

Thumbnail photo via Jerome Miron/USA TODAY Sports Images

Thumbnail photo via Boston Bruins center David Krejci