The Cubs and Mets were connected in trade rumors for more than a month, and the two sides came together on a deal right before Tuesday's 5 p.m. deadline.
The Cubs traded reliever Mychal Givens to New York for minor-league right-hander Saúl González.
"The Cubs have been first class with me, the organization," Givens said after the trade. "They’ve been doing a great job with their push of rebuilding.
"It’s been a great opportunity to play here. The fans have been a great opportunity to play for."
Givens, who signed a one-year deal in March with a mutual option for 2023, has a 2.66 ERA in 40 appearances this season.
He hasn't allowed an earned run over his last 16 appearances, dating back to June 16, a span covering 17 1/3 innings.
González, 22, has a 2.81 ERA in 14 appearances (one start) in low-A this season. He's struck out 29 with seven walks in 25 2/3 innings.
It's the third straight trade deadline Givens has been dealt. The Orioles traded him to the Rockies in 2020, and the Rockies to the Reds last summer.
He said his focus was on the Cubs in recent weeks with the deadline looming and controlling what he can control.
“Controlling that I put on the Cubbies uniform and get called on and go try to win ballgames for the Cubbies right now,” Givens said late last month.
“If I get traded, I'll put on that uniform and try to win ballgames for them. Right now, I’m not focused on the trade deadline or anything, all the rumors, anything like that.
“I'm focused on today and the next few days, whatever I need to do to win the ballgame.”
Contributing from St. Louis: Gordon Wittenmyer