Rodriguez, 31, gets a $1.5 million salary next year, and the Red Sox's option is for $4.25 million with a $500,000 buyout.
He can earn $250,000 in performance bonuses each year for games pitched: $50,000 each for 30 and each additional 10 through 70. In 2023, he also can earn $800,000 in roster bonuses: $200,000 apiece for 30, 60, 90 and 120 active days.
Rodriguez's contract allows him to become a free agent when the deal expires.
The left-hander was 2-4 with a 4.47 ERA last season for the New York Mets, striking out 57 and walking 26 in 50⅓ innings while allowing three home runs.
Rodríguez is 5-9 with a 4.56 ERA in 157 relief appearances for the Philadelphia Phillies (2016-17), Texas Rangers (2020-21), New York Yankees (2021) and Mets (2022). He spent 2018 and '19 with the Chunichi Dragons of Japan's Central League.
In another move Wednesday, the Red Sox acquired infielder/outfielder Hoy Park in a trade with the Pittsburgh Pirates. The Red Sox sent minor league left-hander Inmer Lobo to Pittsburgh for Park, who was designated for assignment Tuesday when the Pirates claimed first baseman Lewin Diaz off waivers from Miami.
Park, a native of Seoul, South Korea, hit .216 (11-for-51) with two homers and six RBIs for Pittsburgh this season. He has appeared in 68 career big league games, batting .201 with five homers and 20 RBIs.
The Associated Press contributed to this report.