In May when Yoenis Cespedes fractured his right ankle at his Port St. Lucie ranch, Mets GM Brodie Van Wagenen described a “violent” fall but provided no context how the fall occurred.

The same was true last month when it was revealed that Cespedes and the Mets agreed to a restructuring of his contract that — among other things — will cost him a minimum of $15.7 million and could cost him as much as almost $30 million.

The Post has learned all involved parties agreed that Cespedes was injured on the ranch stepping into a hole after an interaction with a wild boar.

CESPEDES BASE PAY CUT FROM $29.5M TO $6M

According to multiple people who were informed of the incident, Cespedes has traps on his ranch for a variety of reasons, including to keep boars away from people. But one boar was removed from a trap — perhaps by Cespedes — and either charged toward Cespedes or startled him, causing Cespedes to step into a hole. Cespedes suffered the fractured ankle at a time when he was recovering from surgery to both heels that already was jeopardizing his playing status in 2019. The ankle fracture guaranteed that he would not take an at-bat last season.

Cespedes reported the injury to the Mets, including immediately that he was trying to sidestep a boar. Mets officials and representatives for Cespedes went to the ranch the following day and came away believing essentially that is what occurred. Officials from both the Commissioners Office and the Players Association visited the ranch at a later date and also confirmed that version of how Cespedes was injured.

The Commissioners Office and Players Association became involved once it became clear the Mets were withholding Cespedes’ 2019 pay and were considering an attempt to make the remainder of his pact a non-guaranteed contract.

Kyle Thousand, Cespedes’ agent, declined comment to The Post on Friday afternoon.

The standard language in a player’s contract prohibits the player from participating in a wide range of athletic activities. Guaranteed contracts like Cespedes’ forbid additional activities to mitigate risk. While it is not publicly known if the Mets and Cespedes agreed to specific language that would have made potentially dangerous activities on his ranch a violation of his contract, language in a second Mets player’s contract of recent vintage prohibited “any acts, activities, or sports involving a substantial risk of personal injury.” Engaging with a wild boar at close range would potentially qualify as such an act.

Furthermore, broad precedent existed that would have imperiled the rest of Cespedes’ guaranteed money. In February 1994, Ron Gant broke the fibula and tibia in his right leg in a dirt bike accident on private property. A month later the Braves put Gant on unconditional-release waivers and owed him just 30 days (about $907,000) of his $5.5 million salary (at the time the largest one-year contract in history).

In January 2004, Aaron Boone tore his left ACL while playing pickup basketball. The Yankees contended that Boone was in violation of his contract and paid him 30 days termination pay (about $918,000) of his $5.75 million contract.

The Mets could have tried for the same with Cespedes. And Cespedes could have fought to have every penny paid to him. That a compromise was brokered among MLB, the union, the Mets and Cespedes’ camp suggests both the Mets and Cespedes’ camp were concerned about losing their argument before the independent arbitrator — particularly Cespedes, considering how much in guaranteed money he has forfeited.

CLICK HERE TO GET THE FOX NEWS APP

Cespedes received just $22.8 million of what was supposed to be $29 million in salary last season. For 2020, the guaranteed portion of his contract was reduced from $29.5 million to $6 million. His salary rises to $11 million if Cespedes makes the Opening Day roster _ or if he goes on the injured list at that juncture for an ailment that does not involve his feet or ankle _ and gets prorated at that pay level if he joins the team any time after the season opener. Plate appearance bonuses could add another $9 million to Cespedes’ income.

Cespedes signed a four-year, $110 million contract after the 2016 season. He has played just 119 games since due to a variety of injuries.