Red Sox slugger David Ortiz has undergone a third surgery for complications resulting from being shot in his native Dominican Republic, the team said Thursday.

The 43-year-old retired All-Star went under the knife earlier this week — a month after he was mistakenly targeted by hitmen at the Dial Bar and Lounge in Santo Domingo.

“The operation was performed by Dr. David King at Massachusetts General Hospital. David is recovering well and is in good spirits,” the Red Sox said in a statement. “We continue to be incredibly appreciative of the kindness and compassion shown to David and to our entire family during this difficult time.”

The team didn’t elaborate on the specifics of Ortiz’s surgery.

The botched assassination left Ortiz shot in the back — with the bullet exiting through his stomach and striking his pal Jhoel López in the leg.

Authorities believe alleged mastermind Victor Hugo Gómez Vasquez had ordered the hit on his cousin and Ortiz’s friend, Sixto David Fernández, believing Fernández had snitched on him in a 2011 drug case.

Late last month, the beloved player, known as “Big Papi,” was moved out of the intensive care unit.

Fourteen suspects have been nabbed in connection with the shooting.