The Diamondbacks have made a massive move to upgrade their offense, acquiring outfielder J.D. Martinez from the Tigers in exchange for infield prospects Dawel Lugo, Sergio Alcantara and Jose King. Both teams have announced the deal. There’s reportedly no cash changing hands in the deal, so the D-backs are on the hook for the $4.82MM that remains on Martinez’s $11.75MM salary.

In acquiring Martinez, the D-backs will be adding the very best rental bat on the market. The 29-year-old missed the first six weeks of the season due to a sprained ligament in his foot but has stormed back into the lineup with a .305/.388/.630 batting line and 16 homers through 232 plate appearances in 57 games. Arizona currently has Yasmany Tomas on the shelf and has been relying upon Daniel Descalso and Chris Herrmann to take at-bats in left field.

[Related: Updated Detroit Tigers depth chart and Arizona Diamondbacks depth chart]

By picking up Martinez, the Snakes will not only be massively upgrading their lineup, they’ll also be preventing one of their top division rivals and a potential Wild Card opponent, the Rockies, from acquiring the slugger. Colorado had also reportedly expressed interest in Martinez, but he’ll now slot into a D-backs lineup that already features the likes of Paul Goldschmidt, Jake Lamb, A.J. Pollock and David Peralta. Beyond that, though, the D-backs will add a drastically needed upgrade against left-handed pitching. Arizona ranks last in the Majors with a 65 wRC+ against lefties, and Martinez’s right-handed bat will be a significant boost.

From a defensive standpoint, Martinez won’t do the D-backs many favors, as he’s rated poorly in right field over the past couple of seasons, perhaps in part due to his foot troubles. (Martinez had graded out quite well in right as recently as 2015.) Then again, Tomas has regularly graded out as one of the game’s worst defenders in left field, while Descalso is an infielder that has been playing left out of necessity.

With Martinez set to be a free agent this offseason, the trade stands to benefit him as well. Because he’s been moved, he’ll no longer be eligible to receive a qualifying offer when the season is up, which should only strengthen his case on the open market.

Of the prospects in the deal, Lugo comes with the most fanfare. He entered the season ranked fourth among D-backs farmhands, according to Jim Callis and Jonathan Mayo of MLB.com. The 22-year-old is hitting .282/.325/.428 with seven homers, 21 doubles and four triples through 369 plate appearances in Double-A despite being a couple of years younger than the average age of his competition. He’s played shortstop and third base throughout his minor league career. Callis and Mayo note that he could project as a utility player, but he’s made enough strides recently that a future as a regular isn’t out of the question. Given his inclusion in the deal, the Tigers likely view Lugo as a potential regular at either one of those two positions.

Alcantara, also a middle infielder, ranked 15th among Arizona prospects on that same list prior to the season. He’s off to a .279/.344/.362 batting line with three homers, 15 doubles, a pair triples and 11 steals (albeit in 21 tries) in 378 PAs at Class-A Advanced. Also like Lugo, he’s rather young for his level, having turned 21 just last week. Callis and Mayo praise him as an outstanding defender and labeling him a “no-doubt-about-it shortstop.” He has the strongest arm in Arizona’s system, they add, and his glovework is so strong that he needn’t develop much as a hitter to be an everyday player in the Majors.

King, the youngest of the bunch at 18, recently opened his season in the Rookie-level Arizona League after spending the 2016 season in the Dominican Summer League. Baseball America’s Ben Badler ranked King among the best prospects in the DSL, praising his plus-plus speed and noting that he has 50-steal potential to go along with a compact swing and good bat speed. King is also an up-the-middle player and has split his time between shortstop and second base, though Badler notes that his slightly below average arm makes him a better fit at second base rather than shortstop.

Jon Morosi of MLB.com first said the two sides were close to a deal (Twitter link). Jeff Passan of Yahoo Sports reported the deal was in place (on Twitter). Jon Heyman of FanRag and Ken Rosenthal of FOX Sports/MLB Network noted that the D-backs were sending multiple prospects to Detroit (Twitter links). Nick Piecoro of the Arizona Republic tweeted the prospects that were in the deal. Rosenthal tweeted that there’s no cash changing hands in the deal.