Finally, Matt Harvey removed the mask. He stood in front of his locker in a closed clubhouse, and for about 15 minutes Tuesday afternoon he walked his teammates point by point through the missteps that led to the most embarrassing episode of his career.

“He was on the verge of tears,” one observer said.

This was no longer the invincible Dark Knight — an illusion he had carefully crafted all these years — but a humiliated colleague who sought to make amends for his latest mistake. He partied through the night on Cinco de Mayo, then chased that binge with a Saturday morning round of golf, sapping him of the energy to show up to work that afternoon.

Then Harvey ignored team protocol by failing to notify manager Terry Collins or trainer Ray Ramirez about what he called a migraine headache that left him in no condition to pitch Sunday.

“I put myself in a bad place to be ready for showing up to a ballgame,” a contrite Harvey said later Tuesday at a news conference. “That is my responsibility. I take full blame for that and I’ve apologized to my teammates, I’ve apologized to the coaches, and I’m doing everything in my power so that never happens again.”

The Mets have heard this before, of course. Just before the playoffs in 2015, when he was several hours late for the team’s workout, Harvey gave his word that he never would allow his professionalism to come into question again.

advertisement | advertise on newsday

But that next spring, Harvey was late to an exhibition game in Las Vegas, an incident that did not come to light until much later. He had no such luck with his latest gaffe. He served a three-game suspension, forfeited $80,000 in pay, and endured a public deconstruction that played out over the gossip pages.

“People make mistakes,” Harvey said when questioned about his credibility after yet another misstep. “I’ve made another mistake. There are things that I’ve realized in the last couple of days that I need to be doing or should not be doing. One of those that I should be doing is putting myself in a better place to perform physically and be accountable for my work. That’s something that I’m committing to.”

Despite threats from Harvey’s camp about a grievance, the righthander himself seemed to cool on the idea. Instead, he insisted on taking the blame for his no-show.

Mets videos

“I understand everybody’s anger, or the organization doing what they did,” said Harvey (2-2, 5.14 ERA), who starts Friday in Milwaukee. “I completely understand. It’s me who takes full blame for that. It’s me who needs to fix it and move forward, and make sure it never happens again.”

Harvey, 28, violated not only team guidelines but also his own “48-hour rule” of refraining from partying before a start. After a welfare check by the Mets at his home on Saturday, he arrived Sunday morning at Citi Field “in no condition to pitch,” a source said. Harvey was directed straight to the manager’s office. Waiting for him were furious members of the team brass.

“Everybody deserves a second chance,” said Collins, who grew emotional when he recounted a supportive text to Harvey sent by former teammate Bartolo Colon.

Collins hoped that the suspension gave Harvey a chance to reflect. He also praised him for insisting upon addressing the team as a group and then facing reporters afterward.

Those who witnessed the clubhouse mea culpa took it as genuine and heartfelt. Neil Walker said Harvey “understands what he needs to do to be a better teammate,” while Jay Bruce insisted “there’s no grudges, there’s no lasting effects.”

advertisement | advertise on newsday

Among teammates, the most striking aspect of Harvey’s apology was its honesty. In his speech, he directly tackled his need for renewed professionalism, an especially touchy subject for players who are wired to perform regardless of their troubles off the field.

“It’s not easy going into a clubhouse having to deal with an apology like that for your actions,” Harvey said. “It’s something I don’t want to have to do again. I certainly have felt terrible the last couple of days for what I put myself through, for what I put this organization through. The last thing I ever want to do is do that again.”