New York also picked up a bullpen arm, left-hander Joely Rodriguez, and cash in the deal, but Gallo is the main event. He’s 27 and has had two 40-home-run seasons in his career. He also is controllable through the 2022 season.

FAGAN: The worst thing the Mets could do at the deadline

Texas, meanwhile, is buying a package of prospects with its top trade asset, including a close-to-ready rotation piece. The Rangers acquired four minor leaguers: right-hander Glenn Otto, infielders Ezequiel Duran and Josh Smith and infielder/outfielder Trevor Hauver.

Sporting News grades the trade between New York and Texas.

Joey Gallo trade grades

Yankees: A

New York was lacking a left-handed bat to complement right-handed sluggers Aaron Judge, Giancarlo Stanton and Gary Sanchez. Gallo will fill the role just fine.

There’s no mystery to his game: it’s three true outcomes. He homers (25 through Wednesday), walks (MLB-high 74) and strikes out (125, for a career-low 32.2 percent K rate) a lot. The walks keep his OBP high (.379), so he fits right in with the Yankees’ offensive approach.

Gallo won a Gold Glove in right field last year, but he will need to switch positions in New York with Judge already there. His athletic ability and arm will play anywhere in the outfield. He spent time in left and center for the Rangers, and the Yankees have been running Brett Gardner, Greg Allen, Estevan Florial and Ryan LaMarre out there of late. 

There’s also a luxury tax component to the deal. Gallo is making a reported $6.2 million this year, Rodriguez is making $2.5 million, and the Yankees are close to a threshold they do not want to exceed. They cleared some space for the Gallo pickup Tuesday by trading relievers Justin Wilson ($2.85 million) and Luis Cessa ($1.05 million) to the Reds for a player to be named. The cash the Rangers sent to New York as part of the Gallo deal also will help.

Rodriguez, 29, has compiled a 5.93 ERA in 27 1/3 innings, but his FIP is 3.70 and his opponents’ BABIP is .363, which indicates possible bad luck. His 9.4 walk rate is a career low and his 63.1 ground-ball rate is a career high.

Rangers: B

Texas collected quantity in the trade, but is the quality high enough? National writers and analysts believe so; they say the Yankees’ farm system is so deep that New York was able to deal players who were ranked no higher than 14th (Smith) in MLB Pipeline’s Yankees preseason top 30. Duran was 15th, Hauver was 23rd and Otto was 28th.

Otto, 25, is closest to making the majors as he was promoted to Triple-A Scranton/Wilkes-Barre in mid-July. His arm figures to play, based on his 115:17 strikeout-to-walk ratio in the minors this year. He also has kept the ball in the yard (six home runs allowed in 75 2/3 innings). 

The rest of the group was playing in Single-A. Duran, 22, had a .907 OPS and slugged 12 home runs for high-A Hudson Valley. Smith, 23, was recently promoted to Hudson Valley. He has been an on-base machine (.448 OBP) and hit for power (nine home runs) in limited action (39 games). Hauver, 22, had a .445 on-base percentage in 66 games for low-A Tampa in his first professional season. 

The Rangers can add even more prospects at the deadline because they still have assets to move, beginning with No. 1 starter Kyle Gibson and closer Ian Kennedy.