SAN DIEGO (AP)The New York Mets and Jose Quintana agreed to a $26 million, two-year contract on Wednesday, adding another veteran arm to the team’s rotation.

A person familiar with the negotiations confirmed the move to The Associated Press on condition of anonymity because the deal was pending a physical.

New York has been rebuilding its pitching staff following a playoff loss to San Diego in the wild-card round. Three members of its rotation became free agents this offseason, and the Mets also had several openings in their bullpen.

Ace right-hander Justin Verlander agreed to an $86.7 million, two-year contract with New York on Monday, a deal that was announced Wednesday. The Mets also acquired left-handed reliever Brooks Raley in a trade with Tampa Bay on Wednesday.

Quintana played for Pittsburgh and St. Louis last season, going 6-7 with a 2.93 ERA in 32 starts. The left-hander was terrific after he was traded to the Cardinals in August, posting a 2.01 ERA in 12 appearances for the NL Central champions.

Quintana also worked 5 1/3 scoreless innings for St. Louis in his lone playoff start, but the Cardinals were eliminated by Philadelphia.

Quintana, who turns 34 in January, broke into the majors with the Chicago White Sox in 2012. He is 89-87 with a 3.75 ERA in 315 games, including 289 starts, over 11 seasons with six teams.

He earned his lone All-Star selection in 2016, going 13-12 with a 3.20 ERA in 32 starts with the White Sox.

New York sent minor league lefty Keyshawn Askew to Tampa Bay for Raley, who went 1-2 with a 2.68 ERA and six saves in 60 appearances with the Rays this year.

Verlander gets $43,333,333 in each of the next two seasons, and his deal includes a conditional $35 million player option for 2025. He could exercise the option if he pitches at least 140 innngs in 2024 and an independent physical determines he does not have a right arm injury that would keep him from being on the 2025 active opening-day roster

He would earn $200,000 each for winning an MVP or Cy Young Award, $150,000 for finshing second in voting and $150,000 for third. He also would get $150,000 for World Series MVP, $100,000 for League Championship Series MVP and $100,000 for making the All-Star team.

Verlander gets a full no-trade provision, a hotel suite on road trips and the right to lease a luxury suite at Citi Field for home games.

Follow Jay Cohen at https://twitter.com/jcohenap

AP MLB: https://apnews.com/hub/mlb and https://twitter.com/AP-Sports